Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 2 / June 2007

Tip: Looking for answers? Try searching our database.

Access 2007 SQL Pass Through Queries

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Rob - 20 Jun 2007 23:36 GMT
I have an Access 2003 mdb that I use to connect to a SQL 2005
database. When I open the application in Access 2007 it errors on
using SQL pass through queries.

I see that pass through queries (amongst other options) have been
disabled under Access 2007. However it seems that they are enabled
under certain circumstances so I've been trying to get them working by
changing the security settings.

The queries are still failing after setting the following:
- Sandbox Mode to 0 (turn off sandbox mode for all apps)
- Applied a recognised Digital Signature
- Trusted the Publisher
- Trusted the location of the mdb
- Enable all macros in Macro Settings

I'm using DAO to connect to the database and the code that fails
reads:
strWork = "EXECUTE spLogin"
Set rsSysUsers = dbTest.OpenRecordset(strWork, dbOpenSnapshot,
dbSQLPassThrough)

The error returned is:
error no: 3276
error description: Invalid database object reference.

Any help or ideas would be greatly appreciated.
Sylvain Lafontaine - 21 Jun 2007 06:09 GMT
I don't have Office 2007 installed but here's a wild guess: did you create
dbTest using the standard JET workspace or an ODBCDirect workspace?

If you don't find the source of your problem, then maybe using an ordinary
querydef for running your passthrough queries might be the solution;
however, as you don't say nothing about the rest of your code or why you are
using the dbTest object, it's hard to tell you anything more about this.

Signature

Sylvain Lafontaine, ing.
MVP - Technologies Virtual-PC
E-mail: sylvain aei ca (fill the blanks, no spam please)

>I have an Access 2003 mdb that I use to connect to a SQL 2005
> database. When I open the application in Access 2007 it errors on
[quoted text clipped - 23 lines]
>
> Any help or ideas would be greatly appreciated.
IRS Intern - 25 Jun 2007 02:06 GMT
uh.. DAO and Passthrus are obsolete

move to SQL Server and Access Data Projects, kids

> I don't have Office 2007 installed but here's a wild guess: did you create
> dbTest using the standard JET workspace or an ODBCDirect workspace?
[quoted text clipped - 38 lines]
>
> - Show quoted text -
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.