Many, many thank's jeff, mike and michael :-) So I finaly find something and it's so stupid! All is about OS type Instantclient vs ms4w... I try and I try since 3 days with 64bits Oracle client instead of 32bits :-( My VMWare server is a 64-bit OS but ms4w only supported in 32bit! SHAME ON ME Silverfox ...<div>
<br></div><div><div><a href="http://osgeo-org.1560.n6.nabble.com/MS4W-Users-OS-support-td4263646.html">http://osgeo-org.1560.n6.nabble.com/MS4W-Users-OS-support-td4263646.html</a></div><div><br></div><div>But hey, I find Mike tips very useful for this one...</div>
<div><br></div><div><span style>set CPL_DEBUG=on</span></div><div><span style><br></span></div><div>cheers and have a nice w-e</div><div><br></div><div><br></div><br><div class="gmail_quote">2012/5/30 Smith, Michael ERDC-CRREL-NH <span dir="ltr"><<a href="mailto:Michael.Smith@usace.army.mil" target="_blank">Michael.Smith@usace.army.mil</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Jeff,<br>
<br>
I tested out ms4w with the 11gR2 Instant Client (it was the full client<br>
installer and I just installed the instant client). I had no problems<br>
accessing and oracle database.<br>
<br>
Note that I did not use a TNS connection. I used the Oracle EZConnect<br>
syntax, which is username/password@servername:port/service_name. Note that<br>
the port can be dropped if it is the default 1521. I moved the ogr_OCI.dll<br>
file to the C:\ms4w\gdalplugins directory. Then verified that the Oracle<br>
client was on the path.<br>
<br>
----<br>
Test run<br>
<br>
<br>
C:\ms4w>set<br>
Path=C:\app\Administrator\product\11.2.0\client_1;C:\WINDOWS\system32;C:\WI<br>
NDOWS<br>
...<br>
<br>
C:\ms4w>setenv.bat<br>
GDAL, mapserv, mapcache, PROJ, and shapelib dll<br>
GDAL_DATA path set<br>
GDAL_DRIVER_PATH set<br>
PROJ_LIB set<br>
CURL_CA_BUNDLE set<br>
C:\ms4w>ogrinfo --formats<br>
<div class="im">Supported Formats:<br>
-> "OCI" (read/write)<br>
-> "ESRI Shapefile" (read/write)<br>
</div> ...<br>
<br>
-> "SEGY" (readonly)<br>
<br>
C:\ms4w>ogrinfo<br>
oci:myuser/<a href="http://mypass@dbname.army.mil/servicename.army.mil:esri.states" target="_blank">mypass@dbname.army.mil/servicename.army.mil:esri.states</a><br>
INFO: Open of<br>
`oci:myuser/<a href="http://mypass@dbname.army.mil/servicename.army.mil:esri.states" target="_blank">mypass@dbname.army.mil/servicename.army.mil:esri.states</a>'<br>
using driver `OCI' successful.<br>
1: esri.states<br>
<br>
C:\ms4w>set CPL_DEBUG=on<br>
<br>
C:\ms4w>ogrinfo<br>
oci:myuser/<a href="http://mypass@dbname.army.mil/servicename.army.mil:esri.states" target="_blank">mypass@dbname.army.mil/servicename.army.mil:esri.states</a><br>
<div class="im">OGR: Auto register \ms4w\gdalplugins\ogr_OCI.dll using RegisterOGROCI.<br>
</div>OCI: Userid=myuser, Password=mypass,<br>
Database=<a href="http://dbname.army.mil/servicename.army.mil" target="_blank">dbname.army.mil/servicename.army.mil</a><br>
OCI: Prepare(ALTER SESSION SET NLS_DATE_FORMAT='YYYY/MM/DD'<br>
NLS_TIME_FORMAT='HH24:MI:SS' NLS_TIME_TZ_FORMAT='HH2<br>
4:MI:SS TZHTZM' NLS_TIMESTAMP_FORMAT='YYYY/MM/DD HH24:MI:SS'<br>
NLS_TIMESTAMP_TZ_FORMAT='YYYY/MM/DD HH24:MI<br>
:SS TZHTZM')<br>
OCI: Prepare(SELECT COUNT(*) FROM ALL_SDO_GEOM_METADATA u,<br>
TABLE(u.diminfo) t WHERE u.table_name = 'states' AND u.colu<br>
mn_name = 'SHAPE')<br>
OCI: get dim based of existing data or index failed.<br>
OCI: Prepare(SELECT SRID FROM ALL_SDO_GEOM_METADATA WHERE TABLE_NAME =<br>
UPPER('states') AND COLUMN_NAME = UPPER('SHAPE')<br>
AND OWNER = 'esri')<br>
OGR:<br>
OGROpen(oci:myuser/<a href="http://mypass@dbname.army.mil/servicename.army.mil:esri.states/
022F38D8" target="_blank">mypass@dbname.army.mil/servicename.army.mil:esri.states/<br>
022F38D8</a>) succeeded as OCI.<br>
<br>
INFO: Open of<br>
`oci:myuser/<a href="http://mypass@dbname.army.mil/servicename.army.mil:esri.states" target="_blank">mypass@dbname.army.mil/servicename.army.mil:esri.states</a>'<br>
using driver `OCI' successful.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Michael Smith<br>
<br>
US Army Corps<br>
Remote Sensing GIS/Center<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
<br>
<br>
<br>
On 5/30/12 4:18 PM, "Jeff McKenna" <<a href="mailto:jmckenna@gatewaygeomatics.com">jmckenna@gatewaygeomatics.com</a>> wrote:<br>
<br>
>With Mike's debug trick I do see more info when I pass a bad SID to<br>
>OGR/GDAL:<br>
><br>
>ogrinfo OCI:jeff/marvin@geo2<br>
> OGR: Auto register \ms4w\gdalplugins\ogr_OCI.dll using RegisterOGROCI.<br>
> OCI: Userid=jeff, Password=marvin, Database=geo2<br>
> ERROR 1: ORA-12154: TNS:could not resolve the connect identifier<br>
>specified<br>
> in <unnamed><br>
> OCI: Userid=jeff, Password=marvin, Database=geo2<br>
> ERROR 1: ORA-12154: TNS:could not resolve the connect identifier<br>
>specified<br>
> in <unnamed><br>
> FAILURE:<br>
> Unable to open datasource `OCI:jeff/marvin@geo2' with the following<br>
>drivers.<br>
> -> OCI<br>
> -> ESRI Shapefile<br>
> -> MapInfo File<br>
> -> UK .NTF<br>
><br>
>-jeff<br>
><br>
><br>
><br>
><br>
>--<br>
>Jeff McKenna<br>
>MapServer Consulting and Training Services<br>
><a href="http://www.gatewaygeomatics.com/" target="_blank">http://www.gatewaygeomatics.com/</a><br>
><br>
><br>
>_______________________________________________<br>
>MS4W-Users mailing list<br>
><a href="mailto:MS4W-Users@lists.maptools.org">MS4W-Users@lists.maptools.org</a><br>
><a href="http://lists.maptools.org/mailman/listinfo/ms4w-users" target="_blank">http://lists.maptools.org/mailman/listinfo/ms4w-users</a><br>
<br>
_______________________________________________<br>
MS4W-Users mailing list<br>
<a href="mailto:MS4W-Users@lists.maptools.org">MS4W-Users@lists.maptools.org</a><br>
<a href="http://lists.maptools.org/mailman/listinfo/ms4w-users" target="_blank">http://lists.maptools.org/mailman/listinfo/ms4w-users</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>Simon Mercier<br>Co-Fondateur et Vice-Président chez Solutions Mapgears<br><div><div><div>2383 chemin Ste-Foy, bureau 202, Québec, QC</div><div>Canada G1V 1T1</div>
</div><div><div><br>Tel _ 418.559.7139<br>web _ <a href="http://mapgears.com" target="_blank">mapgears.com</a></div><div>blog _ <a href="http://simonmercier.net/blog" target="_blank">http://simonmercier.net/blog</a><br>linkedIn _ <a href="http://ca.linkedin.com/in/simonmercier" target="_blank">http://ca.linkedin.com/in/simonmercier</a><br>
twitter _ <a href="http://twitter.com/simonmercier" target="_blank">http://twitter.com/simonmercier</a></div></div><div><br></div></div><br>
</div>