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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Writing expression in query field

Status
Not open for further replies.

domino3

MIS
May 20, 2003
307
GB
I have a text field showing occupation which users can fill with whatever they best feel describes the occupation. One of my users would now like to be able to group roughly the records by occupation. For exapmle, shop workers, shop managers, shelf fillers would all be grouped under shop. When I have tried to write an expression to group them in the following way Expr1: IIf([status/Occupation]="*shop worker*","shop",Null) I get blank fields. However, if I write the expression Expr1: IIf([status/Occupation]="shop worker","shop worker",Null) i get shop worker as a result. Is there any way to write this query, as I need to roughly group several hundred records, and I don't really want to have to add and fill an extra field for what should only be a one off request. Thank you.
 
I've just realised I should be putting in "like". It works fine now.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top