The Primaver P6 Users Guide to Excel

July 22, 2017 | Author: aliengineer953 | Category: Array Data Structure, Microsoft Excel, Databases, Spreadsheet, Information Technology Management
Share Embed Donate


Short Description

Primavera...

Description

THE PRIMAVERA P6 USER’S

GUIDE TO EXCEL How to use these two powerful tools together to maximize your productivity and reporting.

1

Table of Contents Chapter 1: Why Primavera P6 and Excel Chapter 2: Excel VLOOKUP Tutorial Chapter 3: P6XL Bridge helps you manipulate P6 data in Excel Chapter 4: How to Import WBS from Excel to Primavera P6 using the SDK Chapter 5: Using Primavera’s .xer File Parser – Import WBS from Excel Without the SDK

2

CHAPTER ONE Introduction: Why Primavera 6 And Excel Are Better Together

3

Primavera P6 users are also Excel users? Why the two are better together. Excel has the ability to map out data in dashboards, utilize math and lookup functions not available in Primavera P6, and overall save you time and stress.

Primavera P6, conversely, can help you manage and track your WBS files in one centralized location. IN this eBook we have packaged up some of our favorite tutorials, so you have an easy way to make use of these powerful tools.

4

CHAPTER TWO EXCEL VLOOKUP TUTORIAL

5

Primavera users are also Excel users. As many of you know, Microsoft Excel has many useful functions in different areas such as Financial, Date & Time, Math, Trig and so on. One of these areas is Look up & Reference. The functions in this area are dealt with lists, indexes and arrays and help us to find some special information in these listed data or other. This required information could be address of a desired cell which contains some special value, a value or action to perform a list of values, a reference specified by a text string, a relative position of an item in array that matches a specified value in a specific order and finally: a value in the leftmost column of a table and then returns a value in the same row from a column you specify. The last function is called VLOOKUP and I myself find it very useful in most of the planning activities. Sometimes when you have some spreadsheets with heaps of information in them and you need to transfer some updated information from one list into another, VLOOKUP helps you to do it fast and accurate. This list could be your export from Primavera and you can update it from a database (which most of the time can have an output in the form of a spreadsheet) using VLOOKUP and then import it in Primavera and everything is updated now, easy and quick! Let’s see how can we define and use this function in our Excel VLOOKUP tutorial. How to write a VLOOKUP formula 6

Let’s start with a practical example. Suppose that we have a list of updated progress of some documents and we want to update their percent completes in another list which has been exported from Primavera. Here are our lists on the right.

Let’s call the right table Database table and the left one Primavera table. Now we want to have percent complete for each document. So we start writing the formula in the Activity % complete column in primavera table.

7

When you choose VLOOKUP function in Excel, you should complete the following inputs:  Lookup_value: This is the value that is common between our arrays and we use it to find our desired value. In this example both arrays have Documents numbers in common, so we use this value as our look up value.  Table_array: In here we should input the address of our main array that have desired information in it and in which data is retrieved. We will see how we should insert the cell address in here.  Col_index_num: This number is the column number in our main array in which our desired data is located. You should notice that this number starts from one for the first column in the array that you have chosen in the previous section, so you should count columns to find your result column and input the number in here. In our example %Complete is located in fifth column so we should input 5 in this part.  Range_lookup: In this part you have two logical TRUE and FALSE options and each one have different meanings in the formula. If you put TRUE the function search for the closest match in the array and you should note that the search is in the ascending order. If you leave this section blank, it works like you put TRUE in it. FALSE means you need to find an exact match in the array, so this option is more accurate and reliable and I prefer this one because sometimes especially when you search some numbers, using TRUE makes you confused. Now let’s get back to our example. The Lookup_value for our example is Activity IDs in the primavera table which is called Document Number in the database table. Our Table_array starts from the first column in the database table and ends on %complete column which is our desired column for getting the result. Col_index is the column number of %complete column which is 5. For getting the most accurate result let’s put the FALSE in the Range_lookup. 8

So our formula is like this:

As you can see for the Table_array amount, the address of cells in the array has been inserted completely, rows and columns, sheet name and even file name is identified. In Excel wherever you see $ sign it means that amount is fixed and if you drag the formula it is not going to be changed, so here the column and the row are both fixed and when you drag the formula for the rest of activities your array is the same but otherwise if you have not $ sign in there and you drag the formula the next one would starts from column C and row 2 till column F and row 32.

