Hi all, I have a question... the option field "Type" on the Sales Invoice Line has options (" ",Account (G/L),Item,Resource,,Charge (Item),,,,,Header,Begin-Total,End-Total);
the option field "Service Type" has options (" ",G/L Account,Item,Labor,Ext. Service).
what does the filter SalesInvoiceLine.SETFILTER("Type",'%1',SalesInvoiceLine."Service Type"::"G/L Account"); do?
Thanks
0
Answers
This is becasue G/L Account options on "Service Type" has the same ordinal (1) like G/L Account option in the Type field.
The reason is that the option values are stored as numbers in the actual tables, and are filtered like numbers.
If you number the options in the Type field you will get:
" " -> 0,Account (G/L) -> 1,Item >2,Resource->3,4,Charge (Item)->5,6,7,8,9,Header->10,Begin-Total->11,End-Total->12
Please note that empty options also counts, therefore resource is number 3, then there is empty option which would be stored as 4, and then the Charge (Item) which is stores as 5
The same for the "Service Type":
" " -> 0,G/L Account -> 1,Item->2,Labor->3,Ext. Service0>4
So the is exactly the same as which is exactly the same as
I hope this makes sense.
Slawek
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-03