Test for NULL or Empty Custom Field in REPORT

Well having fun with SUPPLIER Purchase Orders and it seems SambaPOS may be able to build a simple Suppliers Purchase Order System :smile:

I need help with some simple syntax on not showing lines on a Report where a field is Blank. Can some please assist as I still a little green on Reports?

Report Below:

Trying Syntax:

[Supplier Orders:1,2,3, 3]
{REPORT ENTITY DETAILS:E.Name,EC.Company Name,EC.Email,EC.Orders:(ET=Suppliers):{0}|{1}|{2}|{3}::$4!="":}

Not sure how to eliminate records where ENTITY:Supplier:Orders is Blank? Offending Syntax $4!=""

This report probably will also be generated either paginated OR by Supplier Name.

Well back into for the night shift but have not progressed very far! HELP NEEDED…

[Supplier Orders:1,2,3, 3]
{REPORT ENTITY DETAILS:E.Name,EC.Company Name,EC.Email,EC.Orders.asc:(ET=Suppliers):{0}|{1}|{2}|{3}:::}

Still cannot remove lines with blank Custom Field Data:EC.Orders?
Any reference to EC.Orders returns a blank report and any reference to $4 does the same?

wouldnt it be $3!=''"?

4 columns with 0 being first…

No I think as that numbering is for the column place holders {x} but not returned variables? Anyway It will not test anything before the last COLON if I do not suffix ‘ASC’ to EC.Orders.asc

Also adding anything to :(ET=Suppliers) && EC.Orders!=’’ just returns a blank report…

@Jesse this is my Customer Balance Report which works fine?

[Customer Balances:1,2,3, 1]
{REPORT ENTITY DETAILS:E.Name,EC.Full Name,EC.Address,E.Balance.Sum;0.00;-0.00;0.00:(ET=Customers) && E.AccountId>0:{0}|{1}|{2}|${3}::$4!=0:}

Has to be something with CUSTOM FIELDS - ah crap hurting my head…

Trying some funky Ternary to see if I can omit lines that way but epic FAIL!

Just returns EC.Orders but does only print 3 lines?

[Ternary Test A:1,1]
{REPORT ENTITY DETAILS:EC.Orders:(ET=Suppliers)} != '' ? 'Yes' : 'No'

Prints nothing except the Header.

[Ternary Test B:1,1]
[=('{REPORT ENTITY DETAILS:EC.Orders:(ET=Suppliers)}' == '' ? 'No' : 'Yes')]

Ok Found something where @emre is using a Custom Field in the EXPRESSION!

Ummm - suggestions welcome in the mean time…

Ok stumped this should work? Wonder what version is required!

[Another Test C:1,1]
{REPORT ENTITY DETAILS:E.Name,EC.Orders:(ET=Suppliers) && Entity.GetCustomData("Orders")!=''}

Did you try ‘null’ ?

Well slightly better this produced all records but? So records with blank Orders printed:

{REPORT ENTITY DETAILS:E.Name,EC.Orders:(ET=Suppliers) && Entity.GetCustomData("Orders")!=null}

But in 100 attempts least you got something out!
The field is a “widestr” on testing it thinks all records contain same data. So “=null” returns no records and !=null returns ALL records.

#“winner, winner chicken dinner!”

{REPORT ENTITY DETAILS:E.Name,EC.Orders:(ET=Suppliers) && Entity.GetCustomData("Orders").contains("\r")}

Sorry, I get a little excited when a have a tiny win :smiley: