Group Items w/ Constant Values

I have multiple Stored Procedure Transaction Groups pointing to the same SPROC. Depending on the group, I pass the SPROC a number of values from devices as well as one or two fixed values (not originating from a device).

How can I define a Group Item with a constant value? I’m trying to use Expression Items but I don’t believe I’m defining them correctly … after defining a value within General Properties > Value and closing and opening Designer, the values aren’t persisting. Since I use the same SPROC in multiple places, I can’t define default values for my input parameters …

Can someone help me with this? Do I need to define this within an expression (maybe using a SQL Query and the SELECT statement … ex. SELECT 1) or is there a simpler way? I feel like there’s a simple method to accomplishing this that I’m overlooking …

Thanks in advance …

Let me clarify a bit … I know I can select SQL Query and enter SELECT 9 to have a constant value of 9 … I can also select Expression and enter 9

Is there a way to setting a constant value without using an expression?

Yes, you should be able to just create an expression item and set the value, leaving the “expression mode” as none.

Are you using the latest 7.0.3 version? I know we had a problem with the values of static tags/items, but I thought it was fixed before that version. In your case, you’re setting the value of the item and saving the group, but when it executes it shows 0?

Regards,

Ah, ok … I thought that was the case but I was experiencing mixed results in my test environment … I have been working with 7.0.3.4519 …

Yesterday, If I created an item, set the value and enabled the group, the value showed up as expected. If I disabled the group, closed Designer, opened Designer and enabled the group, the value returned to 0.

Today, I’m not experiencing the above … I’m able to enable/disable the group and close/open Designer and still maintain the expected value. I’ve even restarted the machine altogether and the value is still maintained.

Therefore, it was most likely operator error :blush:

I am finding that if I set a value and perform an export of the group (as XML), the value isn’t maintained when the group is imported … I’ve been doing that extensively in my test environment so I believe that may have been the source of my confusion …

Ah, ok. We’ll look into the export/import.

Regards,