Connecting Tech Pros Worldwide Help | Site Map

"Ambiguous outer joins" error when looping through querydefs

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 8th, 2007, 09:05 AM
Michael Scott
Guest
 
Posts: n/a
Default "Ambiguous outer joins" error when looping through querydefs

This is driving me nuts. Can anyone help?

I have a program which searches for and analyses Access databases
across a corporate network. At one point in the code I am looping
quickly through all the querydefs in the target database to give an
idea of what we're dealing with:

For Each qdf In dbsDiscoveredDatabase.QueryDefs
If Left(qry.Connect, 4) = "ODBC" Then
mblnODBC = True
End If
Next qdf
Quote:
>From time to time this produces Error 3258 "The SQL statement could
not be executed because it contains ambiguous outer joins". I know
what this error message usually means, and how to rectify it, but in
this instance it is baffling me. Am I somehow trying to run the query
by looking at its Connect property?

This happens very infrequently, but I have a feeling it might be
limited to MDE files. Is that a possibility?

Thanks in advance for any help and suggextions.


  #2  
Old November 8th, 2007, 10:55 AM
Bob Quintal
Guest
 
Posts: n/a
Default Re: "Ambiguous outer joins" error when looping through querydefs

Michael Scott <michael.scott@dsl.pipex.comwrote in
news:1194516109.158722.192940@y27g2000pre.googlegr oups.com:
Quote:
This is driving me nuts. Can anyone help?
>
I have a program which searches for and analyses Access databases
across a corporate network. At one point in the code I am looping
quickly through all the querydefs in the target database to give an
idea of what we're dealing with:
>
For Each qdf In dbsDiscoveredDatabase.QueryDefs
If Left(qry.Connect, 4) = "ODBC" Then
mblnODBC = True
End If
Next qdf
>
Quote:
>>From time to time this produces Error 3258 "The SQL statement could
not be executed because it contains ambiguous outer joins". I know
what this error message usually means, and how to rectify it, but in
this instance it is baffling me. Am I somehow trying to run the query
by looking at its Connect property?
>
This happens very infrequently, but I have a feeling it might be
limited to MDE files. Is that a possibility?
>
Thanks in advance for any help and suggextions.
>
When you test the querydef, Access parses the SQL. You just need an
error handler that does a resume next on error 3258.





--
Bob Quintal

PA is y I've altered my email address.

--
Posted via a free Usenet account from http://www.teranews.com

  #3  
Old November 8th, 2007, 07:45 PM
Michael Scott
Guest
 
Posts: n/a
Default Re: "Ambiguous outer joins" error when looping through querydefs

When you test the querydef, Access parses the SQL. You just need an
Quote:
error handler that does a resume next on error 3258.
Thanks very much! I had already added code to do just that, as a
workaround, but it's good to know that that is the solution.

 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,840 network members.