Website Upgrade Incoming - we're working on a new look (and speed!) standby while we finalise the project

Tips on using this forum..

(1) Explain your problem, don't simply post "This isn't working". What were you doing when you faced the problem? What have you tried to resolve - did you look for a solution using "Search" ? Has it happened just once or several times?

(2) It's also good to get feedback when a solution is found, return to the original post to explain how it was resolved so that more people can also use the results.

Import to P3e/c from MS Access

3 replies [Last post]
Steve Eiden
User offline. Last seen 7 years 43 weeks ago. Offline
Joined: 16 Sep 2004
Posts: 19
Groups: None
Greetings. If I wanted to import a tag for a set of tasks in P3e/c based upon an analysis done in MS Access (or Excel) what’s going to be the best platform? SQL’s, ADO, VBA? And since what I see in P3e/c as the activity ID is not what the database regards as the primary key for that task, what fields would I import. And last, can API be used and what is it?

Replies

DANG CORP
User offline. Last seen 9 years 11 weeks ago. Offline
Joined: 3 Oct 2004
Posts: 71
Groups: None

Hi mate,

two options

1) if all of your 60 activities ID (in p3ec) have the same name and you wanted to tag them with the same value, then YES, you can do it all in one go.

eg:
UPDATE TASK SET task_name = ’VU2’
WHERE task_short_name = ’VU’

* notice, i didn’t put in the WHERE proj_id - so the queries will update all activity with that short_name.

2) if your TAG values are different, and you have different Acitivty name for each project too, then use
a LOOP to go thru and update each of the 60 Tasks.


option (2) is ideal, as you have notice that most project have similar activity ID, and that can update other activity which you didnt wanted it to.

u welcome,

later mate.
Steve Eiden
User offline. Last seen 7 years 43 weeks ago. Offline
Joined: 16 Sep 2004
Posts: 19
Groups: None
Vu

Thanks for the help. If using the steps you outlined, I’ve got the Task_ID, a revised Task_name, and a "tag" code for say..60 tasks in Access and want to import them in one step can I do this or must I do it with individual update queries.

Thanks again for your help..

DANG CORP
User offline. Last seen 9 years 11 weeks ago. Offline
Joined: 3 Oct 2004
Posts: 71
Groups: None
Greetings. If I wanted to import a tag for a set of tasks in P3e/c based upon an analysis done in MS Access (or Excel) what’s going to be the best platform? SQL’s, ADO, VBA? And since what I see in P3e/c as the activity ID is not what the database regards as the primary key for that task, what fields would I import. And last, can API be used and what is it?

Hi mate,

Note:
In P3e/c in Database Column
===========================================
Can’t View - proj_id (internal ID)
Project ID - proj_short_name
Activity ID - task_code
Can’t View - task_id (internal ID)
===========================================
task - Activity Table
project - Project Table
===========================================

Primavera P3e/c has an "Internal ID" which they uses to identify each activities on the lower level (that is the database Level - which users don’t see).

The reason for this is sometimes Users have the same activity ID names on different projects.

So the best way to get that "Activity Internal Id" so u can update it is.

1) get the "Project internal ID" from the project table
eg: SELECT proj_id FROM Project WHERE proj_short_name = ’Vu’

2) get the "Acitivity Internal ID" from the task table with the "project internal id" and the "activity ID",

eg: SELECT task_id FROM task WHERE task_code = ’Activity’ AND proj_id = X

where ’X’ is the value that hold the Project ID from step (1)

3) by doing this, you know for sure that you are updating the correct activity, in the project that you wanted.

=============================

And last, can API be used and what is it?

---------
I will split it into sections, these API.


(1) API (Application Program Interface) - its sounds kool, but what is it? - its an Interface for you to write or customise applications that view and updates Primavera data, the downside is that, the API cost you license money on top of your normal License, and you need skills in Java to develop those applications. (API only works with JAVA. nothing else!)

(2) SDK - SDK comes free with P3e/c, and you can use your Visual Basic to write your applications.

(3) why use SDK? - you MUST use the SDK to update the Primavera Database, because the SDK holds business rules that is necessary to make the P3e/c work properly, you cant update it directly. or else it will corrupt the database.

--------
later mate. good luck.