Senin, 13 April 2015

RE: [MS_AccessPros] r SQL Server query to Access

 

Art,
 
Did you set the ODBC Connect Str property of the P-T query? There is a builder button that helps you create this. I typically use DSN-less connections. There are lots of examples at http://www.connectionstrings.com/sql-server/.
 
Duane Hookom, MVP
MS Access
 

To: MS_Access_Professionals@yahoogroups.com
From: MS_Access_Professionals@yahoogroups.com
Date: Mon, 13 Apr 2015 18:55:44 +0000
Subject: Re: [MS_AccessPros] r SQL Server query to Access



I am trying it as a Pass Through query but every time I run it prompts for my ODBC data source. WHen I made it my forms record source it also prompts for the ODBC datasource over and over again. ANy idea? 

With Warm Regards,
 
Arthur D. Lorenzini
IT System Manager
Cheyenne River Housing Authority
Wk.(605)964-4265  Ext. 130
Fax (605)964-1070

"Anyone who claimed that old age had brought them patience was either lying or senile."  






From: "wrmosca@comcast.net [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com>
To: MS_Access_Professionals@yahoogroups.com
Sent: Monday, April 13, 2015 12:55 PM
Subject: RE: [MS_AccessPros] r SQL Server query to Access

 
Duane - single quotes should work fine in this case.

-Bill Mosca




---In MS_Access_Professionals@yahoogroups.com, <duanehookom@hotmail.com> wrote :

Art,
 
If the query doesn't need to be updateable, I would create a pass-through query and use the SQL Server syntax.
 
If you need to re-write this in Access, you should try to replace the single quotes with double quotes.
 
Do you understand the difference between '' and Null? I would consider using:
   city & "" <> ""'
 
Duane Hookom, MVP
MS Access
 

To: MS_Access_Professionals@yahoogroups.com
From: MS_Access_Professionals@yahoogroups.com
Date: Mon, 13 Apr 2015 07:58:56 -0700
Subject: [MS_AccessPros] r SQL Server query to Access




Is there a app or can someone help me to convert the following SQL Server Query to Access query:


SELECT a.CustID, a.UnitID, *
FROM (select custnmbr AS CustID, custclas AS Class, ADRSCODE AS UnitID,Hold,
CUSTNAME AS TenantName,
address1, address2, city, state, zip from RM00101
where INACTIVE = 0 and city <> ' ' AND CUSTCLAS='Rental' and Hold = 0
)  AS a INNER JOIN (Select CUSTNMBR, CUSTNAME, LOCNCODE, LOCNDSCR, BSSI_PortfolioID, BSSI_Description1,
BSSI_Tenant_Lease_Status, BSSI_Lease_Execution_Dat, BSSI_Lease_Termination_D
From B4602200 where
BSSI_Tenant_Lease_Status = 2)  AS b ON a.CustID = b.CUSTNMBR;


WHen I try to run this in ACCESS    I get ODBC call error.


Thank you


Art Lorenzini
South Dakota.






__._,_.___

Posted by: Duane Hookom <duanehookom@hotmail.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (9)

.

__,_._,___

Tidak ada komentar:

Posting Komentar