Skip to main content
Question

Accessing a Custom Enumeration using expression

  • April 23, 2024
  • 5 replies
  • 109 views

Forum|alt.badge.img+3
  • Do Gooder (Partner)
  • 6 replies

Hi,

 When creating custom attributes, for inbuilt enumerations, I can use:

enumeration_name_Api.decode(‘db_value’);

 

But when I create a custom enumeration and try to use the same expression, it gives me errors.

Any idea on how to access a custom enumeration using a statement?

Error:
CUSTOM_ENUMERATION_API"."DECODE": invalid identifier

 

Please help

5 replies

Mayura Wasantha
Superhero (Employee)
Forum|alt.badge.img+18
  • Superhero (Employee)
  • 469 replies
  • April 24, 2024

shared with @deshan.ekanayake @Pushpa Veerappan @Jitharie @Madawa Boragolla - Please try to answer Kalindu 🙂.


Forum|alt.badge.img+3
  • Author
  • Do Gooder (Partner)
  • 6 replies
  • April 24, 2024

Hello Mayura!!!!! :)
Really nice to hear from you!  


Thank you!
 


Forum|alt.badge.img+3
  • Author
  • Do Gooder (Partner)
  • 6 replies
  • April 24, 2024

Hello, 
 Nevermind, I figured it out. It should be:
enumeration_name_CFP.decode(‘db_value’);

 

Thank you!


Mayura Wasantha
Superhero (Employee)
Forum|alt.badge.img+18
  • Superhero (Employee)
  • 469 replies
  • April 25, 2024
Kalindu wrote:

Hello Mayura!!!!! :)
Really nice to hear from you!  


Thank you!
 

🙂🙂


Forum|alt.badge.img+3
  • Sidekick (Customer)
  • 5 replies
  • June 6, 2024

I’ve used something like:

select db_value from CUSTOM_FIELD_ENUM_VALUES

where lu = 'CUSTOM_ENUM_NAME'

Replacing “CUSTOM_ENUM_NAME” with the actual name of the enumeration. Nice and simple. There’s probably a more elegant way using an API, but..


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings