PostgreSQL copies the data into the table

I use the copy command in Postgresql, I have a line of data in a text file, it is the separator, I want to copy it to the db table.

I received an error saying:
Error: Invalid byte sequence encoding “UTF8”: 0x00
SQL status: 22021
Context: COPY real_acct1, line 113038

< p>So I went from the text file to line 113038 and copied it along with 4 or 5 adjacent lines into a new text file and saw the new data come in.

Any useful idea? This is parcel data attribute information.

Your question is actually one of the character encodings. < p>

The easiest way to deal with this problem is to run import data through iconv (assuming you are using a unix machine).

iconv -f original_charset -t utf-8 originalfile> New file

I use the copy command in Postgresql, I have a line of data in a text file, it is the delimiter, and I want to copy it into the db table.

I received an error saying:
Error: Invalid byte sequence encoding “UTF8”: 0x00
SQL status: 22021
Context: COPY real_acct1, No. 113038 Line

So I went from the text file to line 113038 and copied it along with 4 or 5 adjacent lines into a new text file and saw the new data enter.

Any useful ideas? This is parcel data attribute information.

Your problem is actually one of the character encodings.

Handle this problem The easiest way is to run the import data through iconv (assuming you are using a unix machine).

iconv -f original_charset -t utf-8 originalfile>new file

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 744 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.