Need to use custom date filters in script include for reporting
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-14-2024 09:50 AM
Hi Team,
I have requirement to pull a report on Financial year basis. (Ex April 1 2023 to March 31 2024)
Not able to use between operator
I tried to use copy query from Incident table giving input as created between 10 june to 13 june and copied query as below.
sys_created_on>=javascript:gs.dateGenerate('2024-06-10','00:00:00')^sys_created_on<=javascript:gs.dateGenerate('2024-06-13','23:59:59');
even if same hardcoded values are used in script include its giving an error.
Request your help on this.
Best Regards,
Pooja
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-17-2024 05:21 AM
Hello @Pooja58 ,
Please check the date format and also post your code here.
Please refer below article:
https://www.servicenow.com/community/developer-forum/scripted-report-script-include-function/td-p/26...
Please accept my solution if it works for you and thumps up to mark it as helpful.
Thank you!!
Thank you!!
Dnyaneshwaree Satpute
Tera Guru