I see the format function is not supported with SQL . Is
there a equivilant I can use.
e.g.
[integer datatype]
format(employee_number,"000000") so all employee numbers
display in a 6 digit length
052365
002563
000235
instead of
52365
2563
235
thanks folks
Hi Brian !
Try this:
RIGHT("000000"+convert(varchar, NAME_OF_COLUMN), 6)
HTH, Jens S??meyer.
> I see the format function is not supported with SQL . Is
> there a equivilant I can use.
[quoted text clipped - 16 lines]
>
> thanks folks
Bryan - 08 Sep 2003 08:59 GMT
Thanks. I will give it a try.
>-----Original Message-----
>Hi Brian !
[quoted text clipped - 27 lines]
>
>.
Samuel - 15 Oct 2003 07:56 GMT
can make your MyFormat :
ALTER FUNCTION MyFormat (@strFormat nvarchar(255), @StrOrigen
nvarchar(255))
RETURNS nvarchar(255)
AS
BEGIN
RETURN SUBSTRING ( @strFormat , 1 , Len(@strFormat) - Len(@StrOrigen))
+ @strOrigen
END
> Hi Brian !
>
[quoted text clipped - 24 lines]
> >
> > thanks folks