Cascade Skyline - with Microsoft Logo and Project Support header - author Brian Smith

  • Brian Smith's Microsoft Project Support Blog

    To Add or Update - That is the Question. The PSI and custom fields - Updated

    • 49 Comments

    This posting was inspired by a support call concerning custom fields - but does apply to other entities in the Project dataset and others.  The question was around the QueueUpdateProject and QueueAddToProject web services calls that are part of the Project web service in the PSI.  If you use the wrong call then the error message is usually helpful telling you you can't add with the update call and vice versa.  But the thing that does catch people out are the custom fields... 

    By default a project dataset will not contain any rows in the ProjectCustomFields data table unless they have either been set (through PWA, Project Professional or the PSI) or they contain formulae, or are based on a lookup table with a default value defined.  So for a freshly created project (from Project Professional) when looking at Project Information it appears that all custom fields are there - and some may even look to have values (number fields will show 0) whereas in fact once saved there are no rows in the dataset for project custom fields (except as mentioned above - formulae based, and default lookup tables values).  So if you want to set a custom field via the PSI your code should check if there is a row already present for that custom field (identify by the MD_PROP_UID or MD_PROP_ID) and if it is there then you can change the value and use QueueUpdateProject - and if it doesn't exist then you will need to create a new blank project dataset and add a new project custom field row and set the values (including a new GUID for CUSTOM_FIELD_UID, the projects PROJ_UID and the MD_PROP_UID for the field you want to set) then use the QueueAddToProject.

    (Update - Although this logic holds true for adding/updating tasks to a Project dataset you can in fact ADD a new custom field row to an existing project dataset and use the QueueUpdateProject method - and it will work.  You do not need to use the QueueAddToProject method - although this will work too, assuming it only contains the additional custom field row!  Thanks to Martin for pointing this out - through experience.)

    Just to confuse the situation we have a bug currently when using the PSI or creating an Activity Plan/Proposal that can duplicate custom field rows.  If you have any project level custom fields that use graphical indicators but do not have formulae then you can get duplicate custom field rows created for each of them.  I'm not sure yet if the bug is they get created at all (as they do not get created in Project Professional projects) or that they appear twice. I will post an update when I have more information.  For now a quick workaround is to not use graphical indicators for this type of field.  Cleaning up existing ones may be a little more challenging and I would suggest a support call.  Although this causes problems for the PSI when updating these duplicated rows (so this affects changes for Activity Plans , Proposals and use of the Edit Project Properties in PWA) you can still make changes in Project Professional through the Project Information dialog.

    The errors you might see - (these are generic so you could see these errors for other root causes):-

    When updating a custom field for an Activity Plan or Proposal you will get an error dialog box:-

    Windows Internet Explorer
    An error has occurred when saving your project to the server. Please contact your system administrator for assistance.
    [GeneralUnhandledException]

    When updating a custom field through Project Center's Edit Project Properties option the error will display at the top of the page in red:-

    The project could not be saved due to the following reason(s):

    An unknown error has occured (occurred is mis-spelled in the error).

    When updating through the PSI this will result in a GeneralUnhandledException.

    One final point - setting or updating a project custom field for an existing Project Professional created project through the PSI or Edit Project Properties will also introduce this problem.  The extra duplicates will get added as well as the custom field you are setting.

  • Brian Smith's Microsoft Project Support Blog

    Just checking in... updated

    • 46 Comments

    One problem that our customers appear to be running into is checking in projects.  We do have a bug that appears to leave projects checked out when you wouldn't expect them to be.  But I suspect that in many cases it may be that the architectural changes to 2007 have caused some of this confusion - and the default view of the queue may well hide the true cause of the problem.

    So - check out these different scenarios to see if this covers your issues:-

    • Project Professional says my project is checked out - but the server says it isn't.  This is one we are looking at a hotfix for - but there is a simple workaround that seems to resolve in most cases.  Open the project read-only, then close again.  This seems to push through a check-in and then it can be opened read-write.
    • The check-in says "Waiting to be Processed" and even using force check-in does not get it checked in.  The force check-in option should really be called request check-in - as there is nothing forceful about it.  It sinply puts a check-in request into the queue - but if the first one is just sitting there going nowhere then guess what - this second (third, fourth...) will not go any faster.  The best approach for this type of error is to look in the queue for any outstanding jobs for the same project.  If the problem happened yesterday (or before) then it may not show in the queue until you change the job history to include earlier dates.  Many times we will hear "but the queue is empty..." which may just mean no failed jobs still sitting there from today - but the failure could have happenend last week or last month!  Once you find the problem job then what should you do?  Well, that depends on the nature of the job.  If there is a save from Project Professional that is incomplete then getting the user who has the project checked out to open Project Professional and re-connect is the best approach.  Cancelling a job of this type will lose data!  Once you have resolved the initial issue and any other queued jobs for this project are processing (or cancelled if you really must) then the check-in should finally work.
    • If your symptoms don't match these scenarios then you may need to log a support call to get this checked out (if you will excuse the pun).

    UPDATE: Thanks to Ed Hanna and Brian Kennemer for bringing it to my attention - but it appears that closing Project using the X in the top right can lead to check-in issues.  So best practice would be first to save and ensure that any communication with the server has completed (look in the status area after saving) and then using File, Close.

    Technorati Tags: Project Server 2007

  • Brian Smith's Microsoft Project Support Blog

    Update to OLAP Issue: February release of SQL Server Management Objects works with Reporting Services add-in for SharePoint

    • 0 Comments

    If you are a regular reader you may remember that the loading of the Microsoft SQL Server 2005 SP2 component "Reporting Services Add-in for Microsoft SharePoint Technologies" broke the OLAP cube builds as it removed a required component when used on an aplication server that was not the SQL Server host too.  Well if you load the February update to the SQL Management Objects (rather than the November issue) available as part of the Feature Pack release then this problem is resolved!

    Feature Pack available here

    Microsoft SQL Server 2005 Service Pack 2  available here

    Don't forget (like I did) to load the add-in for SharePoint on your web front ends as well as your app server - or you will see an error as your front end web.config will be referring to a component (RSSharePointSoapProxy) that your web front end knows nothing about.

    Technorati Tags: Project Server 2007

  • Brian Smith's Microsoft Project Support Blog

    Update to the Project 2007 SDK Now Available!

    • 0 Comments

    Online at http://www.microsoft.com/downloads/details.aspx?FamilyId=2672F6F9-7028-4B30-99A2-18CB1EED1ABE&displaylang=en you can now download the latest SDK with plenty of new content.  The online version will also be updated in the next day or so.  New topics for this April 2007 release are:-

    · XML Schema References for Project (15 topics; includes the ChangeList Schema Reference)

    · Changes for Custom Project Guides 

    · Custom Fields in OLAP Cubes (in the Local and Enterprise Custom Fields topic)

    · How to: Generate ChangeXML for Statusing Updates

    · Project Server Report Pack (9 topics)

    · Walkthrough: Creating a PSI Extension 

    · Walkthrough: Develop an Impersonation Web Application

    Other updates include enumeration descriptions, PSI method permissions, TimesheetDataSet properties, and a VBA sample for Project Deliverables.

    The online Windows SharePoint Services 3.0 and MOSS 2007 SDKs will also be updated by the end of April.

    Great work Jim and the team!

    Technorati Tags: Project Server 2007

  • Brian Smith's Microsoft Project Support Blog

    SQL Deadlocks and the Project Server 2007 Queues

    • 2 Comments

    I had a question from my blog (thanks Alex!) on SQL deadlocks and error messages like the following on a busy server.

    System.Data.SqlClient.SqlError: Transaction (Process ID 84) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.

    You will also see error id 7747 in the application event log.

    This can be an issue with systems that are quite stressed and in all cases I have seen relates to the process that selects the queue jobs for processing. It does not break anything as such and no data is lost – but processing of queue jobs is delayed (but as the system is very busy they probably wouldn’t have processed quickly anyway!).

    Deadlocks occur when two transactions interact in such a way that one requires a resource that the other has locked, and vice versa. Because neither task can continue until a resource is available and neither resource can be released until a task continues, a deadlock state exists. SQL Server selects one of the transactions as the victim and ends it – and posts the above error.  See the SQL Server Books Online for more details.

    In Project Server 2007 you can monitor activity using perfmon, and the counters include SQL retries per minute for both the Project and Timesheet queues. You can also modify the queue settings which can reduce the occurrence or behavior of the deadlocks. We don’t have any prescriptive guidance yet on suggested changes, but certainly reducing the number of threads, increasing the polling interval, or increasing the SQL retry intervals would likely reduce the number of deadlocks you see. However, these changes will also reduce the throughput of your queue – particularly when processing light weight jobs. If you see the deadlock behavior at specific time of day only – and want to change queue settings to suit workload you could even use the QueueSystem web service to change the settings (using the SetQueueConfiguration method).

    I’m not sure if anyone will really want to micro-manage their queue in this way – or what the overall throughput benefits would be – but the option is there.

    Technorati Tags: Project Server 2007

Page 86 of 93 (464 items) «8485868788»