[Mapserver-users] Problem using ODBC

Kalpin Kalpin
Fri Jun 4 03:11:17 EDT 2004


This is a multi-part message in MIME format.

------=_NextPart_000_0076_01C44A3D.CDD5AE10
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Dear all,

I have try to edit my .map like this :

LAYER
  NAME blocks
  TYPE POLYGON
  STATUS ON
  CONNECTIONTYPE OGR
  CONNECTION "ODBC:sa/kalpin at MSQL"
  DATA "SELECT * FROM TbBlock"
  CLASS
    NAME 'BLOCKS'
    OUTLINECOLOR 128 128 128
    COLOR 160 208 117
    TEMPLATE "blocks.html"
  END
  HEADER "blocks_header.html"
  FOOTER "blocks_footer.html"=20
  METADATA
    WMS_TITLE "Blocks region"
    WMS_ABSTRACT "Blocks region shapefile."
    WMS_SRS "EPSG:26915"
  END
END

But, I get error like below :

msDrawMap(): Image handling error. Failed to draw layer named 'blocks'.=20
msOGRFileOpen(): OGR error. Open failed for OGR connection =
`ODBC:sa/kalpin at MSQL'. File not found or unsupported format.=20


What must I do ?



Thank you=20



Kalpin Erlangga Silaen
------=_NextPart_000_0076_01C44A3D.CDD5AE10
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1106" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2><FONT face=3DArial size=3D2>Dear=20
all,</FONT></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>I have try to edit my .map like this =
:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>LAYER<BR>&nbsp; NAME blocks<BR>&nbsp; =
TYPE=20
POLYGON<BR>&nbsp; STATUS ON<BR>&nbsp; CONNECTIONTYPE OGR<BR>&nbsp; =
CONNECTION=20
"ODBC:sa/kalpin at MSQL"<BR>&nbsp; DATA "SELECT * FROM TbBlock"<BR>&nbsp;=20
CLASS<BR>&nbsp;&nbsp;&nbsp; NAME 'BLOCKS'<BR>&nbsp;&nbsp;&nbsp; =
OUTLINECOLOR 128=20
128 128<BR>&nbsp;&nbsp;&nbsp; COLOR 160 208 117<BR>&nbsp;&nbsp;&nbsp; =
TEMPLATE=20
"blocks.html"<BR>&nbsp; END<BR>&nbsp; HEADER =
"blocks_header.html"<BR>&nbsp;=20
FOOTER "blocks_footer.html" <BR>&nbsp; METADATA<BR>&nbsp;&nbsp;&nbsp; =
WMS_TITLE=20
"Blocks region"<BR>&nbsp;&nbsp;&nbsp; WMS_ABSTRACT "Blocks region=20
shapefile."<BR>&nbsp;&nbsp;&nbsp; WMS_SRS "EPSG:26915"<BR>&nbsp;=20
END<BR>END</FONT></DIV>
<DIV><FONT face=3DArial size=3D2><FONT face=3DArial =
size=3D2></FONT></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>But, I get error like below =
:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2><FONT face=3D"Times New Roman" =
size=3D3>msDrawMap():=20
Image handling error. Failed to draw layer named 'blocks'. =
<BR>msOGRFileOpen():=20
OGR error. Open failed for OGR connection `ODBC:sa/kalpin at MSQL'. File =
not found=20
or unsupported format. </FONT><BR></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>What must I do ?</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thank you </FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Kalpin Erlangga =
Silaen</DIV></FONT></BODY></HTML>

------=_NextPart_000_0076_01C44A3D.CDD5AE10--




More information about the mapserver-users mailing list