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

ThingWorx Navigate is now Windchill Navigate Learn More

Translate the entire conversation x

Configuration Table multi-part key (compound key)

CC_13244540
4-Participant

Configuration Table multi-part key (compound key)

Hello all,

I have a multi-row configuration table with two key fields defined in the datashape.

 

In a service I need to get a specific row from the configuration table using the GetConfigurationTableRow function which takes a key and a tableName as input parameters.

My configuration table key fields are fieldA and fieldB. The values that make up these key values are being retrieved from another step in my service and are being passed to the GetConfigurationTableRow.

 

I am passing the key parameter as fieldAValue+fieldBValue (so the passed key is something like "valueAvalueB". This mimics the format of the compound key visible in a datatable mashup; the key value of the configuration table is not visible anywhere that I can determine.

 

My service fails with the below error:

"Error executing service serviceName. Message :: ProjectName.Manager does not have a key of [valueAvalueB in table [myConfigurationTable] - See Script Error Log for more details."

 

The Script Log unfortunately provides no further information.

The "[" proceeding the the key in the error message is added by the system. As far as I can determine, the configuration table is using a special format for its compound keys internally that is different than they format that is visible on multi-key datatables. 

Unfortunately, I am unable to achieve the goal of my service without being able to match the configuration table key.

I would appreciate any possible assistance in identifying the configuration table key format and resolving this issues.

 

Thanks in advance!

ACCEPTED SOLUTION

Accepted Solutions
GuillaumeL
14-Alexandrite
(To:CC_13244540)

Hello,

 

Unfortuantely configuration table does not work with multi key As key, just enter "fieldBValue" and you will get an answer. Basically it considers only the latest key.

What you can do to workaround is to create a new field that will represent the key and that concatenate field A & field B. Just like datatable mechanism. This is only a workaround.

What you can do is raise a bug to the tech support and expect a fix in a later version. But for your current development, it won't be enough I suppose ...

 

Best Regards,

Guillaume

View solution in original post

1 REPLY 1
GuillaumeL
14-Alexandrite
(To:CC_13244540)

Hello,

 

Unfortuantely configuration table does not work with multi key As key, just enter "fieldBValue" and you will get an answer. Basically it considers only the latest key.

What you can do to workaround is to create a new field that will represent the key and that concatenate field A & field B. Just like datatable mechanism. This is only a workaround.

What you can do is raise a bug to the tech support and expect a fix in a later version. But for your current development, it won't be enough I suppose ...

 

Best Regards,

Guillaume

Announcements


Top Tags