Queries

dkbrostyle

New Member
Joined
Mar 16, 2002
Messages
28
Hi i would like a query which makes a search and then copies it to another sheet. What are the process with that.

I would like to know if the append query can be used and how would i copy information to another. This would mean that i would need a macro which can be pressed to authorise the data being copied.

Thanks for your help and time.
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
An append query is used to append data to tables.
If you link your excel spreadsheet (File - Get External Data - Link) you should be able to append fields to it from other tables within Access.

I think what you mean by "a query which makes a search" is just the standard way that queries use parameters to limit what shows up.

Try this:

Open up the QBE wizard and select your source table
After finishing, open up the query in design mode.
On the row labeled Criteria, add something. If it's a string field, it will put it in quotes and if you execute it, it will only show you items that match the string you type in...in that specific field.

After you do this, return to design mode. Change the query type to Append (tool bar at top) and type in or select the table name you wish to append the data to. Save the query.

Next time you run this query, the same information that appeared on your screen will be appended to the destination table.
-
Something to pay attention to. Access makes a 'guess' as to which fields in the source table to append to the destination table based on field names. If they don't match, you can still append, but you must go into the append query design mode to tell it where to send the field data. Make sure the field types are compatible (sending text to a numeric field!)

Mike
 
Upvote 0

Forum statistics

Threads
1,221,668
Messages
6,161,158
Members
451,687
Latest member
KENNETH ROGERS

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top