Changeset 323
- Timestamp:
- 04/06/06 10:40:50 (19 years ago)
- Location:
- branches/stable/cgi-bin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/cgi-bin/ipdb.psql
r286 r323 95 95 GRANT ALL on "allocations" to "ipdb"; 96 96 97 CREATE VIEW "searchme" as SELECT allocations.cidr, allocations.custid, allocations."type", allocations.city, allocations.description, allocations.notes FROM allocations UNION SELECT poolips.ip, poolips.custid, poolips.type, poolips.city, poolips.description, poolips.notesFROM poolips;97 CREATE VIEW "searchme" as SELECT allocations.cidr, allocations.custid, allocations."type", allocations.city, allocations.description, allocations.notes, allocations.oldcustid FROM allocations UNION SELECT poolips.ip, poolips.custid, poolips.type, poolips.city, poolips.description, poolips.notes, poolips.oldcustid FROM poolips; 98 98 99 99 REVOKE ALL on "searchme" from PUBLIC; -
branches/stable/cgi-bin/search.cgi
r319 r323 105 105 106 106 # First chunk of SQL. Filter on custid, description, and notes as necessary. 107 my $sql = "(select $cols from searchme where $webvar{custexclude} custid ilike '%$webvar{custid}%')". 108 " $sqlconcat $webvar{custexclude} oldcustid ilike '%$webvar{custid}%')". 107 my $sql = "(select $cols from searchme where". 108 " $webvar{custexclude} (custid ilike '%$webvar{custid}%'". 109 " OR $webvar{custexclude} oldcustid ilike '%$webvar{custid}%'))". 109 110 " $sqlconcat (select $cols from searchme where $webvar{descexclude} description ilike '%$webvar{desc}%')". 110 111 " $sqlconcat (select $cols from searchme where $webvar{notesexclude} notes ilike '%$webvar{notes}%')";
Note:
See TracChangeset
for help on using the changeset viewer.