Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Handle Date format in a dynamic way

Hi Experts,

I need to handle the date format in a dynamic way in different systems.

Sample Scenario:

In my DEV system i am writing a select query where i need to validate the date field which is of the format 12/31/9999.

select * from <table> where date = '12/31/9999'.

This gets relevant records & works fine in DEV system.

But when it goes to QA system the same select query fails to fetch data as the date format is 12.31.9999.

select * from <table>

where date = '12/31/9999'. --> Fails

Similarly when it is PRD system (production) the same select query fails as the date format is 12-31-9999.

select * from <table>

where date = '12/31/9999'. --> Fails

Please post your suggestions.

Thanks

Dany

Tags:
Former Member

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question