I don't think you should use Lane
for the generic element, but rather use a BPMN PartnerRole
or PartnerEntity
element.
Using lanes would be a BPMN syntax violation.
Apart from that, if you want to query the model to get all lanes and their generic element you can use a query like this
select o.ea_guid AS CLASSGUID, o.Object_ID as CLASSTYPE, o.Name, o.Stereotype, gen.Name as GenericElement
from ((t_object o
inner join t_objectproperties tv on (tv.Object_ID = o.Object_ID
and tv.Property = 'PartitionElementRef'))
left join t_object gen on gen.ea_guid = tv.Value)
where o.Stereotype = 'Lane'
The Lane
is linked to the generic element with the tagged value PartitionElementRef
which contains the guid of the generic element.
If you want to get the Activities in your lane you join again with t_object
using the ParentID
select act.ea_guid AS CLASSGUID, act.Object_ID as CLASSTYPE, act.Name, act.Stereotype,
o.Name as Lane, gen.Name as GenericElement
from (((t_object o
inner join t_objectproperties tv on (tv.Object_ID = o.Object_ID
and tv.Property = 'PartitionElementRef'))
left join t_object gen on gen.ea_guid = tv.Value)
inner join t_object act on (act.ParentID = o.Object_ID
and act.Stereotype = 'Activity'))
where o.Stereotype = 'Lane'
Bonus tip: if you leave the name of the lane empty, it will show the name of the generic element on the diagram.