E
excel/access-chump
I understand enough vb to have a general idea of what is going on when I look
at vb code but I can't seem to write my own code, despite all the Access
helps.
I'm using Access 2003.
I can get all three queries to work as queries, but when I try to run them
in vb I get a runtime error ‘3211’ and a message: “Data Base engine could not
lock table ‘InvenTracker’ because it is already in use by another person or
process.â€
This is my vb:
DoCmd.OpenQuery "itTable"
DoCmd.OpenQuery "itUpdate"
I have tried putting this in various places: DoCmd.CloseTable, “InvenTrackerâ€
Pass Through Query: InvenTrackerTest = "itTest"
SELECT x.HPKeyword,
x.ReviewerId,
x.addrkey,
x.ChartsScheduled,
x.ChartsRetrieved,
x.ChartsNotRetrieved,
x.AppStart,
x.AppEnd
FROM vw_ScheduledChartByRvwrAppt x
WHERE x.AppStart >= getdate()-3
AND x.AppStart <=getdate()+24
ORDER BY x.AppStart, x.AppEnd
Make-table Query: InvenTrackerMakeTable = "itTable"
SELECT x.*,
x.addrkey & " (" & x.ChartsScheduled & ")" AS addrkey
INTO InvenTracker
FROM itTest AS x;
Update Query: InvenTrackerUpdate = "itUpdate"
UPDATE InvenTracker SET InvenTracker.ReviewerId = Trim([ReviewerId]);
I’ve only been working in Access for about 2 weeks and I’m learning fast but
still rather confused.
Is there a way to run itUpdate as a subquery in itTable?
More questions to follow…
at vb code but I can't seem to write my own code, despite all the Access
helps.
I'm using Access 2003.
I can get all three queries to work as queries, but when I try to run them
in vb I get a runtime error ‘3211’ and a message: “Data Base engine could not
lock table ‘InvenTracker’ because it is already in use by another person or
process.â€
This is my vb:
DoCmd.OpenQuery "itTable"
DoCmd.OpenQuery "itUpdate"
I have tried putting this in various places: DoCmd.CloseTable, “InvenTrackerâ€
Pass Through Query: InvenTrackerTest = "itTest"
SELECT x.HPKeyword,
x.ReviewerId,
x.addrkey,
x.ChartsScheduled,
x.ChartsRetrieved,
x.ChartsNotRetrieved,
x.AppStart,
x.AppEnd
FROM vw_ScheduledChartByRvwrAppt x
WHERE x.AppStart >= getdate()-3
AND x.AppStart <=getdate()+24
ORDER BY x.AppStart, x.AppEnd
Make-table Query: InvenTrackerMakeTable = "itTable"
SELECT x.*,
x.addrkey & " (" & x.ChartsScheduled & ")" AS addrkey
INTO InvenTracker
FROM itTest AS x;
Update Query: InvenTrackerUpdate = "itUpdate"
UPDATE InvenTracker SET InvenTracker.ReviewerId = Trim([ReviewerId]);
I’ve only been working in Access for about 2 weeks and I’m learning fast but
still rather confused.
Is there a way to run itUpdate as a subquery in itTable?
More questions to follow…