SQL help 
Author Message
 SQL help

SQL help
Could someone help me polish my SQL below? I’m trying to
set a combo box’s row source and am trying to tell the
WHERE  clause of my SQL to search a field for an
occurrence of the word “Home Hardware” any place in the
field, but I haven’t gotten anything to work yet. Please
advise.

strSQL = "SELECT RetailerNumber & '-' &
RetailerStoreNumber & ' ' & StoreName AS
Retailer,RetailerNumber,RetailerStoreNumber,StoreName,Addre
ss1,Address2,City,Province,PostalCode,PhoneNumber,RegionCod
e FROM tblRetailerStore WHERE RegionCode ='" & 1301 & "'
and StoreName = *Home Hardware*"



Tue, 12 Oct 2004 02:30:18 GMT  
 SQL help
Voila!

strSQL = "SELECT RetailerNumber & '-' &
RetailerStoreNumber & ' ' & StoreName AS
Retailer,RetailerNumber,RetailerStoreNumber,StoreName,Addre
ss1,Address2,City,Province,PostalCode,PhoneNumber,RegionCod
e FROM tblRetailerStore WHERE RegionCode ='" & 1301 & "'
AND StoreName LIKE '*Home Hardware*'"

Quote:
>-----Original Message-----
>SQL help
>Could someone help me polish my SQL below? I’m trying to
>set a combo box’s row source and am trying to tell the
>WHERE  clause of my SQL to search a field for an
>occurrence of the word “Home Hardware” any place in the
>field, but I haven’t gotten anything to work yet. Please
>advise.

>strSQL = "SELECT RetailerNumber & '-' &
>RetailerStoreNumber & ' ' & StoreName AS
>Retailer,RetailerNumber,RetailerStoreNumber,StoreName,Addr
e
>ss1,Address2,City,Province,PostalCode,PhoneNumber,RegionCo
d
>e FROM tblRetailerStore WHERE RegionCode ='" & 1301 & "'
>and StoreName = *Home Hardware*"

>.



Tue, 12 Oct 2004 02:44:55 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. SQL Help - SQL sub-query

2. Access SQL to Visual Basic SQL Help

3. Good Reporting Tool for VB to SQL (Currently Use Crystal) or Crystal w/SQL Help Appreciated

4. SQL Help (WWW to SQL)

5. SQL HELP: Access to SQL Server

6. SQL help problem. Please help

7. querydef sql help

8. UPDATE SQL HELP!!!

9. sql help, I think

10. SQL help

11. SQL Help

12. SQL Help!

 

 
Powered by phpBB® Forum Software