Bruce Momjian <[EMAIL PROTECTED]> writes:
> Particularly, how do we identify a numeric and dates?
We don't, and I'm not convinced that we should. The entire concept is
suspect in a type-agnostic system. In particular, I've really got a
problem with the fact that TypeCategory uses a fixed, nonexpansible
set of categories.
Even if you try to push ahead with using TypeCategory, I'd lay a side
bet that it doesn't work. Will those spreadsheets that make this
nonstandard assumption about quotes having semantic significance be able
to cope with all the possible output formats from timestamptz, for
instance? How about timetz, which is in the same category?
> The only other thing we could do would be to add something to pg_type
> that says whether it needs quotes. Seems like overkill.
Seems like wrong. The real problem here is that "whether it needs
quotes" depends on the program you are intending to export to, the
semantic behavior you want, and likely also the phase of the moon.
I don't think we can hope to invent a COPY behavior rule that
automagically gets this right. What's needed is a tool that can output
a user-customizable data format, and that seems to me to be outside
regards, tom lane
---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly