Question Locked

MS Access

0 helpful
6 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
can anyone give some conditioning on MS Access field query? thank you

6 replies

by john.a.wills

Probably your question can be answered by one of the many TR participants, but first the question must be posed.

by rhey_shane22

thank you for that reply..
anyway below is the code where i use IIF statement: can you give me some function other that IIF?

SELECT tblEmployee.EmployeeID, [fname] & " " & [Lname] AS Fullname, tblPurchase.Quantity, IIf(([tblpurchase].[quantity])<=50,"200",IIf([tblpurchase].[quantity]<=100,"500","Excellent!")) AS Bonus
FROM tblEmployee INNER JOIN tblPurchase ON tblEmployee.EmployeeID = tblPurchase.EmployeeID;

by john.a.wills

You could include a WHERE clause for the bonus in several separate SELECT sttements then make a UNION of those SELECT statements, but I think IIF is more readable and easier. I do not off-hand know of anything else one might write; I seem to remember a CASE statement in SQL, but I cannot find it in my books.

by rhey_shane22

Thank you for that suggestion.. .

Do you know how to publish a php file on lan connection? can give a step? thank you again;

This discussion is closed to new replies.