psi DeactivateResources

C

Chester

Hi
We have tried to use DeactivateResources method, but the resource type had
not been changed.
According to MSDN PDS PSI equivalents we should use UpdateResources.

So what is DeactivateResources method for in this case?

Regards
 
C

Chester

Hi Chris,

After further investigation, it appears that res_type value actually does
change appropriately in the Published database using DeactivateResource(...)
method, but this change does not propogate to the Reporting database.

We have even tried changing the name and setting res_type using the resource
data set. While the name change is reflected in the Reporting database, the
res_type still does not change.

Regards,
Chester
 
C

Chester

Hi,

We have tried changing the resource status from active to inactive and vice
versa using PWA, and the results are the same: the resource type is modified
in the published database, but stays the same in the reporting database.

Could you please confirm whether this is intended behaviour (and if
possible, elaborate why this is so) or if this is, indeed, a bug?

Thank you in advance,
Chester
 
C

Chester

Hi Chris,

We have tried all of the following:

1)
....
PSAdminLibrary2007.WebResource.ResourceDataSet rds =
mainResource.ReadResource(resourceID);

rds.Resources[0].RES_NAME = "test";
if (rds.Resources[0].RES_TYPE < 100)
rds.Resources[0].RES_TYPE += 100;

mainResource.CheckOutResources(new Guid[] { resourceID });
mainResource.UpdateResources(rds, false, false);
....

Results: the name updates in both the published and the reporting databases.
RES_TYPE is updated ONLY in the published database (e.g. if it was 2
originally, it will now be 102 in published db and still 2 in reporting)

2)
....
mainResource.DeactivateResources(new Guid[] { resourceID }, false);
....

Results: RES_TYPE is updated ONLY in the published database as above.
Reporting db still has the old value, even if we later change some other
resource fields like name, custom fields, etc.

3)

Change resource status to inactive through Project Web Access

Results: RES_TYPE is updated ONLY in the published database as above


In the queue, we can see that the Reporting Synch job runs successfully.
However, RES_TYPE does not appear to be synching with the Reporting database.

We have service pack 1 installled.


Do you have any idea what is causing the RES_TYPE field to not synch with
the Reporting database?

Regards,
Chester
 
C

Chris Boyd

It looks like your doing everything right.


--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


Chester said:
Hi Chris,

We have tried all of the following:

1)
...
PSAdminLibrary2007.WebResource.ResourceDataSet rds =
mainResource.ReadResource(resourceID);

rds.Resources[0].RES_NAME = "test";
if (rds.Resources[0].RES_TYPE < 100)
rds.Resources[0].RES_TYPE += 100;

mainResource.CheckOutResources(new Guid[] { resourceID });
mainResource.UpdateResources(rds, false, false);
...

Results: the name updates in both the published and the reporting databases.
RES_TYPE is updated ONLY in the published database (e.g. if it was 2
originally, it will now be 102 in published db and still 2 in reporting)

2)
...
mainResource.DeactivateResources(new Guid[] { resourceID }, false);
...

Results: RES_TYPE is updated ONLY in the published database as above.
Reporting db still has the old value, even if we later change some other
resource fields like name, custom fields, etc.

3)

Change resource status to inactive through Project Web Access

Results: RES_TYPE is updated ONLY in the published database as above


In the queue, we can see that the Reporting Synch job runs successfully.
However, RES_TYPE does not appear to be synching with the Reporting database.

We have service pack 1 installled.


Do you have any idea what is causing the RES_TYPE field to not synch with
the Reporting database?

Regards,
Chester

Chris Boyd said:
Hey,

You need to make an update to the resource (UpdateResource PSI) to kick off
a publish job which will update the RDB.

--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/
 
C

Chester

Hi Chris,

Since we are experiencing the same behaviour when making changes using
either PSI or PWA, can you clarify whether the RES_TYPE field not updating in
the Reporting database (especially when all other fields get updated, so the
synch did take place) is, in fact, a bug or intended behaviour?

Thanks in advance,
Chester

Chris Boyd said:
It looks like your doing everything right.


--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


Chester said:
Hi Chris,

We have tried all of the following:

1)
...
PSAdminLibrary2007.WebResource.ResourceDataSet rds =
mainResource.ReadResource(resourceID);

rds.Resources[0].RES_NAME = "test";
if (rds.Resources[0].RES_TYPE < 100)
rds.Resources[0].RES_TYPE += 100;

mainResource.CheckOutResources(new Guid[] { resourceID });
mainResource.UpdateResources(rds, false, false);
...

