<html>
<head>
        <title></title>
        
<meta name="GENERATOR" content="MSHTML 8.00.6001.18783"></meta>
</head>

<body>
        
<div>I'm working on the regression-tests for the distance-functions and don't really understand the behavior of postgis or the planner or what it is, doing it.</div>
        
<div> </div>
        
<div>if I run:<br />
                select st_astext(geom1) from<br />
                (select NULL as geom1) a;</div>
        
<div> </div>
        
<div>I get:</div>
        
<div><br />
                FEIL:  failed to find conversion function from unknown to geometry</div>
        
<div><br />
                ********** Error **********</div>
        
<div>FEIL: failed to find conversion function from unknown to geometry<br />
                SQL state: XX000</div>
        
<div> </div>
        
<div>but if I run:</div>
        
<div>select st_astext(NULL)</div>
        
<div>or</div>
        
<div>select st_astext(NULL) from<br />
                (select NULL as geom1) a;</div>
        
<div> </div>
        
<div>then I just get an empty answer without error-message.</div>
        
<div> </div>
        
<div>and if I run :</div>
        
<div> </div>
        
<div>select geom1 from<br />
                (select NULL as geom1) a;</div>
        
<div> </div>
        
<div>I also get just an empty answer.</div>
        
<div> </div>
        
<div>Why is this conversion-function trigged when I use a sub-query and not otherwise and only if I use the NULL-value in a function and not if I just show it.</div>
        
<div> </div>
        
<div> </div>
        
<div> </div>
</body>
</html>