Hi,
I have to convert SQL server function isNumeric to teradata.
IsNumeric checks for the string in numeric format or not.( eg. sel isNumeric('123'); --ans:- 1. sel isNumeric('abc'); --ans :- 0)
isNumeric also accepts numeric value or column as its parameter(dont know why??) (eg. sel isNumeric(123); --ans:- 1)
now implementing it in teradata, a way possible is overload it with two inputs, 1st varchar datatype and 2nd integer datatype( and many other datatype like FLOAT).
and it is done.
but problem occurs when it comes to null handling.
eg. sel isNumeric(null); --cant fit best function for this.
Hi,
I have to convert SQL server function isNumeric to teradata.
IsNumeric checks for the string in numeric format or not.( eg. sel isNumeric('123'); --ans:- 1. sel isNumeric('abc'); --ans :- 0)
isNumeric also accepts numeric value or column as its parameter(dont know why??) (eg. sel isNumeric(123); --ans:- 1)
now implementing it in teradata, a way possible is overload it with two inputs, 1st varchar datatype and 2nd integer datatype( and many other datatype like FLOAT).
and it is done.
but problem occurs when it comes to null handling.
eg. sel isNumeric(null); --cant fit best function for this.