Failed to import Data from csv into CloudSQL-postgres

872 views
Skip to first unread message

Ahmed Mohamed

unread,
Jan 29, 2021, 1:11:12 PM1/29/21
to Google Cloud SQL discuss

Hi GCP- community, 

I have a csv table in cloud storage that matches the table in CloudSQL. The service account of CloudSQL instance has granted storage.objectAdmin IAM role as mentioned in the GCP-Documentions. I am also the owner of the project. 

1- When I imported the data into the table (Overview--> import) the job shows up that the data has been successfully imported but when I check the table using SELECT it doesn't deliver any data?

2- When I use the gcloud sql command: gcloud sql import csv gs://[BUCKET_NAME]/[FILE_NAME] --database=[DATABASE_NAME] --table=[TABLE_NAME] I get this msg : ERROR: (gcloud.sql.import.csv) [ERROR_RDBMS] ERROR: relation "temp_value" does not exist 

Thanks For your support!

 

Olu

unread,
Feb 1, 2021, 10:32:04 AM2/1/21
to Google Cloud SQL discuss

Hello, 

Thank you for reporting this issue to this thread. 

I understand you obtained an Error RDBMS while attempting to import your data from a CSV file in Cloud Storage to your CloudSQL Instance. I wonder if this issue still persists. As explained in this documentation[1 -- please see the last few words of the section], this type of error often suggests a few things about your setup. 
"If you get an error such as ERROR_RDBMS, ensure the table exists. If the table exists, confirm that you have the correct permissions on the bucket."

Can you please confirm that the table exists?

Reply all
Reply to author
Forward
0 new messages