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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query Differences

Status
Not open for further replies.

cmz21

Programmer
May 5, 2005
110
US
Hello,
I have a strange problem with some queries. I have created an append query to append records to a table. It takes about 30 second to run. I saved the query, came back the next day, and the query takes a ridiculous amount of time to run. I have compacted database hoping to clear up this problem, but it doesn't seem to go away.

The strangest part is that if I open the query and just switch the last 2 fields around, it goes back to running quickly again. I assume it will do this no matter which fields I move.

Anyone have any thoughts on what might be happening with this? I am running MS Access 2000 on a Windows XP pc.

Thanks for any help.
 
I have a bit of change for this post. It seems that now I can run the query just fine as is, but when I try to use the sql statement for the query in vba, it runs forever (I let it run for over an hour). If I call the query from vba, it takes around 20 seconds to run.

Hope this is clear.

thanks for any input
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top