-
November 3rd, 2012, 07:44 AM
#1
How to Make an Entry in a Table and Make in another with same Primary
Well i am currently making a system using ASP.net C# and SQL Server
What i want to achieve is when i create an entry in a Table. Lets say "Customers" with primary key "customerID".
When i create entries in the table and i have a Column with Identity and i successfully entered every data needed.
I want to create an entry in another table with the same value as my primary key.
So in the first table
Customers
customerID: 1
Name: Mr. Random
Pass: RandomPassword
it will create an entry in another table like this and the other data are empty.
CustomersOrder
customerID: 1
order1: <empty>
order2: <empty>
i want to do this because i separated some data on tables and i want them to have the same key or ID to search or edit them easily.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|