Hello list,

 

I found that the filter for value relation is working strange.

 

This expresion is equal (filter returns true): 

$geometry = geomFromWKT('LINESTRING(390364.82999985886272043
6126622.90999916009604931, 390354.81999995314981788
6126636.05999972019344568, 390385.25999995262827724
6126666.33999972231686115, 390437.70999995339661837
6126716.58999972138553858, 390504.5499999534804374
6126735.08999972138553858, 390559.1499999538064003
6126749.38999972492456436, 390612.05999990634154528
6126763.44999945163726807)')

As WKT is calculated from $geometry of that line.

 

But if I try this expresion with added buffer of 1 meter for both sides for
the same feature:

 

buffer($geometry, 1) =
buffer(geomFromWKT('LINESTRING(390364.82999985886272043
6126622.90999916009604931, 390354.81999995314981788
6126636.05999972019344568, 390385.25999995262827724
6126666.33999972231686115, 390437.70999995339661837
6126716.58999972138553858, 390504.5499999534804374
6126735.08999972138553858, 390559.1499999538064003
6126749.38999972492456436, 390612.05999990634154528
6126763.44999945163726807)'),1)

 

it returns false.

 

The Idea is to use the spatial filter to query points that are in buffer of
line.

 

I use the following expresion:

 

 

within( geomFromWKT('POINT('|| "x" || ' ' || "y"|| ')'), buffer($geometry),
1) = 1      -  but this returns false.

„x“ and „y“ are coordinates of point

 

while such works fine:

 

within( geomFromWKT('POINT('|| "x" || ' ' || "y"|| ')'),
buffer(geomFromWKT('LINESTRING(390364.82999985886272043
6126622.90999916009604931, 390354.81999995314981788
6126636.05999972019344568, 390385.25999995262827724
6126666.33999972231686115, 390437.70999995339661837
6126716.58999972138553858, 390504.5499999534804374
6126735.08999972138553858, 390559.1499999538064003
6126749.38999972492456436, 390612.05999990634154528
6126763.44999945163726807)'),1) ) = 1

 

there $geometry = geomFromWKT('LINESTRING(390364.82999985886272043
6126622.90999916009604931, 390354.81999995314981788
6126636.05999972019344568, 390385.25999995262827724
6126666.33999972231686115, 390437.70999995339661837
6126716.58999972138553858, 390504.5499999534804374
6126735.08999972138553858, 390559.1499999538064003
6126749.38999972492456436, 390612.05999990634154528
6126763.44999945163726807)')

 

any ideas for such strange behaviour?

 

 

 

 

Sincerely,

Paulius Litvinas

GIS consultant

line


map

S. Žukausko str. 17,
LT-08234 Vilnius, Lithuania 

telephone

Tel. + 370 5 278 8456
Mob. +370 656 10 089 

mail_and_earth

 <mailto:[email protected]> [email protected]
 <http://www.infoera.lt/> www.infoera.lt 

info_era_autodesk

 

 

_______________________________________________
Qgis-user mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to