<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
I'm not building from source because the environment is windows and
I don't have a way (and knowledge ) configure all compile
environment.<br>
<br>
But thank you for the explanation I understand the problem, it's
probably that because labels with big numbers are converted to
scientific notation.<br>
<br>
The round values are ok for visualization in the labels but not to
use in the class filter expressions.<br>
<br>
I will waiting ... thx<br>
<br>
Mário <br>
<br>
On 20-07-2011 16:18, Steve Lime wrote:
<blockquote
cite="mid:CAMrKZ980kRLNb3pzCPqK=5fW-vcixUwgiQHcmRjb_Rozk+uMkg@mail.gmail.com"
type="cite">I don't have access to SDE on my home box but will in
a few days when I'm back to work... SDE uses the function
msDoubleToString in mapstring.c to convert values (MapServer holds
all attribute values as strings). The conversion uses the %g
conversion specifier. That must be the problem.<br>
<br>
If you're building from source you could try changing the calls to
msDoubleToString in mapsde.c to pass MS_TRUE instead of MS_FALSE
for the last argument. That will trigger the use of %f, perhaps
that will make a difference. <br>
<br>
Could also try changing the conversion specifiers in
msDoubleToString to use %Lf and %Lg and see that fixes things.<br>
<br>
Steve<br>
<br>
<div class="gmail_quote">On Tue, Jul 19, 2011 at 12:41 PM, Mario
Franco <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:mario.franco@ydreams.com">mario.franco@ydreams.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div bgcolor="#FFFFFF" text="#000000"> Can anyone that uses
mapserver with sde reproduce the label and expression issue
that I'm having?
<div>
<div class="h5"><br>
<br>
<br>
<br>
On 15-07-2011 15:38, Mario Franco wrote:
<blockquote type="cite"> <br>
The version is Mapserver 5.6.3 and using the attribute
as label was how find out the values were being
rounded.<br>
For example the attribute has values from 1000 to
170000 and if the value is smaller than 100000 rounds
the value with one decimal but above 100000<br>
rounds to and integer.<br>
I'm using sqlserver with the SDE and the atrribute
type is numeric could this have anything to do with
it?<br>
<br>
Mário<br>
<br>
On 15-07-2011 15:23, Steve Lime wrote:
<blockquote type="cite">
<div>On issue one, what version are you using?
MapServer shouldn't be rounding the value. The
comparison should be being done as a double. It
might be helpful to see a sample dataset although
if this is SDE I can't test on my end. One thing
to try to help diagnose the problem would be to
create a sample mapfile that draws your layer and
uses the area attribute for labeling. What shows
up for labels?</div>
<div><br>
</div>
<div>Steve<br>
<br>
Sent from my iPad</div>
<div><br>
On Jul 15, 2011, at 5:14 AM, Mario Franco <<a
moz-do-not-send="true"
href="mailto:mario.franco@ydreams.com"
target="_blank">mario.franco@ydreams.com</a>>
wrote:<br>
<br>
</div>
<blockquote type="cite">
<div> Hi, <br>
<br>
I having two issues with mapserver if anyone can
help me I would be appreciated.<br>
<br>
The first has to do with an Expression in a
class:<br>
<br>
I have a shape with an attribute with the
172060.0937 but when add to the class:<br>
<br>
<blockquote type="cite"><small>EXPRESSION (
[AREA] = 172060.0937 )</small></blockquote>
<br>
The problem is that this expression returns
false because mapserver is rounding the double
value from the database. If I compare with:<br>
<br>
<blockquote type="cite"><small>EXPRESSION (
[AREA] = 172060)</small></blockquote>
<br>
it works. There is any way to turn this off or
to increase the precision?<br>
<br>
<br>
<br>
The second issue is:<br>
<br>
I'm using this url (<small><a
moz-do-not-send="true"
href="http://localhost:82/cgi-bin/mapserv.exe?map=D%3a%5Cprojects%5CInag%5CInterSIG+II%5CInterSIG+Website%5CTrunk%5CInterSIG+ASP.NET%5CMaps%2fintersig_281.map&qlayer=Concelhos&layers=Concelhos&MAPSIZE=629%20467&MINX=-232614.525612302&MINY=-49761.6088409424&MAXX=676601.080299802&MAXY=625284&mode=NQUERY&MAPSHAPE=POLYGON%28%28-232614%20-49761,%20-232614%20625284,%20676601%20625284,%20676601%20-49761,%20-232614%20-49761%29%29"
target="_blank">http://localhost:82/cgi-bin/mapserv.exe?map=D%3a\projects\Inag\InterSIG+II\InterSIG+Website\Trunk\InterSIG+ASP.NET\Maps%2fintersig_281.map&qlayer=Concelhos&layers=Concelhos&MAPSIZE=629%20467&MINX=-232614.525612302&MINY=-49761.6088409424&MAXX=676601.080299802&MAXY=625284&mode=NQUERY&MAPSHAPE=POLYGON%28%28-232614%20-49761,%20-232614%20625284,%20676601%20625284,%20676601%20-49761,%20-232614%20-49761%29%29</a></small>)
to execute a nquery but I always get the error
"msSDELayerGetShape(): SDE error.
SE_stream_fetch_row(): Invalid parameter value
passed to function. (-66) "<br>
<br>
The log doesn't help that much:<br>
<small><br>
</small>
<blockquote type="cite"><small>[Fri Jul 15
10:47:19 2011].20000 msSDELayerOpen(): Layer
Concelhos opened from scratch.<br>
[Fri Jul 15 10:47:23 2011].35000
msConnPoolRegister(Concelhos,ydinag2,port:5151,sde,sde,sde,01D6BCC0)<br>
[Fri Jul 15 10:47:23 2011].35000
msSDELayerOpen(): Layer Concelhos specified
version SDE.DEFAULT.<br>
[Fri Jul 15 10:47:23 2011].42000
msSDEGetLayerInfo(): Looking for layer by
SDE.CONCELH_PTCONT_2008_0_596, SHAPE,
ydinag2,port:5151,sde,sde,sde<br>
[Fri Jul 15 10:47:23 2011].42000
msSDEGetLayerInfo(): No cached layerid
found.<br>
[Fri Jul 15 10:47:23 2011].63000
msSDELCacheAdd(): Caching id for
SDE.CONCELH_PTCONT_2008_0_596, SHAPE,
ydinag2,port:5151,sde,sde,sde<br>
[Fri Jul 15 10:47:23 2011].72000 Getting all
column information in msSDELayerInitItemInfo<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
DICO<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
CONCELHO<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
DI<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
DISTRITO<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
CCDR<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
NUT3<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
NUT3_NOME<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
NUT2<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
NUT2_NOME<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
AREA2008_1<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
objectid<br>
[Fri Jul 15 10:47:23 2011].79000
msSDELayerInitItemInfo(): getting info for
SHAPE<br>
[Fri Jul 15 10:47:23 2011].79000 Column
information has already been gotten...
returning from msSDELayerInitItemInfo<br>
[Fri Jul 15 10:47:43 2011].122000
msSDELayerGetShape(): SDE error.
SE_stream_fetch_row(): Invalid parameter
value passed to function. (-66)<br>
[Fri Jul 15 10:47:43 2011].126000
msFreeMap(): freeing map at 01D3EFE8.<br>
[Fri Jul 15 10:47:43 2011].126000
msSDELayerCloseConnection(): Closing
connection for layer Concelhos.<br>
[Fri Jul 15 10:47:43 2011].126000
msConnPoolRelease(Concelhos,ydinag2,port:5151,sde,sde,sde,01D6BCC0)<br>
[Fri Jul 15 10:47:43 2011].126000
msConnPoolClose(ydinag2,port:5151,sde,sde,sde,01D6BCC0)<br>
[Fri Jul 15 10:47:43 2011].156000
msSDELayerClose(): Closing layer Concelhos.<br>
[Fri Jul 15 10:47:43 2011].156000
msConnPoolRelease(Concelhos,ydinag2,port:5151,sde,sde,sde,00000000)<br>
[Fri Jul 15 10:47:43 2011].156000
msConnPoolRelease(): Unable to find handle
for layer 'Concelhos'.<br>
[Fri Jul 15 10:47:43 2011].156000
msConnPoolRelease(): General error message.
Unable to find handle for layer 'Concelhos'.</small><br>
</blockquote>
<br>
<br>
Here part of my configuration:<br>
<blockquote type="cite">
<pre style="font-family:Consolas;font-size:13;color:black;background:white"> LAYER
NAME "Concelhos"
METADATA
"wms_title" "Concelhos" # required
"wfs_title" "Concelhos" # required
"gml_featureid" "ID" ## REQUIRED
"gml_geometries" "geom"
"gml_geom_type" "polygon"
"gml_include_items" "all" # Optional (serves all attributes for layer)
"gml_exclude_items" "GEOMETRY,OBJECTID"
"ows_include_items" "all"
"ows_exclude_items" "GEOMETRY,OBJECTID"
END
DUMP true
TOLERANCE 10
TOLERANCEUNITS meters
TYPE polygon
#CONNECTIONTYPE SDE
CONNECTIONTYPE PLUGIN
PLUGIN "D:/ms4w/Apache/specialplugins/msplugin_sde_92.dll"
CONNECTION "ydinag2,port:5151,sde,sde,sde"
DATA "SDE.CONCELH_PTCONT_2008_0_596,SHAPE,SDE.DEFAULT"
PROJECTION
"init=EPSG:3763" #--sistema de coordenadas desta layer na origem
END
STATUS ON
OPACITY 100
TEMPLATE '../Templates/Identify/t.html'
</pre>
</blockquote>
<br>
I'm using Mapserver 5.6.3, I know it's not the
latest but I didn't updated yet. <br>
<br>
Any help would be useful and thx in advance.<br>
<br>
Mário Franco <br>
<br>
<div> </div>
</div>
</blockquote>
<blockquote type="cite">
<div><span>_______________________________________________</span><br>
<span>mapserver-users mailing list</span><br>
<span><a moz-do-not-send="true"
href="mailto:mapserver-users@lists.osgeo.org"
target="_blank">mapserver-users@lists.osgeo.org</a></span><br>
<span><a moz-do-not-send="true"
href="http://lists.osgeo.org/mailman/listinfo/mapserver-users"
target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a></span><br>
</div>
</blockquote>
</blockquote>
<br>
<div> </div>
</blockquote>
<br>
<br>
</div>
</div>
<font color="#888888">
<div>-- <br>
<p> <span>Mário Franco</span> | Software Developer | <a
moz-do-not-send="true"
href="mailto:mario.franco@ydreams.com"
target="_blank">mario.franco@ydreams.com</a><br>
YDreams - Informática S.A. | <a
moz-do-not-send="true" href="http://www.ydreams.com"
target="_blank"> www.ydreams.com</a> | <a
moz-do-not-send="true"
href="tel:%2B351%20210%20314%20000"
value="+351210314000" target="_blank">+351 210 314
000</a> | <a moz-do-not-send="true"
href="http://www.ydreams.com/blog/" target="_blank">Blog</a>
| <a moz-do-not-send="true"
href="http://www.youtube.com/ydreams"
target="_blank">YouTube</a> | <a
moz-do-not-send="true"
href="http://www.vimeo.com/ydreams/" target="_blank">Vimeo</a>
| <a moz-do-not-send="true"
href="http://twitter.com/ydreams/" target="_blank">Twitter</a></p>
<p> <b>Disclaimer and Confidentiality Notice:</b>
YDreams accepts no responsibility or liability
whatsoever with regard to the information herein
contained. This message including any attachment
hereof is confidential and may be privileged or
otherwise legally protected from disclosure and may
only be read, copied and used by the intended
recipient. If you are not the intended recipient,
please contact the sender immediately (+351 210 314
000) and delete this email and any attachment
permanently from your system. You must not copy this
email or any attachment or disclose its/their contents
to any other person or entity. Thank you.</p>
</div>
<div> </div>
</font></div>
<br>
_______________________________________________<br>
mapserver-users mailing list<br>
<a moz-do-not-send="true"
href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a><br>
<a moz-do-not-send="true"
href="http://lists.osgeo.org/mailman/listinfo/mapserver-users"
target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a><br>
<br>
</blockquote>
</div>
<br>
</blockquote>
<br>
<br>
</body>
</html>