Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X
Hallo,
i have a problem to create a SW-Subtask with im createissue.
I use the following commandline:
(1) im createissue --Field="Project=/XX/YY" --Field="SWI=ZZ" --Field="Summary='my summary" --Field="Assigned User=me" --type=SW-Subtask --Field="Observer=he"
Creating SW-Subtask ...
Editing fields ...
Submitting ...
Could not save item: Cannot change the state to IMPLEMENTATION:
There's no parent of type SW-Task.
Then i used the following commandline:
(2) im createissue --Field="Project=/XX/YY" --Field="SWI=ZZ" --Field="Summary='my summary" --Field="Assigned User=me" --type=SW-Subtask --Field="Observer=he" --Field="parent=196" (196 is the parent workitem ID)
I got :
Creating SW-Subtask ...
Editing fields ...
Submitting ...
Could not save item: bitIndex < 0: -951
Could you please provide to me the correct solution to create a workitem with a predifined parent?
Thanks and regards
Miled Attia
Solved! Go to Solution.
Hi @all
I'm the administrator of the integrity system at Attia's company.
I solved his problem by explaining our Process-Model (Request->SW-Task->SW-Subtask) and give him the right Syntax:
im createissue --type=SW-Subtask --field="Project=/MKS/MKS Test" --field=SWI=Undefined --field="Assigned User=xxx" --field=Observer=xxx --field=summary=testsub --addFieldValues="Backward Relationships=166286"
where 166286 is the parent Item (SW-Task in correct state)
Best Regards,
Tobi
Hallo Miled,
Do you have a stack trace from your server's server.log file? You might need to turn up DEBUG logging, but I don't think that will be necessary for this issue.
Regards,
Kael
Miled,
Did you resolve this issue successfully, or are you still stuck?
Regards,
Kael
If you are working with documents and content nodes, you will need to use slightly different commands. For example:
rq createcontent --type=SW-Subtask --field="Assigned User=[username]" --field="Summary=My Summary" --field=SWI=ZZ --field=project=/XX/YY --parentID=[ID of node or document]
Hi Joe,
ich have tried to use this method, but i got the following error message.
**** The Type "SW-Subtask" is not a node type.
Regards
Miled
In that case, the SW-Subtask type can't be created with rq createcontent
. The rq createcontent
command only works with content (node) types.
Any propsal to create an issue with type SW-Subtask and having a parent SW-Task?
Something seems odd, here. Is SW-Subtask a document model content item? The error from the rq createcontent command suggests it is not, but the error you originally posted suggests that it is:
Could not save item: Cannot change the state to IMPLEMENTATION:
There's no parent of type SW-Task.
Could you post the output of the commands:
im viewtype SW-Task
im viewtype SW-Subtask
Seeing how these types have been configured might suggest the best next action.
Regards,
Kael
Greetings,
I created a [Requirement] using "im importcontent" CLI command without specifying the [parentID]. This is allowed and is required. At the time of the item creation, the parent has not yet been created.The system is now preventing moving the item to the parent. See info below.
Below are the commands used
im importcontent --type=Requirement --field=Name=BCH_Test
Created ID 12201
im movecontent --insertLocation=first --parentID=22001 12201
*** MKS124717: The specified item 12,201 does not have a parent.
Hi @all
I'm the administrator of the integrity system at Attia's company.
I solved his problem by explaining our Process-Model (Request->SW-Task->SW-Subtask) and give him the right Syntax:
im createissue --type=SW-Subtask --field="Project=/MKS/MKS Test" --field=SWI=Undefined --field="Assigned User=xxx" --field=Observer=xxx --field=summary=testsub --addFieldValues="Backward Relationships=166286"
where 166286 is the parent Item (SW-Task in correct state)
Best Regards,
Tobi
Thank you all for your Help and for the quick Reply!!