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

where clause with alias and/or table name [CORE884] #1277

Closed
firebird-automations opened this issue Jul 31, 2006 · 5 comments
Closed

where clause with alias and/or table name [CORE884] #1277

firebird-automations opened this issue Jul 31, 2006 · 5 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: Anderson Franco (anderson.franco)

The folow query runs fine in Firebird 1.5.2 and 1.0.3:

select * from table t where http://table.ID = 1

When you define an alias for the table and you use the table name instead the alias, firebird returns a SQL error code -206: 'Column unkown'

If you don't define an alias or if you use the alias, everyting is ok:

select * from table t where http://t.ID = 1
or
select * from table where http://table.ID = 1

@firebird-automations
Copy link
Collaborator Author

Commented by: @mkubecek

This is intended. See Release Notes, section Known Compatibility Issues / SQL Migration Issues / DML / Changed Ambiguity Rules.

@firebird-automations
Copy link
Collaborator Author

Commented by: Claudio Valderrama C. (robocop)

The behavior you observe is correct and in compliance with the SQL standard: once a table is given an alias, that alias is the only way to reference the table.

@firebird-automations
Copy link
Collaborator Author

Modified by: Claudio Valderrama C. (robocop)

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Won't Fix [ 2 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Workflow: jira [ 11109 ] => Firebird [ 14809 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant