You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by Chris Howe <cj...@yahoo.com> on 2006/08/31 22:09:18 UTC

ContactList.singleUse indicator

>From this week's development blog

"Add singleUse indicator to ContactList to allow for
lists whose members should be contacted only once.
Updated sendCommEventAsEmail to expire
ContactListParty if singleUse = 'Y'. (r 437027)"

Would this type of functionality be better suited as
ContactListAttribute.attrName = singleUse ;
ContactListAttribute.attrValue = Y  ??

Is there a forseeable use outside of the implemented
functionality of this field?

If there is not and maintaining the field in the
ContactList Entity is still preferred, then is there
any benefit in having attribute entities?

Re: ContactList.singleUse indicator

Posted by Chris Howe <cj...@yahoo.com>.
actually, it seems my question was exactly in line
with what your reference page suggests...

EntityAttribute is used to store instances of
name-value pair attributes for a given Entity
instance. An attribute can be used in place of a
column on the Entity table, especially when the
attribute does not apply to all types of Entities.
Attributes can also be used ad-hoc for any name-value
pair information that applies to a given Entity
instance. If many attributes apply to a given
EntityType it may be best to create a separate entity
to hold those attributes, and have that entity be
associated with the EntityType instance by naming it
the same as the entityTypeId and setting the hasTable
field to 'Y' on the EntityType instance. This will be
faster than repeatedly querying a collection of
attributes for a given Entity instance.




--- David E Jones <jo...@undersunconsulting.com>
wrote:

> 
> It sounds like you still have some confusion about
> what the  
> attributes are meant to be used for. They are really
> for temporary  
> needs (though I recommend against even that...), or
> more importantly  
> for name/value pairs that are not known when you are
> designing the  
> data model and writing code. I don't mean to be
> decided later, I mean  
> defined as not known until the user decides.
> 
> You might also find the doc on the helpful:
> 
>
http://incubator.apache.org/ofbiz/entity-overview.html
> 
> For this, it should DEFINITELY be a field of an
> entity, and not an  
> attribute.
> 
> -David
> 
> 
> On Aug 31, 2006, at 2:09 PM, Chris Howe wrote:
> 
> > From this week's development blog
> >
> > "Add singleUse indicator to ContactList to allow
> for
> > lists whose members should be contacted only once.
> > Updated sendCommEventAsEmail to expire
> > ContactListParty if singleUse = 'Y'. (r 437027)"
> >
> > Would this type of functionality be better suited
> as
> > ContactListAttribute.attrName = singleUse ;
> > ContactListAttribute.attrValue = Y  ??
> >
> > Is there a forseeable use outside of the
> implemented
> > functionality of this field?
> >
> > If there is not and maintaining the field in the
> > ContactList Entity is still preferred, then is
> there
> > any benefit in having attribute entities?
> 
> 


Re: ContactList.singleUse indicator

Posted by David E Jones <jo...@undersunconsulting.com>.
It sounds like you still have some confusion about what the  
attributes are meant to be used for. They are really for temporary  
needs (though I recommend against even that...), or more importantly  
for name/value pairs that are not known when you are designing the  
data model and writing code. I don't mean to be decided later, I mean  
defined as not known until the user decides.

You might also find the doc on the helpful:

http://incubator.apache.org/ofbiz/entity-overview.html

For this, it should DEFINITELY be a field of an entity, and not an  
attribute.

-David


On Aug 31, 2006, at 2:09 PM, Chris Howe wrote:

> From this week's development blog
>
> "Add singleUse indicator to ContactList to allow for
> lists whose members should be contacted only once.
> Updated sendCommEventAsEmail to expire
> ContactListParty if singleUse = 'Y'. (r 437027)"
>
> Would this type of functionality be better suited as
> ContactListAttribute.attrName = singleUse ;
> ContactListAttribute.attrValue = Y  ??
>
> Is there a forseeable use outside of the implemented
> functionality of this field?
>
> If there is not and maintaining the field in the
> ContactList Entity is still preferred, then is there
> any benefit in having attribute entities?