diff --git a/README.md b/README.md index 11e78cb5..928610b1 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ Easiest install is to use pip: ### Materializations - Table: - - Will be materialized as columns store index by default (requires SQL Server 2017 as least). To override specify: + - Will be materialized as columns store index by default (requires SQL Server 2017 as least). To override: {{ config( as_columnstore = false, @@ -44,10 +44,11 @@ Easiest install is to use pip: ### Sources ### Testing & documentation -- Unique: Is the only test tested so far. The rest will be tested and added if possible soon. - +- All tests supported - Docs ### Snapshots - Timestamp - Check + +But, all columns in source table needs to be set to allow NULL. If any column has a NOT NULL constraint, an error will be thrown. \ No newline at end of file diff --git a/dbt/include/sqlserver/macros/schema_tests.sql b/dbt/include/sqlserver/macros/schema_tests.sql index 17051113..c21c1418 100644 --- a/dbt/include/sqlserver/macros/schema_tests.sql +++ b/dbt/include/sqlserver/macros/schema_tests.sql @@ -6,7 +6,7 @@ select count(*) as validation_errors from ( select - {{ column_name }} + {{ column_name }} as validation_errors from {{ model }} where {{ column_name }} is not null