constraint on a column

I am a little confused on the correct way to add a certain constraint on a
column.

I am using PD 9.5 with a physical data model for a Sybase ASE 12.0 database.

I have a column "SIC_Code" CHAR(8) which needs to be filled with only
digits. I can't use a numeric datatype because some values will have leading
zero's ( "07896656" ).

I want to put a column constraint, but don't understand how to create the
proper expression so it gets in the ddl script that I generate. Any hints?

Thanks in advance.

John Dzilvelis


0
Johndz
2/12/2003 7:32:39 PM
sybase.powerdesigner.general 9408 articles. 1 followers. Follow

1 Replies
556 Views

Similar Articles

[PageSpeed] 52
Get it on Google Play
Get it on Apple App Store

I'm not sure of the functions in ASE, but what I've seen before is something
like a series of "Charat(1) between '0' and '9'".  You might ask this
question in the ASE forums to see if there are any shortcuts or faster
functions.

--
Michael F. Nicewarner [TeamSybase]
http://www.datamodel.org
mailto:psyclo@NO_SPAM.datamodel.org


"Johndz" <john_REMOVEME_dzilvelis@coxtarget.com> wrote in message
news:v5ji2At0CHA.198@forums.sybase.com...
> I am a little confused on the correct way to add a certain constraint on a
> column.
>
> I am using PD 9.5 with a physical data model for a Sybase ASE 12.0
database.
>
> I have a column "SIC_Code" CHAR(8) which needs to be filled with only
> digits. I can't use a numeric datatype because some values will have
leading
> zero's ( "07896656" ).
>
> I want to put a column constraint, but don't understand how to create the
> proper expression so it gets in the ddl script that I generate. Any hints?
>
> Thanks in advance.
>
> John Dzilvelis
>
>


0
Mike
2/19/2003 1:15:28 PM
Reply: