Updating tables with foreign key constraints Google pussy webcam chats
As of HANA 1.0 SPS5 (officially released through New DB revision 45), it is now possible to define referential constraints between two tables.
Referential Constraints are also known as Foreign Keys, in the way they define an “external” (foreign) relationship from the referencing table to a referenced table.
One thing I noticed is that the table definition (opened by double clicking the table name in the Navigator view) does not mention there is a FK in this table at all.
Which sounds kinda flawed to me, since I thought this screen was supposed to tell you everything about that table’s data model.
One of the functionalities in HANA SPS5 that makes it possible is exactly the enablement of Foreign Keys.
And, just to make sure the failed loading was indeed due to the FK, I inserted Customer #3 in the “CUSTOMER” table, hence making the Order #3 entry correct from a referential point of view.
Running the same test as above, we finally get the expected entries in the Order table, hence proving the failed loading was indeed due to the FK.
Lastly, I wanted to test the behavior of FKs in HANA when importing data from bulk load tools (e.g. Unfortunately, I don’t have a SLT instance connected to this HANA rev45 box, hence I won’t be able to test it.
As for Data Services, I’ll run some tests later and update this blog with the findings. in CSV format), one can use the native HANA bulk loading command, the “IMPORT FROM” statement. It was really simple, I just create a file with three rows equivalent to the ones I had inserted above in the “ORDER” table. I also deleted all entries from the “ORDER” table in order to avoid Primary Key constraints to fail the insert.