<div dir="ltr">You can also add unique constraints and composite constraints to the JPA model for your &quot;Warehouse&quot; class - see: <a href="http://stackoverflow.com/questions/3126769/uniqueconstraint-annotation-in-java">http://stackoverflow.com/questions/3126769/uniqueconstraint-annotation-in-java</a> (just one of many resources that can tell you how to do this.)</div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, May 4, 2014 at 9:57 PM, George Gastaldi <span dir="ltr">&lt;<a href="mailto:ggastald@redhat.com" target="_blank">ggastald@redhat.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
AFAIK this is a specific business requirement and you need to change in the EJB after the code is generated for you.<br>
<br>
Best Regards,<br>
<br>
George<br>
<br>
&gt; Em 04/05/2014, às 22:24, <a href="mailto:forge-users@lists.jboss.org">forge-users@lists.jboss.org</a> escreveu:<br>
<div class="HOEnZb"><div class="h5">&gt;<br>
&gt; Hi.<br>
&gt; Using JBoss.Forge, how to prevent duplicate data ? I created an entity named &quot;warehouse&quot; and added some records with the same description.<br>
&gt; Did Forge any control about ?<br>
&gt; Thanks<br>
&gt;<br>
&gt; Posted by forums<br>
&gt; Original post: <a href="https://community.jboss.org/message/872295#872295" target="_blank">https://community.jboss.org/message/872295#872295</a><br>
&gt; _______________________________________________<br>
&gt; forge-users mailing list<br>
&gt; <a href="mailto:forge-users@lists.jboss.org">forge-users@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/forge-users" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-users</a><br>
<br>
_______________________________________________<br>
forge-users mailing list<br>
<a href="mailto:forge-users@lists.jboss.org">forge-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/forge-users" target="_blank">https://lists.jboss.org/mailman/listinfo/forge-users</a></div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>Lincoln Baxter, III<br>
<a href="http://ocpsoft.org" target="_blank">http://ocpsoft.org</a><br>&quot;Simpler is better.&quot;
</div>