cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

MKS web services createItem

ksequeira
1-Newbie

MKS web services createItem

I am new to MKS web services. I am calling the createItem passing the CreateItemType. I get the following error. Could not save item: MKS124147: The following fields which are mandatory in the state Submitted have not been filled in: Description. Please do tell me is you have a sample request for createItem.

1 ACCEPTED SOLUTION

Accepted Solutions
LLawton
14-Alexandrite
(To:ksequeira)

I would look at the definition of the type you are trying to create to understand how it's defined and how it works.

One way is to view the presentation template and look for the "Description" somewhere. Chances are, you have a field with a "Display Name" of Description, but a real name that's different, and that's what you need in your code. My suspicion is that the error message shows the display name.

View solution in original post

6 REPLIES 6

This error will occur also on command line or in java api, all the same, and all with the same solution which is to add the field that is called out in the error message.

If you are editing your soap envelope directly then you will want to add one of these:

            <sch:ItemField Name="Description">

               <sch:longtext null="?">quick brown dog jumping over lazy fox or whatever</sch:shorttext>

            </sch:ItemField>

You could also relax the workflow to not require that field.  To do so is probably not practical in real life, but can be useful for a quick test.

(Also be mindful of the need to make the contents XML-safe.  If your description field contents include XML then it has to be escaped within your soap envelope.)

David,

  Thanks a lot for your response.  I am using a java client generated from the WSDL. I did try your suggestion.

I get the following error

Could not save item: MKS124066: Field "Description" does not exist.

It fails both ways. If I do not put in a description, I get

MKS124147: The following fields which are mandatory in the state Submitted have not been filled in: Description

As of now, I do not have the option to relax the workflow.

Thanks

Karl

Well now that is a puzzler, how Description field can be reported as required and yet not exist.  My guesses are or stale wsdl or crossed endpoints or maybe  variation in dbname vs display name of the field?

LLawton
14-Alexandrite
(To:ksequeira)

I would look at the definition of the type you are trying to create to understand how it's defined and how it works.

One way is to view the presentation template and look for the "Description" somewhere. Chances are, you have a field with a "Display Name" of Description, but a real name that's different, and that's what you need in your code. My suspicion is that the error message shows the display name.

I found the issue. The field name was All - Description. I had initially copied it from an email and was treated as a special char. I typed it in as a minus and that fixed it . Thanks a lot David and Laurent for your time.

Announcements

Windchill RVS Users


Please take our

Windchill RV&S Authoring with Formula Editor Survey