-
-
Notifications
You must be signed in to change notification settings - Fork 546
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem with CSV #26
Comments
I think I will need more details, like a reproductible complete test-case, because my testing here shows no problem: CL-USER> (cl-csv:read-csv-row "C:\\some\\nasty\\windows\\path\\,foo"
:separator #\,
:quote #\"
:escape "\\\"")
("C:\\some\\nasty\\windows\\path\\" "foo")
CL-USER> (cl-csv:read-csv-row "C:\\some\\nasty\\windows\\path\\"
:separator #\,
:quote #\"
:escape "\\\"")
("C:\\some\\nasty\\windows\\path\\") See the test/ directory for easy self-contained examples using the Also, in your case, did you notice that you can actually directly connect pgloader to the MySQL source and load from a database connection? |
I was trying to use CSV because I have to load the data (only) from mysql to postgres and the CSV-source gives me the possibility to configure the table/column mapping between source and target (e.g. 'user.userid' => 'users.id'). I don't think that this is possible with the mysql-source, or at least I did not find any options to specify the table/column-mapping between mysql and postgres. I can specify a specific table, I can say 'data only', and I can cast types by column - but I cannot configure the actual mapping. Or did I miss something? |
You can speficy the mapping using a MySQL View on top of your current data model, then have pgloader only migrate the views. Easier way to do that is create a new schema in MySQL and have all the views in there, as they will be able to refer to the main tables in the main schema. See the clause |
Nice workflow - thanks for your hints! |
Closing this for now as I lost my failing pgloader-script and cannot provide more details to reproduce the csv-reading error. |
Hi,
pgloader has problems with csv-values like this one:
It responds with:
I used the following WITH options:
The csv was created with mysqldump:
Seems like there is a bug in pgloader's csv-parser?
The text was updated successfully, but these errors were encountered: