I have CSV file that contains records for all the provinces (chm, mk ...). file.csv:time,language,province,longitude,latitudenumber  en  chm number  number  number  en  mk  number  number  Structure of my PostgreSQL db looks like this: chm (schema)|    cvs (table) mk (schema)|    cvs (table): last_provinceI would like to import file.csv in PostgreSQL that records fit to same Schema/Province. chm (schema)|    cvs (table)|        time: number (column1)|        language: en (column2)|        province: chm (column3)|        longitude: number (column4)|        latitude: number (column5) mk (schema)|    cvs (table)|        time: number (column1)|        language: en (column2)|        province: chm (column3)|        longitude: number (column4)|        latitude: number (column5): last_provinceWhat is the easiest way to accomplish that?Note: I know that I can import data with command copy but I only know how to copy it to a specific schema.\copy chm.cvs(time,language,province,longitude,latitude) FROM '/home/Desktop/data/file.csv' DELIMITERS ',' CSV HEADER;Can I somehow make some kind of condition which would be equal to WHERE province = 'chm'
How can I import CSV file into a PostgreSQL based on condition
files;csv;postgresql