Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure 1 AS one for SQL Server with Calculations #30686

Merged
merged 1 commit into from Sep 23, 2017

Conversation

metaskills
Copy link
Contributor

@metaskills metaskills commented Sep 23, 2017

During the work done in #29848 a regression was caused for SQL Server where derived tables need to create references to column names. For example, this simple calculation example fails, with VS Code screenshot to latest SQL Server on Linux connection.

SELECT COUNT(*)
FROM ( SELECT 1 ) count

screen shot 2017-09-22 at 9 31 54 pm

The fix is simple, we can use 1 AS one which is even referenced in a const already but in another module. Open to alternatives if the usage is not ideal. Also, it would be super cool if this could be applied to 5-1-stable since v5.1.4 is now broken for us. Thanks so much for whomever's time on this too. Thanks y'all!!!

cc @kamipo

@rails-bot
Copy link

r? @pixeltrix

(@rails-bot has picked a reviewer for you, use r? to override)

@sgrif sgrif merged commit c371eef into rails:master Sep 23, 2017
kamipo pushed a commit that referenced this pull request Sep 26, 2017
Ensure `1 AS one` for SQL Server with Calculations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants