[Qgis-user] Qgis 2.13 on windows 7: ogr2ogr oracle to shape does not keep decimals.

Nicolas Cadieux nicolas.cadieux at archeotec.ca
Mon Jan 11 07:08:43 PST 2016


Hi, 
Just ideas... 
I have no idea what a blob field is... But can you save the file in spatialite?  That is a more modern file format than shp files.  Have you tried exporting without this field in QGIS?  Are the decimals ok?  Could you then export the blob field using ogr then link it back to the shp file after?  Could you use and intermediate database format like postgreSQL before you send it to .shp? 
You are right, playing with local language config usually fixes problems like decimal comma vs point problems.  Make sure everything is in us English from data base to your computer.  Try exporting a few lines in other formats to see if it an org2org thing or a machine configuration problem...  If you find no solutions, you could ultimately separate that field in Oracle between int and decimals and then use the field calculator to recreate the decimals... 
Nicolas Cadieux M.Sc. 
Les Entreprises Archéotec inc.  
8548, rue Saint-Denis Montréal H2P 2H2 
Téléphone: 514.381.5112  Fax: 514.381.4995 
www.archeotec.ca 
On Jan 11, 2016 5:20 AM, "Lopez Agostini, Diana [via OSGeo.org]	" <ml-node+s1560n5244514h95 at n6.nabble.com> wrote: 





Hi, 
  
We’ve got a vector layer in a spatial oracle repository. 
We need to export it (both geometry and attributes) to a shape file. 
  
We cannot use “save as shape” directly from qgis, because the oracle layer has a blob field that prevent this operation.

And we cannot drop the blob field because it is needed for other purposes. 
  
So we’re using OGR2OGR instead. 
The oracle layer have several fields  tipus ‘double’: 
  

  
After de conversion, the shape file keeps  the double format, but we’ve lost the decimal data. 
For exemple: 
  
Before conversion: AREA_HA = 3379.88378172 
After conversion:    AREA_HA=  3379 
  
We have repeated the conversion applying different “locale” configurations, in case the problem was originated by the decimal separation character used: “.” or “,”. 
However, the results are equally bad. 
  
Do you know any workaround for this issue ?

  
  
Thanks in advance, 
  
  [hidden email] 

  



_______________________________________________
Qgis-user mailing list
[hidden email] 
List info: http://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: http://lists.osgeo.org/mailman/listinfo/qgis-user 

	
	
	
	
	
	
	
		If you reply to this email, your message will be added to the discussion below: 
		http://osgeo-org.1560.x6.nabble.com/Qgis-2-13-on-windows-7-ogr2ogr-oracle-to-shape-does-not-keep-decimals-tp5244514.html 
	
	
		To start a new topic under Quantum GIS - User, email ml-node+s1560n4125267h38@n6.nabble.com 
		To unsubscribe from Quantum GIS - User, click here . 
		NAML 
	



--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Qgis-2-13-on-windows-7-ogr2ogr-oracle-to-shape-does-not-keep-decimals-tp5244514p5244577.html
Sent from the Quantum GIS - User mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20160111/8da4c275/attachment.html>


More information about the Qgis-user mailing list