CoreBOSBB
How to create a report of records that have missing date? - Printable Version

+- CoreBOSBB (https://discussions.corebos.org)
+-- Forum: Support (https://discussions.corebos.org/forumdisplay.php?fid=17)
+--- Forum: Administrator Support (https://discussions.corebos.org/forumdisplay.php?fid=8)
+--- Thread: How to create a report of records that have missing date? (/showthread.php?tid=1325)



How to create a report of records that have missing date? - Guido1982 - 10-31-2018

I need to create a report of assets and filter those on a custom date field. The filter criterium is that the field should be empty (it is not mandatory). We want to create a list of assets where that date is missing. But in reports, I can't filter on empty dates since an empty string is not a valid date format. I also tried a dash '-' and '00-00-0000', but without success. How can I filter reports on empty date fields?


RE: How to create a report of records that have missing date? - joebordes - 10-31-2018

Have you tried a dollar sign?

http://corebos.org/documentation/doku.php?id=en:using_filters#blank_dates


RE: How to create a report of records that have missing date? - joebordes - 10-31-2018

The code for that to work is there:

https://github.com/tsolucio/corebos/blob/master/modules/Reports/ReportRun.php#L723

but it doesn't get the results, while I have someone look into that you can use the other accepted format: --$

that string worked for me


RE: How to create a report of records that have missing date? - Guido1982 - 10-31-2018

Thanks! I'll try that. Never occurred to me that this could be in the docs..


RE: How to create a report of records that have missing date? - Guido1982 - 11-01-2018

Seems to have done the trick for me. Glad to see I only got 5 results. I included the column that I wanted to check in the report, all dates showed 00-00-0000 (which is SQL for no date if I'm not mistaken).