Error "Run-time error '1004': General ODBC Error (1 Viewer)

D4WNO

New member
Local time
Today, 09:53
Joined
Jun 13, 2012
Messages
5
Hi all,

I'm having trouble running a file that I run weekly, when running the update query I receive error message: "Run-time error '1004': General ODBC Error

When I run debug, it fails at the 2nd line of code below:

Sheets("CCL").Visible = True
Sheets("CCL").Range("A1").QueryTable.Refresh BackgroundQuery:=False
Sheets("CCL").Visible = False
Sheets("Planned").Visible = True
Sheets("Planned").Range("A1").QueryTable.Refresh BackgroundQuery:=False
Sheets("Planned").Visible = False
Sheets("Unplanned").Visible = True
Sheets("Unplanned").Range("A1").QueryTable.Refresh BackgroundQuery:=False
Sheets("Unplanned").Visible = False
Sheets("Summary Pivots").Visible = True
Sheets("Summary Pivots").PivotTables("PivotTable6").PivotCache.Refresh
Sheets("Summary Pivots").PivotTables("PivotTable1").PivotCache.Refresh
Sheets("Summary Pivots").PivotTables("PivotTable4").PivotCache.Refresh
Sheets("Summary Pivots").PivotTables("PivotTable5").PivotCache.Refresh
Sheets("Summary Pivots").PivotTables("PivotTable7").PivotCache.Refresh
Sheets("Summary Pivots").PivotTables("PivotTable3").PivotCache.Refresh
Sheets("Summary Pivots").Visible = False
Sheets("Summary").Activate
Range("B4").Select
End Sub

My excel links the CCL data from Access via the below details and from what I know, nothing has changed. I've googled the error and it seems to mention an awful lot that there could be a problem with the link but I'm very inexperienced with Access and not quite sure where I should be looking.

Work connection details:
Connection string:
DSN=MS Access Database;DBQ=R:\Reporting\Change Control Reporting Database\Database\CCL_Lookup.mdb;DefaultDir=R:\Reporting\Change Control Reporting Database\Database;DriverId=25;FIL=MS Access;MaxBufferSize=2048;PageTimeout=5;UID=admin;

Command text:
SELECT Combined.`Document Number`, Combined.`Date Registered`, Combined.`Date Implemented`
FROM Combined Combined
 

PaulO

Registered User.
Local time
Today, 09:53
Joined
Oct 9, 2008
Messages
421
Has the sheet/tab called "CCL" be renamed/moved/deleted?
 

Users who are viewing this thread

Top Bottom