Publish Diagrams in Oracle Designer – create PNG, GIF, TIFF, JPEG and BMP files for Designer Diagrams

Recently I installed Oracle Designer 9.0.4.5 – a maintenance release, released on November 18th. Previous releases were 10g (9.0.4.3) and patch release 9.0.4.4. All these releases contain a new feature, called Publish Diagrams. This feature allows you to export diagrams in Oracle Desiger – such as Entity Relationship Diagrams or Server Diagrams – to files in one of the familiar image formats (PNG, GIF, JPEG, TIFF or BMP). You can also publish diagrams directly to the ROB (Repository Object Browser) for viewing on the Web.

When you open the diagram in either the ERD or the Design Editor, you will find a new option under the Menu Utilities: Publish Diagrams. When you select that option, the next dialog is shown.
Publish Diagrams in Oracle Designer - create PNG, GIF, TIFF, JPEG and BMP files for Designer Diagrams PublishDiagramsDialog
Here you select a set of diagrams (from one to all) of the current type in all Folders of the current Workarea. These diagrams can be published either to the local file system in an specified format (PNG, GIF, etc.) or to the Repository Object Browser.

The diagram published to the file system as PNG file looks as follows:Diagram published from Oracle Designer using the new Publish Diagrams functionality

Publish Diagrams to the Repository Object Browser

To display diagrams in the Repository Object Browser, normally you have to do several things manually: create a GIF or PNG file for every diagram that you want to publish, copy these files either to the /images/ directory of the ROB or to a Folder in the Repository and finally include a reference to the file between curly braces in the Description or Notes of the Diagram, for example: {erd.gif} or {REP_FILE=als_erd.png}.

The Publish Diagrams to Repository Object Browser functionality in the new Designer Releases takes care of each of these steps! It loads the Diagram files into the Repository and uses the REP_FILE option to hook them into the Diagram reports in the ROB. This works very smoothly! The next screenshot shows the result of Publishing the ALS_ERD diagram to the ROB.
Publish Diagrams in Oracle Designer - create PNG, GIF, TIFF, JPEG and BMP files for Designer Diagrams DiagramPublishedToRob
You can open the diagram image-file by double clicking the ALS_ERD.png File that was created by the Publish Diagram utility.

Note:Images that are stored as file in the Repository can only be seen if you have enabled the Download Files functionality through Servlet Container – an Application Server complementing the Oracle HttpServer/MOD_PLSQL setup. So if you do not enable file download, the diagrams published to the Repository will not be visible in the ROB.

From the On Line Help on Publish Diagrams:

Enables you to publish Designer diagrams to the Repository Object Browser (ROB) or to save them as files to a file system directory.

Available Diagrams pane Shows the diagrams within the current workarea. If you want to publish a subset of these diagrams, click the diagram or diagrams that you want to publish.

Selected Diagrams pane Diagrams listed in this pane will be published when you click the OK button. If a diagram was active in the Design Editor when you opened the Publish Diagrams dialog, it will automatically be listed in this pane.

File Name text box This is enabled only if the “Publish to File” option is chosen (see below). This text box displays the target file name for the diagram currently highlighted in the Selected Diagrams pane. By default the target file name is the same as the diagram name in the repository. You can change the target file name by overtyping the text in this box.

Publish to Repository Object Browser option Choose this option to publish the diagrams to the Repository Object Browser.

Publish to File option Choose this option to publish the diagrams to files.

Directory text box This text box shows the file system directory to which the files containing the diagrams will be written. A directory will be suggested, which will be one of the following:
– the mapped directory of the application system, if the selected diagrams belong to one application system
– the directory chosen during the previous publish operation
– the system temporary directory.
You can change the suggested directory by overtyping the text in this box, or by using the Browse button.

Publish Format text box Choose a format for the published diagrams from the drop-down list. You can choose from PNG, GIF, TIFF, JPEG and BMP.

Publishing Diagrams for older releases of Oracle Designer

If you have an older release of Oracle Designer, anywhere from Designer/2000 1.3.2 to releases prior to 10g (or 6i the latest maintenance release) there also is a (n awkward) way of publishing diagrams, not known to all:

  • open the Diagram in the ERD or the Designer Editor
  • From the Edit Menu, choose the option Copy; do not select any objects before picking this Copy option
  • The diagram is now on the Clipboard. For example: open a (new) Word Document. Use the Edit, Paste Special, Picture option to paste the diagram as a picture in your Word document.
  • If you want to have a GIF image for your diagram, you can now save the Word Document as Web Page; Word will then save all pictures in the document, including the Diagram, as GIF file