Comments
2 comments
-
Hi @Mij!
I'm afraid the Foreign Key (manual) generator will only allow you to choose from a table within the same database as you've seen. However, you should be able to reference a column from the different database by using the Generic>SQL Statement column. You can then use something like a "SELECT employeeNumber" query to get the values from the table in the other database.
I hope that helps but please let us know if not!
(Note that there was a bug in SQL Data Generator versions 4.3.0 and 4.3.1 that would make Generic>SQL Statement fail with an "Object reference is not set to an instance of an object" error, but this is resolved in today's release of 4.3.2, available from Help>Check for updates.) -
This does seem to work for me. I have to click on the table again to have it successfully generate. If I click on the column, it tells me that my database credentials aren't working. But pulling data and shuffling which is what I need. Thank you!
Add comment
Please sign in to leave a comment.
The first column I wish to reference the employee number from the other database, however when I select FK (manual), it won't let me pick a table and column from that other database table that my current table references. It only tries to let me pick a table in this database. My second column I wish to reference from a table within this database (an access level for the application). This one appears to reference the correct FK defined by the database.
Is there something I can do with the first column though to get it to correctly be a manual FK to the other database values?