Christopher Kings-Lynne kirjutas N, 07.08.2003 kell 04:33:
> My other question is we play around with bytea fields to escape nulls and
> chars < 32 and stuff so that when someone browses the table, they get
> '\000<unknown>\000...', etc.
actually bytea *stores* char(0), you get \000 or \x0 or ¬@ or whatever
depending on whatever you use for displaying it.
the escaping i's done only to fit the data into a SQL statement when
inserting the data into the database. select returns straight bytes from
bytea.
> However, are the other field types for which
> we have to do this? Can you put nulls and stuff in text/varchar/char
> fields?
No. Nulls are not allowed in text/varchar fields.
-------------
Hannu