Argh! What's a 'bpchar'? (copy/serial issues...I think)
От | Ken Corey |
---|---|
Тема | Argh! What's a 'bpchar'? (copy/serial issues...I think) |
Дата | |
Msg-id | 3A6776A3.FA725B59@kencorey.com обсуждение исходный текст |
Ответы |
Re: Argh! What's a 'bpchar'? (copy/serial issues...I think)
|
Список | pgsql-novice |
I'm trying to copy some data (several hundred rows) from the file /tmp/player.txt containing: 9,test16610,EN,NULL,a@b.com 10,test24930,EN,NULL,a@b.com 11,test19829,EN,NULL,a@b.com 12,test6285,EN,Y,a@b.com 13,test20885,EN,NULL,a@b.com ... into this table: CREATE TABLE PLAYER ( PLAYER_ID SERIAL, PLAYER_NAME varchar(255) NOT NULL, PLAYING_FOR varchar(255) NOT NULL, CHEAT_FLAG char(1) NULL, EMAIL varchar(255) NULL, --UNIQUE (PLAYER_NAME,PLAYING_FOR,EMAIL), CONSTRAINT PK_PLAYER PRIMARY KEY (PLAYER_ID) ) ; with this command: GRE=# copy player from '/tmp/player.txt' using delimiters ','; ERROR: Unable to identify an operator '=' for types 'bpchar' and 'varchar' You will have to retype this query using an explicit cast ERROR: Unable to identify an operator '=' for types 'bpchar' and 'varchar' You will have to retype this query using an explicit cast (I've tried adding a "with null as 'null'", with no success.) Anyone got a clue for the newbie? -Ken
В списке pgsql-novice по дате отправления: