We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
sb_helptext
1 parent dbb559f commit 169d79fCopy full SHA for 169d79f
CHANGELOG.md
@@ -1,4 +1,11 @@
1
2
+## v4.2.1
3
+
4
+#### Fixed
5
6
+* Guard against empty view definitions when `sb_helptext` fails silently. Fixes #337.
7
8
9
## v4.2.0
10
11
#### Added
lib/active_record/connection_adapters/sqlserver/schema_statements.rb
@@ -415,6 +415,7 @@ def table_name_or_views_table_name(table_name)
415
416
def views_real_column_name(table_name, column_name)
417
view_definition = schema_cache.view_information(table_name)[:VIEW_DEFINITION]
418
+ return column_name unless view_definition
419
match_data = view_definition.match(/([\w-]*)\s+as\s+#{column_name}/im)
420
match_data ? match_data[1] : column_name
421
end
0 commit comments