With my current setup, the autoincrement variable set in postgresql is
visible in the Django admin as "Sample_ID", with an empty form field.
The user can't possibly know what the next value in the sequence
should be, so I'm wondering how to deal with the field, as it is Not
NULL, and any attempt to submit without a value returns an error. Is
there perhaps a way to make the field not visible in admin, but have
the field automatically filled in once the rest of the form fields are
submitted?

On May 4, 4:37 pm, "pjrhar...@gmail.com" <pjrhar...@gmail.com> wrote:
> Hi,
>
> See this ticket for details on the error you are seeing:
>
> http://south.aeracode.org/ticket/407
>
> If I understand correctly, it sounds like you're asking for something
> that isn't possible anyway.
>
> The id isn't known until the item is inserted into the database,
> because the database assigns the ids. It wouldn't be possible for
> django to guess this - someone else could add another item after you
> load your add item page, taking the id that your item was meant to
> have.
>
> Regards,
>
> Peter

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.

Reply via email to