I have 2 related tables, master and a child, the master table have a primary which is an autonumber and I reference that autonumber to my child table as a foreign key so my problem is to get the value of the autonumber from a master table and write it to my child table when adding a new record to my child table, I was wandering if anyone know how to do that

Thanx in advance

it depends what you are doing at time of insert to the master table, if you are using a stored procedure you can use this

insert into mastertable .....

select @@identity

same as your other post, i would say to close the other one