Home » SQL & PL/SQL » SQL & PL/SQL » Query about the in-built functions in Oracle
Query about the in-built functions in Oracle [message #379319] Tue, 06 January 2009 01:13 Go to next message
SUHAS22845
Messages: 51
Registered: August 2008
Location: BANGALORE
Member

Hi All,

Can any one of you please tell me, weather there is any in-built function to check weather an input string is of type date or not.

Re: Query about the in-built functions in Oracle [message #379325 is a reply to message #379319] Tue, 06 January 2009 01:23 Go to previous messageGo to next message
Michel Cadot
Messages: 68733
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
There is none.
But there are many examples on how to implement this here. Search for "isdate".

Regards
Michel
Re: Query about the in-built functions in Oracle [message #379365 is a reply to message #379319] Tue, 06 January 2009 04:00 Go to previous messageGo to next message
pablolee
Messages: 2882
Registered: May 2007
Location: Scotland
Senior Member
An input string is never a date. It is a string. All you can do is check to see if maybe it can be converted into a date, but even then, you could still end up with the wrong answer:
Account Number 20011112 theoretically could be a date... But it's not.
Re: Query about the in-built functions in Oracle [message #379440 is a reply to message #379365] Tue, 06 January 2009 08:01 Go to previous messageGo to next message
joy_division
Messages: 4963
Registered: February 2005
Location: East Coast USA
Senior Member
Good answer!
Re: Query about the in-built functions in Oracle [message #379622 is a reply to message #379440] Wed, 07 January 2009 06:41 Go to previous message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
If you use the 'J' julian date format mask, then any number <= 5373484 can be a date
Previous Topic: Update in huge data in partitioned table
Next Topic: Can not connect to database
Goto Forum:
  


Current Time: Sun Feb 09 20:58:11 CST 2025