Hello,
I'm trying to create a composite type with an argument, to create one field of
this type like character varying(x), but I don't know if this can be done with
PostgreSQL. I want something like:
CREATE TYPE mytype AS (
tx character varying(x),
t2nd integer
);
I need to limit the number of chars in this field tx. And different lengths
will be used when creating tables with this type (so a Domain will suffer the
same problem). I'm not looking for a solution like a separate column with
maxChars and a Check, because lots of columns will be required (and others
design reasons).
Any suggestions?
Thanks.
----------------------------------------------------------------------
Free pop3 email with a spam filter.
http://www.bluebottle.com/tag/5
---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?
http://archives.postgresql.org/