Set the group state for mixed group items

Hello everybody

I have a group for a light, which consist of items of different types.

Group  gLight1
Switch LightPower (gLight1)
Number LightLevel (gLight1)
Dimmer LightColor (gLight1)

In groups of different item types the state is always NULL. Thats not nice and I want to set the state to something more sensible like “ON”. I know the doc and how it works with groups of a specific type. Is there a way for groups like this one?

Thank you a lot

Have you tried it? You’ll have to give your Group both a type and an aggregation function. Some functions work with mixed type members, some just are not sensible e.g. averaging switches.
I’d expect to be able to have a Switch type Group with mixed Switch and Dimmer members, not so sure about Number members.

Well, that works somehow. As a side effect OH tries to set/update the state itself from the group items. It does not use the switch item but any item, what means the state can be wrong. I need to overwrite the state via postUpdate().

I’ll keep an eye on this. Maybe it is a good solution.

I’ve no idea what you mean.
The state of a Group type Item is calculated from is members by design.

If you want an Item you can change the state of at will, that’s just an Item. You can’t do that with a Group.