Reporting Reference Manual

download Reporting Reference Manual

of 34

Transcript of Reporting Reference Manual

  • 7/27/2019 Reporting Reference Manual

    1/34

    Reporting

    Reference Manual

  • 7/27/2019 Reporting Reference Manual

    2/34

    Disclaimer

    Information of a technical nature, and particulars of the product and its use, is given by AVEVASolutions Ltd and its subsidiaries without warranty. AVEVA Solutions Ltd and its subsidiaries disclaim

    any and all warranties and conditions, expressed or implied, to the fullest extent permitted by law.

    Neither the author nor AVEVA Solutions Ltd, or any of its subsidiaries, shall be liable to any person orentity for any actions, claims, loss or damage arising from the use or possession of any information,particulars, or errors in this publication, or any incorrect use of the product, whatsoever.

    Copyright

    Copyright and all other intellectual property rights in this manual and the associated software, and everypart of it (including source code, object code, any data contained in it, the manual and any otherdocumentation supplied with it) belongs to AVEVA Solutions Ltd or its subsidiaries.

    All other rights are reserved to AVEVA Solutions Ltd and its subsidiaries. The information contained in

    this document is commercially sensitive, and shall not be copied, reproduced, stored in a retrievalsystem, or transmitted without the prior written permission of AVEVA Solutions Ltd Where suchpermission is granted, it expressly requires that this Disclaimer and Copyright notice is prominentlydisplayed at the beginning of every copy that is made.

    The manual and associated documentation may not be adapted, reproduced, or copied, in any materialor electronic form, without the prior written permission of AVEVA Solutions Ltd. The user may also notreverse engineer, decompile, copy, or adapt the associated software. Neither the whole, nor part of theproduct described in this publication may be incorporated into any third-party software, product,machine, or system without the prior written permission of AVEVA Solutions Ltd, save as permitted bylaw. Any such unauthorised action is strictly prohibited, and may give rise to civil liabilities and criminalprosecution.

    The AVEVA products described in this guide are to be installed and operated strictly in accordance withthe terms and conditions of the respective licence agreements, and in accordance with the relevantUser Documentation. Unauthorised or unlicensed use of the product is strictly prohibited.

    First published September 2007

    AVEVA Solutions Ltd, and its subsidiaries 2007

    AVEVA Solutions Ltd, High Cross, Madingley Road, Cambridge, CB3 0HB, United Kingdom

    Trademarks

    AVEVA and Tribon are registered trademarks of AVEVA Solutions Ltd or its subsidiaries. Unauthorised

    use of the AVEVA or Tribon trademarks is strictly forbidden.

    AVEVA product names are trademarks or registered trademarks of AVEVA Solutions Ltd or itssubsidiaries, registered in the UK, Europe and other countries (worldwide).

    The copyright, trade mark rights, or other intellectual property rights in any other product, its name orlogo belongs to its respective owner.

    AVEVA Solut ions Ltd

  • 7/27/2019 Reporting Reference Manual

    3/34

    Reporting Reference Manual

    Contents Page

    12.0i

    Reporting Reference Manual

    2007 AVEVA Solutions Ltd

    Reporting

    Introduction to Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:1

    Sample Report Templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:1

    Before You Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:2

    Starting to Use Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:3

    How to Use This Manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:3

    Running a Report f rom a Saved Template. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:3

    Creating and Running a Simple Repor t . . . . . . . . . . . . . . . . . . . . . . 2:1

    Creating a Simple Nozzle Schedule . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:1

    Destination. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:1

    Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:1

    Columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:1

    Running the Report . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:2

    Column Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:2

    Adding and Moving Columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:3

    Runtime Prompts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:4

    Saving and Deleting Templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:4

    Saving a Template . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:4

    Deleting a Template. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:5

    Report ing on Different Parts of the Database . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:5

    Adding Elements using the Members List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:5

    Adding Elements in a Given Volume . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:5

  • 7/27/2019 Reporting Reference Manual

    4/34

    12.01 A1:ii

    Reporting Reference Manual

    2007 AVEVA Solutions Ltd

    From . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:6

    More Column Layout Opt ions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:6

    Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:6Numeric Display. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:7

    Text Display . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8

    Introductions and Summaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8

    Sort ing and Totalling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:1

    Changing the Order of Sort ing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:2

    Sort ing on More than one Attribute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:2

    Totall ing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:4

    Subtotalling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:4

    Showing only the First Occurrence of Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:5

    Quanti ty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:6

    Selective Report ing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4:1

    File Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:1

    Page Information Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:1

    Report Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:2

    Late Evaluation of Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:2

    Points to Note. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:2

    Headers, Footers and Page Lengths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3

    Introduction and Summaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3

    Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3

    Addi tional Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6:1

    Running Repor ts in Batch Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6:1

    System Command Option . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6:1

    Report Output Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6:1

  • 7/27/2019 Reporting Reference Manual

    5/34

    Reporting Reference Manual

    Introduction to Reports

    12.01:1 2007 AVEVA Solutions Ltd

    1 Introduction to Reports

    This manual is an introduction to the PDMS Reports Utility, available in DESIGN, DRAFTand PARAGON.

    The main features of the Report Utility include:

    Generation of report to file or screen. Listing of any element from a PDMS database.

    Specify lists of properties by which elements can be sorted.

    Quantifying of lists under sub-totals and grand totals.

    The ability to create expressions for column values, based on the contents of thecolumn or the results of other columns.

    The ability to use expressions in report output, including user definition of titles,summaries, headers and footers.

    Generation of reports with specified column widths and delimiters for interfacing toother database systems or spread sheets.

    Complete control over the report definition and layout.

    Generation of reports using the batch process.

    1.1 Sample Report Templates

    You produce a report by running a report template. The template specifies what the reportwill contain, whether it will be sent to the screen or a file and how it will be laid out.Templates also specify what information can be specified at the time the report is run, forexample, what part of the database, or the output filename.

    There is a library of example reports supplied with the product in the directory %PDMSUI%/REPORTS. Under this directory is a TEMPLATES directory, which contains the templateswhich generated the reports. The templates are PDMS macros, but the best way to see how

    they are set up is to select Utilities>Reports>Modify... from the main menu, and look at thesettings on the forms displayed.

    Templates have the file extension .tmp, and the corresponding reports have a file extension.rep.

    Most of the examples are based on the sample project and the sample templates suppliedwith the product.

  • 7/27/2019 Reporting Reference Manual

    6/34

    12.01:2

    Reporting Reference Manual

    Introduction to Reports

    2007 AVEVA Solutions Ltd

    The sample templates produce the following types of report:

    1.2 Before You Start

    This manual assumes that you are familiar with PDMS to the level of the Basic TrainingCourse.

    Most of the examples in this manual illustrate templates which report directly on PDMSattributes and pseudo-attributes. You can also use more complex expressions in reporttemplates, and although some of these are illustrated, you will need to be familiar with PML,the AVEVA Programmable Macro Language, if you want to set these up for yourself.

    For information about further training, please contact your nearest AVEVA Support Office(see the copyright page at the front of this guide for details).

    To use the sample templates supplied with the product, the PDMS variable $PDMSREPDIRshould be set to the directory where the sample reports are stored.

    nozz_sched This is a Nozzle schedule, which lists all Nozzles sorted by

    name, and shows the P1 bore, connection type anddirection, and the position of each Nozzle.

    line_list This report is a list of Branches, sorted by the name of thePipe which owns them. The Head and Tail bores and theHead and Tail references are given.

    pipe_mto This report shows material information for all Branchmembers, sorted by type, Detail Text and Material Text. TheTube length and quantity of each component are totalled.There is an Imperial version of this report template.

    tube_mto This report totals all Tubing. The Specification Reference,

    P1 Bore, Detail Text and Material Text are shown.

    steel_mto This is a material take-off list for structural components.

    valve_list This report is an example of selective reporting.

    centre_line The centre-line length of each Branch is listed. There is anImperial version of this report template.

    tube_gradient This report gives the gradient of each tubing component.

    catalogue_param This is an example of reporting on the catalogue database.It lists Branch members, with their CATREFs and theparameters of the CATREFs.

    catalogue_ptgmref This is an example of reporting on the catalogue database.It lists Branch members, with their CATREFs followed by thePTREFs and GMREFs of the CATREFs.

    tube_area_vol This report uses derived properties to report on the areaand volume of tubing.

  • 7/27/2019 Reporting Reference Manual

    7/34

    Reporting Reference Manual

    Introduction to Reports

    12.01:3 2007 AVEVA Solutions Ltd

    1.3 Starting to Use Reports

    You will usually have a library of report templates set up for you, but you can produce and

    run a report template quickly by selecting Reports>Create, filling in the New ReportTemplate form to specify what you want to report on and then pressingApply on the form,which will run the report.

    Note that this is the easiest way of testing a template that you are creating or modifying.

    1.4 How to Use This Manual

    Running a Report from a Saved Template summarises how to run a report from a savedtemplate, which you may already know about.

    Creating and Running a Simple Report in Chapter Creating and Running a Simple Report isa tutorial which works through the steps of creating a simple report template, running it and

    saving it.

    Sorting and Totalling in Chapter Sorting and Totalling illustrates sorting and totalling bymodifying the sample templates.

    Selective Reporting in Chapter Selective Reporting is a brief introduction to using PMLexpressions to produce selective

    File Reports in Chapter File Reports describes the options which are only applicable to filereports, including inserting headers and footers. It also describes how to insert introductionsand summaries, which can be provided for screen reports as well, but they are created inthe same way as headers and footers.

    Note that not all the options on all the forms are described when they are first seen. If you

    want more information about a form, use the online help.

    1.5 Running a Report from a Saved Template

    You may already be familiar with creating a report by running a saved report template. If not,try this introductory exercise:

    1. Select Utilities>Reports>Run. You will see a File Browser, showing the contents ofthe directory REPORTS. Select the TEMPLATES sub-directory.

    2. Select the report template pipe_mto.tmp and select Open. You will see the ReportDetails form, with the following options:

    Filename

    If you specify a filename, the report will be sent to the given file in your workingdirectory. If you leave the text box empty, the report will be sent to the screen.

    Hierarchy

    Give a list of elements. The report will be output for all the elements given, and allthe elements owned by them.

  • 7/27/2019 Reporting Reference Manual

    8/34

    12.01:4

    Reporting Reference Manual

    Introduction to Reports

    2007 AVEVA Solutions Ltd

  • 7/27/2019 Reporting Reference Manual

    9/34

    Reporting Reference Manual

    Creating and Running a Simple Report

    12.02:1 2007 AVEVA Solutions Ltd

    2 Creating and Running a Simple Report

    This chapter describes how to create a simple report template, run it and save it. To workthrough the example, start up DESIGN, DRAFT or PARAGON, using the SAM project.

    2.1 Creating a Simple Nozzle ScheduleThe exercise creates a nozzle schedule, a simplified version of the one in the templatenozz_sched.tmp supplied with the product.

    If you are running DRAFT, make sure that the Members List for the DESIGN database isdisplayed.

    Select Utilities>Reports>Create . You will see the New Report Template form.

    There are several groups of options on the form, described in the following subsections.

    2.1.1 Destination

    Destination allows you to specify whether the report is output to Screen or to a File.

    For this example, select Screen.

    2.1.2 Selection

    The Selection options allow you to specify the type of item you want to report on, and thelevel in the database hierarchy below which the selection will be made.

    The Zone EQUIP in the sample project contains the Equipment /E1301, which owns severalNozzles. We will produce a template to report on these Nozzles.

    For this example:

    1. Enter NOZZ in theType(s)

    textbox.2. Leave the With text box blank. This is used in selective reporting, described in

    Selective Reporting.

    3. Replace WORLD in the Hierarchy text box with /E1301. Note that the slash must bepresent, as you can give several names in the box.

    2.1.3 Columns

    Now create three columns for the report, to display the name of the Nozzle, the arrive boreand the position, using the Columns options.

    Select the New option button, and the Creating Column form will be displayed.

  • 7/27/2019 Reporting Reference Manual

    10/34

    12.02:2

    Reporting Reference Manual

    Creating and Running a Simple Report

    2007 AVEVA Solutions Ltd

    The Expression text box defines the contents of the column. You can enter a PDMSattribute or pseudo-attribute here, or an expression containing attributes or pseudo-attributes.

    Ignore the Sorting and Precedence option for now. By default, the list of items in the reportwill be sorted in the order in which they are stored in the database.

    You can set the Units option when appropriate.

    The Column Layout button is used to control the format of each column, but we will use thedefault layout for now.

    Fill in the form as follows:

    1. For the first column, enter NAME in the Expression text box.

    2. This is all you need to set for the first column: do not press OK yet, but select NextColumn. The settings on the Creating Column form will be cleared ready for you todefine the second column.

    3. The second column will display the arrive bore of the Nozzles. Type P1 BORE into theExpression text box. Select Units ofAny/mm.

    4. Select Next Column again and define the third column, which will display thecoordinates of the Nozzle, by entering POS into the Expression text box. Units shouldbe set to Pos(mm).

    Now select OK on the Creating Column form. Note that the three columns you have definedare shown in the scrolling list on the New Report Template form.

    2.1.4 Running the Report

    SelectApply on the New Report Template form, which will run the report.

    The report will be output to a window: if you have an active window displayed, for examplethe command line window, the report will be displayed there. If there is no active window, anew window will be opened.

    The report should look like this:

    Note: By default the text that you entered in the Expression text box is used as the columnheading. You can change this, as described in Text Display.

    2.2 Column Layout

    The layout of this report is not very easy to read, so now we will use the option on the Layoutfor Column form to improve it.

    NAME P1 BORE POS

    / E1301- S1 200. 00 E 0. 00 N 3540. 00 D 635. 00

    / E1301- S2 200. 00 E 0. 00 N 1100. 00 U 635. 00

    / E1301- S3 200. 00 E 0. 00 N 5980. 00 U 635. 00

    / E1301- T1 100. 00 E 0. 00 N 290. 00 U 635. 00

    / E1301- T2 100. 00 E 0. 00 N 290. 00 D 635. 00

  • 7/27/2019 Reporting Reference Manual

    11/34

    Reporting Reference Manual

    Creating and Running a Simple Report

    12.02:3 2007 AVEVA Solutions Ltd

    Highlight POS in the list on the New Report Template form, and select Modify. On theModifying Column 3 form, select Column Layout, and you will see the Layout for Columnform.

    Set the Spaces before Column option to 4, and set Justification to Left. The output willlook like this:

    Further column layout options are describes in More Column Layout Options.

    2.3 Adding and Moving Columns

    Now we will add two more columns to the report, for P1 CONN and P1 DIR.

    1. A new column is inserted before the one selected in the list on the New ReportTemplate form. To insert a column at the end of the list of columns, make sure that theentry reading is highlighted, and select New again.

    2. Enter P1 CONN into the Expression text box and set Units to Off. On the ColumnLayout

    form, set justification toLeft

    . SelectNext Column

    on theCreating Column

    form.

    3. Enter P1 DIR into theExpression text box and set Units to Off. On the Column Layoutform, set justification to Centre and select OK.

    4. Select OK on the Creating Column form.

    Remember that inserting a new column will renumber all columns to the right of the newcolumn.

    Now move the POS column so that it is the last (fifth) column again.

    1. Highlight the POS column in the list on the New Report Template form, and select theMove option button. You will see the Move Column form. Select 5 from the optiongadget and select OK.

    2. SelectApply on the New Report Template form. The modified report should look likethis:

    NAME P1 BORE POS

    /E1301-S1 200.00 E 0.00 N 3540.00 D 635.00

    /E1301-S2 200.00 E 0.00 N 1100.00 U 635.00

    /E1301-S3 200.00 E 0.00 N 5980.00 U 635.00

    /E1301-T1 100.00 E 0.00 N 290.00 U 635.00

    /E1301-T2 100.00 E 0.00 N 290.00 D 635.00

    NAME P1 BORE P1 CONN P1 DI R POS

    / E1301- S1 200. 00 FBD D E 0. 00 N 3540. 00 D 635. 00

    / E1301- S2 200. 00 FBD U E 0. 00 N 1100. 00 U 635. 00

    / E1301- S3 200. 00 FBD U E 0. 00 N 5980. 00 U 635. 00

    / E1301- T1 100. 00 FBB U E 0. 00 N 290. 00 U 635. 00

    / E1301- T2 100. 00 FBB D E 0. 00 N 290. 00 D 635. 00

  • 7/27/2019 Reporting Reference Manual

    12/34

    12.02:4

    Reporting Reference Manual

    Creating and Running a Simple Report

    2007 AVEVA Solutions Ltd

    2.4 Runtime Prompts

    If you are going to save the template so that it can be run in future, it is likely that you will

    want to have some control over the content when the report is run. For example, you willwant to specify the part of the hierarchy to report on.

    You can control what information the user is prompted for when the report is run usingruntime prompts. The Runtime Prompts form will be displayed when you selectOptions>Runtime Prompts on the menu on the New/Modify Report Template form.

    The options correspond to the options on theNew/Modify Report Template form. They are:

    File name

    Type(s)

    With

    Hierarchy

    Volume From

    File name allows you to specify the file where the report will be stored. The only otheroptions we have looked at so far are Type(s) and Hierarchy.

    1. Switch on File name, Type(s) and Hierarchy on the Runtime Prompts form and selectOK.

    2. Now run the report again, by selectingApply on the New Report Template form. Youwill see the Report Details form, with the values you have set on the Report Templateform for the three parameters displayed. You can now change them: for example, entera filename, and add other Equipments to Hierarchy.

    Note: If you specify in the template that a report will be sent to a file, and the user removes

    the filename on the Report Details form, the report will be sent to the screen.However, if you specify that the report will be sent to the screen, do not switch on theFilename option on the Runtime Prompts form, because the report will be sent to thescreen even if the user gives a filename.

    Note: Do not set any runtime prompts for report templates intended for batch mode.

    Note: Text boxes filled on the Runtime Prompts form will appear as defaults on the ReportDetails form.

    2.5 Saving and Delet ing Templates

    2.5.1 Saving a Template

    If you want to save the report template in a file, select one of the options under File on themenu at the top of the New Report Template form:

    Save As allows you to save the template in a new file. A File Browserwill be displayed.

    Save saves the template to the current file if the template has been saved already. Thefilename is shown in the title bar of the form.

    Note: The file where the template is stored has no relation to the file specified if you wantto output the report itself to a file. See File Reports for more information.

    You can save your template if you wish, provided you have write access to the directory, but

    you will not need it in future exercises.

  • 7/27/2019 Reporting Reference Manual

    13/34

    Reporting Reference Manual

    Creating and Running a Simple Report

    12.02:5 2007 AVEVA Solutions Ltd

    2.5.2 Delet ing a Template

    If you select Reports>Delete, you will see a File Browser from which you can select the

    template or report you want to delete.

    2.6 Reporting on Different Parts of the Database

    The following exercises are based on the supplied template pipe_mto.tmp. You may wishto look at the corresponding supplied report, pipe_mto.rep, first, using a text editor.

    Select Utilities>Reports>Modify, and select the template from the list. The Modify ReportTemplate form will be displayed. Note that this is exactly the same as the New ReportTemplate form, except that the name of the template is shown in the title bar of the form, andthe setting for the template are shown on the form.

    Note: All the supplied templates output to files, and have runtime prompts set. For the

    exercises, we suggest that you send the reports to the screen, and switch off theruntime prompts by selecting Options>Runtime Prompts from the menu at the top ofthe Modify Report Template form.

    The parts of the database you want to include in the report are specified by entering theelements at the top of each part of the hierarchy in the Hierarchy text box on the New/Modify Report Template form. The default is the World. If you just want to specify one or twoelements, you can just type in the element names. The names must always be preceded bya slash and separated by a space, because you can enter several names, for example:

    / 100- B- 1 / 100- B- 2

    If you want to specify several elements, it is easiest to use the Hierarchy form, which alsoallows you to report on all the elements in a Volume, selected from the MDB, the Drawlist

    or the Obstruction list.

    2.6.1 Adding Elements using the Members List

    The Hierarchy form is displayed when you select theHierarchy button on the Modify ReportTemplate form.

    1. Go to the PIPES Zone in the Members List.

    2. Select Pipe /100-B-1 in the Members List, and select CE on the Hierarchy form. ThePipe will be shown in the scrolling list in the Hierarchy form. Do the same for /100-B-2and /150-A-3.

    3. Note that you can remove an element from the list by highlighting it in the list andpressing Remove.

    4. Select OK on the Hierarchy form, and the Pipes will appear in the Hierarchy text boxon the Modify Report Template form.

    Note: Specifying elements using this option will override anything you specify in the Volumeor From option.

    2.6.2 Adding Elements in a Given Volume

    If you leave the Hierarchy option on the Modify Report Template form empty, you canspecify a Volume in the model, and report on elements Completely within or Partiallywithin it. Selecting Completely within or Partially within from the Volume option buttonon the Hierarchy form will display the Report Volume form, which is used in the same way

    as other PDMS forms for defining volumes.

  • 7/27/2019 Reporting Reference Manual

    14/34

    12.02:6

    Reporting Reference Manual

    Creating and Running a Simple Report

    2007 AVEVA Solutions Ltd

    The volume is defined by entering the coordinates of the diagonal of a limits box, either byentering the coordinates into the text boxes, or using the menu options to pick a point withthe cursor. The reporting volume can also be defined by selecting the Grid Lines option

    from the Intersections menu on the Report Volume form. This will display the Volume fromGrid form, which is used in exactly the same way as the Clip from Grid form (described inGraphical Model Manipulation Guide).

    Note: Specifying a Volume will select elements from the whole MDB. The other Fromoptions cannot be used.

    2.6.3 From

    The From options are used to specify where the Reports Utility will look for the elements toreport on:

    MDB

    should be used if you are giving specific elements in the Hierarchy.

    Drawlist

    will select all elements in the drawlist. The Hierarchy text box should be left blank.

    Obstruction list

    will select all elements in the obstruction list. The Hierarchy text box should be leftblank.

    2.7 More Column Layout Options

    The following examples illustrate some more of the options on the Layout for Column n

    form.

    Some of the options are only used in sorting and totalling, and these are described inSorting and Totalling. Some only apply to File reports, and these are described in FileReports. This section describes the general options which apply to all reports.

    2.7.1 Layout

    The number ofSpaces before column. This is the number of spaces between the end ofthe previous column and the start of the current column. The effect will be affected by theJustification.

    The Column width in characters. If you do not give a value, the width of the widest entry will

    be used.The Justification can be set to Left, Centre orRight.

    The effects of the layout options are illustrated in the following examples, based on thetemplate centre_line.tmp:

    The format as supplied:

    Cent r e Li ne Lengt h Report f or / 100- B- 1

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE LENGTH

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

  • 7/27/2019 Reporting Reference Manual

    15/34

    Reporting Reference Manual

    Creating and Running a Simple Report

    12.02:7 2007 AVEVA Solutions Ltd

    J ustification for the HBORE column set to Centre:

    Space before the HBORE column set to 5, rather than 2:

    Space before the HBORE column set to 2, and the column width set to 15:

    2.7.2 Numeric Display

    The Remaindercan be set to:

    Decimal

    in which case you can specify the number ofDecimal places

    or

    Fraction

    in which case you must specify the Denominator. In the output, the denominator willbe reduced if possible.

    The Style only affects how feet and inches are displayed. For example:

    US gives 10'-5"

    PDMSgives 10' 5

    Leading zeros can be on or off.

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 55

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    Cent r e Li ne Lengt h Report f or / 100- B- 1

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE LENGTH

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 55

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    Cent r e Li ne Lengt h Report f or / 100- B- 1

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE LENGTH

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 55

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    Cent r e Li ne Lengt h Report f or / 100- B- 1

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE LENGTH

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 55

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

  • 7/27/2019 Reporting Reference Manual

    16/34

    12.02:8

    Reporting Reference Manual

    Creating and Running a Simple Report

    2007 AVEVA Solutions Ltd

    2.7.3 Text Display

    You can specify the characters used to specify Unset text.

    Headings

    For reports without sorting or totalling Headings will normally be On. For example ofswitching Headings off, see Sorting and Totalling. The Page option is only used for filereports. For more information, see File Reports .

    Heading Text

    The Heading Text can be set to:

    Expression Tex t

    which will use the expression entered in the Expression text box on the CreatingColumn form. For example, CLLE for the centre line length.

    Default

    which will use the full PDMS attribute name is possible. For example, if you enter CLLEin the Expression text box, the column heading will be CENTRE LINE LENGTH.

    Custom

    in which case you should enter the text required in the text box. You can insert severallines of text. The Centre Line Length template, which has the heading split over twolines, is an example.

    Values

    For reports without sorting or totalling Values will normally be On. For examples of the otheroptions see Sorting and Totalling.

    Subtotals and Totals

    Totals can only be produced for columns containing numeric data, and which do not havethe Subtotal option set. For more information, see Sorting and Totalling.

    2.8 Introductions and Summaries

    The Page options on the menu on the New/Modify Report Template form can be used toinsert Introductions and Summaries into screen or file reports. However, they normallyinvolve using variables, which are introduced in Selective Reporting and so they aredescribed later, in File Reports.

  • 7/27/2019 Reporting Reference Manual

    17/34

    Reporting Reference Manual

    Sorting and Totalling

    12.03:1 2007 AVEVA Solutions Ltd

    3 Sorting and Totalling

    By default, the items reported on will be listed in the order that they are stored in thedatabase.

    You can specify which attributes will be used to sort the elements in the report and the type

    of sorting, for example, ascending or descending numerical order. If more than one attributeis used for sorting, you can control the precedence, that is which attribute is sorted first.

    For this exercise, look at the template line_list.tmp by selecting Utilities>Reports>Modifyon the Main Menu.

    Note: The sample templates are all for file reports, with runtime prompts set. If you want totry the examples, send the reports to the screen and switch the prompts off (useOptions>Runtime Prompts on the New/Modify Report Template form).

    This template reports on the Pipe Name, Specification, Head Bore, Tail Bore, Head Ref andTail Ref of Branches. The template sorts the Branches in ascending order of Head Bore.

    With the Hierarchy set to the Zone PIPES, the output will look like this:

    Li ne Li st f or WORLDPI PE PSPEC HBORE TBORE HREF TREF

    / 50- B- 9 / A3B 15. 00 15 / 50- B- 9-B1- TEE2 =0/ 0

    / 40- B- 10 / A3B 40. 00 40 / 40- B- 10- B1- TEE1 / 40- B- 10- B1- TEE2

    / 100- B- 1 / A3B 50. 00 100 / P1502A- N2 =0/ 0

    / 100- B- 1 / A3B 50. 00 100 / P1502B- N2 / 100- B- 1- B1- TEE1

    / 50- B- 9 / A3B 50. 00 50 / P1501A- N2 / 1101/ N4

    / 50- B- 9 / A3B 50. 00 50 / 50- B- 9- B1- TEE4 / 50- B- 9- B1- TEE5

    / 50- B- 9 / A3B 50. 00 50 / P1501B- N2 / 50- B- 9- B1- TEE1

    / 40- B- 10 / A3B 50. 00 40 / 50- B- 9-B1- TEE3 =0/ 0

    / 80- A- 11 / A1A 50. 00 80 / 80- B- 14- B1 =0/ 0

    / 80- B- 14 / A3B 50. 00 50 / 80- B- 14- B1- TEE1 / 80- A- 11- B1- TEE1

    / 100- B- 1 / A3B 80. 00 80 / 100- B- 1- B1- TEE2 / 100- B- 1- B1- TEE3/ 100- B- 2 / A3B 80. 00 80 / 100- B- 2- B1- TEE1 =71/ 608

    / 80- B- 7 / A3B 80. 00 80 / E1302A- S2 / D1201- N1

    / 100- C- 12 / F1C 80. 00 80 / 100- C- 12- B1- TEE1 / 100- C- 12- B1- TEE2

    / 80- B- 14 / A3B 80. 00 50 / D1201- N2 / 80- A- 11- B1

    / 100- B- 2 / A3B 100. 00 100 =0/ 0 / 150- A- 3- B1

    / 150- A- 3 / A1A 100. 00 150 / 100- B- 2- B1 =0/ 0

    / 100- B- 8 / A3B 100. 00 100 / D1201- N4 / P1501B- N1

    / 100- B- 8 / A3B 100. 00 100 / 100- B- 8- B1- TEE1 / P1501A- N1

    / 100- C- 12 / F1C 100. 00 100 =0/ 0 / 1301/ NS2

    / 100- C- 13 / F1C 100. 00 100 / 1301/ NS1 =0/ 0

    / 150- B- 6 / A3B 150. 00 150 / 1101/ N5 / E1302B- S1

    / 150- A- 57 / A1A 150. 00 100 =0/ 0 / P1502A- N1

    / 150- A- 57 / A1A 150. 00 100 / 150- A- 57- B1- TEE1 / P1502B- N1

  • 7/27/2019 Reporting Reference Manual

    18/34

    12.03:2

    Reporting Reference Manual

    Sorting and Totalling

    2007 AVEVA Solutions Ltd

    / 200- B- 4 / A3B 200. 00 200 / 1101/ N3 / 1301/ N1

    / 250- B- 5 / A3B 200. 00 250 / 1301/ N2 / 1101/ N2

    / 250- B- 5 / A3B 200. 00 250 / 1301/ N4 =72/ 615

    Summary: 27 Li nes i n Schedul e

    3.1 Changing the Order of Sort ing

    Change the order of sorting to descending order of Head Bore. Select HBORE in the list onthe Modify Report Template form, and select the (Columns) Modify option button.

    On the Modify Columns form, set the Sorting option button to 9-0. When you run the report,the output will be as follows:

    Li ne Li st f or / PI PES

    PI PE PSPEC HBORE TBORE HREF TREF

    / 200- B- 4 / A3B 200. 00 200 / C1101- N3 / E1301- S1

    / 250- B- 5 / A3B 200. 00 250 / E1301- S2 / C1101- N2/ 250- B- 5 / A3B 200. 00 250 / E1301- S3 =140/ 612

    / 150- B- 6 / A3B 150. 00 150 / C1101- N6 / E1302B- S1

    / 150- A- 57 / A1A 150. 00 100 =0/ 0 / P1502A- N1

    / 150- A- 57 / A1A 150. 00 100 / 150- A- 57- B1- TEE1 / P1502B- N1

    / 100- B- 2 / A3B 100. 00 100 / C1101- N1 / 150- A- 3- B1

    / 150- A- 3 / A1A 100. 00 150 / 100- B- 2- B1 =0/ 0

    / 100- B- 8 / A3B 100. 00 100 / D1201- N4 / P1501B- N1

    / 100- B- 8 / A3B 100. 00 100 / 100- B- 8- B1- TEE1 / P1501A- N1

    / 100- C- 12 / F1C 100. 00 100 =0/ 0 / E1301- T1

    / 100- C- 13 / F1C 100. 00 100 / E1301- T2 =0/ 0

    / 100- B- 1 / A3B 80. 00 80 / 100- B- 1- B1- TEE2 / 100- B- 1- B1- TEE3

    / 100- B- 2 / A3B 80. 00 80 / 100- B- 2- B1- TEE1 =139/ 603

    / 80- B- 7 / A3B 80. 00 80 / E1302A- S2 / D1201- N1

    / 100- C- 12 / F1C 80. 00 80 / 100- C- 12- B1- TEE1 / 100- C- 12- B1- TEE2

    / 80- B- 14 / A3B 80. 00 50 / D1201- N2 / 80- A- 11- B1

    / 100- B- 1 / A3B 50. 00 100 / P1502A- N2 / C1101- N4

    / 100- B- 1 / A3B 50. 00 100 / P1502B- N2 / 100- B- 1- B1- TEE1

    / 50- B- 9 / A3B 50. 00 50 / P1501A- N2 / C1101- N5

    / 50- B- 9 / A3B 50. 00 50 / 50- B- 9- B1- TEE4 / 50- B- 9- B1- TEE5

    / 50- B- 9 / A3B 50. 00 50 / P1501B- N2 / 50- B- 9- B1- TEE1

    / 40- B- 10 / A3B 50. 00 40 / 50- B- 9-B1- TEE3 =0/ 0

    / 80- A- 11 / A1A 50. 00 80 / 80- B- 14- B1 =0/ 0

    / 80- B- 14 / A3B 50. 00 50 / 80- B- 14- B1- TEE1 / 80- A- 11- B1- TEE1

    / 40- B- 10 / A3B 40. 00 40 / 40- B- 10- B1- TEE1 / 40- B- 10- B1- TEE2

    / 50- B- 9 / A3B 15. 00 15 / 50- B- 9-B1- TEE2 =0/ 0Summary: 27 Li nes i n Schedul e

    3.2 Sort ing on More than one Attr ibute

    Remember to use the Next column and Previous column option buttons on the ModifyColumns form, to move between columns.

    Keeping Sorting as 0-9 for HBORE, switch Sorting to 0-9 for TBORE. Note that thePrecedence button is now set to 2, and that the precedence is also shown by Sort 1 andSort 2 against the columns on the Modify Report Template form. Go back to the HBOREcolumn, and note that the Precedence is shown as 1. This means that the Branches will be

    sorted first in order of Head Bore, and second in order of Tail Bore.

  • 7/27/2019 Reporting Reference Manual

    19/34

    Reporting Reference Manual

    Sorting and Totalling

    12.03:3 2007 AVEVA Solutions Ltd

    If you run the report now, the output will look like this; note the different order for Brancheswith HBORE 50:

    Li ne Li st f or / PI PES

    PI PE PSPEC HBORE TBORE HREF TREF/ 200- B- 4 / A3B 200. 00 200 / C1101- N3 / E1301- S1

    / 250- B- 5 / A3B 200. 00 250 / E1301- S2 / C1101- N2

    / 250- B- 5 / A3B 200. 00 250 / E1301- S3 =140/ 612

    / 150- A- 57 / A1A 150. 00 100 =0/ 0 / P1502A- N1

    / 150- A- 57 / A1A 150. 00 100 / 150- A- 57- B1- TEE1 / P1502B- N1

    / 150- B- 6 / A3B 150. 00 150 / C1101- N6 / E1302B- S1

    / 100- B- 2 / A3B 100. 00 100 / C1101- N1 / 150- A- 3- B1

    / 100- B- 8 / A3B 100. 00 100 / D1201- N4 / P1501B- N1

    / 100- B- 8 / A3B 100. 00 100 / 100- B- 8- B1- TEE1 / P1501A- N1

    / 100- C- 12 / F1C 100. 00 100 =0/ 0 / E1301- T1

    / 100- C- 13 / F1C 100. 00 100 / E1301- T2 =0/ 0

    / 150- A- 3 / A1A 100. 00 150 / 100- B- 2- B1 =0/ 0/ 80- B- 14 / A3B 80. 00 50 / D1201- N2 / 80- A- 11- B1

    / 100- B- 1 / A3B 80. 00 80 / 100- B- 1- B1- TEE2 / 100- B- 1- B1- TEE3

    / 100- B- 2 / A3B 80. 00 80 / 100- B- 2- B1- TEE1 =139/ 603

    / 80- B- 7 / A3B 80. 00 80 / E1302A- S2 / D1201- N1

    / 100- C- 12 / F1C 80. 00 80 / 100- C- 12- B1- TEE1 / 100- C- 12- B1- TEE2

    / 40- B- 10 / A3B 50. 00 40 / 50- B- 9-B1- TEE3 =0/ 0

    / 50- B- 9 / A3B 50. 00 50 / P1501A- N2 / C1101- N5

    / 50- B- 9 / A3B 50. 00 50 / 50- B- 9- B1- TEE4 / 50- B- 9- B1- TEE5

    / 50- B- 9 / A3B 50. 00 50 / P1501B- N2 / 50- B- 9- B1- TEE1

    / 80- B- 14 / A3B 50. 00 50 / 80- B- 14- B1- TEE1 / 80- A- 11- B1- TEE1

    / 80- A- 11 / A1A 50. 00 80 / 80- B- 14- B1 =0/ 0

    / 100- B- 1 / A3B 50. 00 100 / P1502A- N2 / C1101- N4

    / 100- B- 1 / A3B 50. 00 100 / P1502B- N2 / 100- B- 1- B1- TEE1

    / 40- B- 10 / A3B 40. 00 40 / 40- B- 10- B1- TEE1 / 40- B- 10- B1- TEE2

    / 50- B- 9 / A3B 15. 00 15 / 50- B- 9-B1- TEE2 =0/ 0

    Summary: 27 Li nes i n Schedul e

    Change the Precedence of the TBORE column to 1, which will automatically change theprecedence of the HBORE column to 2.

    Now the output will look like this:

    Li ne Li st f or / PI PES

    PI PE PSPEC HBORE TBORE HREF TREF

    / 50- B- 9 / A3B 15. 00 15 / 50- B- 9-B1- TEE2 =0/ 0

    / 40- B- 10 / A3B 50. 00 40 / 50- B- 9-B1- TEE3 =0/ 0

    / 40- B- 10 / A3B 40. 00 40 / 40- B- 10- B1- TEE1 / 40- B- 10- B1- TEE2/ 80- B- 14 / A3B 80. 00 50 / D1201- N2 / 80- A- 11- B1

    / 50- B- 9 / A3B 50. 00 50 / P1501A- N2 / C1101- N5

    / 50- B- 9 / A3B 50. 00 50 / 50- B- 9- B1- TEE4 / 50- B- 9- B1- TEE5

    / 50- B- 9 / A3B 50. 00 50 / P1501B- N2 / 50- B- 9- B1- TEE1

    / 80- B- 14 / A3B 50. 00 50 / 80- B- 14- B1- TEE1 / 80- A- 11- B1- TEE1

    / 100- B- 1 / A3B 80. 00 80 / 100- B- 1- B1- TEE2 / 100- B- 1- B1- TEE3

    / 100- B- 2 / A3B 80. 00 80 / 100- B- 2- B1- TEE1 =139/ 603

    / 80- B- 7 / A3B 80. 00 80 / E1302A- S2 / D1201- N1

    / 100- C- 12 / F1C 80. 00 80 / 100- C- 12- B1- TEE1 / 100- C- 12- B1- TEE2

    / 80- A- 11 / A1A 50. 00 80 / 80- B- 14- B1 =0/ 0

    / 150- A- 57 / A1A 150. 00 100 =0/ 0 / P1502A- N1

    / 150- A- 57 / A1A 150. 00 100 / 150- A- 57- B1- TEE1 / P1502B- N1

  • 7/27/2019 Reporting Reference Manual

    20/34

    12.03:4

    Reporting Reference Manual

    Sorting and Totalling

    2007 AVEVA Solutions Ltd

    / 100- B- 2 / A3B 100. 00 100 / C1101- N1 / 150- A- 3- B1

    / 100- B- 8 / A3B 100. 00 100 / D1201- N4 / P1501B- N1

    / 100- B- 8 / A3B 100. 00 100 / 100- B- 8- B1- TEE1 / P1501A- N1

    / 100- C- 12 / F1C 100. 00 100 =0/ 0 / E1301- T1/ 100- C- 13 / F1C 100. 00 100 / E1301- T2 =0/ 0

    / 100- B- 1 / A3B 50. 00 100 / P1502A- N2 / C1101- N4

    / 100- B- 1 / A3B 50. 00 100 / P1502B- N2 / 100- B- 1- B1- TEE1

    / 150- B- 6 / A3B 150. 00 150 / C1101- N6 / E1302B- S1

    / 150- A- 3 / A1A 100. 00 150 / 100- B- 2- B1 =0/ 0

    / 200- B- 4 / A3B 200. 00 200 / C1101- N3 / E1301- S1

    / 250- B- 5 / A3B 200. 00 250 / E1301- S2 / C1101- N2

    / 250- B- 5 / A3B 200. 00 250 / E1301- S3 =140/ 612

    Summary: 27 Li nes i n Schedul e

    3.3 Totalling

    To see the effect of totalling, use the template centre_line.tmp and set the hierarchy to 100-B-1 and 100-B-2.

    The template as supplied will report on the Branches, giving the Pipe name and the PipeSpecification, sorted on descending order of Head Bore, and the Centre Line Length, asfollows:

    Cent r e Li ne Lengt h Repor t f or / 100- B- 1 / 100- B- 2

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 100. 00 7610. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 2 / 100- B- 2- B2 / A3B 80. 00 2526. 65

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 56

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    Now switch on the Totalling option button on the Layout for Column form for the CentreLine Length column, and the report will appear like this:

    Cent r e Li ne Lengt h Repor t f or / 100- B- 1 / 100- B- 2

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 100. 00 7610. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19/ 100- B- 2 / 100- B- 2- B2 / A3B 80. 00 2526. 65

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 56

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    ===========

    55236. 56

    3.4 Subtotalling

    The Subtotals option on the Layout for Column form can be Off or set to the number of asorted column. Subtotals can only be produced for columns containing numeric data.

  • 7/27/2019 Reporting Reference Manual

    21/34

    Reporting Reference Manual

    Sorting and Totalling

    12.03:5 2007 AVEVA Solutions Ltd

    SetSubtotalling on for the Centre Line Length column, and the report will look like this:

    Cent r e Li ne Lengt h Report f or / 100- B- 1 / 100- B- 2

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 100. 00 7860. 35

    - - - - - - - - - - -

    7860. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 2 / 100- B- 2- B2 / A3B 80. 00 2526. 65

    - - - - - - - - - - -

    4981. 84

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 55

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    - - - - - - - - - - -

    42644. 36

    Subt ot al l i ng wi t h Tot al l i ng wi l l pr oduce t he f ol l owi ng r epor t :PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 100. 00 7610. 35

    - - - - - - - - - - -

    7610. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 2 / 100- B- 2- B2 / A3B 80. 00 2526. 65

    - - - - - - - - - - -

    4981. 84

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 56

    / 100- B- 1 / 100- B- 1- B3 / A3B 50. 00 3119. 80

    - - - - - - - - - - -42644. 36

    ===========

    55236. 56

    Subtotalling is closely related to the Values option on the Layout for Column form. Theoptions are:

    On

    The result of the expression (entered in the Expression text box on the CreatingColumn form) will be shown for every line in the report. This is the normal setting forreports without sorting or totalling.

    Off

    No values will be shown.

    1st

    If this column is sorted, this option can be used to display only the first occurrence of aparticular expression result.

    Sub

    A value will only be output in this column when a subtotal appears in one of the othercolumns.

    3.4.1 Showing only the First Occurrence of Values

    For a sorted column, you can output only the first occurrence of a value. For example, setthe Values to 1st for the HBORE column:

    Cent r e Li ne Lengt h Repor t f or / 100- B- 1 / 100- B- 2

  • 7/27/2019 Reporting Reference Manual

    22/34

    12.03:6

    Reporting Reference Manual

    Sorting and Totalling

    2007 AVEVA Solutions Ltd

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 100. 00 7610. 35

    - - - - - - - - - - -

    7610. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 80. 00 2455. 19

    / 100- B- 2 / 100- B- 2- B2 / A3B 2526. 65

    - - - - - - - - - - -

    4981. 84

    / 100- B- 1 / 100- B- 1- B1 / A3B 50. 00 39524. 56

    / 100- B- 1 / 100- B- 1- B3 / A3B 3119. 80

    - - - - - - - - - - -

    42644. 36===========

    55236. 56

    You can display each value for a sorted column next to the corresponding subtotal value.

    Set the Values option for HBORE (which must be sorted) to Sub. Set the Centre LineLength Subtotals to 4, that is, show subtotals for each value in column 4 (HBORE).

    Cent r e Li ne Lengt h Repor t f or / 100- B- 1 / 100- B- 2

    PI PE NAME PSPEC HEAD BORE CENTRE LI NE

    LENGTH

    / 100- B- 2 / 100- B- 2- B1 / A3B 7610. 35

    - - - - - - - - - - -100. 00 7610. 35

    / 100- B- 1 / 100- B- 1- B2 / A3B 2455. 19

    / 100- B- 2 / 100- B- 2- B2 / A3B 2526. 65

    - - - - - - - - - - -

    80. 00 4981. 84

    / 100- B- 1 / 100- B- 1- B1 / A3B 39524. 56

    / 100- B- 1 / 100- B- 1- B3 / A3B 3119. 80

    - - - - - - - - - - -

    50. 00 42644. 36

    ===========55236. 56

    3.5 Quantity

    The template pipe_mto.tmp outputs a report which shows the quantity of each type of itemwith a given Detail Text. Hence the important relationship is between Column 2, Detail Text,and Column 5, Quantity.

    Values are set to Sub for all the columns except Detail Text, where the 1st occurrenceof each value is given.

    Subtotals is set to 2 for the Quantity column, which means that items with the same

    Detail Text are totalled.

  • 7/27/2019 Reporting Reference Manual

    23/34

    Reporting Reference Manual

    Sorting and Totalling

    12.03:7 2007 AVEVA Solutions Ltd

    The elements are first sorted alphabetically on type. The Material Text, and in the case ofTUBI elements, the length, is also given.

    The columns are set up as follows:

    TYPE

    SortAa to zZ, Precedence 1.

    Values set to Sub , Subtotals Offand Total Off.

    DTXR

    SortAa to zZ, Precedence 2.

    Values set to 1st , Subtotals Offand Total Off.

    MTXX

    No sorting.

    Values set to Sub , Subtotals Offand Total Off.

    ITLE

    No sorting.

    Values set to Sub , Subtotals set to 2 and Total Off.

    QUANTITY

    No sorting.

    Values set to Sub , Subtotals set to 2 and Total Off.

    Pi pework MTO f or / 100-B- 1 / 100- B- 2 / 150- A- 3

    Type Detai l Materi al Tube Quanti t y

    Text Text

    ATTA unset unset 5

    ELBO ELBOW LR ANSI B16. 9 BW ASTM A234- WPB 17FLAN ANSI . B16. 36. WN. ORI FACE. FLANGE. #300. RF ASTM A105 2

    FLAN FLANGE WN ANSI B16. 5 #150. RF ASTM A105 2

    FLAN FLANGE WN ANSI B16. 5 #300. RF ASTM A105 22

    GASK GASKET RF 1. 5MM ANSI B16. 5 #150 SS & ASB 2

    GASK GASKET RF 1. 5MM ANSI B16. 5 #300 SS & ASB 26

    I NST ORI FI CE PLATE 3MM THK #300 unset 1

    REDU NI PPLE CONC SWAGED BLE/ PSE ASTM A234- WPB 2

    REDU REDU CONC ANSI B16. 9 BW ASTM A234- WPB 3

    REDU REDU ECC ANSI B16. 9 BW ASTM A234- WPB 2

    TEE TEE ANSI B16. 9 BW ASTM A234- WPB 5

    TUBI PI PE SCH40 ANSI B36. 10 API 5L- B 13410. 56 51

    VALV CTRL VALVE FI SHER TYPE 657- ED #300. RF ASTM A216- WCB 2

    VALV MI SSI ON K WAFER CHECK VALVE #300 RF ASTM A216- WCB 2

    VALV VALVE GATE ANSI B16. 10 #150. RF ASTM A216- WCB 1

    VALV VALVE GATE ANSI B16. 10 #300. RF ASTM A216- WCB 5VALV VALVE GLOBE ANSI B16. 10 #300. RF ASTM A216- WCB 2

  • 7/27/2019 Reporting Reference Manual

    24/34

    12.03:8

    Reporting Reference Manual

    Sorting and Totalling

    2007 AVEVA Solutions Ltd

  • 7/27/2019 Reporting Reference Manual

    25/34

    Reporting Reference Manual

    Selective Reporting

    12.04:1 2007 AVEVA Solutions Ltd

    4 Selective Reporting

    The With option on the New/Modify Report Template form allows you to restrict the report toelements of the given type whose properties satisfy given conditions. The restriction isdefined by an Expression, which is entered in the text box, full information about usingexpressions is given in the PDMS Database Reference Manual.

    The expressions used in selective reporting will be a combination of PDMS attributes orpseudo-attributes, logical operators and values.

    For example, if you are reporting on Elbows (that is, you have entered ELBO in the Typetext box), you can restrict the report to Elbows with ABORE greater than 50 by entering theexpression:

    ABORE GT 50

    whereABORE is the PDMS attribute, GT is an operator meaning greater than, and 50 is thevalue. The operators you can use are:

    You can specify more than one condition using the operators AND, OR and NOT. Forexample, to report on Elbows with ABORE greater than 50 but less than 100 enter:

    (ABORE GT 50) AND (ABORE LT 100)

    EQ equal to

    NE not equal to

    GT greater than

    GE greater than or equal to

    LE less than

    LT less than or equal to

  • 7/27/2019 Reporting Reference Manual

    26/34

    12.04:2

    Reporting Reference Manual

    Selective Reporting

    2007 AVEVA Solutions Ltd

  • 7/27/2019 Reporting Reference Manual

    27/34

    Reporting Reference Manual

    File Reports

    12.05:1 2007 AVEVA Solutions Ltd

    5 File Reports

    This chapter describes how to set up templates for reports that will be output to a file. Thecontent of the reports is defined in the same way as for screen reports, and the layout of thecolumns is also controlled in the same way, but there are additional options which controlheaders, footers and headings and other information which can be added to file reports.

    Set Destination to File, and give a filename in the text box. The file will be stored in thedirectory PDMSUSER/REPORTS.

    You should also specify what will happen if the file exists. The options are

    Append

    If the file exists, output will be appended to it.

    New

    If the file exists, you will be prompted to confirm that you want to overwrite the file.

    Overwrite

    If the file exists, it will be overwritten with no warning.

    5.1 Page Information Options

    The options under Page Information on the menu at the top of the New/Modify ReportTemplate form allow you to add information which is not specified in the body of the report.The options are:

    Set a Header

    Set a Footer

    Insert an Introduction into the Report

    Insert a Summary into the Report

    Set the Page Length

    Each option displays a form with a text pane. You type the information you want in the textpane. Each line of information is entered as an expression, full information about usingexpressions is given in the Database Management Reference Manual.

  • 7/27/2019 Reporting Reference Manual

    28/34

    12.05:2

    Reporting Reference Manual

    File Reports

    2007 AVEVA Solutions Ltd

    5.2 Report Variables

    There are several special variables used to insert information such as date and page

    numbers in a report. The variables are designed to be used outside the body of the report,that is, in the Introduction, Summary, Header or Footer.

    These variables must be used together with the operators which control late evaluation ofvariables. See Section , .

    5.2.1 Late Evaluation of Variables

    Variables stored in file report templates must be used with one of the late evaluationoperators described below. Without these operators, the variables would be evaluated assoon as the form containing them is actioned using the OK orApply button, instead of beingstored as variables in the template and evaluated when the template is run.

    The three operators are:

    VTEXT, used for the late evaluation of variables when a text result is required.

    VLOGICAL, used for late evaluation when a logical result is required.

    VVALUE, used for late evaluation when a numeric result is required.

    Examples of using the report variables with the late evaluation operators are given in thefollowing sections.

    5.2.2 Points to Note

    A summary of the information you are most likely to need in setting up the page information

    is given below.

    !pageno Inserts page numbers.

    !filename Inserts the filename to which the report will be sent.

    !seltype Inserts the contents of the Type text box.

    !selhierarchy Inserts the contents of the Hierarchy text box.

    !selvolspec Inserts Off, Completely within orPartially within, as specified onthe Hierarchy form.

    !selvolume Inserts the coordinates defining the volume, as specified on theHierarchy form.

    !selfrom Inserts MDB, Drawlist or Obstruction List, as specified on theHierarchy form.

    !criteria Inserts the complete selection criteria on which the report is based.

    !selsize Inserts the number of elements that match the criteria.

    !selno Inserts the sequence number of an element in a selection. Thisvariable should be used with the Sort option on the CreatingColumn form set to Fix for the column.

    !date Inserts today's date.

    !time Inserts the time.

  • 7/27/2019 Reporting Reference Manual

    29/34

    Reporting Reference Manual

    File Reports

    12.05:3 2007 AVEVA Solutions Ltd

    Text must be entered in quotes. For example:

    ' Page number '

    You can include any PML variables in the expressions.

    Variables must be preceded by one of the functions vtext, vval or vlog, which ensurelate evaluation of the variables. For more information see Section , . For example, toshow the page number on every page of the report, enter the following expression inthe header or footer:

    vtext ( !pageno )

    If you want to combine text and variables in the same expression (that is, on the sameline, you must combine them using the text operator +. For example, if you want tonumber the pages with the format Page 1, Page 2 and so on, you should enter thefollowing expression in the header or footer:

    ' Page ' + vt ext ( ! pageno )

    5.3 Headers, Footers and Page LengthsInformation in Headers and Footers will appear at the top or bottom of every pages of a filereport. Headers and footers are not available for screen reports.

    Note: You must have a page length of between 5 and 500 lines set before headers andfooters will be displayed in file reports.

    The Page Length form, Page Headerform and Page Footerform are displayed by selectingthe options under Page Info from the menu on the New Report Template form.

    5.4 Introduction and Summaries

    Both file reports and screen reports can have an Introduction and Summary. You can insertwhatever text and variables you want.

    5.5 Examples

    The following examples are mainly taken from the templates supplied with the product.

    To insert a page number containing the textPage number, followed by the page number,use the !pageno variable:

    ' Page No. ' + vt ext ( ! pageno)

    To insert the users name in the form of the text User Name: followed by the name, usethe PDMS global variable !!user:

    ' User name: ' + vt ext ( ! ! user )

    To insert the date and time, use the report variables !date and !time:

    ' Dat e: ' + vt ext ( ! dat e) + ' ' + vt ext ( ! t i me)

    To insert a blank line, use:

    ' '

    To insert the hierarchy reported on, use:

  • 7/27/2019 Reporting Reference Manual

    30/34

    12.05:4

    Reporting Reference Manual

    File Reports

    2007 AVEVA Solutions Ltd

    ' Nozzl e Schedul e f or ' + vtext ( ! s el hi erarchy)

    To insert the number of elements reported on, use, for example:

    ' Summar y: ' + vt ext ( ! sel si ze) + ' Nozzl es i n Schedule'

  • 7/27/2019 Reporting Reference Manual

    31/34

    Reporting Reference Manual

    Additional Information

    12.06:1 2007 AVEVA Solutions Ltd

    6 Additional Information

    6.1 Running Reports in Batch Mode

    Report templates are PDMS macros, which can be run in batch mode by giving thecommand $M/template-name. For more information about batch mode, see the PDMS

    MONITOR Reference Manual.

    Note: Report templates for batch mode must not have any runtime prompts set.

    6.2 System Command Option

    The System Command text box on the New/Modify Report Template form allows you togive a system command that will be run when the report has been completed.

    For example, you could use this option to send the report output to a printer, or to run amacro to process the report. The command is entered as an expression full informationabout expressions, is given in the Database Management Reference Manual.

    6.3 Report Output Formats

    The Report Format form will be displayed when you select Options > Other Formats onthe menu on the New/Modify Report Template form. It allows you to output a report in CSV(Comma Separated Variable) format, which can be read into a spreadsheet.

    You can specify the field separator and text delimiter. Values in the report are recognised astext if the Units option on the Creating Column form is set to Off.

  • 7/27/2019 Reporting Reference Manual

    32/34

    12.06:2

    Reporting Reference Manual

    Additional Information

    2007 AVEVA Solutions Ltd

  • 7/27/2019 Reporting Reference Manual

    33/34

    Index

    12.0Index page 1

    Reporting Reference Manual

    2007 AVEVA Solutions Ltd

    A

    Adding and moving columns. . . . . . . . . . 2:3Adding elements . . . . . . . . . . . . . . . . . . . 2:5

    B

    Batch mode. . . . . . . . . . . . . . . . . . . . . . . 6:1

    C

    Column Layout . . . . . . . . . . . . . . . . . . . . 2:2Column width . . . . . . . . . . . . . . . . . . . . . 2:6Columns . . . . . . . . . . . . . . . . . . . . . . . . . 2:1Columns:adding . . . . . . . . . . . . . . . . . . . 2:3Columns:moving . . . . . . . . . . . . . . . . . . . 2:3Creating a report template . . . . . . . . . . . 2:1CSV format . . . . . . . . . . . . . . . . . . . . . . . 6:1

    D

    Decimal

    . . . . . . . . . . . . . . . . . . . . . . . . . . 2:7Deleting a template . . . . . . . . . . . . . . . . . 2:5Destination . . . . . . . . . . . . . . . . . . . . . . . 5:1Drawlist:adding elements from . . . . . . . . 2:6

    E

    Expressions . . . . . . . . . . . . . . . . . . . . . . 4:1

    F

    File reports . . . . . . . . . . . . . . . . . . . 2:1, 5:1First occurrence:of values. . . . . . . . . . . . 3:5

    Footers . . . . . . . . . . . . . . . . . . . . . . 5:1, 5:3

    Formats:output . . . . . . . . . . . . . . . . . . . . 6:1Fraction . . . . . . . . . . . . . . . . . . . . . . . . . 2:7

    H

    Headers . . . . . . . . . . . . . . . . . . . . . .5:1, 5:3Headings . . . . . . . . . . . . . . . . . . . . . . . . 2:8Hierarchy . . . . . . . . . . . . . . . . . . . . . . . . 2:5Hierarchy:adding elements . . . . . . . . . . 2:5

    I

    Imperial units style . . . . . . . . . . . . . . . . . 2:7Introductions. . . . . . . . . . . . . . . . . . . . . . 2:8Introductions in reports. . . . . . . . . . .5:1, 5:3

    J

    J ustification . . . . . . . . . . . . . . . . . . . . . . 2:6

    L

    Leading zeros. . . . . . . . . . . . . . . . . . . . . 2:7

    N

    New Report Template form . . . . . . . . . . 2:1Numeric Display . . . . . . . . . . . . . . . . . . . 2:7

    O

    Obstruction list:adding elements from . . 2:6Output formats . . . . . . . . . . . . . . . . . . . . 6:1

  • 7/27/2019 Reporting Reference Manual

    34/34

    Reporting Reference Manual

    P

    Page information. . . . . . . . . . . . . . . . . . . 5:1

    Page length

    . . . . . . . . . . . . . . . . . . . . . . . 5:1page length . . . . . . . . . . . . . . . . . . . . . . . 5:3Precedence. . . . . . . . . . . . . . . . . . . . . . . 3:2

    Q

    Quantity. . . . . . . . . . . . . . . . . . . . . . . . . . 3:6

    R

    Remainder . . . . . . . . . . . . . . . . . . . . . . . 2:7Report Details form . . . . . . . . . . . . . . . . . 1:3Report variables . . . . . . . . . . . . . . . . . . . 5:2

    Reports directory. . . . . . . . . . . . . . . . . . . 1:1Running a report . . . . . . . . . . . . . . . . . . . 1:3Runtime Prompts . . . . . . . . . . . . . . . . . . 3:1Runtime prompts. . . . . . . . . . . . . . . . . . . 2:4

    S

    Sample report templates. . . . . . . . . . . . . 1:1Saving a template . . . . . . . . . . . . . . . . . . 2:4Screen reports . . . . . . . . . . . . . . . . . . . . 2:1Selective reporting . . . . . . . . . . . . . . . . . 4:1Sorting. . . . . . . . . . . . . . . . . . . . 2:6, 2:8, 3:1

    Spaces before column

    . . . . . . . . . . . . . . 2:6Style (Imperial units) . . . . . . . . . . . . . . . . 2:7Subtotalling . . . . . . . . . . . . . . . . . . . . . . . 3:4Subtotals . . . . . . . . . . . . . . . . . . . . . . . . . 2:8Summaries . . . . . . . . . . . . . . . . . . . . . . . 2:8Summaries in reports . . . . . . . . . . . 5:1, 5:3System Command . . . . . . . . . . . . . . . . . 6:1

    T

    Templates:deleting . . . . . . . . . . . . . . . . . 2:5Templates:saving . . . . . . . . . . . . . . . . . . 2:4Text Display . . . . . . . . . . . . . . . . . . . . . . 2:8

    Totalling . . . . . . . . . . . . . . . . . . . . . 3:1, 3:4Totals . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8

    U

    Unset text . . . . . . . . . . . . . . . . . . . . . . . . 2:8

    V

    Values . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8Values:in subtotalling . . . . . . . . . . . . . . . 3:5Variables:late evaluation. . . . . . . . . . . . . 5:2

    Volumes:adding elements from

    . . . . . . . 2:5

    W

    With option . . . . . . . . . . . . . . . . . . . . . . . 4:1