<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.7601.17537"></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial>Pierre,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial>Actually the single raster version is documented. Though
I did run into memory issues -- so still think we need some work on
that.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial><A
href="http://www.postgis.org/documentation/manual-svn/RT_ST_MapAlgebra.html">http://www.postgis.org/documentation/manual-svn/RT_ST_MapAlgebra.html</A></FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial>Regina</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial><A
href="http://www.postgis.us">http://www.postgis.us</A></FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=725142019-14032011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV><FONT color=#0000ff size=2
face=Arial></FONT><FONT color=#0000ff size=2 face=Arial></FONT><FONT
color=#0000ff size=2 face=Arial></FONT><BR>
<DIV dir=ltr lang=en-us class=OutlookMessageHeader align=left>
<HR tabIndex=-1>
<FONT size=2 face=Tahoma><B>From:</B>
postgis-users-bounces@postgis.refractions.net
[mailto:postgis-users-bounces@postgis.refractions.net] <B>On Behalf Of
</B>Andreas Forø Tollefsen<BR><B>Sent:</B> Monday, March 14, 2011 2:03
PM<BR><B>To:</B> PostGIS Users Discussion<BR><B>Cc:</B> Pierre
Racine<BR><B>Subject:</B> Re: [postgis-users] PostGIS Raster
Decimal?<BR></FONT><BR></DIV>
<DIV></DIV>Hi Pierre,
<DIV><BR></DIV>
<DIV>I will check it out tomorrow and give some feedback.</DIV>
<DIV><BR></DIV>
<DIV>Cheers,</DIV>
<DIV>Andreas<BR><BR>
<DIV class=gmail_quote>2011/3/14 Pierre Racine <SPAN dir=ltr><<A
href="mailto:Pierre.Racine@sbf.ulaval.ca">Pierre.Racine@sbf.ulaval.ca</A>></SPAN><BR>
<BLOCKQUOTE
style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex"
class=gmail_quote>
<DIV lang=EN-US vlink="purple" link="blue">
<DIV>
<P class=MsoNormal><SPAN style="COLOR: #1f497d; FONT-SIZE: 11pt">I’m very
aware of the problem. Will try to fix it the best we can. </SPAN></P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d; FONT-SIZE: 11pt"></SPAN> </P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d; FONT-SIZE: 11pt">Why not
testing ST_MapAlgebra and give us your feedback? It is still to document but
the specifications are in this page:</SPAN></P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d; FONT-SIZE: 11pt"></SPAN> </P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d; FONT-SIZE: 11pt"><A
href="http://trac.osgeo.org/postgis/wiki/WKTRaster/SpecificationWorking02"
target=_blank>http://trac.osgeo.org/postgis/wiki/WKTRaster/SpecificationWorking02</A></SPAN></P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d; FONT-SIZE: 11pt"></SPAN> </P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d; FONT-SIZE: 11pt">Pierre</SPAN></P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d; FONT-SIZE: 11pt"></SPAN> </P>
<DIV
style="BORDER-BOTTOM: medium none; BORDER-LEFT: blue 1.5pt solid; PADDING-BOTTOM: 0cm; PADDING-LEFT: 4pt; PADDING-RIGHT: 0cm; BORDER-TOP: medium none; BORDER-RIGHT: medium none; PADDING-TOP: 0cm">
<DIV>
<DIV
style="BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0cm; PADDING-LEFT: 0cm; PADDING-RIGHT: 0cm; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<P class=MsoNormal><B><SPAN style="FONT-SIZE: 10pt">From:</SPAN></B><SPAN
style="FONT-SIZE: 10pt"> <A
href="mailto:postgis-users-bounces@postgis.refractions.net"
target=_blank>postgis-users-bounces@postgis.refractions.net</A> [mailto:<A
href="mailto:postgis-users-bounces@postgis.refractions.net"
target=_blank>postgis-users-bounces@postgis.refractions.net</A>] <B>On Behalf
Of </B>Andreas Forø Tollefsen<BR><B>Sent:</B> 14 mars 2011 11:24<BR><B>To:</B>
PostGIS Users Discussion<BR><B>Subject:</B> Re: [postgis-users] PostGIS Raster
Decimal?</SPAN></P></DIV></DIV>
<DIV>
<DIV></DIV>
<DIV class=h5>
<P class=MsoNormal> </P>
<P class=MsoNormal>Hi Pierre.</P>
<DIV>
<P class=MsoNormal> </P></DIV>
<DIV>
<P class=MsoNormal>Yes. I think that would be
an appropriate temporary fix.</P></DIV>
<DIV>
<P class=MsoNormal>Still, a bit problematic when working with climate data
which very often include decimal digits and often have weekly and monthly
rasters for 100's of years :)</P></DIV>
<DIV>
<P class=MsoNormal> </P></DIV>
<DIV>
<P class=MsoNormal>Good luck.</P></DIV>
<DIV>
<P class=MsoNormal> </P></DIV>
<DIV>
<P class=MsoNormal>Best,</P></DIV>
<DIV>
<P class=MsoNormal>Andreas</P>
<DIV>
<P class=MsoNormal> </P>
<DIV>
<P class=MsoNormal>2011/3/14 Pierre Racine <<A
href="mailto:Pierre.Racine@sbf.ulaval.ca"
target=_blank>Pierre.Racine@sbf.ulaval.ca</A>></P>
<P class=MsoNormal>Andreas,<BR><BR>This is a well known problem. See ticket <A
href="http://trac.osgeo.org/postgis/ticket/650"
target=_blank>http://trac.osgeo.org/postgis/ticket/650</A><BR><BR>I will
discuss this problem with Frank this week at the code sprint in
Montreal.<BR><BR>For now you can use some GIS with map algebra capability to
multiply your raster by 10 before importing or test our brand new
ST_MapAlgebra function (still to
debug).<BR><BR>Pierre<BR><BR>>-----Original Message-----<BR>>From:
Pierre Racine<BR>>Sent: 14 mars 2011 10:55<BR>>To: Pierre
Racine<BR>>Subject: FW: [postgis-users] PostGIS Raster
Decimal?<BR>><BR>><BR>><BR>>From: <A
href="mailto:postgis-users-bounces@postgis.refractions.net"
target=_blank>postgis-users-bounces@postgis.refractions.net</A> [mailto:<A
href="mailto:postgis-users-" target=_blank>postgis-users-</A><BR>><A
href="mailto:bounces@postgis.refractions.net"
target=_blank>bounces@postgis.refractions.net</A>] On Behalf Of Andreas Forø
Tollefsen<BR>>Sent: 14 mars 2011 10:53<BR>>To: PostGIS Users
Discussion<BR>>Subject: [postgis-users] PostGIS Raster Decimal?</P>
<DIV>
<DIV>
<P class=MsoNormal>><BR>>Hi. Again.<BR>><BR>>I have been working
on some raster data in PostGIS lately.<BR>>However, i have some issues with
the raster values become integer after importing the sql to
postgis.<BR>>For instance this
procedure:<BR>><BR>>C:\prio_grid\source\gpw>c:\python26\python
c:\prio_grid\script\raster2pgsql.py -<BR>>r
c:\prio_grid\source\gpw\lrc30p90\glp90ag30\w001001.adf -t gpw90 -s 4326 -o
gpw<BR>>90.sql -I -M<BR>><BR>>Then to
database:<BR>>C:\prio_grid\source\gpw>psql -h 192.168.1.55 -d priogrid
-f gpw90.sql<BR>><BR>>Querying this data:<BR>>SELECT gpw90.gid,
((gpw90.gpw90val).val) AS gpw90<BR>>INTO popgrid<BR>>FROM (SELECT
priogrid_land.gid, ST_Intersection(gpw90.rast, priogrid_land.centroid) AS
gpw90val FROM<BR>>gpw90, priogrid_land WHERE
ST_Intersects(priogrid_land.centroid, gpw90.rast)) AS gpw90<BR>>WHERE
gpw90.gid = 139303<BR>>GROUP BY
gid,((gpw90.gpw90val))<BR>>;<BR>><BR>>Gives:<BR>>gid;
gpw90<BR>>139303;39849<BR>><BR>>The value in the original raster
is:<BR>>39849.2<BR>><BR>>Question is then. How can i ensure that
raster remain decimal and not integer after this import and<BR>>query
process?<BR>><BR>>Thanks.<BR>>Andreas<BR>_______________________________________________<BR>postgis-users
mailing list<BR><A href="mailto:postgis-users@postgis.refractions.net"
target=_blank>postgis-users@postgis.refractions.net</A><BR><A
href="http://postgis.refractions.net/mailman/listinfo/postgis-users"
target=_blank>http://postgis.refractions.net/mailman/listinfo/postgis-users</A></P></DIV></DIV></DIV>
<P
class=MsoNormal> </P></DIV></DIV></DIV></DIV></DIV></DIV></DIV><BR>_______________________________________________<BR>postgis-users
mailing list<BR><A
href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</A><BR><A
href="http://postgis.refractions.net/mailman/listinfo/postgis-users"
target=_blank>http://postgis.refractions.net/mailman/listinfo/postgis-users</A><BR><BR></BLOCKQUOTE></DIV><BR></DIV></BODY></HTML>