Subject | Re: [firebird-support] isNumeric() |
---|---|
Author | Ivan Prenosil |
Post date | 2005-01-03T17:14:25Z |
>From: "Lester Caine"Do you just need to test whether the value is pure numeric,
> I know I am going to have to create a UDF for this, but I'll ask the
> question first.
>
> I have a data source which has 'age' as a field. This is normally years,
> but also includes some text (3 mths, infant, 2 d, etc) There are not
> many text entries, and a lot I've filtered, but I need a check ideally
> in the CASE statement that pulls out the 'clean' numeric year entries,
> so I'm just left with the odd ones.
or whether the string is number possibly followed by 'year' word,
or do you actually need to retrieve the value itself
('20 years' -> 20, '24 months' -> 2, ... ) ?
Ivan