Ticket #950 (closed defect: fixed)
Topology: LayerTrigger - wrong filter
| Reported by: | aperi2007 | Owned by: | strk |
|---|---|---|---|
| Priority: | blocker | Milestone: | PostGIS 2.0.0 |
| Component: | topology | Version: | trunk |
| Keywords: | Cc: |
Description
Hi, The LayerTrigger? function in topology section actually use this code sql:
query = 'SELECT * '
|| ' FROM ' || quote_ident(toponame)
|| '.relation '
|| ' WHERE topogeo_id = ' || OLD.topology_id
|| ' AND layer_id = '|| OLD.layer_id
|| ' LIMIT 1';
--RAISE NOTICE '%', query;
I guess the comparing between topogeo_id and topology_id is wrong. This could be allow/deny wrongly the deleting of some Layer. Also I guess the correct sql should be this:
query = 'SELECT * '
|| ' FROM ' || quote_ident(toponame)
|| '.relation '
|| ' WHERE layer_id = '|| OLD.layer_id
|| ' LIMIT 1';
Because the topology is already the one when triggering this function.
regards, Andrea.
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

