Can anyone tell me why the following SQL refuses to insert more than 1 result (using sqlite3)? And how to make it insert all distinct values from the select port_shipment?
The cargo table in this database contains more than 2000 distinct values for port_shipment, but I tried several versions of the insert-command which resulted always in only 1 value inserted.
create table port (
port_ID integer not null primary key,
port_description text unique collate nocase,
port_name text,
country text,
lat text,
lon text
)
insert or ignore into port (port_ID, port_description)
values (null, (SELECT port_shipment FROM cargo))
Thanks!