Now we can take a look at results and they are amazing. We have our updated list very easy and quick:

9

Tips For using VLOOKUP function there are some tips that you should consider them: 1. Always your lookup value should be in the first column of your table array. If you do not obey this rule the formula won’t work for you. In our example the formula searches the Document Number column to find out our Activity IDs and return their %complete and this column is the first one in the selected array. Sometimes you have to replace columns to put your look up value in the first place of the array. 2. When your lookup value is a text instead of numbers the format of tables are important and you need to make them similar to each other, then the formula can find the result. 3. After writing the formula and drag it for all the cells of the column, maybe the result would appear in another category. In our example if I haven’t set the category of percentage for Activity % complete column in primavera table, the data could be appeared in the decimal number format. Therefore, you need to be sure that you set the proper format for that column. 4. You remember that in the table_array part of the formula when you choose the array by dragging on the cells, the complete address of the array apppears in the formula. On the other hand, most of the time your result is getting from a different file. Sometimes when you close and save both files and then change the place of the reference file (in our example database file) in your computer the formula gets confused and gives you errors. Consequently you may lose your results. I prefer to copy and paste the value of formula after checking that it has worked correctly. So it doesn’t matter where I’m going to save the reference file and the next time when I open the main file, the lookup values are on their place in the file and I have them.

10

Conclusion VLOOKUP is one of the most useful functions in Excel especially for planners and it helps you to save your time and have many updated spreadsheet for either importing to primavera or preparing reports and charts by them. But you should consider the tips and always check the results randomly to be sure that the formula has worked correctly, because this function has many dependencies and if you miss to obey all the rules you may get the wrong results, but when you get used to it, there won’t be any error and you just enjoy its quickness.

11

CHAPTER THREE P6XL BRIDGE HELPS YOU MANIPULATE P6 DATA IN EXCEL

12

What is the P6XL Bridge? The P6XL Bridge is an Excel tool that uses the P6 SDK to communicate with the underlying P6 database using SQL in the background without involving the Primavera P6 Client. Although the user does not deal with SQL directly, the burden of maintaining basic data integrity rules and basic scheduling logic rules is shifted to the user. Primavera P6 is often used to create massive schedules that need constant updating. The P6 Client GUI is not often conducive to the common data manipulation abilities of Excel. The Bridge aims to enable that marriage by exposing the P6 database records, tables, and scheduling logic to the user in simple Excel tables. The P6 Client could still be running while using the Bridge. It could be used to do parts of the data manipulation that is easier in the Client like global change. It could also be used to view the changes made in the Bridge in a more graphical representation. And now….let’s see the P6XL Bridge in Action! In this tutorial, we create and assign 5 activity codes in a sample P6 project using Excel. We use the P6XL Bridge for this because it is not possible to do it in P6 directly without XER manipulation. It is not even possible using the Excel Import/Export functionality in P6 alone without a lot of effort. In this tutorial, we demonstrate that it boils down to a mere copy and paste operation when using the Bridge. Tutorial Assets

13

The following assets were used during the production of this tutorial. 

The P6XL Bridge



Sample Project.xer

Step 1 – Import the Sample Project Import and open the Sample Project XER above in P6 by going to the File menu then Import. Follow the prompts of the wizard. Take note of the pre-created sample global activity code and the pre-created code value, as ABOVE

Also note that a code value is already assigned to the first activity.

14

Step 2 – Open the Project in the Bridge Assuming you have a functional P6XL Bridge, bring up the project list by double-clicking on the PROJECT table. If you are having trouble, consult with the installation manual on the P6XL Bridge website.

Locate the sample project and open it by typing Open under Changes (column E) on the same row as your project. In the case below, this is cell E5. Then click the Update button. Now your project is open in the Bridge.

Step 3 – Record your Tasks Locate the TASK table and record it by selecting it then clicking the Record button. This will make available all your Task IDs in a separate sheet. We will use this later.

15

Step 4 – Input Activity Codes Stay on the Interface sheet then record the ACTVCODE table just like we did above.

Go the ACTVCODE sheet and notice that the code value that we discovered in P6 under our Sample Activity Code is already there.

Start typing (or copy and paste) the desired code values as below. Notice the Insert command will appear automatically. Fill 3 columns: the short name, the long name, and the parent code ID. When done click on the Update button. Your codes are now created in P6.

