The reason why i had avoided short hands such as 'alias-all' when developing ModelUnionViewEntity are:
- Union is on strictly homogeneous sets. Doing auto mapping can cause runtime errors if view changes. A lot of people are not terribly familar with unions so alias-all may cause pain. - While very useful, unions are rarely used. Convenience would come into play only rarely. - Generally short expression is nice but i think there is a chance of query getting more expensive than desired with more columns fetched and perhaps more joins(in underlying views) if things like 'alias-all' are used in view/union entity. For things to do with db fetches(views/unions) i tend to be conservative and use explicit fields. Harmeet On Fri, Mar 26, 2010 at 12:19 AM, Bob Morley <[email protected]> wrote: > > JIRA-3575 has been created that contains union support. A couple of things > I > would consider to enhance this capability ... > > 1) The ability to have a short-hand in the xml representation similar to > "alias-all" the idea here is you could define the union and the fields you > want, but then just take "all" for each field across all of the entity > members rather than having to define each of them (when the field name > matches the name). > > 2) This becomes much more powerful if you couple it with the ability to > create view-entities that can have member-entity references to other > view-entities / union-view-entities. We have found this very powerful, > being able to create a view-entity that can collect all the data for a > specific presentment artifact like a form or a screen reducing the need for > multiple queries, etc. > > If we feel this is desirable for the community/project I can gather up the > pieces that allow #2 and include that as a separate patch. > -- > View this message in context: > http://n4.nabble.com/entity-engine-union-support-tp1607240p1691129.html > Sent from the OFBiz - Dev mailing list archive at Nabble.com. >
