Skip to main content
1-Visitor
March 2, 2026
Question

Handling Sql server table rows using Thingworx

  • March 2, 2026
  • 1 reply
  • 74 views
  1. How to display all rows in mashup. It displays only 500 rows.

Eg :- A mashup grid displays rows from SQL Server, It displays only 500 rows.

 

     2. How to work on access on buttons in mashup.

Eg :- A button should visible for only few users.

 

1 reply

16-Pearl
March 2, 2026

1. You set maxRows to some high value. default is 500

 
 

sql_service.png

2. You create a service like "CanUserSeeButton" and it checks if the current user has specific UserGroup he needs to have, returns true/false which you bind on button visibility. To get current user you can use snippet.

currentUser.png

To get his groups check https://community.ptc.com/t5/ThingWorx-Developers/How-to-Find-all-User-Groups-for-a-Given-User/m-p/1038382 

Or you only check for specific usernames - but a group would be easier to handle on the long run 😉

19-Tanzanite
March 2, 2026

Just two comments:

1) Setting maxRows to a high value means all rows are pulled from the table, which can result in  high server load and long waiting times for the user.

If the number of rows in the table is not under your control, you probably want to implement paging. Thingworx Help Center and Support knowledgebase have information about this.

2) Making the button visible/enabled only for some users does not mean they can't call the service launched by the button. They could still launch a REST service directly. Which means you have to assign the correct privileges to that service as well.