Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data Access Page - SQL SELECT / INSERT

Status
Not open for further replies.

dcanfield

Technical User
Apr 25, 2005
23
US

I have a form in Access that displays a record from a Data Entry table.

I created a module that would select the record from the Data Entry table (as displayed in the form), and append it the Master Data table. I created a macro to run this module, and linked it to a button on the form where it was activated by ‘OnClick”. It all works fine.

I then created a "DATA ACCESS PAGE" in MS Access from this form.

I had to tweak the control on the form that has the “OnClick” feature so that it is set to run a VBScript shown below. When the user clicks on the “Submit” button, I want to append the data from the data entry table into the Master table.

It is not currently working….No error messages....just nothing happens.

Any help much appreciated.

Thanks!
David

sqlSelect = "SELECT BIA_DATA_ENTRY.* INSERT INTO BIA_MASTER FROM BIA_DATA_ENTRY WHERE ID > ' 0 ' "




 
sqlSelect = "INSERT INTO BIA_MASTER SELECT BIA_DATA_ENTRY.* FROM BIA_DATA_ENTRY WHERE ID > 0"

How is this SQL code executed ?


Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top