16

Take note of the resulting code value IDs, as highlighted below. We will use that later.

Step 5 – Assign the Codes Go to the Interface sheet. Double-click on the TASKACTV table to open Activity Code Assignments. Notice that one activity is already assigned a Sample Code value just like we discovered in P6.

Go to the ACTVCODE sheet. Copy the activity code value IDs as highlighted in the above step into the TASKACTV table in the Interface sheet 3 times as indicated below. Notice the commands will automatically.

17

Insert appear

Go to the TASK sheet. Select the activity IDs corresponding to “Initiation 1” through “Construction 5” as indicated below. Then copy.

Go to the Interface sheet. Paste the activity IDs in the TASKACTV table as illustrated below.

18

Finally, fill-down the activity code ID and project ID columns. Then click the Update button to get the result below.

Your assignments are now complete. Additionally, the TASK table was automatically altered and a new column was added to it. To examine the assignments in the altered TASK table: hit Alt – F8 on your keyboard, then run the Reconnect DB macro, then visit the TASK tab, double-click on a table name in the first column. This will refresh the TASK table. Go to the last column on the right. You’ll see your assignments there. That column is another way to alter the code assignments.

19

If you go to P6, you can confirm that your assignments are now complete. Hit F5 to refresh and see the changes.

Wrap Up This tutorial demonstrates the power of managing P6 data using Excel directly. We do this by using the P6XL Bridge which communicates with the P6 database live without importing. In this demonstration, we used a concrete example of assigning activity codes to a sample project. Things for you to try: Delete the code assignments from the TASK table and try to reassign them again from there without using the TASKACTV table for Activity Code Assignments. What else you should know about the P6XL Bridge: 

The Bridge can access all common P6 tables including relationships, resources, assignments, and WBS. 20









The Bridge can copy and move projects between EPS nodes. It can also delete projects and other data. The Bridge facilitates using Excel formulas so you can manipulate P6 data according to your business needs. For advanced users, the Bridge includes a facility for cycling through projects to make predefined changes. Advanced users can also repackage and repurpose the P6XL Bridge functionality to create interactive reports.

21

CHAPTER FOUR HOW TO IMPORT WBS FROM EXCEL TO PRIMAVERA P6 USING THE SDK

22

In this tutorial we explain how to use the Oracle Primavera P6 SDK to import a WBS from Excel to Primavera P6. We are using the WBS.xls P6 SDK spreadsheet made available by Oracle Support. The SDK is a very handy tool, but the data must exactly respect the required format, we used a sample WBS and a step-by-step guide to prepare the data to be imported. We assume you already have the Primavera SDK installed. Tutorial Assets The following assets were used during the production of this tutorial.  WBS-Import-P6-Tutorial.xls  WBS.xls Step 1 – Copy the WBS from to Excel For simplification, every step of the tutorial has its own Excel worksheet in the spreadsheet (see WBS-Import-P6-Tutorial.xls in Tutorials Assets). I’ve numbered each worksheet appropriately. For this tutorial, we’re using a sample WBS from this site. We’ve already cleaned-up and pasted it for you into the WBS-Import-P6-Tutorial.xls on Worksheet 1. I have modified the original WBS to add a root node (SAMPLE – the first entry in the WBS list) as the project name.

23

Step 2 – Split the WBS Path into Distinct Levels Copy the column WBS Code from “Worksheet 1″ to “Worksheet 2″ in Excel. We will use the Text to Columns function on the Excel Data tab (Excel 2010), it a very easy tool to split one column by delimiters into multiple columns.

Highlight the WBS Code column, and click on Text to Columns.

When the wizard screen comes up, select Delimited, and click Next.

24

Set the delimiter to a dot “.” .

