Skip to main content
1-Visitor
February 11, 2019
Question

Issue with escape quote

  • February 11, 2019
  • 5 replies
  • 2266 views

Goodmorning,

we are started to work with Thingworx and Azure using MQTT. 

We have some remote properties that will contain data from the devices, and some others in addition to the twinDesired that the device will need to read.

These two properties should be string (in screenshot pkc_1 and pkc_2) 

The problem is that when we try to retrieve data from device, property appers with escaped 

 

{\"pkc_1\":\"0,19-02-11 16:56:00\"}

 

Is there something on twx side we can do to avoid to escape it or this will be send always in this way and we can only parse on device side (low level)

 

Thank you

5 replies

Support
February 20, 2019

Hi @lguagneli84.

 

When you retrieve the data, which field in your screenshot should contain the string?  We need to know where the data you're showing is being sent.

 

Regards.

 

--Sharon

1-Visitor
February 21, 2019

The field pkc_1 will contains some string that remote device should read. Thing and device (a remote device) are connected through mqtt. Remote device is able to read field pkc_1 as topic.

Support
February 25, 2019

Hi @lguagneli84.

 

We're still not clear.  What property are you seeing this on: 

 

{\"pkc_1\":\"0,19-02-11 16:56:00\"}

 

We suspect there could be a type conversion that is causing this, so we need to understand where you're seeing it.

 

Regards.

 

--Sharon

5-Regular Member
February 25, 2019

Hi lguagneli84,

 

I understand you are getting telemetary data from azure.

 

You can pass this to Thingworx property with base type as json object and try.

 

Thank you,

Support
March 14, 2019

Hi @lguagneli84.

 

If the solution provided by @gnandyala answered your question, please mark it as the Accepted Solution for the benefit of others with the same question.  If you have found a different solution, please feel free to post it here and mark that as the Accepted Solution.

 

Regards.

 

--Sharon