<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=us-ascii" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.7601.17573"></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial>Virginia,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial>I think you are missing a mode='2' in your
connection. That was a new requirement that was added for GDAL
1.8+</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial>Try putting that in. I think the speed on the loading
still needs quite a bit of work though last I tried. The speed issues will
hopefully be resolved before 2.0 release.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial>Thanks,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial>Regina</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><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=826084804-02062011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=826084804-02062011><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV><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>Virginia Maffei<BR><B>Sent:</B> Wednesday, June 01, 2011 8:00
PM<BR><B>To:</B> postgis-users@postgis.refractions.net<BR><B>Subject:</B>
[postgis-users] Mapserver connection to Postgis Raster<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px">Hi,
i'm new at this and i'm trying to connect to postgis raster in the
mapfile.</DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px">I
loaded a tif file into postgis raster database with the raster2pgsql.py script.
It created a table with 2 fields: rid and rast.</DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px">In
the mapfile i added the connection like it specifies in the postgis raster FAQ
but it doesn't displays anything.</DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px"><BR></DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px">This
is my mapfile:</DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px"><BR></DIV>
<DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">MAP</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> IMAGETYPE
PNG24</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> EXTENT
366582.2901411663 6127927.100382689 857582.2901411663
6670927.100382689</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> SIZE
491 543</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> SHAPEPATH
"../data"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><BR></SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> LAYER # MODIS raster layer begins
here</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> NAME
modis</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><SPAN
style="WHITE-SPACE: pre-wrap"></SPAN>TYPE
RASTER</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><SPAN
style="WHITE-SPACE: pre-wrap"></SPAN>STATUS ON<SPAN
style="WHITE-SPACE: pre-wrap"> </SPAN></SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><SPAN
style="WHITE-SPACE: pre-wrap"></SPAN>DATA "PG:host=localhost port=5432
dbname='postgis' user='postgres' password='postgres' schema='public'
table='HumedadDeExtincion'" </SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> PROCESSING
"NODATA=0"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><SPAN
style="WHITE-SPACE: pre-wrap"></SPAN>PROCESSING "SCALE=AUTO"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><SPAN
style="WHITE-SPACE: pre-wrap"></SPAN>PROCESSING
"SCALE_BUCKETS=201"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> PROCESSING
"BANDS=1"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> OFFSITE 71
74 65</SPAN></FONT></DIV>
<DIV><SPAN style="BORDER-COLLAPSE: collapse; WHITE-SPACE: pre-wrap"><FONT
face="arial, sans-serif"></FONT></SPAN></DIV>
<DIV><SPAN style="BORDER-COLLAPSE: collapse; WHITE-SPACE: pre-wrap"><FONT
face="arial, sans-serif"></FONT></SPAN></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">CLASS</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN style="BORDER-COLLAPSE: collapse">NAME
"red"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">EXPRESSION ([pixel] <
10)</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">COLOR 255 0 0</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">END</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">CLASS</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN style="BORDER-COLLAPSE: collapse">NAME
"green"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">EXPRESSION ([pixel] >= 10 AND [pixel] <
15000 )</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">COLOR 0 255 0</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">END</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">CLASS</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN style="BORDER-COLLAPSE: collapse">NAME
"blue"</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">EXPRESSION ([pixel] >= 15000
)</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">COLOR 0 255 0</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse">END</SPAN></FONT></DIV>
<DIV><SPAN style="BORDER-COLLAPSE: collapse; WHITE-SPACE: pre-wrap"><FONT
face="arial, sans-serif"></FONT></SPAN></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> END # MODIS raster layer ends
here</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> </SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"> # End of LAYER DEFINITIONS
-------------------------------</SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><BR></SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN style="BORDER-COLLAPSE: collapse">END
# All map files must come to an end just as all other things must come
to...</SPAN></FONT></DIV></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><BR></SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN
style="BORDER-COLLAPSE: collapse"><BR></SPAN></FONT></DIV>
<DIV><FONT face="arial, sans-serif"><SPAN style="BORDER-COLLAPSE: collapse">I
have gdal 1.6 , postgis 1.5 and ms4w with </SPAN></FONT><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">mapserver </SPAN><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">5.6.6 </SPAN></DIV>
<DIV><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif"><BR></SPAN></DIV>
<DIV><SPAN style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">We
cant see the tiff file on the browser, it only appears a white
image.</SPAN></DIV>
<DIV><SPAN style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">We
did try with the tif without the database connection an it works.</SPAN></DIV>
<DIV><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif"><BR></SPAN></DIV>
<DIV><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">Could you help
us?</SPAN></DIV>
<DIV><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif"><BR></SPAN></DIV>
<DIV><SPAN
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif">Thank
you</SPAN></DIV>
<DIV
style="BORDER-COLLAPSE: collapse; FONT-FAMILY: arial, sans-serif; FONT-SIZE: 13px"><BR></DIV></BODY></HTML>