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

Fix TypeError: Cannot visit Arel::SelectManager when executing a subquery with Arel #236

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

muryoimpl
Copy link

When executing a subquery using Arel, a TypeError: Cannot visit Arel::SelectManager is raised if Arel::SelectManager is called internally.

To fix this error, I have added a visit_Arel_SelectManager to arel_visitors_depth_first.rb and test. The implementation is based on https://github.com/rails/rails/blob/f6918a5b5d0b8c3a700513c2624cc195e0a78d14/activerecord/lib/arel/visitors/to_sql.rb#L358-L361

@muryoimpl
Copy link
Author

@microsoft-github-policy-service agree company="ASHITA-TEAM"

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

2 participants