alexk824
Technical User
- Nov 11, 2010
- 2
The following is a query we have. Im wondering how I can run multiple fields at the same time. Right now I have to change ((Contact1.KEY2)="1")) over and over to run through all the regions, but I want to know if there is a way to run 1 through 30 or so all at the same time without doing "1" query... "2" query... etc... any help on this would be greatly appreciated. Thanks
SELECT Contact1.Company, Contact1.address1 AS street, Contact1.address2 AS pobox, Contact1.City, Contact1.state, Contact1.zip, Contact1.phone1 AS phone,Contact1.fax, Contact1.Key2 AS service_area, ContSupp.CONTSUPREF AS CalDueDate, ContSupp.Linkacct AS Manufacturer, ContSupp.Country AS Model, Contact1.contact, Contact1.title,Contact1.phone2 AS phone1, Contact1.phone3 AS fax1, Contact1.ext1 AS ext
FROM ContSupp INNER JOIN Contact1 ON ContSupp.ACCOUNTNO = Contact1.ACCOUNTNO
WHERE (((ContSupp.RECTYPE)="P") AND ((ContSupp.CONTSUPREF) Like "201001%") AND ((ContSupp.ZIP) Is Null) AND
((Contact1.KEY2)="1"))
SELECT Contact1.Company, Contact1.address1 AS street, Contact1.address2 AS pobox, Contact1.City, Contact1.state, Contact1.zip, Contact1.phone1 AS phone,Contact1.fax, Contact1.Key2 AS service_area, ContSupp.CONTSUPREF AS CalDueDate, ContSupp.Linkacct AS Manufacturer, ContSupp.Country AS Model, Contact1.contact, Contact1.title,Contact1.phone2 AS phone1, Contact1.phone3 AS fax1, Contact1.ext1 AS ext
FROM ContSupp INNER JOIN Contact1 ON ContSupp.ACCOUNTNO = Contact1.ACCOUNTNO
WHERE (((ContSupp.RECTYPE)="P") AND ((ContSupp.CONTSUPREF) Like "201001%") AND ((ContSupp.ZIP) Is Null) AND
((Contact1.KEY2)="1"))