Changes between Version 27 and Version 28 of RHT PATE


Ignore:
Timestamp:
Jan 27, 2012 3:09:30 PM (13 years ago)
Author:
cedric
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • RHT PATE

    v27 v28  
    2929DROP TYPE IF EXISTS id_drain; 
    3030CREATE TYPE id_drain as (id_drain int); 
     31-- je sors le create table de la fonction pour gagner du temps... Attention à bien le lancer sinon ça plantera 
     32DROP TABLE IF EXISTS rht.upstream_riversegments; 
     33CREATE TABLE rht.upstream_riversegments(id_drain integer); 
    3134DROP  FUNCTION IF EXISTS rht.upstream_segments(id_ numeric); 
    3235CREATE OR REPLACE FUNCTION rht.upstream_segments(id_ numeric) RETURNS setof int AS $$ 
     
    3538        BEGIN 
    3639        -- filling a new table with the results from a catchment 
    37          
    38         DROP TABLE IF EXISTS rht.upstream_riversegments; 
    39         CREATE TABLE rht.upstream_riversegments(id_drain integer); 
    4040        EXECUTE 'insert into rht.upstream_riversegments (select cast(unnest(vecteurchemin) as integer) as id_drain  
    4141        from (SELECT regexp_split_to_array(ltree2text(chemin),E''\\\\.+'') as vecteurchemin from rht.rhtvs2 where chemin ~ ''*.'||id_||'.*'') as sub