-- View: "v_genre_export"

DROP VIEW "v_genre_export";

CREATE OR REPLACE VIEW "v_genre_export"
AS
SELECT g1.parentcd, 
 g2.genrenm as parentnm, 
 g1.genrecd, 
 g1.genrenm, 
 g1.disppriority
 FROM t_genre g1 
  LEFT JOIN t_genre g2 
  ON g1.parentcd=g2.genrecd AND g2.delflg=FALSE 
WHERE g1.delflg = FALSE
ORDER BY COALESCE(g1.parentcd,0), g1.disppriority
;
