J
john.kaye
I am trying to use Data Shape to join Assignments to
AssignmentsTimePhasedByDay. My connection String is:
sMPP = "D:\Master.mpp"
sConn = "Provider=MSDATASHAPE;Extended Properties='Project Name=" +
sMPP + _
"';Persist Security Info=False;Data Source='';User ID='';Initial
Catalog=" + sMPP + _
";Data Provider=Microsoft.Project.OLEDB.11.0"
The connection works with simple select statements like:
sSQL = "SELECT AssignmentRemainingWork , AssignmentResourceName,
AssignmentStart FROM Assignments WHERE AssignmentRemainingWork>0"
sSQL = "SELECT AssignmentUniqueID , AssignmentResourceName FROM
Assignments WHERE AssignmentRemainingWork>0"
sSQL= "SELECT AssignmentUniqueID, AssignmentTimeActualWork ,
AssignmentTimeWork, AssignmentTimeStart FROM AssignmentTimephasedByDay
" & _
" WHERE AssignmentTimeWork > AssignmentTimeActualWork"
As soon as I use SHAPE, I get an error message: data provider failed
while executing a provider command e.g.
sSql = "SHAPE {SELECT TaskUniqueId FROM Tasks} APPEND ({SELECT
TaskUniqueID, ResourceUniqueID FROM Assignments} RELATE 'TaskUniqueId'
TO 'TaskUniqueId')"
The Shape commend I want to execute is:
sSQL = "SHAPE {SELECT AssignmentUniqueID , AssignmentResourceName FROM
Assignments WHERE AssignmentRemainingWork>0}" & _
" APPEND ({ SELECT AssignmentUniqueID, AssignmentTimeActualWork ,
AssignmentTimeWork, AssignmentTimeStart FROM AssignmentTimephasedByDay
" & _
" WHERE AssignmentTimeWork > AssignmentTimeActualWork } AS Details" & _
" RELATE 'AssignmentUniqueID' TO 'AssignmentUniqueID')"
Can anyone help me out here?
Thank in advance.
Best Wishes, John.
AssignmentsTimePhasedByDay. My connection String is:
sMPP = "D:\Master.mpp"
sConn = "Provider=MSDATASHAPE;Extended Properties='Project Name=" +
sMPP + _
"';Persist Security Info=False;Data Source='';User ID='';Initial
Catalog=" + sMPP + _
";Data Provider=Microsoft.Project.OLEDB.11.0"
The connection works with simple select statements like:
sSQL = "SELECT AssignmentRemainingWork , AssignmentResourceName,
AssignmentStart FROM Assignments WHERE AssignmentRemainingWork>0"
sSQL = "SELECT AssignmentUniqueID , AssignmentResourceName FROM
Assignments WHERE AssignmentRemainingWork>0"
sSQL= "SELECT AssignmentUniqueID, AssignmentTimeActualWork ,
AssignmentTimeWork, AssignmentTimeStart FROM AssignmentTimephasedByDay
" & _
" WHERE AssignmentTimeWork > AssignmentTimeActualWork"
As soon as I use SHAPE, I get an error message: data provider failed
while executing a provider command e.g.
sSql = "SHAPE {SELECT TaskUniqueId FROM Tasks} APPEND ({SELECT
TaskUniqueID, ResourceUniqueID FROM Assignments} RELATE 'TaskUniqueId'
TO 'TaskUniqueId')"
The Shape commend I want to execute is:
sSQL = "SHAPE {SELECT AssignmentUniqueID , AssignmentResourceName FROM
Assignments WHERE AssignmentRemainingWork>0}" & _
" APPEND ({ SELECT AssignmentUniqueID, AssignmentTimeActualWork ,
AssignmentTimeWork, AssignmentTimeStart FROM AssignmentTimephasedByDay
" & _
" WHERE AssignmentTimeWork > AssignmentTimeActualWork } AS Details" & _
" RELATE 'AssignmentUniqueID' TO 'AssignmentUniqueID')"
Can anyone help me out here?
Thank in advance.
Best Wishes, John.