Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I would like to exclude all values for a field that are a certain length.
The reason for this is because a user has entered a false value against an invoice of 4 billion odd. This has been invoiced and then credited in our ERP system, but still shows in QlikView and really screws up the legends on our charts.
I'm guessing the easiest way would be to just if the invoice value is more than 9 characters trim to null as we will be dealing with a + and - value.
Any advice would be greatly appreciated.
Hi Lewis,
You can check for the length of that field in the script, and set its value to 0, so when it's aggregated or summed in the script will return 0.
LOAD ...
If(Len(InvoiceValue) > 9, 0, InvoiceValue) AS InvoiceValue,
If(Len(InvoiceValue) > 9, 1) AS FlagIncorrectInvoiceValue,
...
Hope that helps.
Miguel
Hi Lewis,
You can check for the length of that field in the script, and set its value to 0, so when it's aggregated or summed in the script will return 0.
LOAD ...
If(Len(InvoiceValue) > 9, 0, InvoiceValue) AS InvoiceValue,
If(Len(InvoiceValue) > 9, 1) AS FlagIncorrectInvoiceValue,
...
Hope that helps.
Miguel
Perfect, thank you Miguel!