Hi, I have created a virtual field that has a computed value. However, the field value is not coming. The primary table is salesline and the method is:
public static str ItemName()
{
DictDataEntity de = new DictDataEntity(tableNum(CustomSalesOrderLineV2Entity));
int64 salesLineRecId = str2Int64(de.computedColumnString(tableStr(SalesLine),
fieldStr(SalesLine, RecId),
FieldNameGenerationMode::WhereClause));
SalesLine salesLine;
select firstonly salesLine where salesLine.RecId == salesLineRecId;
return salesLine.itemName();
}
On changing the code I passed the salesLineRecId as string and I found its value is coming as 0. Though the recid field is present in data entity as field recidcopy1. Can anyone please help me understand where I might be going wrong.