AugForums.com

An Acumatica User Group

  • Free
    • Start Here
    • Rolodex
    • Podcast
    • Blog
    • Forums
  • Paid
    • AugSQL
    • GI Course
    • GI Library
    • Consulting
  • Register
Acumatica Forums

By using this website, you agree to our Terms of Use (click here)

Forums
AUG Forums
Acumatica Report De...
How to create a vis...
 
Notifications
Clear all

Questions How to create a visible expression that uses Contains or StartsWith

 
Acumatica Report Designer
Last Post by Kurt Bauer 3 years ago
3 Posts
3 Users
3 Reactions
3,010 Views
RSS
Andrea Grover, ECBA, CSSGB
Posts: 2
 Andrea Grover, ECBA, CSSGB
Topic starter
June 7, 2022 1:02 pm
(@agrover)
Active Member
Joined: 4 years ago

I would like to be able to control the visibility of a field on the SO Invoice (SO643000) using a contains, like, or startswith filter.  I have not been able to get the syntax right.  'Like' using SQL syntax gave an unsupported error.  

=[ARInvoice.CustomerLocationID] StartsWith ('W/C?') will not validate and says Missing operator before the StartsWith operand.  Same if I use Contains.

I tried this and it basically ignores it:

=[ARInvoice.CustomerLocationID] = 'W/C?'

Can someone help with the correct syntax and which one works (contains or startswith)?


2 Replies
Dianne A
Posts: 23
 Dianne A
June 8, 2022 9:48 am
(@dianne-a)
Eminent Member
Joined: 5 years ago

Hi Andrea,

You can use the "InStr()" function to find strings within strings. It returns the position within the source string where the string to find exists. If it is not found, the function returns -1. The first position of the source string is 0.

Examples...

1) To look for "xyz" anywhere inside field [EPEmployee.AcctName], use the following - if the result is -1, it wasn't found; if the result is >=0, that's where it was found:

=InStr([EPEmployee.AcctName],'xyz')

2) To look for "xyz" only at the beginning of the field, use the following - if the result of the expression is False, it wasn't found at the beginning; if the result of the expression is True, it was found at the beginning: [use this for your Visible Expression]

=InStr([EPEmployee.AcctName],'xyz')=0 

Dianne


Reply
Kurt Bauer
Posts: 45
 Kurt Bauer
June 8, 2022 10:22 am
(@kurtybauer)
Trusted Member
Joined: 6 years ago

You could even use the Left() function in the visible expression.

=Left([DAC.FIELDNAME],1)='W' or Left([DAC.FIELDNAME],1)='C'

Kurt


Reply
Tim Rodman, Royce Lithgo and Dianne A reacted
Forum Jump:
  Previous Topic
Next Topic  
Forum Information
Recent Posts
Unread Posts
Tags
  • 12 Forums
  • 2,526 Topics
  • 10.9 K Posts
  • 37 Online
  • 2,324 Members
Our newest member: Michael Kiley
Latest Post: Pick List report suddenly not splitting on Shipment
Forum Icons: Forum contains no unread posts Forum contains unread posts
Topic Icons: Not Replied Replied Active Hot Sticky Unapproved Solved Private Closed

Online Members

 No online members at the moment

Acumatica Forums

Terms of Use & Disclaimers :: Privacy Policy

Copyright © 2025 · AUG Forums, LLC. All rights reserved. This website is not owned, affiliated with, or endorsed by Acumatica, Inc.

‹›×

    ‹›×