Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing cbo select 1

Status
Not open for further replies.

BabyPowder2u

Programmer
May 4, 2005
87
US
I have a form which has 2 cboSelects

1. SelDiv
2. SelectPOC

The Div is selected, then used to pull up a list of POC's. The select for the POC is:

SELECT tblPOC.POCID, tblPOC![FirstName] & " " & tblPOC![LastName] AS POC1
FROM tblPOC
WHERE ((([tblPOC]![DivID])=[forms]![frmPOC_ModDel].[SelectDiv]));


I would like to modify this so if no "Div" is selected, all POC's in the table will be pulled into the list.

Any help to accomplish this would be appreciated.

T
 
SELECT POCID, FirstName & ' ' & LastName AS POC1
FROM tblPOC
WHERE DivID=[Forms]![frmPOC_ModDel]![SelectDiv]
OR [Forms]![frmPOC_ModDel]![SelectDiv] Is Null

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top