Skip to content
This repository was archived by the owner on Aug 14, 2019. It is now read-only.

Records from the table 'release_name' is not fully copied #31

Open
shultz-zz opened this issue Jul 4, 2011 · 4 comments
Open

Records from the table 'release_name' is not fully copied #31

shultz-zz opened this issue Jul 4, 2011 · 4 comments
Milestone

Comments

@shultz-zz
Copy link

I run this query from \backend\mysql.pl
mysql> LOAD DATA LOCAL INFILE 'C:\release_name' INTO TABLE release_name1 FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '' LINES TERMINATED BY '\n' STARTING BY '';
and saw
Query OK, 790828 rows affected, 3 warnings (44.42 sec)
Records: 802086 Deleted: 0 Skipped: 11258 Warnings: 0

Why do so many records missing?

@chancemedia
Copy link
Collaborator

The release_name table contains unique text names for releases not the releases themselves. For example the title "Greatest Hits" would be used by many releases but that only gets one record in the release_name table.

select count(*) from release_name;

805874

select count(*) from release;

956678

@shultz-zz
Copy link
Author

it's clear, because some releases are grouped into release_group. But in my case dont copied rows with non-unique field name
Why i have 11 258 missing records?

@chancemedia chancemedia reopened this Jul 4, 2011
@chancemedia
Copy link
Collaborator

They are not "missing" mysql has decided not to process them. It might do this for a variety of reasons:

  1. The files are valid but mysql doesn't understand the character set of some data.
  2. The data files are not formatted in a way mysql can understand.

Look at your warnings by typing SHOW WARNINGS immediately after the loading file.

@shultz-zz
Copy link
Author

Only 3 warnings, but missed more than 11 thousand records

+---------+------+---------------------------------------------------------------------------------------+
| Level | Code | Message |
+---------+------+---------------------------------------------------------------------------------------+
| Warning | 1366 | Incorrect string value: '\xF0\x90\x90\xA4\xF0\x90...' for column 'name' at row 102813 |
| Warning | 1366 | Incorrect string value: '\xF0\x9D\x84\x9E\xE3\x81...' for column 'name' at row 309524 |
| Warning | 1366 | Incorrect string value: '\xF0\xA1\x91\x9E t...' for column 'name' at row 437176 |
+---------+------+---------------------------------------------------------------------------------------+
3 rows in set (0.00 sec)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants