> > String: > > How to distinguish NULL and empty? > > > > In the COPY command, it conside no quoted empty as NULL and quoted ones as > > empty. > > This rule not defined in the CSV standard(RFC4180). > > For example: > > A,,B has three item: 'A', NULL and 'B' > > A,"",B has three item: 'A', empty and 'B' > > Should we follow this rule? > > I think it is good. > > Sounds good to me.
With the width-delimiter, user can set empty values by "5,,12" or "5,0,12". Should we add NULL-value support? Like: "5,<NULL>,12" How about other types? boolean, integer, float, and so on. This is my idea: For String, the user can select one chioce: "empty" (generate "FORCE NOT NULL" option for COPY or '' for INSERT), "NULL" (left nochange, for column nullable column) "ERROR" (don't generate statement, log only). "CONSTANT" (user-defined string) All of them act on NULL. For others: "NULL" (left nochange) "ERROR" (don't generate statement, log only). "CONSTANT" (user-defined string) or [other options depend on type] All of them act on NULL or empty. Until now, I have no idea with array type. ----------------------------------------------- Quan Zongliang quanzongli...@gmail.com CIT Japan: http://www.cit.co.jp CIT China: http://www.citbj.com.cn -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers