https://bugzilla.wikimedia.org/show_bug.cgi?id=44933

--- Comment #1 from [email protected] ---
Solution found. The following line numbers are from Semantic Maps version
2.0.1.2:

In includes/SM_GeoCoordsValueDescription.php, change lines 63 and 64 from:

$conditions[] = "{$tableName}.$fieldNames[0] $comparator $lat";
$conditions[] = "{$tableName}.$fieldNames[1] $comparator $lon";

to:

$conditions[] = "{$tableName}.$fieldNames[1] $comparator $lat";
$conditions[] = "{$tableName}.$fieldNames[2] $comparator $lon";

This fixes the issue when querying for a match on a specific set of
coordinates, like in the example in the opening post. It doesn't, however, fix
the issue when doing a "within distance/proximity" query. To fix this, change
lines 143 to 146 in includes/SM_AreaValueDescription.php from:

$conditions[] = "{$tableName}.$fieldNames[0] $smallerThen $north";
$conditions[] = "{$tableName}.$fieldNames[0] $biggerThen $south";
$conditions[] = "{$tableName}.$fieldNames[1] $smallerThen $east";
$conditions[] = "{$tableName}.$fieldNames[1] $biggerThen $west";

to:

$conditions[] = "{$tableName}.$fieldNames[1] $smallerThen $north";
$conditions[] = "{$tableName}.$fieldNames[1] $biggerThen $south";
$conditions[] = "{$tableName}.$fieldNames[2] $smallerThen $east";
$conditions[] = "{$tableName}.$fieldNames[2] $biggerThen $west";

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to