If "text" is in cell L151 then "POSTED"

xpander

New member
Local time
Today, 03:21
Joined
Mar 21, 2024
Messages
4
Can you use INSTR or something in an Access query to make it so that, for example, If "text" is in cell L151 then "POSTED" else "Not POSTED" ?
 
Hi. Welcome to AWF!

I think you can as well as trying to use the LIKE operator. Give it a shot and let us know how it goes.
 
=IF(INSTR(1,[L151],"text")<>0, "POSTED","Not POSTED")
 
=IF(INSTR(1,[L151],"text")<>0, "POSTED","Not POSTED")
In a query, you wouldn't use the equals sign and you would use the IIF() function and not IF().
 
Can you use INSTR or something in an Access query to make it so that, for example, If "text" is in cell L151 then "POSTED" else "Not POSTED" ?
Excel has COUNTIF instead of InStr.

=IF(COUNTIF(L151,"*Text*"),"Posted","Not Posted")
 
Last edited:

Users who are viewing this thread

Back
Top Bottom