--The sql is: SELECT c.TABLE_NAME tableName, c.COLUMN_NAME fieldName FROM INFORMATION_SCHEMA.COLUMNS c WITH (NOLOCK) WHERE c.TABLE_NAME IN ("Table1", "Table2",.....) AND columnproperty(object_id(c.TABLE_SCHEMA + '.' + c.TABLE_NAME),c.COLUMN_NAME, 'IsIdentity') <> 1 |
|