Skip to main content
Answer

Is it possible to use a wildcard in an IIF statement

  • June 14, 2023
  • 2 replies
  • 229 views

Forum|alt.badge.img

I have a generic inquiry that I am using an IIF statement in the Results Grid to add and populate a column in the GI results.. 

The statement is as follows:

=IIf( [SOInvoice.DocDesc] = 'ROLLER', '050116', ' ' )

What I am running into is there have been a few time where the SOInvoice.DocDesc containers more than just “ROLLER”, it might have ROLLER - xyz. 

When the GI is run this field is empty if the parameter of ‘ROLLER’ isn’t exact. Is there a wildcard available in Acumatica like the * in VB?

Thank you!

Best answer by darylbowman

Use the Substring() function to get the first six characters and then compare against that.

 

Something like 

=IIf(Substring([SOInvoice.DocDesc], 0, 6)='ROLLER', '050116', ' ')

 

2 replies

darylbowman
Captain II
Forum|alt.badge.img+15
  • Answer
  • June 14, 2023

Use the Substring() function to get the first six characters and then compare against that.

 

Something like 

=IIf(Substring([SOInvoice.DocDesc], 0, 6)='ROLLER', '050116', ' ')

 


Forum|alt.badge.img
  • Author
  • Freshman I
  • June 14, 2023

darylbowman

Thank you for the quick reply and will give this a try..

Have a nice day!