The following documentation comment has been logged on the website: Page: https://www.postgresql.org/docs/14/sql-copy.html Description:
When copying a csv file into a table, ifthere is a string missing a double quote in the end, COPY will return an error saying the string is infinitely long. But placing quote '''' (quote and four single quotes) resolves the issue. The documentation does not explain why that mechanism would work, and instead refers to fixing the csv file.