src: |
  SELECT 'DO'::text || t_durees_sejour_c.oid::text AS oid,
      t_durees_sejour_c.texte,
      t_durees_sejour_c.code,
      '2'::text AS level,
      '9'::text || t_durees_sejour_c.code AS tri,
      '0'::character(1) AS is_cti
     FROM activite.t_durees_sejour_c
    WHERE (t_durees_sejour_c.oid IN ( SELECT p_oids.oid
             FROM activite.p_oids
            WHERE p_oids.code_table = 'dursej'::text))
    ORDER BY '9'::text || t_durees_sejour_c.code;