on 02-16-2015 7:43 PM
--- Sybase version Adaptive Server Enterprise/15.0.3/EBF 17687 ESD#1.1 RELSE/P/x86_64/Enterprise Linux/ase1503/2681/64-bit/FBO/Thu Aug 20 17:17:06 2009 ---
Hi all,
I have a 'very simple problem' I can sort-out and hope you can help me with it.
I have a user-defined datatype in my database
1> sp_help numericn
2> go
Type_name Storage_type Length Prec Scale Nulls Default_name Rule_name Access_Rule_name Identity
--------- ------------ ------ ---- ----- ----- ------------ --------- ---------------- ----------
numericn numericn 17 38 38 1 NULL NULL NULL 0
(1 row affected, return status = 0)
but when I try to create a table based on it, I have a failure
1> create table toto (tata numericn)
2> go
Msg 2715, Level 16, State 2
Server 'MX2931VM', Line 1
Can't find type 'numericn'.
What else should I check to figure out my issue?
Thanks
Simon
Hi Bret,
First of all, thanks for your prompt answer.
My example is not written correctly and migth be misleading but my database does have a user-defined datatype name numericn (numeric-aine) which is based on numeric,
But again you might be right as the name I gave might be a reserved word.
Thanks Bret
Simon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
A newly created ASE will have these:
1> select type, usertype, name from systypes where name like "numeric%"
2> go
type usertype
name
---- --------
---------------------------------------------------------------------------
------------------------
63 10
numeric
108 28
numericn
(2 rows affected)
Attempting to create user-defined datatype named "numerin" should get an error:
1> sp_addtype numericn, int
2> go
Msg 17302, Level 16, State 1:
Server 'rel1572_bret_sun2', Procedure 'sp_addtype', Line 214:
A type with the specified name already exists.
(return status = 1)
Cheers,
-bret
Thanks Bret,
In that case I'll use numeric null
Simon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
numeric isn't actually a user-defined datatype; it is a system defined type used to implement NUMERIC NULL.
-bret
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.