Append query from command butoon

swaroop1012

Registered User.
Local time
Today, 23:22
Joined
Nov 21, 2008
Messages
19
Hi,

I am working on a database where i need to append a query on to a table from a form. I am doing this without forms till now.

Is there anyway of doing that from a command button. Also is there any possibility of deleting the table with the same command button (i.e. delete the table data and append with the new data) .The query name is "DCQuery" and the table name is "CPTable". I am not very good at SQL. So can anyone give the solution in VB codes.

Thanks in advance.
 
Hi,

I am working on a database where i need to append a query on to a table from a form. I am doing this without forms till now.

Is there anyway of doing that from a command button. Also is there any possibility of deleting the table with the same command button (i.e. delete the table data and append with the new data) .The query name is "DCQuery" and the table name is "CPTable". I am not very good at SQL. So can anyone give the solution in VB codes.

Thanks in advance.

the query grid gives you all you need to know to do this. make a qry on CDquery, change it to an APPEND, when it asks what object to append to, click CPTable. this is the jist. i'm getting a sense that you really don't know how to ask the question so i can't really know for sure what you want.

yes you can append with data still, or delete it out then put new stuff in. make sure of these though:

*the query is not pulling from the table
*appended fields FROM the query are same datatypes as the fields in the TABLE that they're being transported to


to delete the table's rec's, then append the query's recs, i'm not going to give u an example, because there are tons of em. macros, code, queries, manually bang on keyboard, etc...
 

Users who are viewing this thread

Back
Top Bottom