pgsql/update_tables_0.5.x-0.6-dovecot-1.2.x.pgsql
branchv0.6.x
changeset 511 0244f1344b04
parent 503 492c179094c9
child 512 821d3ffaaaca
equal deleted inserted replaced
510:1fa354bbdb90 511:0244f1344b04
   493              WHERE gid = did
   493              WHERE gid = did
   494                AND address = localpart
   494                AND address = localpart
   495             LOOP
   495             LOOP
   496                 RETURN NEXT record;
   496                 RETURN NEXT record;
   497             END LOOP;
   497             END LOOP;
       
   498         IF NOT FOUND THEN
       
   499             FOR record IN
       
   500                 SELECT recipient, destination
       
   501                   FROM catchall
       
   502                  WHERE gid = did
       
   503                 LOOP
       
   504                     RETURN NEXT record;
       
   505                 END LOOP;
       
   506         END IF;
   498         RETURN;
   507         RETURN;
   499     END;
   508     END;
   500 $$ LANGUAGE plpgsql STABLE
   509 $$ LANGUAGE plpgsql STABLE
   501 RETURNS NULL ON NULL INPUT
   510 RETURNS NULL ON NULL INPUT
   502 EXTERNAL SECURITY INVOKER;
   511 EXTERNAL SECURITY INVOKER;