You can also add unique constraints and composite constraints to the JPA model for your "Warehouse" class - see: http://stackoverflow.com/questions/3126769/uniqueconstraint-annotation-in-java (just one of many resources that can tell you how to do this.)


On Sun, May 4, 2014 at 9:57 PM, George Gastaldi <ggastald@redhat.com> wrote:
Hi,

AFAIK this is a specific business requirement and you need to change in the EJB after the code is generated for you.

Best Regards,

George

> Em 04/05/2014, às 22:24, forge-users@lists.jboss.org escreveu:
>
> Hi.
> Using JBoss.Forge, how to prevent duplicate data ? I created an entity named "warehouse" and added some records with the same description.
> Did Forge any control about ?
> Thanks
>
> Posted by forums
> Original post: https://community.jboss.org/message/872295#872295
> _______________________________________________
> forge-users mailing list
> forge-users@lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/forge-users

_______________________________________________
forge-users mailing list
forge-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/forge-users



--
Lincoln Baxter, III
http://ocpsoft.org
"Simpler is better."