expression in a query field

R

ram

I would like to add a field to the query below that calculates the number of
computers that have been ordered but not shipped.
I would like to add a field that counts the number of people where
[Order_Date] is not blank and [PC_Ship_Date] is blank to the query below

SELECT Count(Processtbl!Invitation_Sent) AS [Invitation Sent],
Count(Processtbl!Date_Computer_Ordered) AS [Computers Ordered],
Count(Processtbl!PC_Shipped) AS [Computers Shipped]
FROM Processtbl;

I would prefer not to create a seprate query. Thanks in advance for any help
 
K

Ken Sheridan

Try:

SUM(IIF([Order_Date] IS NOT NULL AND [PC_Ship_Date] IS NULL,1,0))

Ken Sheridan
Stafford, England
 
R

ram

Thanks Ken just what I needed

Ken Sheridan said:
Try:

SUM(IIF([Order_Date] IS NOT NULL AND [PC_Ship_Date] IS NULL,1,0))

Ken Sheridan
Stafford, England

ram said:
I would like to add a field to the query below that calculates the number of
computers that have been ordered but not shipped.
I would like to add a field that counts the number of people where
[Order_Date] is not blank and [PC_Ship_Date] is blank to the query below

SELECT Count(Processtbl!Invitation_Sent) AS [Invitation Sent],
Count(Processtbl!Date_Computer_Ordered) AS [Computers Ordered],
Count(Processtbl!PC_Shipped) AS [Computers Shipped]
FROM Processtbl;

I would prefer not to create a seprate query. Thanks in advance for any help
 
Top