By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,871 Members | 2,368 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,871 IT Pros & Developers. It's quick & easy.

how to update/insert from one access DB to another

P: 2
Hi,

I am really new at Access but have been reading and trying to learn. I hope someone can help me figure out how to either update or insert records from one DB table to another database table. There is an extra complexity because of the fact that I only want to update a few of the fields in the existing database's record with new data. Obviously if there isn't an existing record in the base DB I would want to insert the incoming record.

Would I use Visual Basic to do this? I'm in a time crunch as I have been asked to do this by my boss even though he knows I don't know Access. My job is totally unrelated to this but of course I am interested in learning VB and Access!

Thanks in advance for any help.

Cheers.

Bob
Jan 15 '07 #1
Share this Question
Share on Google+
3 Replies


P: 46
perhaps u can try with a select stat and follow up insert stat using sql query.

Hi,

I am really new at Access but have been reading and trying to learn. I hope someone can help me figure out how to either update or insert records from one DB table to another database table. There is an extra complexity because of the fact that I only want to update a few of the fields in the existing database's record with new data. Obviously if there isn't an existing record in the base DB I would want to insert the incoming record.

Would I use Visual Basic to do this? I'm in a time crunch as I have been asked to do this by my boss even though he knows I don't know Access. My job is totally unrelated to this but of course I am interested in learning VB and Access!

Thanks in advance for any help.

Cheers.

Bob
Jan 16 '07 #2

NeoPa
Expert Mod 15k+
P: 31,489
Hi,

I am really new at Access but have been reading and trying to learn. I hope someone can help me figure out how to either update or insert records from one DB table to another database table. There is an extra complexity because of the fact that I only want to update a few of the fields in the existing database's record with new data. Obviously if there isn't an existing record in the base DB I would want to insert the incoming record.

Would I use Visual Basic to do this? I'm in a time crunch as I have been asked to do this by my boss even though he knows I don't know Access. My job is totally unrelated to this but of course I am interested in learning VB and Access!

Thanks in advance for any help.

Cheers.

Bob
Firstly, maybe not intuitively, databases generally separate INSERT INTO (append) from UPDATE queries. These two items must be done separately.
Secondly, apart from saying the above, there's little more that can be done without any information as to your database (table) structures and how they all fit together.
You could look at this thread (Basic SQL Syntax for Access Queries) for help or post MetaData for your two tables :
Posting Table/Dataset MetaData
Expand|Select|Wrap|Line Numbers
  1. Table Name=tblStudent
  2. StudentID; Autonumber; PK
  3. Family; String; FK
  4. Name; String
  5. University; String; FK
  6. MaxMark; Numeric
  7. MinMark; Numeric
Jan 16 '07 #3

P: 2
Thanks NeoPa and technocraze, I appreciate the pointers...
Jan 17 '07 #4

Post your reply

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