Skip to content

Commit 12c4e4e

Browse files
committed
Merge commit 'vegantech/master'
2 parents 78458b4 + 47ac275 commit 12c4e4e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/active_record/connection_adapters/sqlserver_adapter.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -731,6 +731,11 @@ def tables(name = nil)
731731
end
732732
end
733733

734+
def table_exists?(table_name)
735+
#If the table is external, see if it has columns
736+
super(table_name) || (columns(table_name).size>0)
737+
end
738+
734739
def indexes(table_name, name = nil)
735740
ActiveRecord::Base.connection.instance_variable_get("@connection")["AutoCommit"] = false
736741
__indexes(table_name, name)

0 commit comments

Comments
 (0)