How to create a user defined datatype?

From: Wang, Shu-yi <wang_at_centralworks.com>
Date: Sat, 19 Jun 1999 13:39:45 -0700
Message-ID: <376C0011.B5D30A2C_at_centralworks.com>



Is there a way to create a user defined datatype in Oracle without using the "create
type" command?

For example, I want to create a datatype called "comment" which is varchar2(128), so I can define other variables as a "comment" type. I'm wondering how this can be done in Oracle. I don't want to create an object which would require me to refer the object name first then the type name.

My intention is to organize users defined variables with those datatypes. If the length of variables changed, I only want to change it at one place. I understand that good PL/SQL programming style would help, but I wonder if there is something that could be done from a DBA position.

Any suggestions and comments will be appreciated! Thanks in advance.

Wang, Shu-Yi Received on Sat Jun 19 1999 - 22:39:45 CEST

Original text of this message