run-time error '3078'

T

TimWhitehill

Hi,

I have a bizzare problem. I had code that worked last week and now all of
the sudden it doesn't. No patches or other changes have been applied to my
computer. The network staff in my office has verified this. I'm running
Access 2007. I found no changes in my references and I've doubled checked to
make sure I have the correct ones selected.

The following is a simplified version of the code that I've been using to
try to debug this monster.

Function checkdate() As Date
Dim db As DAO.Database
Dim mt As DAO.Recordset2

Set db = CurrentDb
Set mt = db.OpenRecordset("dbo.DateTable", dbOpenTable)
checkdate = mt("firstdate")

mt.Close
End Function

The error I get back is:
Run-Time error '3078'
The microsoft office access database engine cannot find the input table or
query 'dbo.DateTable'. Make sure it exists and that its name is spelled
correctly

The dbo.DateTable is on an SQL server and I'm linking to it. I can open the
table from Access and I can run queries against it. Here's a weird thing, if
I make a query that reads the table, I can access it in my code. This means I
can get around my problem, but I don't understand why this worked fine for a
month and then come in Monday morning and I get the error. I also tested that
all SQL linked tables I have give me this error, Access tables work fine. I
even created a brand new database to test this and I still get the error.
 
C

Clifford Bass

Hi Tim,

Basic questions: Usually when I have linked to non-access backend
tables the period gets converted to an underscore. So are you renaming the
table link back to use the period in the name? If not, maybe you should use
this?

Set mt = db.OpenRecordset("dbo_DateTable", dbOpenTable)

Clifford Bass
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top