SQL Tags between clients

First, if my undersanding of SQL tags is correct, if I change a SQL tag which is set as DB, on one client, then all clients will see that same tag change to the new value. Is this correct?

Second if I have a table on a screen and the data is populate by an SQL query, and the polling is off for that query, it will only update on one of two conditions. Condition1 - If there is some dynamic property that changes the query on that page. Condition2 - If some value is changed in the database ( in this case MS SQL) Would this also be correct?

Third using same conditions as number 2. Lets say 2 clients are looking at the same screen. Client 1 dynamically changes the query by some method. In this case if I understand things, client1 would see the new updated data and client2’s data would remain unchanged. Is this correct?

Fourth refering to number 2 above. Lets say the dynamic portion of the query comes from an SQL DB tag. Now using number 3 in conjunction with number 2, would the change in the tags value be seen as a change and would it update both clients or just the client where the data was changed from?

For the fourth item I am thinking it would not change the data on client 2. I have tried this and it does not trigger the data to auto refresh. So as a way to make it work I am thinking of doing the following. On the screen in question have a label and have it properties set to hide it. In the labeled event triggered change setting have a refresh of the tables data. This way when client one sets the dynamic property to change the data client 2 will also change to show the same data. The screen in question just show run time statistics and it based on the current running shift. So when one client changes the view to say second shift I want them all to change.

Thanks and have a great weekend.

  1. Yes, that’s correct.
  2. With polling off, a change to the query will re-run it. Changes to the underlying data will not cause an update.
  3. Correct, with polling off a change in one query would not affect the other.
  4. Correct, a DB SQLtag that changes will affect the query in all open clients.

To implement this, create a dynamic property and bind it’s value to that DB tag. Insert that dynamic property into your SQL query binding.

I had hopped that number 1 was correct.

However number 2, I dont know if it was just a fluke or what but I did try it a two or three times, it was on the same screen. I had the screen open in designer, I minimized the screen, went into SQL Studio Manager, added some data to a table which the screen used, when I maximized the desinger, the data I had added to the SQL table showed up on my screen. That was without reloading the screen or opening the data binding. SO that is why I just made the assumtion that if data changed on the bound table that it would also cause an update.

Now as for items 3 and 4. I do have the tag in the SQL query. I do have the polling off. From the one client I changed the value in the SQL tag. On the client I changed the value from the data updated. However on the other client the data did not update till I manually refreshed the screen. This is why I mentioned about placing a label on the screen and hiding it. Then on its data changed event trigger a refresh.

Here is the code I have:

select mach_num, serial, pageid, accum, shift, operator, assist1, jobid from '[]tablename' 

And like I said I have the polling off. I would have thought that when the tablename tag changed values that the query would run because it detected a change. But it did not until I manually refreshed by either going out of the screen and comming back into it or by using a button on the screen with the proper code.

Thanks for your quick responce.

[quote=“nathan”]1. Yes, that’s correct.
2. With polling off, a change to the query will re-run it. Changes to the underlying data will not cause an update.
3. Correct, with polling off a change in one query would not affect the other.
4. Correct, a DB SQLtag that changes will affect the query in all open clients.

To implement this, create a dynamic property and bind it’s value to that DB tag. Insert that dynamic property into your SQL query binding.[/quote]

I was just rereading my latest post and realized I made an error on the code. After the FROM I have

'[]tablename'

that is incorrect it should be

{[]tablename}

I am also going to try Natans idea which seems more simple than mine. I will on the scren in question create a dynamic property, bind that to my SQL Tag, then use that Dynamic property in my where clause. Will let you know. Have a great day.

[quote=“nathan”]1. Yes, that’s correct.
2. With polling off, a change to the query will re-run it. Changes to the underlying data will not cause an update.
3. Correct, with polling off a change in one query would not affect the other.
4. Correct, a DB SQLtag that changes will affect the query in all open clients.

To implement this, create a dynamic property and bind it’s value to that DB tag. Insert that dynamic property into your SQL query binding.[/quote]