I have a local install of CartoDB in my Ubuntu 14.04. I have created a CartoDB account called "development" and been playing with it for a while. Now I'd like to import some data from a shapefile directly using ogr2ogr.

I've installed GDAL 2.0 since this post mentioned ogr2ogr wouldn't create new tables in CartoDB unless upgraded to 2.0, and tried this command:

ogr2ogr --config CARTODB_API_KEY XXXX -f CartoDB "CartoDB:development" myfile.shp

This is what I get:

ERROR 1: HTTP error code : 404
ERROR 1: HTML error page returned by server
ERROR 1: CartoDB driver doesn't support database creation.
CartoDB driver failed to create CartoDB:development
  • Having this error too... does it mean you have to have the table created first in CartoDB then you can run GDAL to populate it? – DPSSpatial Aug 7 '15 at 17:06

I think you may have the ogr2ogr syntax wrong. The last line suggests that ogr2ogr didn't expect that type of argument.

I'm using GDAL 2.1.0dev, and this works for me:

ogr2ogr --config CARTODB_API_KEY XXXX -f CartoDB CartoDB:wri-02 myfile.shp

I think you just need to remove the quotes around the "CartoDB:Development", provided that your account is really development.cartodb.com.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.