Professional Documents
Culture Documents
Disclaimer
Information of a technical nature, and particulars of the product and its use, is given by AVEVA Solutions 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 or entity 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 every part of it (including source code, object code, any data contained in it, the manual and any other documentation 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 retrieval system, or transmitted without the prior written permission of AVEVA Solutions Ltd Where such permission is granted, it expressly requires that this Disclaimer and Copyright notice is prominently displayed at the beginning of every copy that is made. The manual and associated documentation may not be adapted, reproduced, or copied, in any material or electronic form, without the prior written permission of AVEVA Solutions Ltd. The user may also not reverse engineer, decompile, copy, or adapt the associated software. Neither the whole, nor part of the product 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 by law. Any such unauthorised action is strictly prohibited, and may give rise to civil liabilities and criminal prosecution. The AVEVA products described in this guide are to be installed and operated strictly in accordance with the terms and conditions of the respective licence agreements, and in accordance with the relevant User 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 its subsidiaries, 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 or logo belongs to its respective owner.
Contents
Page
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 from a Saved Template. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1:3
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
12.0
From
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:6
Quantity
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3:6
Headers, Footers and Page Lengths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3 Introduction and Summaries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3 Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5:3
1 A1:ii
12.0
Introduction to Reports
This manual is an introduction to the PDMS Reports Utility, available in DESIGN, DRAFT and 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 the column 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 to other database systems or spread sheets. Complete control over the report definition and layout. Generation of reports using the batch process.
1.1
1:1
12.0
The sample templates produce the following types of report: nozz_sched This is a Nozzle schedule, which lists all Nozzles sorted by name, and shows the P1 bore, connection type and direction, and the position of each Nozzle. This report is a list of Branches, sorted by the name of the Pipe which owns them. The Head and Tail bores and the Head and Tail references are given. This report shows material information for all Branch members, sorted by type, Detail Text and Material Text. The Tube length and quantity of each component are totalled. There is an Imperial version of this report template. This report totals all Tubing. The Specification Reference, P1 Bore, Detail Text and Material Text are shown. This is a material take-off list for structural components. This report is an example of selective reporting. The centre-line length of each Branch is listed. There is an Imperial version of this report template. This report gives the gradient of each tubing component. This is an example of reporting on the catalogue database. It lists Branch members, with their CATREFs and the parameters of the CATREFs. This is an example of reporting on the catalogue database. It lists Branch members, with their CATREFs followed by the PTREFs and GMREFs of the CATREFs. This report uses derived properties to report on the area and volume of tubing.
line_list
pipe_mto
catalogue_ptgmref
tube_area_vol
1.2
1:2
12.0
1.3
1.4
1.5
1:3
12.0
1:4
12.0
2.1
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 the level in the database hierarchy below which the selection will be made. The Zone EQUIP in the sample project contains the Equipment /E1301, which owns several Nozzles. We will produce a template to report on these Nozzles. For this example: 1. Enter NOZZ in the Type(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 be present, 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 bore and the position, using the Columns options. Select the New option button, and the Creating Column form will be displayed.
2:1
12.0
The Expression text box defines the contents of the column. You can enter a PDMS attribute or pseudo-attribute here, or an expression containing attributes or pseudoattributes. Ignore the Sorting and Precedence option for now. By default, the list of items in the report will 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 the default 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 Next Column. The settings on the Creating Column form will be cleared ready for you to define the second column. 3. The second column will display the arrive bore of the Nozzles. Type P1 BORE into the Expression text box. Select Units of Any/mm. 4. Select Next Column again and define the third column, which will display the coordinates of the Nozzle, by entering POS into the Expression text box. Units should be set to Pos(mm). Now select OK on the Creating Column form. Note that the three columns you have defined are shown in the scrolling list on the New Report Template form.
2.1.4
POS E 0.00 E 0.00 E 0.00 E 0.00 E 0.00 N 3540.00 N 1100.00 N 5980.00 N 290.00 N 290.00 D 635.00 U 635.00 U 635.00 U 635.00 D 635.00
Note: By default the text that you entered in the Expression text box is used as the column heading. 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 Layout for Column form to improve it.
2:2
12.0
Highlight POS in the list on the New Report Template form, and select Modify. On the Modifying Column 3 form, select Column Layout, and you will see the Layout for Column form. Set the Spaces before Column option to 4, and set Justification to Left. The output will look like this:
NAME
/E1301-S1 /E1301-S2 /E1301-S3 /E1301-T1 /E1301-T2
P1 BORE
200.00 200.00 200.00 100.00 100.00
POS
E 0.00 E 0.00 E 0.00 E 0.00 E 0.00 N 3540.00 N 1100.00 N 5980.00 N 290.00 N 290.00 D 635.00 U 635.00 U 635.00 U 635.00 D 635.00
Further column layout options are describes in More Column Layout Options.
2.3
2:3
12.0
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 will want 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 using runtime prompts. The Runtime Prompts form will be displayed when you select Options>Runtime Prompts on the menu on the New/Modify Report Template form. The options correspond to the options on the New/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 other options 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 select OK. 2. Now run the report again, by selecting Apply on the New Report Template form. You will see the Report Details form, with the values you have set on the Report Template form for the three parameters displayed. You can now change them: for example, enter a 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 the Filename option on the Runtime Prompts form, because the report will be sent to the screen 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 Report Details form.
2.5
2.5.1
Note: The file where the template is stored has no relation to the file specified if you want to 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.
2:4
12.0
2.5.2
Deleting 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
/100-B-1 /100-B-2
If you want to specify several elements, it is easiest to use the Hierarchy form, which also allows you to report on all the elements in a Volume, selected from the MDB, the Drawlist or the Obstruction list.
2.6.1
2.6.2
2:5
12.0
The volume is defined by entering the coordinates of the diagonal of a limits box, either by entering the coordinates into the text boxes, or using the menu options to pick a point with the 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 from Grid form, which is used in exactly the same way as the Clip from Grid form (described in Graphical Model Manipulation Guide). Note: Specifying a Volume will select elements from the whole MDB. The other From options cannot be used.
2.6.3
From
The From options are used to specify where the Reports Utility will look for the elements to report 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 left blank.
2.7
2.7.1
Layout
The number of Spaces before column. This is the number of spaces between the end of the previous column and the start of the current column. The effect will be affected by the Justification. 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 or Right. The effects of the layout options are illustrated in the following examples, based on the template centre_line.tmp: The format as supplied: Centre Line Length Report for /100-B-1 PIPE /100-B-1 NAME /100-B-1-B2 PSPEC /A3B HEAD BORE 80.00 CENTRE LINE LENGTH 2455.19
2:6
12.0
/100-B-1 /100-B-1
/100-B-1-B1 /100-B-1-B3
/A3B /A3B
50.00 50.00
39524.55 3119.80
Justification for the HBORE column set to Centre: Centre Line Length Report for /100-B-1 PIPE /100-B-1 /100-B-1 /100-B-1 NAME /100-B-1-B2 /100-B-1-B1 /100-B-1-B3 PSPEC /A3B /A3B /A3B HEAD BORE 80.00 50.00 50.00 CENTRE LINE LENGTH 2455.19 39524.55 3119.80
Space before the HBORE column set to 5, rather than 2: Centre Line Length Report for /100-B-1 PIPE /100-B-1 /100-B-1 /100-B-1 NAME /100-B-1-B2 /100-B-1-B1 /100-B-1-B3 PSPEC /A3B /A3B /A3B HEAD BORE 80.00 50.00 50.00 CENTRE LINE LENGTH 2455.19 39524.55 3119.80
Space before the HBORE column set to 2, and the column width set to 15: Centre Line Length Report for /100-B-1 PIPE /100-B-1 /100-B-1 /100-B-1 NAME /100-B-1-B2 /100-B-1-B1 /100-B-1-B3 PSPEC /A3B /A3B /A3B HEAD BORE 80.00 50.00 50.00 CENTRE LINE LENGTH 2455.19 39524.55 3119.80
2.7.2
Numeric Display
The Remainder can be set to: or Fraction in which case you must specify the Denominator. In the output, the denominator will be reduced if possible. US gives 10'-5" PDMS gives 10' 5 Decimal in which case you can specify the number of Decimal places
The Style only affects how feet and inches are displayed. For example:
2:7
12.0
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 of switching Headings off, see Sorting and Totalling. The Page option is only used for file reports. For more information, see File Reports .
Heading Text
The Heading Text can be set to: Expression Text which will use the expression entered in the Expression text box on the Creating Column 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 CLLE in 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 several lines of text. The Centre Line Length template, which has the heading split over two lines, is an example.
Values For reports without sorting or totalling Values will normally be On. For examples of the other options see Sorting and Totalling. Subtotals and Totals Totals can only be produced for columns containing numeric data, and which do not have the Subtotal option set. For more information, see Sorting and Totalling.
2.8
2:8
12.0
3:1
12.0
/200-B-4 /A3B 200.00 200 /250-B-5 /A3B 200.00 250 /250-B-5 /A3B 200.00 250 Summary: 27 Lines in Schedule
3.1
3.2
3:2
12.0
If you run the report now, the output will look like this; note the different order for Branches with HBORE 50:
Line List for /PIPES PIPE PSPEC HBORE TBORE /200-B-4 /A3B 200.00 200 /250-B-5 /A3B 200.00 250 /250-B-5 /A3B 200.00 250 /150-A-57 /A1A 150.00 100 /150-A-57 /A1A 150.00 100 /150-B-6 /A3B 150.00 150 /100-B-2 /A3B 100.00 100 /100-B-8 /A3B 100.00 100 /100-B-8 /A3B 100.00 100 /100-C-12 /F1C 100.00 100 /100-C-13 /F1C 100.00 100 /150-A-3 /A1A 100.00 150 /80-B-14 /A3B 80.00 50 /100-B-1 /A3B 80.00 80 /100-B-2 /A3B 80.00 80 /80-B-7 /A3B 80.00 80 /100-C-12 /F1C 80.00 80 /40-B-10 /A3B 50.00 40 /50-B-9 /A3B 50.00 50 /50-B-9 /A3B 50.00 50 /50-B-9 /A3B 50.00 50 /80-B-14 /A3B 50.00 50 /80-A-11 /A1A 50.00 80 /100-B-1 /A3B 50.00 100 /100-B-1 /A3B 50.00 100 /40-B-10 /A3B 40.00 40 /50-B-9 /A3B 15.00 15 Summary: 27 Lines in Schedule HREF /C1101-N3 /E1301-S2 /E1301-S3 =0/0 /150-A-57-B1-TEE1 /C1101-N6 /C1101-N1 /D1201-N4 /100-B-8-B1-TEE1 =0/0 /E1301-T2 /100-B-2-B1 /D1201-N2 /100-B-1-B1-TEE2 /100-B-2-B1-TEE1 /E1302A-S2 /100-C-12-B1-TEE1 /50-B-9-B1-TEE3 /P1501A-N2 /50-B-9-B1-TEE4 /P1501B-N2 /80-B-14-B1-TEE1 /80-B-14-B1 /P1502A-N2 /P1502B-N2 /40-B-10-B1-TEE1 /50-B-9-B1-TEE2 TREF /E1301-S1 /C1101-N2 =140/612 /P1502A-N1 /P1502B-N1 /E1302B-S1 /150-A-3-B1 /P1501B-N1 /P1501A-N1 /E1301-T1 =0/0 =0/0 /80-A-11-B1 /100-B-1-B1-TEE3 =139/603 /D1201-N1 /100-C-12-B1-TEE2 =0/0 /C1101-N5 /50-B-9-B1-TEE5 /50-B-9-B1-TEE1 /80-A-11-B1-TEE1 =0/0 /C1101-N4 /100-B-1-B1-TEE1 /40-B-10-B1-TEE2 =0/0
Change the Precedence of the TBORE column to 1, which will automatically change the precedence of the HBORE column to 2. Now the output will look like this:
Line List for /PIPES PIPE PSPEC HBORE /50-B-9 /A3B 15.00 /40-B-10 /A3B 50.00 /40-B-10 /A3B 40.00 /80-B-14 /A3B 80.00 /50-B-9 /A3B 50.00 /50-B-9 /A3B 50.00 /50-B-9 /A3B 50.00 /80-B-14 /A3B 50.00 /100-B-1 /A3B 80.00 /100-B-2 /A3B 80.00 /80-B-7 /A3B 80.00 /100-C-12 /F1C 80.00 /80-A-11 /A1A 50.00 /150-A-57 /A1A 150.00 /150-A-57 /A1A 150.00 TBORE 15 40 40 50 50 50 50 50 80 80 80 80 80 100 100 HREF /50-B-9-B1-TEE2 /50-B-9-B1-TEE3 /40-B-10-B1-TEE1 /D1201-N2 /P1501A-N2 /50-B-9-B1-TEE4 /P1501B-N2 /80-B-14-B1-TEE1 /100-B-1-B1-TEE2 /100-B-2-B1-TEE1 /E1302A-S2 /100-C-12-B1-TEE1 /80-B-14-B1 =0/0 /150-A-57-B1-TEE1 TREF =0/0 =0/0 /40-B-10-B1-TEE2 /80-A-11-B1 /C1101-N5 /50-B-9-B1-TEE5 /50-B-9-B1-TEE1 /80-A-11-B1-TEE1 /100-B-1-B1-TEE3 =139/603 /D1201-N1 /100-C-12-B1-TEE2 =0/0 /P1502A-N1 /P1502B-N1
3:3
12.0
/100-B-2 /A3B 100.00 /100-B-8 /A3B 100.00 /100-B-8 /A3B 100.00 /100-C-12 /F1C 100.00 /100-C-13 /F1C 100.00 /100-B-1 /A3B 50.00 /100-B-1 /A3B 50.00 /150-B-6 /A3B 150.00 /150-A-3 /A1A 100.00 /200-B-4 /A3B 200.00 /250-B-5 /A3B 200.00 /250-B-5 /A3B 200.00 Summary: 27 Lines in Schedule
100 100 100 100 100 100 100 150 150 200 250 250
/C1101-N1 /D1201-N4 /100-B-8-B1-TEE1 =0/0 /E1301-T2 /P1502A-N2 /P1502B-N2 /C1101-N6 /100-B-2-B1 /C1101-N3 /E1301-S2 /E1301-S3
/150-A-3-B1 /P1501B-N1 /P1501A-N1 /E1301-T1 =0/0 /C1101-N4 /100-B-1-B1-TEE1 /E1302B-S1 =0/0 /E1301-S1 /C1101-N2 =140/612
3.3
Totalling
To see the effect of totalling, use the template centre_line.tmp and set the hierarchy to 100B-1 and 100-B-2. The template as supplied will report on the Branches, giving the Pipe name and the Pipe Specification, sorted on descending order of Head Bore, and the Centre Line Length, as follows:
Centre Line Length Report for /100-B-1 /100-B-2 PIPE NAME PSPEC HEAD BORE CENTRE LINE 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 Centre Line Length column, and the report will appear like this:
Centre Line Length Report for /100-B-1 /100-B-2 PIPE NAME PSPEC HEAD BORE CENTRE LINE 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 a sorted column. Subtotals can only be produced for columns containing numeric data.
3:4
12.0
Set Subtotalling on for the Centre Line Length column, and the report will look like this:
Centre Line Length Report for /100-B-1 /100-B-2 CENTRE LINE 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 Subtotalling with Totalling will produce the following report: PIPE NAME PSPEC HEAD BORE CENTRE LINE 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 PIPE NAME PSPEC HEAD BORE
Subtotalling is closely related to the Values option on the Layout for Column form. The options are: On The result of the expression (entered in the Expression text box on the Creating Column form) will be shown for every line in the report. This is the normal setting for reports 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 a particular expression result. Sub A value will only be output in this column when a subtotal appears in one of the other columns.
3.4.1
3:5
12.0
PIPE
NAME /100-B-2-B1
PSPEC /A3B
HEAD BORE
/100-B-2
/100-B-1 /100-B-2
/100-B-1-B2 /100-B-2-B2
/A3B /A3B
/100-B-1 /100-B-1
/100-B-1-B1 /100-B-1-B3
/A3B /A3B
CENTRE LINE LENGTH 100.00 7610.35 ----------7610.35 80.00 2455.19 2526.65 ----------4981.84 50.00 39524.56 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 Line Length Subtotals to 4, that is, show subtotals for each value in column 4 (HBORE).
Centre Line Length Report for /100-B-1 /100-B-2 PIPE NAME PSPEC HEAD BORE CENTRE LINE 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 item with 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 occurrence of each value is given. Subtotals is set to 2 for the Quantity column, which means that items with the same Detail Text are totalled.
3:6
12.0
The elements are first sorted alphabetically on type. The Material Text, and in the case of TUBI elements, the length, is also given. The columns are set up as follows: TYPE Sort Aa to zZ, Precedence 1. Values set to Sub, Subtotals Off and Total Off. DTXR Sort Aa to zZ, Precedence 2. Values set to 1st, Subtotals Off and Total Off. MTXX No sorting. Values set to Sub, Subtotals Off and 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.
Pipework MTO for /100-B-1 /100-B-2 /150-A-3 Type Detail Text ATTA unset ELBO ELBOW LR ANSI B16.9 BW FLAN ANSI.B16.36.WN.ORIFACE.FLANGE.#300.RF FLAN FLANGE WN ANSI B16.5 #150.RF FLAN FLANGE WN ANSI B16.5 #300.RF GASK GASKET RF 1.5MM ANSI B16.5 #150 GASK GASKET RF 1.5MM ANSI B16.5 #300 INST ORIFICE PLATE 3MM THK #300 REDU NIPPLE CONC SWAGED BLE/PSE REDU REDU CONC ANSI B16.9 BW REDU REDU ECC ANSI B16.9 BW TEE TEE ANSI B16.9 BW TUBI PIPE SCH40 ANSI B36.10 VALV CTRL VALVE FISHER TYPE 657-ED #300.RF VALV MISSION K WAFER CHECK VALVE #300 RF VALV VALVE GATE ANSI B16.10 #150.RF VALV VALVE GATE ANSI B16.10 #300.RF VALV VALVE GLOBE ANSI B16.10 #300.RF
Material Text unset ASTM A234-WPB ASTM A105 ASTM A105 ASTM A105 SS & ASB SS & ASB unset ASTM A234-WPB ASTM A234-WPB ASTM A234-WPB ASTM A234-WPB API 5L-B ASTM A216-WCB ASTM A216-WCB ASTM A216-WCB ASTM A216-WCB ASTM A216-WCB
Tube
Quantity 5 17 2 2 22 2 26 1 2 3 2 5 51 2 2 1 5 2
13410.56
3:7
12.0
3:8
12.0
Selective Reporting
The With option on the New/Modify Report Template form allows you to restrict the report to elements of the given type whose properties satisfy given conditions. The restriction is defined by an Expression, which is entered in the text box, full information about using expressions is given in the PDMS Database Reference Manual. The expressions used in selective reporting will be a combination of PDMS attributes or pseudo-attributes, logical operators and values. For example, if you are reporting on Elbows (that is, you have entered ELBO in the Type text box), you can restrict the report to Elbows with ABORE greater than 50 by entering the expression:
ABORE GT 50
where ABORE is the PDMS attribute, GT is an operator meaning greater than, and 50 is the value. The operators you can use are: EQ NE GT GE LE LT equal to not equal to greater than greater than or equal to less than less than or equal to
You can specify more than one condition using the operators AND, OR and NOT. For example, to report on Elbows with ABORE greater than 50 but less than 100 enter:
4:1
12.0
4:2
12.0
File Reports
This chapter describes how to set up templates for reports that will be output to a file. The content of the reports is defined in the same way as for screen reports, and the layout of the columns is also controlled in the same way, but there are additional options which control headers, 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 the directory 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
Each option displays a form with a text pane. You type the information you want in the text pane. Each line of information is entered as an expression, full information about using expressions is given in the Database Management Reference Manual.
5:1
12.0
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. !pageno !filename !seltype !selhierarchy !selvolspec !selvolume !selfrom !criteria !selsize !selno Inserts page numbers. Inserts the filename to which the report will be sent. Inserts the contents of the Type text box. Inserts the contents of the Hierarchy text box. Inserts Off, Completely within or Partially within, as specified on the Hierarchy form. Inserts the coordinates defining the volume, as specified on the Hierarchy form. Inserts MDB, Drawlist or Obstruction List, as specified on the Hierarchy form. Inserts the complete selection criteria on which the report is based. Inserts the number of elements that match the criteria. Inserts the sequence number of an element in a selection. This variable should be used with the Sort option on the Creating Column form set to Fix for the column. Inserts today's date. Inserts the time.
!date !time
These variables must be used together with the operators which control late evaluation of variables. See Section , .
5.2.1
Examples of using the report variables with the late evaluation operators are given in the following 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.
5:2
12.0
'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 ensure late evaluation of the variables. For more information see Section , . For example, to show the page number on every page of the report, enter the following expression in the header or footer:
vtext( !pageno )
If you want to combine text and variables in the same expression (that is, on the same line, you must combine them using the text operator +. For example, if you want to number the pages with the format Page 1, Page 2 and so on, you should enter the following expression in the header or footer:
5.3
5.4
5.5
Examples
The following examples are mainly taken from the templates supplied with the product. To insert a page number containing the text Page number, followed by the page number, use the !pageno variable:
''
To insert the hierarchy reported on, use:
5:3
12.0
5:4
12.0
6
6.1
Additional Information
Running Reports in Batch Mode
Report templates are PDMS macros, which can be run in batch mode by giving the command $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
6.3
6:1
12.0
6:2
12.0
Index
A
Adding and moving columns . . . . . . . . . . 2:3 Adding elements . . . . . . . . . . . . . . . . . . . 2:5
H
Headers . . . . . . . . . . . . . . . . . . . . . . 5:1, Headings . . . . . . . . . . . . . . . . . . . . . . . . Hierarchy . . . . . . . . . . . . . . . . . . . . . . . . Hierarchy:adding elements . . . . . . . . . . 5:3 2:8 2:5 2:5
B
Batch mode . . . . . . . . . . . . . . . . . . . . . . . 6:1
C
Column Layout . . . . . . . . . . . . . . . . . . . . 2:2 Column width . . . . . . . . . . . . . . . . . . . . . 2:6 Columns . . . . . . . . . . . . . . . . . . . . . . . . . 2:1 Columns:adding . . . . . . . . . . . . . . . . . . . 2:3 Columns:moving . . . . . . . . . . . . . . . . . . . 2:3 Creating a report template . . . . . . . . . . . 2:1 CSV format . . . . . . . . . . . . . . . . . . . . . . . 6:1
I
Imperial units style . . . . . . . . . . . . . . . . . 2:7 Introductions . . . . . . . . . . . . . . . . . . . . . . 2:8 Introductions in reports . . . . . . . . . . . 5:1, 5:3
J
Justification . . . . . . . . . . . . . . . . . . . . . . 2:6
D
Decimal . . . . . . . . . . . . . . . . . . . . . . . . . . 2:7 Deleting a template . . . . . . . . . . . . . . . . . 2:5 Destination . . . . . . . . . . . . . . . . . . . . . . . 5:1 Drawlist:adding elements from . . . . . . . . 2:6
L
Leading zeros . . . . . . . . . . . . . . . . . . . . . 2:7
N
New Report Template form . . . . . . . . . . 2:1 Numeric Display . . . . . . . . . . . . . . . . . . . 2:7
E
Expressions . . . . . . . . . . . . . . . . . . . . . . 4:1
F
File reports . . . . . . . . . . . . . . . . . . . 2:1, 5:1 First occurrence:of values . . . . . . . . . . . . 3:5 Footers . . . . . . . . . . . . . . . . . . . . . . 5:1, 5:3
O
Obstruction list:adding elements from . . 2:6 Output formats . . . . . . . . . . . . . . . . . . . . 6:1
Index page 1
12.0
P
Page information . . . . . . . . . . . . . . . . . . . 5:1 Page length . . . . . . . . . . . . . . . . . . . . . . . 5:1 page length . . . . . . . . . . . . . . . . . . . . . . . 5:3 Precedence . . . . . . . . . . . . . . . . . . . . . . . 3:2
W
With option . . . . . . . . . . . . . . . . . . . . . . . 4:1
Q
Quantity . . . . . . . . . . . . . . . . . . . . . . . . . . 3:6
R
Remainder . . . . . . . . . . . . . . . . . . . . . . . 2:7 Report Details form . . . . . . . . . . . . . . . . . 1:3 Report variables . . . . . . . . . . . . . . . . . . . 5:2 Reports directory . . . . . . . . . . . . . . . . . . . 1:1 Running a report . . . . . . . . . . . . . . . . . . . 1:3 Runtime Prompts . . . . . . . . . . . . . . . . . . 3:1 Runtime prompts . . . . . . . . . . . . . . . . . . . 2:4
S
Sample report templates . . . . . . . . . . . . . 1:1 Saving a template . . . . . . . . . . . . . . . . . . 2:4 Screen reports . . . . . . . . . . . . . . . . . . . . 2:1 Selective reporting . . . . . . . . . . . . . . . . . 4:1 Sorting . . . . . . . . . . . . . . . . . . . . 2:6, 2:8, 3:1 Spaces before column . . . . . . . . . . . . . . 2:6 Style (Imperial units) . . . . . . . . . . . . . . . . 2:7 Subtotalling . . . . . . . . . . . . . . . . . . . . . . . 3:4 Subtotals . . . . . . . . . . . . . . . . . . . . . . . . . 2:8 Summaries . . . . . . . . . . . . . . . . . . . . . . . 2:8 Summaries in reports . . . . . . . . . . . 5:1, 5:3 System Command . . . . . . . . . . . . . . . . . 6:1
T
Templates:deleting . . . . . . . . . . . . . . . . . 2:5 Templates:saving . . . . . . . . . . . . . . . . . . 2:4 Text Display . . . . . . . . . . . . . . . . . . . . . . 2:8 Totalling . . . . . . . . . . . . . . . . . . . . . 3:1, 3:4 Totals . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8
U
Unset text . . . . . . . . . . . . . . . . . . . . . . . . 2:8
V
Values . . . . . . . . . . . . . . . . . . . . . . . . . . . 2:8 Values:in subtotalling . . . . . . . . . . . . . . . 3:5 Variables:late evaluation . . . . . . . . . . . . . 5:2 Volumes:adding elements from . . . . . . . 2:5
Index page 2
12.0