Nested methods
Ivan Smahin
IvanSmahin at public.kherson.ua
Mon Jul 18 01:31:46 CDT 2005
jda wrote:
> I thought perhaps the SELECT CASE statement might do what I'm looking
> for. Here's a query that looks like it should work, but returns nothing.
> Any ideas?
>
> SELECT CASE WHEN
> LOCATE('The ',title)=1 THEN RIGHT(title, LENGTH(title) - LENGTH('The
> '))
> ELSE
> WHEN LOCATE('An ',title)=1 THEN RIGHT(title, LENGTH(title) -
> LENGTH('An '))
> ELSE
> WHEN LOCATE('A ',title)=1 THEN RIGHT(title, LENGTH(title) -
> LENGTH('A '))
> ELSE
> title
>
>
I guess you have some exception from parser -right?
Anycase you should use much more simple statement:
SELECT
CASE
WHEN ... THEN ...
WHEN ... THEN ...
WHEN ... THEN ...
...
ELSE title
END
--
Best regards,
Ivan Smahin
More information about the Valentina
mailing list