<div>Hello members!</div>
<div> </div>
<div>I'm running a python script to execute an ogr2ogr command. The process has been sucessful, but now I want to create a shp for each layer a shp has. I now I must use the command :</div>
<div><font size="2" face="Courier New">ogr2ogr newX.shp -where "LAYER = 'layerValueX'" original.shp</font></div>
<div><font face="arial,helvetica,sans-serif">The code for the subprocess is as follows:</font></div>
<div><font face="courier new,monospace">for line in open("unico.txt", "r").readlines():<br> p = subprocess.Popen([C:/Archivos de programa/FWTools2.4.7/bin/ogr2ogr', line+'.shp', </font></div>
<div><font face="courier new,monospace">' -where', '\"LAYER= \'line\'\"', b+'.shp'])</font><font face="arial,helvetica,sans-serif">unfortuanely wtih this code the module reads the variable line, which as the value of the layer has a string "line": The problem is located after the word LAYER, I don't have idea about the properly way to write the quotes.</font></div>
<div> </div>
<div>Hope you can help, regards!</div>
<p style="COLOR: #000000"><br></p>