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

Default column(s) for REFERENCES [DOC1] #15

Closed
firebird-automations opened this issue Sep 5, 2001 · 5 comments
Closed

Default column(s) for REFERENCES [DOC1] #15

firebird-automations opened this issue Sep 5, 2001 · 5 comments

Comments

@firebird-automations
Copy link

Submitted by: prenosil (prenosil)

SFID: 458863#⁠
Submitted By: prenosil

In Language Reference, there is written for REFERENCES
keyword used in CREATE TABLE and ALTER TABLE commands:

=====
<col_constraint> = [CONSTRAINT constraint] ...
REFERENCES other_table [( other_col [,
other_col ...])] ...

REFERENCES Specifies that the column values are
derived from column values in
another table; if you do not specify column names,
InterBase looks for
a column with the same name as the referencing column
in the
referenced table.

Current (and I think that correct) behaviour is that
if you do not specify column names, primary key
from referenced table is used.

@firebird-automations
Copy link
Author

Commented by: Alice F. Bird (firebirds)

Date: 2005-10-03 17:40
Sender: dimitr
Logged In: YES
user_id=61270

Our current behaviour is 100% standard compliant. I'm
assigning this issue to Paul Vinkenoog to ensure our doc
makers are aware about that.

@firebird-automations
Copy link
Author

Modified by: Alice F. Bird (firebirds)

description: SFID: 458863#⁠
Submitted By: prenosil

In Language Reference, there is written for REFERENCES
keyword used in CREATE TABLE and ALTER TABLE commands:

=====
<col_constraint> = [CONSTRAINT constraint] ...
REFERENCES other_table [( other_col [,
other_col ...])] ...

REFERENCES Specifies that the column values are
derived from column values in
another table; if you do not specify column names,
InterBase looks for
a column with the same name as the referencing column
in the
referenced table.

Current (and I think that correct) behaviour is that
if you do not specify column names, primary key
from referenced table is used.

=>

SFID: 458863#⁠
Submitted By: prenosil

In Language Reference, there is written for REFERENCES
keyword used in CREATE TABLE and ALTER TABLE commands:

=====
<col_constraint> = [CONSTRAINT constraint] ...
REFERENCES other_table [( other_col [,
other_col ...])] ...

REFERENCES Specifies that the column values are
derived from column values in
another table; if you do not specify column names,
InterBase looks for
a column with the same name as the referencing column
in the
referenced table.

Current (and I think that correct) behaviour is that
if you do not specify column names, primary key
from referenced table is used.

@firebird-automations
Copy link
Author

Commented by: @paulvink

Even in InterBase 6, an FK without explicit target column already referenced the PK of the target table.
So the IB 6 LangRef is wrong here.

I've documented the correct behaviour in the LangRefUpdates.

@firebird-automations
Copy link
Author

Modified by: @paulvink

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

resolution: Fixed [ 1 ]

@firebird-automations
Copy link
Author

Modified by: @paulvink

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

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

2 participants