Diagram and pl/sql script