Make sure to format the columns as Text (if your code is 01, Excel will keep it 01 as text, otherwise it will change to 1.

25

Here’s the result.

Step 3 – Organize The WBS by Level.

Copy the new split columns to “Worksheet 3″ and paste each under the appropriate L1, L2, L3, L4 or L5 heading (use the yellow L columns, not the green ones). If you have more levels, just adjust the spreadsheet to add them in.

26

The Level colum n on Worksheet 3 is not needed for this tutorial. I have just added it to show that we can determine the level of each WBS by counting how many times the separator (or the delimiter) is repeated.

The green L-columns contain some text formulas that will recombine part of the WBS Path to build parent and children fields that we’ll need for the import. Step 4 – Organize the WBS by Parent & Child

We’re going to combine all of the green L-columns now on Worksheet 4. Start by copying the data under green-L1 and pasting it to the Parent column on Worksheet 4. Copy the green-L2 data and paste it to the Child column on Worksheet 4. 27

The next steps might seem unintuitive, but they are important to follow correctly. We’ll then clean things up afterwards. Copy the data as follows:  Copy the green-L2 data again and this time paste it to the bottom of the data in the Parent column on Worksheet 4  Copy the green-L3 data and paste it to the bottom of the Child column on Worksheet 4  Copy the green-L3 data again and this paste it to the bottom of the Parent column  Copy the green-L4 data and paste it to the bottom of the Child column  Copy the green-L4 data again and this paste it to the bottom of the Parent column  Copy the green-L5 data and paste it to the bottom of the Child column Essentially the column data should be combined like this: Parent col Child col L1 data L2 data L2 data L3 data L3 data L4 data L4 data L5 data

Actually that’s the most important step in this tutorial, in order for the SDK (a relational database) to understand the structure of the WBS; this one must be presented as Parent and children table.

28

Step 5 – Remove Duplicates Copy the columns Parent and Child from Worksheet 4, and paste them to Worksheet 5. Highlight both columns.

On the Excel Data tab, click Remove Duplicates to clean up any duplicate entries we’ve created.

29

Next, select ok

In the column “check the same relation”, I put a formula to check if there is the same item in parent and child. Click the column Filter and select only “No”. This will filter out any other entries we don’t need for the import.

30

Step 6 – Separating Child and Parent WBS Items With the column filter still set to “No” highlight the Parent and Child columns, copy and paste them to Worksheet 6 as follows:  Copy the Parent column and paste under Parent WBS ID  Copy the Child column and paste under WBS ID CHILD The WBS Code column is automatically generated by removing from the WBS ID CHILD code the equivalent Parent WBS ID. Now our WBS is ready to be imported to Primavera P6. Step 7 – Open Primavera P6 In Admin -> Admin Preferences, check the maximum WBS Code length that Primavera P6 can accept. The default of 20 will work for this tutorial; however, you may want to increase this value to 30 or 40 characters for future imports.

31

You’ll want to have an empty project already setup in P6 that we will import to. If you don’t have one, login to Primavera and create an empty project now, then come back to this step. By default, the first level of the WBS is the name of the project. In this case change the name of the project to SAMPLE, once you finish importing you can modify the name.

32

Step 8 – Open the P6 SDK WBS.xls As usual input the password, and click on Update Project List. Select the empty project you created. **Make sure you select the right project. Click on “Get WBS”.

As expected, only the WBS root node is imported into the spreadsheet.

Copy and paste from the Excel file the columns Parent WBS ID, WBS Code and the WBS Name Don’t overwrite the root node that is already there.

33

Click “Set WBS”.

It will take some time to process the data (the SDK is famous for very being slow).

34

Step 9 – Enjoy

Wrap Up We explained how to import a WBS dictionary to Primavera P6 using Excel and the P6 SDK. Here are some examples as to why it is very useful for planners: 1. It is very easy to import a standard WBS into your schedule (perhaps your company Cost breakdown Structure). 2. If your schedule is using activities codes, you can easily generate WBS in Excel and imported back to P6. 3. You can design a first cut of your WBS outside Primavera, using many freely available WBS utilities. Once it is approved, it can easily be imported to Primavera. We suggest you try WBStool, a mind mapping WBS tool. All WBS or mind mapping tool can export the WBS path to Excel, which means this file can be used as an integration tool to Primavera.

35

 

Things for you to try: If you want to understand the logic behind all this data processing, google “hierarchical database model”. Using CTE recursive query in any Database you can generate the WBS Parent and WBS child in one operation. But if you are just a planner, SQL might be black magic for you (as it is for me). The approach discussed in this Tutorial will do the trick, and will you save a lot of time doing what all planners hate the most – manual typing.

36

CHAPTER FIVE USING PRIMAVERA’S .XER FILE PARSER – IMPORT WBS FROM EXCEL WITHOUT THE SDK

37

In the previous chapter, we learned how to how to import WBS from Excel to Primavera P6 using the SDK. In this chapter we explain how to import a WBS dictionary in Primavera P6 without the SDK To load the WBS data into Primavera P6, instead of using the SDK we will use the XER File Parser utility provided by Oracle. Essentially, the File Parser is an excel file that can read the data contained in a .xer file, and gives the user the ability to modify some information and to build a new .xer. It is definitely one of the most powerful utilities for Primavera P6, either standalone or enterprise, and it is much safer to use than the SDK, as you don’t write directly to the Primavera database – unlike the SDK. Tutorial Files Complete this tutorial by downloading the following files:  P6xerFileParserBuilder.xls - MS Excel 2003 and prior  xerFileParserBuilder_2007 - MS Excel 2007 and later  WBS_id_Generator.xls

Before You Start 38

Primavera P6 has a well-defined database at its core, but you don’t need to be an IT graduate to understand how it works. Here’s what you DO need to know:  Understand what a Primary Key is used for  Understand what a Foreign Key is used for  Understand the type of relationships between tables in the database I recommend googling the terms above. There are a lot of courses available on database structures. The descriptions of the tables of Primavera P6 r8.2 database tables are available here. It can be very useful to understand how the P6 database is organized (WBS, Activity Codes, Resources, etc.) Also, here are some best practices on working with the XER File Parser utility:  Always work on a copy of the .xer file, and make sure to always build a new .xer file.  Never directly update a program from a modified .xer file, first import it as a separate project, and check if everything is ok, then you can update your program.  Never import any .xer file directly to a production database; it is too easy to contaminate P6 global data objects. Import to a test database first.

Step 1 – Generate a dummy xer file.

Create a blank dummy schedule in P6 – don’t add any WBS or activities. Export the blank schedule to .xer format. The purpose is to have a .xer file with minimal data. For the purposes of this tutorial, the name of the schedule is Test, and the WBS code, is Sample Oil, Gas WBS.

39

Step 2 – Open the Xer file using the Excel Parser Utility.

Open the Excel XER File Parser spreadsheet. Click on Load XER file, select TEXT.xer file then click OK.

Here’s what you should see. The table for the WBS dictionary is called PROJWBS. Click the PROJWBS link to edit WBS data.

40

Here is the result:

The most important columns are wbs_id, wbs_short_name, wbs_name and parent_wbs_id. In the next steps, we’ll show you how to generate those ids from a WBS. Step 3 – Generate the WBS_id and the Parent_WBS_id Open the WBS_id_Generator.xls Excel file. In the second row, copy and paste the values from the Excel File Parser. Please notice, we have changed the WBS Code from “TEST” to “Sample”.

Now copy the data in yellow from the Excel file done in the previous tutorial. The primary key for the table PROJWBS is wbs_id. We generate a new wbs_id for the new WBS. Please notice for the first wbs_id we add 100 (40484 — 40584) then we increase the number by 1. Then for the column Parent_wbs_id, by using a VLOOKUP formula, we can find the corresponding wbs_id for the Parent.

41

Step 3 – Build the new xer file with the new WBS. Now all what we have to do is fill the columns with the data of the WBS.  Wbs_id, wbs_short_name, wbs_name, parent_wbs_id; copy in the values from the WBS_id_Generator.xls.  Proj_id, obs_id, sum_data_flag, status_code, ev_user_pct, ev_etc_user_value, orig_cost, indep_remain_total_cost, ev_compute_type, ev_etc_compute_type ; copy and keep the same data from the first row  proj_node_flag : all rows have the value N.  seq_num : copy the same value to any new rows (which is first value +100)  Guid : this is another primary key generated by the database, for any new rows leave this column empty.  Don’t add anything to columns with empty values. 

Now click on Build XER file. Select a new file name (TEST1) then click on OK.

Voila, now you have a new .xer file, loaded with the WBS dictionary. You can now import that file to your P6 database. But remember to have a look at it on a test 42

database first – don’t import it to a Production database until you’ve checked the import works. Wrap Up The XER File Parser is a must-have utility for any planner especially if he deals with external schedules. In this tutorial we showed only one particular use, but this utility has much broader use. But who knows, perhaps one day Primavera will add the facility to copy and paste from Excel – other Planning software can do it, so why not P6?

43

WE HOPE THAT YOU ENJOYED OUR GUIDE

44

View more...

Comments

Copyright ©2017 KUPDF Inc.
SUPPORT KUPDF