Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: SOS please help with constraint check with like
Ana C. Dent wrote:
> juan wrote:
>
>> for start i am spanish and my english is not very good, i am sorry for >> this. >> >> i want made a constraint like this >> >> CONSTRAINT "CHECPCP" CHECK(CODPOSTAL LIKE '[0-9][0-9][0-9][0-9][0-9]') >> >> this constraint works correctly in SQL Server, but not in oracle. >> >> how can i specify a rank like wich i use in SQL Server for oracle?
Postal codes can never be numeric. If they were you would lose the many postal codes that have leading 00 and 0.
-- Daniel Morgan http://www.outreach.washington.edu/ext/certificates/oad/oad_crs.asp http://www.outreach.washington.edu/ext/certificates/aoa/aoa_crs.asp damorgan_at_x.washington.edu (replace 'x' with a 'u' to reply)Received on Sun Feb 08 2004 - 13:15:06 CST