Subject CORRECTION Re: [firebird-support] formatting a number
Author Ali Gökçen
Hi Grant,
sorry about my codes, it was not the direct compilable code.
I will be more carefull and detailed from now.

Yes you can use case, coalasce in SPs.

here is the compilable code:

mypaddednumber = ( case when mynumber<10 then '00000000'
when mynumber<100 then '0000000'
...
end
)
|| mynumber;

Regards,

Ali


--- In firebird-support@yahoogroups.com, Grant Brown <grant@s...>
wrote:
> Hi Ali,
>
> I can not seem to get the case statement to work inside a stored
procedure.
>
> Am I missing something ?
>
> --
> Regards,
> Grant Brown
>
> Product Development Manager
> Phone : 02 4229 1185
> Mobile : 0412 926 995
> Email : grant@s...
> Web : www.sitedoc.com.au
>
> SiteDoc - Easy to Use - Powerful Results