Getting id of last inserted row
-
Hi, i have two tables with a 1:n relation. I insert a new row in the first table without knowing the id of it, because of a trigger in the table. Now i want to insert a bunch of rows in the second table, but i need the id of the before inserted row because of the foreign key. How could i do that?:confused: I use a firebird embedded db with .net + C#
-
Hi, i have two tables with a 1:n relation. I insert a new row in the first table without knowing the id of it, because of a trigger in the table. Now i want to insert a bunch of rows in the second table, but i need the id of the before inserted row because of the foreign key. How could i do that?:confused: I use a firebird embedded db with .net + C#
-
Hi, i have two tables with a 1:n relation. I insert a new row in the first table without knowing the id of it, because of a trigger in the table. Now i want to insert a bunch of rows in the second table, but i need the id of the before inserted row because of the foreign key. How could i do that?:confused: I use a firebird embedded db with .net + C#
Just set a parameter equal to
@@IDENTITY
.
CleaKO
"I think you'll be okay here, they have a thin candy shell. 'Surprised you didn't know that." - Tommy Boy
"Fill it up again! Fill it up again! Once it hits your lips, it's so good!" - Frank the Tank (Old School) -
Just set a parameter equal to
@@IDENTITY
.
CleaKO
"I think you'll be okay here, they have a thin candy shell. 'Surprised you didn't know that." - Tommy Boy
"Fill it up again! Fill it up again! Once it hits your lips, it's so good!" - Frank the Tank (Old School)