Timeline for FK relationships between schemas in azure SQL don't work
Current License: CC BY-SA 4.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jan 13, 2019 at 21:57 | vote | accept | Phil | ||
Jan 13, 2019 at 21:57 | history | edited | Aaron Bertrand | CC BY-SA 4.0 |
added 11 characters in body
|
Jan 13, 2019 at 21:55 | comment | added | Aaron Bertrand |
I don't mean the CREATE SCHEMA specifically, I mean changes to the schema in general - tables, constraints, etc. Sorry to be ambiguous. I would check what's there before you deploy the script, the order of the scripts in the dacpac, and the output of the schema compare. Not all schema compares are equal.
|
|
Jan 13, 2019 at 21:05 | comment | added | Phil | Thanks for your response, but i'm trying to figure out how to make a smaller version of the tables that show the issue, but you're right it works for me. I am using a dacpac, but i'm also using schema compare on my sql project and just running the script it generates from there. doesn't seem to be an ordering issue (schema is already created). I'll keep investigating though. looks like it might not be any azure specific thing like i thought then. | |
Jan 13, 2019 at 20:57 | history | edited | Aaron Bertrand | CC BY-SA 4.0 |
added 445 characters in body
|
Jan 13, 2019 at 20:56 | comment | added | Aaron Bertrand | Can you post the dacpac somewhere? I can't make that code fail on Azure SQL Database but it's possible the dacpac has creation scripts listed in the wrong order or the constraints are separated out into a different (later) step and aren't in the right order either. | |
Jan 13, 2019 at 20:55 | comment | added | Phil | yeah, i apologize, i do actually add the key but forgot to include it in my example | |
Jan 13, 2019 at 20:50 | history | answered | Aaron Bertrand | CC BY-SA 4.0 |