Quantcast

Programming Error at admin

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Programming Error at admin

kessev
I used the sql sever to create model but when I want to open admin page it pop out this!
What's wrong is it?







--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/9130c815-f5b7-48f6-b8a6-4808d7011bae%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Programming Error at admin

Andréas Kühne
Have you run the migrations for the project?

It looks like you don't have the sessions table created?

Regards,

Andréas

2017-03-17 14:58 GMT+01:00 kessev <[hidden email]>:
I used the sql sever to create model but when I want to open admin page it pop out this!
What's wrong is it?







--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/9130c815-f5b7-48f6-b8a6-4808d7011bae%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAK4qSCdzHQk2P%3D4xqgF7nFxpYE2FDDQrXH9gXwW_eJahu0U1%3DQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Programming Error at admin

kessev
Yeah, it might be the problem, when I migrated it show these error.












Andréas Kühne於 2017年3月18日星期六 UTC+8上午2時44分36秒寫道:
Have you run the migrations for the project?

It looks like you don't have the sessions table created?

Regards,

Andréas

2017-03-17 14:58 GMT+01:00 kessev <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="Nx04BbUkBQAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">maxxacre...@...>:
I used the sql sever to create model but when I want to open admin page it pop out this!
What's wrong is it?



--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/f5565238-a5a3-4f0b-8c9e-879f22dfe17f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Programming Error at admin

Andréas Kühne
You shouldn't get any errors when running migrations. What I am guessing now is that the sessions table is missing completely or some of the columns in the table are missing. Make sure that you can run migrations properly before you try using the admin interface.

Regards,

Andréas

2017-03-18 4:02 GMT+01:00 kessev <[hidden email]>:
Yeah, it might be the problem, when I migrated it show these error.












Andréas Kühne於 2017年3月18日星期六 UTC+8上午2時44分36秒寫道:
Have you run the migrations for the project?

It looks like you don't have the sessions table created?

Regards,

Andréas

2017-03-17 14:58 GMT+01:00 kessev <[hidden email]>:
I used the sql sever to create model but when I want to open admin page it pop out this!
What's wrong is it?



--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/f5565238-a5a3-4f0b-8c9e-879f22dfe17f%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAK4qSCfiHUcUxRzn63H3O3pXq5bm9wRUP1VAYTG7GQmpSwNqDA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Programming Error at admin

Melvyn Sopacua

On Saturday 18 March 2017 08:52:03 Andréas Kühne wrote:

> You shouldn't get any errors when running migrations. What I am

> guessing now is that the sessions table is missing completely or some

> of the columns in the table are missing.

 

But you would only be in that state, if the session migrations are in django_migrations and the tables removed afterwards.

So clearing the django_migrations table from entries with app='sessions' should recreate them, but you may get inconsistent history errors.

 

It's generally not pretty to use migrations and then hack the database. If you use migrations to alter your schema, you should always use migrations or be prepared to jump down the rabbit hole.

--

Melvyn Sopacua

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/2920523.2ZJsQo3oRE%40devstation.
For more options, visit https://groups.google.com/d/optout.
Loading...