Quantcast
Channel: Teradata Forums - Database
Viewing all articles
Browse latest Browse all 14773

How do I retrieve the most recent used autonumber?? - topic by coffee

$
0
0
I see this question everywhere.  I sure hope there is an answer.   Use case: Master table that has a column (id) with "generated always as identity..." so it will create the unique id. Other tables that have a foreign key (id_fk).   1. Insert row into master table. 2. Retrieve the unique id that was just auto created in the master table. 3. insert rows into the other tables using the value of id in the id_fk column.  

read more


Viewing all articles
Browse latest Browse all 14773

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>