Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Updated join to include VIEWs along with TABLEs for determining the I…

…DENTITY column.
  • Loading branch information...
commit 77761086066a719738b8ad6ebc691aa1f1e52349 1 parent 1a5ce97
@Altonymous Altonymous authored
View
2  lib/active_record/connection_adapters/sqlserver/schema_statements.rb
@@ -191,7 +191,7 @@ def column_definitions(table_name)
INNER JOIN #{db_name_with_period}.sys.objects AS o
ON s.schema_id = o.schema_id
AND o.is_ms_shipped = 0
- AND o.type = 'U'
+ AND o.type IN ('U', 'V')
AND o.name = columns.TABLE_NAME
INNER JOIN #{db_name_with_period}.sys.columns AS c
ON o.object_id = c.object_id
Please sign in to comment.
Something went wrong with that request. Please try again.