
Are you like me going crazy to figure out how to find the integer value of an enum type? No problem, the solution is around the corner.
In this case you have 2 options :
- Open SSMS SQL session and run a query.
- Create a job / Runnable class
SQL Query
select t1.NAME,t2.ENUMID,t2.ENUMVALUE,t2.NAME EnumValueName
from ENUMIDTABLE t1
inner join ENUMVALUETABLE t2 on t1.ID=t2.ENUMID
where t1.NAME='SalesType' //Put here your Base Enum Type Name
Job / Runnable class
static void main(Args _args)
{
DictEnum enum = new DictEnum(enumName2Id("DEDCoreProductCatalogSetupRecType"));
int i;
for (i=0; i < enum.values(); i++)
{
info('enum integer value : '+ int2Str(enum.index2Value(i)) + ' - enum name : '+ enum.index2Label(i));
}
}