<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Testo fumetto Carattere";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
span.StileMessaggioDiPostaElettronica17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.TestofumettoCarattere
        {mso-style-name:"Testo fumetto Carattere";
        mso-style-priority:99;
        mso-style-link:"Testo fumetto";
        font-family:"Tahoma","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 2.0cm 2.0cm 2.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi All,<o:p></o:p></p><p class=MsoNormal>I would appreciate a lot your help if you could suggest how to fix this: &#8220;dijkstra_sp&#8221; function seems not to work :-s. <o:p></o:p></p><p class=MsoNormal>I excuse in advance: my knowledge of db and gis systems is very little and you will have to provide a &#8220;pgrouting for dummies&#8221; explanation <span style='font-family:Wingdings'>J</span><o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I am working with win32, postgresql 8.4, pgadmin 1.10.5, postgis 1.5, pgrouting 1.03. <o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I processed my&nbsp; shp file in &nbsp;Openjump &nbsp;first (I made the edge file planar and calculated the length of the edges) and then imported it in postgresql by using this plugin for pgadmin: <a href="http://www.roxor.it/guide/13-guide-gis/13-guida-importare-shape-postgres-postgis.html">http://www.roxor.it/guide/13-guide-gis/13-guida-importare-shape-postgres-postgis.html</a>.<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I have imported all the pgrouting functions by following these steps: <a href="http://hi.baidu.com/%C5%A3%B5%C3%CC%EC%CF%C2/blog/item/beabb7b4512c35c037d3ca03.html">http://hi.baidu.com/%C5%A3%B5%C3%CC%EC%CF%C2/blog/item/beabb7b4512c35c037d3ca03.html</a> (step 2).<o:p></o:p></p><p class=MsoNormal>I have currently all the postgis and pgrouting functions loaded, a table with the &#8220;the_geom&#8221;, &#8220;gid&#8221;, &#8220;source&#8221;, &#8220;target&#8221;, &#8220;length&#8221; fields, as described in the link above and a table that will contain the results of dijkstra (steps 5, 6,7,8). <o:p></o:p></p><p class=MsoNormal>I get stuck when I call the &nbsp;&#8220;dijkstra_sp&#8221; function (step 8).. the error msg is:<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>ERROR:&nbsp; source contains a null value<o:p></o:p></p><p class=MsoNormal>CONTEXT:&nbsp; PL/pgSQL function &quot;dijkstra_sp&quot; line 12 at cycle FOR in an instruction EXECUTE<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Any idea about what went wrong?<o:p></o:p></p><p class=MsoNormal>Thanks a lot!<o:p></o:p></p><p class=MsoNormal>Maria<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p></div></body></html>