Model "created_by"

93 views
Skip to first unread message

Petey

unread,
Jul 13, 2011, 2:40:59 PM7/13/11
to django...@googlegroups.com
Hi!

I've made a model in news application:
http://pastebin.com/49VkFT14

I want it to save user who created a message, however I get this message:

OperationalError at /admin/news/news/add/

(1054, "Unknown column 'user_id' in 'field list'")



Nick Serra

unread,
Jul 13, 2011, 5:52:14 PM7/13/11
to Django users
That error just means you didn't add that field to the database and it
can't find it. Verify the user_id field is on that table.

On Jul 13, 2:40 pm, Petey <efri...@gmail.com> wrote:
> Hi!
>
> I've made a model in news application:http://pastebin.com/49VkFT14
>
> I want it to save user who created a message, however I get this message:
> OperationalError at /admin/news/news/add/(1054, "Unknown column 'user_id' in
> 'field list'")
Reply all
Reply to author
Forward
0 new messages