I fixed this by doing:

ALTER TABLE app_user AUTO_INCREMENT = 100;


George.Francis wrote:
> 
> yes, id value is null in the User instance being persisted
> 
> 
> mraible wrote:
>> 
>> You might check that the id is null and not 0 before the save occurs.
>> 
>> Matt
>> 
>> On Wed, Jun 4, 2008 at 3:59 PM, George.Francis <[EMAIL PROTECTED]>
>> wrote:
>>>
>>> And yes, APP_USER.ID has AUTO_INCREMENT set to true...
>>>
>>>
>>> George.Francis wrote:
>>>>
>>>> Hello,
>>>> I inherited a JSF Appfuse application backed by MySQL.  When an
>>>> Administrator tries to create a new user, they get the following
>>>> stacktrace.  It seems to imply that the DB can't auto generate a new
>>>> primary key value.  I can't immediately tell how the application got
>>>> into
>>>> this state, since I know the 'out-of-the-box' app does allow the
>>>> creation
>>>> of users.  Can someone suggest a route of investigation?
>>>>
>>>> javax.faces.el.EvaluationException:
>>>> org.springframework.orm.hibernate3.HibernateSystemException: The
>>>> database
>>>> returned no natively generated identity value; nested exception is
>>>> org.hibernate.HibernateException: The database returned no natively
>>>> generated identity value
>>>>       at
>>>> javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:91)
>>>>       at
>>>> org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:54)
>>>>       at javax.faces.component.UICommand.broadcast(UICommand.java:383)
>>>>       at
>>>> org.ajax4jsf.framework.ajax.AjaxViewRoot.processEvents(AjaxViewRoot.java:274)
>>>>       at
>>>> org.ajax4jsf.framework.ajax.AjaxViewRoot.broadcastEvents(AjaxViewRoot.java:250)
>>>>
>>>>
>>> :-):-):-)
>>> --
>>> View this message in context:
>>> http://www.nabble.com/MySql-javax.faces.el.EvaluationException-%3A-no-natively-generated-identity-value-tp17657529s2369p17657669.html
>>> Sent from the AppFuse - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>>> For additional commands, e-mail: [EMAIL PROTECTED]
>>>
>>>
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>> 
>> 
>> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/MySql-javax.faces.el.EvaluationException-%3A-no-natively-generated-identity-value-tp17657529s2369p17672902.html
Sent from the AppFuse - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to