Results: the name updates in both the published and the reporting databases.
RES_TYPE is updated ONLY in the published database (e.g. if it was 2
originally, it will now be 102 in published db and still 2 in reporting)

2)
...
mainResource.DeactivateResources(new Guid[] { resourceID }, false);
...

Results: RES_TYPE is updated ONLY in the published database as above.
Reporting db still has the old value, even if we later change some other
resource fields like name, custom fields, etc.

3)

Change resource status to inactive through Project Web Access

Results: RES_TYPE is updated ONLY in the published database as above


In the queue, we can see that the Reporting Synch job runs successfully.
However, RES_TYPE does not appear to be synching with the Reporting database.

We have service pack 1 installled.


Do you have any idea what is causing the RES_TYPE field to not synch with
the Reporting database?

Regards,
Chester

Chris Boyd said:
Hey,

You need to make an update to the resource (UpdateResource PSI) to kick off
a publish job which will update the RDB.

--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


:

Hi,

We have tried changing the resource status from active to inactive and vice
versa using PWA, and the results are the same: the resource type is modified
in the published database, but stays the same in the reporting database.

Could you please confirm whether this is intended behaviour (and if
possible, elaborate why this is so) or if this is, indeed, a bug?

Thank you in advance,
Chester


After further investigation, it appears that res_type value actually does
change appropriately in the Published database using DeactivateResource(...)
method, but this change does not propogate to the Reporting database.

We have even tried changing the name and setting res_type using the resource
data set. While the name change is reflected in the Reporting database, the
res_type still does not change.

Regards,
Chester

:

DeactiveResource(...) should work. Did any exceptions get thrown? Are there
any errors in the ULS logs? Also, can you provide a code snippet?


--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


:

Hi
We have tried to use DeactivateResources method, but the resource type had
not been changed.
According to MSDN PDS PSI equivalents we should use UpdateResources.

So what is DeactivateResources method for in this case?

Regards
 
C

Chester

Has anybody faced with a similar problem?

Regards

Chris Boyd said:
It looks like your doing everything right.


--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


Chester said:
Hi Chris,

We have tried all of the following:

1)
...
PSAdminLibrary2007.WebResource.ResourceDataSet rds =
mainResource.ReadResource(resourceID);

rds.Resources[0].RES_NAME = "test";
if (rds.Resources[0].RES_TYPE < 100)
rds.Resources[0].RES_TYPE += 100;

mainResource.CheckOutResources(new Guid[] { resourceID });
mainResource.UpdateResources(rds, false, false);
...

Results: the name updates in both the published and the reporting databases.
RES_TYPE is updated ONLY in the published database (e.g. if it was 2
originally, it will now be 102 in published db and still 2 in reporting)

2)
...
mainResource.DeactivateResources(new Guid[] { resourceID }, false);
...

Results: RES_TYPE is updated ONLY in the published database as above.
Reporting db still has the old value, even if we later change some other
resource fields like name, custom fields, etc.

3)

Change resource status to inactive through Project Web Access

Results: RES_TYPE is updated ONLY in the published database as above


In the queue, we can see that the Reporting Synch job runs successfully.
However, RES_TYPE does not appear to be synching with the Reporting database.

We have service pack 1 installled.


Do you have any idea what is causing the RES_TYPE field to not synch with
the Reporting database?

Regards,
Chester

Chris Boyd said:
Hey,

You need to make an update to the resource (UpdateResource PSI) to kick off
a publish job which will update the RDB.

--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


:

Hi,

We have tried changing the resource status from active to inactive and vice
versa using PWA, and the results are the same: the resource type is modified
in the published database, but stays the same in the reporting database.

Could you please confirm whether this is intended behaviour (and if
possible, elaborate why this is so) or if this is, indeed, a bug?

Thank you in advance,
Chester


After further investigation, it appears that res_type value actually does
change appropriately in the Published database using DeactivateResource(...)
method, but this change does not propogate to the Reporting database.

We have even tried changing the name and setting res_type using the resource
data set. While the name change is reflected in the Reporting database, the
res_type still does not change.

Regards,
Chester

:

DeactiveResource(...) should work. Did any exceptions get thrown? Are there
any errors in the ULS logs? Also, can you provide a code snippet?


--
Chris Boyd
MS Project
Program Manager

Blog: http://blogs.msdn.com/project_programmability/


:

Hi
We have tried to use DeactivateResources method, but the resource type had
not been changed.
According to MSDN PDS PSI equivalents we should use UpdateResources.

So what is DeactivateResources method for in this case?

Regards
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top