469,334 Members | 4,230 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,334 developers. It's quick & easy.

Multiple Entries for the same key in an access DB

Hi everyone,

i have an emp id say p12234
and an entry for this id has been made into the access DB.

now i want to add another record for the same key (there is no primary key set)

such that the output appears as :

emp_id name qty date
p12234 p 1 30/03/2007
p12234 p 2 31/03/2007

plz help to write the query for this.....
Mar 30 '07 #1
3 1081
dorinbogdan
839 Expert 512MB
Welcome to TheScripts TSDN...

Suposing that the table name is employee, execute this query:
Expand|Select|Wrap|Line Numbers
  1. Insert Into employee (emp_id, [name], qty, [date])
  2. Values ('p12234', 'p',2, '31/03/2007')
  3.  
Replace employee with your real table name.

Does it solve your problem?
Mar 30 '07 #2
Welcome to TheScripts TSDN...

Suposing that the table name is employee, execute this query:
Expand|Select|Wrap|Line Numbers
  1. Insert Into employee (emp_id, [name], qty, [date])
  2. Values ('p12234', 'p',2, '31/03/2007')
  3.  
Replace employee with your real table name.

Does it solve your problem?
Hi Sir,
Actually d scenario is I've designed 1 snacks order system. in this everyday employee in our company order for snack's qty. now in this im takin d current date. d problem is, any employee id entered for d 1st time while saving d record in d DB doesnt throw any error but if on next day if i try to enter snack's qty on same employee id, it dosnt take that data and shows a blank screen (not any error).
since there are multiple entries for d same key I've not assigned primary key to d table...

now how should I proceed??
Mar 31 '07 #3
dorinbogdan
839 Expert 512MB
Please provide your code.
Apr 2 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Usenet | last post: by
5 posts views Thread by Sammy | last post: by
3 posts views Thread by Bernard Lebel | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.