ODBC/OVF connection
Piero Cavalieri
piero.cavalieri at HEIDI.IT
Fri Jul 15 07:40:33 PDT 2005
Hi all,
on my devel machine I successfully connect to a layer via ODBC/OVF
connection. Layer is a MSSQL table on Win2k.
I done the same thing on production machine (Win2003) => problems.
ArchimpXP_SIAT.ovf file:
<OGRVRTDataSource>
<OGRVRTLayer name="impianti">
<SrcDataSource>ODBC:xx/xxxx at Archimp_HEIDI</SrcDataSource>
<SrcLayer>Impianti</SrcLayer>
<GeometryType>wkbPoint</GeometryType>
<LayerSRS>epsg:26591</LayerSRS>
<GeometryField encoding="PointFromColumns"
y="Longitudine"x="Latitudine" />
</OGRVRTLayer>
</OGRVRTDataSource>
.map file:
LAYER
GROUP i_dep_grp
CONNECTION "ArchimpXP_SIAT.ovf"
CONNECTIONTYPE OGR
DATA "impianti"
NAME "impianti"
METADATA
"wms_title" "Impianti Depurazione"
"wms_srs" "26591"
END
PROJECTION
"init=epsg:26591"
END
STATUS ON
...
...
web page:
...
<asp:listitem value=i_dep_grp selected=true>Depurazione</asp:listitem>
...
ODBC connection test:
ogrinfo ODBC:xx/xxxx at Archimp_HEIDI
returns the list of db tables, so seems ok.
Error messages when requesting the web page:
msDrawMap(): Image handling error. Failed to draw layer named 'impianti'.
msOGRFileOpen(): OGR error. Open failed for OGR connection
`Archimp_HEIDI.ovf'. Failed to import LayerSRS `epsg:26591'.
" msDrawMap(): Image handling error. Failed to draw layer named 'impianti'.
msOGRFileOpen(): OGR error. Open failed for OGR connection
`Archimp_HEIDI.ovf'. Failed to import LayerSRS `epsg:26591'.
"
I don't understand if errors occurs during connection open or it's layer
related.
The only difference beteween development environment seems to be that in
production machine data files are in different drive (web application in
C:, data in D:; of course SHAPEPATH is set right).
Help please
P.
More information about the MapServer-users
mailing list