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

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

When I Bind the Sql query data on to the led display it's not showing any value?

Bhargav1
6-Contributor

When I Bind the Sql query data on to the led display it's not showing any value?

I have written a sql query where when i execute I am getting the result in output window but when i bind that value to led it's showing nothing.

 

I have followed  

https://community.ptc.com/t5/ThingWorx-Developers/How-to-show-the-SQL-query-result-in-LED-display-or-Value-display/td-p/505569

 

But there is no use can anyone please help me in this ?

 

 

Regards

Bhargav 

 

5 REPLIES 5

@Bhargav1  Are you receiving any related error in Application logs?

 

Thanks,

Vibhuti

Bhargav1
6-Contributor
(To:vangne)

@vangne, there is no error in the application log related to it .

Hi,

 

I suppose you have a mashup with the led widget, please click on View Mashup.

Click on Show/Hide Debug Info and enable Bindings. Can you identify the binding between the led and result of query?

 

Regards,

Raluca Edu

Bhargav1
6-Contributor
(To:raluca_edu)

Hi ,

This is the log it's showing

 

16:23:04 INFO - ThingWorx Mashup Runtime vundefined
16:23:07 WARN - trying to set a parameter that is not defined: "forceClose". Ignoring it
16:23:11 WARN - trying to set a parameter that is not defined: "features". Ignoring it
16:23:13 ERROR - Runtime exception handling data update for binding {"Id":"1d295e6e-57d8-41e5-9f75-ee119b59d702","SourceArea":"Data","SourceSection":"Things_Database","SourceId":"Container_Dashboard_values","SourceDetails":"AllData","TargetArea":"UI","TargetSection":"","TargetId":"leddisplay-9","PropertyMaps":[{"SourceProperty":"result","SourcePropertyType":"Field","SourcePropertyBaseType":"NUMBER","TargetProperty":"Data","TargetPropertyType":"property","TargetPropertyBaseType":"NUMBER"}],"isBoundToSelectedRows":false} Exception: Cannot read property '0' of undefined
16:23:13 ERROR - Error in invoking service Things_Database, Container_Dashboard_values, Things, Database, Services, Container_Dashboard_values. Error from the server: "Unable to Invoke Service Container_Dashboard_values on Database : Execute Update failed: org.postgresql.util.PSQLException: A result was returned when none was expected."
16:23:13 ERROR - Runtime exception handling data update for binding {"Id":"050e949e-f259-4f9c-a307-4f7610be2bf4","SourceArea":"Data","SourceSection":"Things_Database","SourceId":"openstreet_map_test","SourceDetails":"AllData","TargetArea":"UI","TargetSection":"","TargetId":"dhxgrid-13","PropertyMaps":[{"SourceProperty":"","SourcePropertyType":"InfoTable","SourcePropertyBaseType":"INFOTABLE","TargetProperty":"Data","TargetPropertyType":"property","TargetPropertyBaseType":"INFOTABLE"}],"isBoundToSelectedRows":false} Exception: Cannot read property 'length' of undefined
16:23:13 ERROR - Error in invoking service Things_Database, openstreet_map_test, Things, Database, Services, openstreet_map_test. Error from the server: "Error executing service. Message ::Unable To Convert From org.mozilla.javascript.UniqueTag to INFOTABLE - See Script Error Log for more details."
16:23:13 ERROR - Error in invoking service Things_Database, upload_data, Things, Database, Services, upload_data. Error from the server: "Unable to Invoke Service upload_data on Database : Execute Query failed: org.postgresql.util.PSQLException: ERROR: syntax error at or near "$1" Position: 8"

@raluca_edu wrote:

Hi,

 

I suppose you have a mashup with the led widget, please click on View Mashup.

Click on Show/Hide Debug Info and enable Bindings. Can you identify the binding between the led and result of query?

 

Regards,

Raluca Edu



@raluca_edu wrote:

Hi,

 

I suppose you have a mashup with the led widget, please click on View Mashup.

Click on Show/Hide Debug Info and enable Bindings. Can you identify the binding between the led and result of query?

 

Regards,

Raluca Edu




Hi,

 

I can see there is error with binding the led widget, I cannot figure it out only from the above errors.

Please check the binding for led and also access rights to run a specific service (you are using admin or non-admin user?)

Please give a little bit more of details on how you get the info from database, what service/code you are using, etc.

 

Thank you,

Raluca Edu

Top Tags