View: Temp_Column_Characteristics_View
View definition
`CREATE VIEW cdal.Temp_Column_Characteristics_View AS SELECT O.name AS TABLE_NAME , CASE O.type WHEN 'U' THEN 'BASE TABLE' WHEN 'V' THEN 'VIEW' END AS TABLE_TYPE , CV.COLUMN_NAME , CV.COLUMN_INDEX , CV.TYPE_NAME , CV.IS_AUTO_NUM , CV.COLUMN_PRECISION , CV.COLUMN_SCALE , CV.COLUMN_COLLATION , CV.IS_NULLABLE , CASE WHEN CV.IS_COMPUTED = 1 OR O.type = 'V' OR CV.IS_AUTO_NUM = 1 OR CV.TYPE_NAME = 'rowversion' OR CV.TYPE_NAME = 'timestamp' THEN 'DISALLOWED' WHEN CV.IS_NULLABLE = 0 AND CV.HAS_DEFAULT = 0 THEN 'REQUIRED' ELSE 'OPTIONAL' END AS ON_INSERT FROM tempdb.sys.objects AS O WITH ( NOLOCK ) INNER JOIN cdal.Temp_Columns_View CV WITH ( NOLOCK ) ON O.object_id = CV.object_id WHERE O.type IN ( 'U', 'V' ) AND O.is_ms_shipped = 0;`