Re: Why doesn't syncdb ever modify or drop tables anymore?

2008-12-25 Thread Ramiro Morales

On Thu, Dec 25, 2008 at 8:21 PM, Fluoborate  wrote:
>
> It never modified tables? But in the tutorial, you "accidentally" omit
> the __unicode__ method and then you add it in later, and that works.
> Was the __unicode__ method simply an attribute of the Python and not
> the database, and that's why it works?
>

Exactly, the __unicode__ method is that, a Python method and not
a model field that represent a DB table column.

> Also, shouldn't sqlclear appname drop the tables, allowing me an
> opportunity to reestablish the tables? Sqlclear didn't clear the
> tables, even though it printed appropriate DROP TABLE statements, it
> just didn't issue the statements. Thanks.

That's exactly the intended behavior (and always has been. Please
read the fine documentation for more details:

http://docs.djangoproject.com/en/dev/ref/django-admin/#sqlclear-appname-appname

-- 
 Ramiro Morales

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: Why doesn't syncdb ever modify or drop tables anymore?

2008-12-25 Thread Fluoborate

It never modified tables? But in the tutorial, you "accidentally" omit
the __unicode__ method and then you add it in later, and that works.
Was the __unicode__ method simply an attribute of the Python and not
the database, and that's why it works?

Also, shouldn't sqlclear appname drop the tables, allowing me an
opportunity to reestablish the tables? Sqlclear didn't clear the
tables, even though it printed appropriate DROP TABLE statements, it
just didn't issue the statements. Thanks.

On Dec 25, 1:58 pm, "Chris Czub"  wrote:
> syncdb has never been able to modify existing models. In order to get
> some functionality like that, look into 
> django-evolution:http://code.google.com/p/django-evolution/
>
> -Chris
>
> On Thu, Dec 25, 2008 at 1:11 AM, Fluoborate  wrote:
>
> > Running the command:
> > python manage.py syncdb
> > Used to add tables and modify tables if necessary. I don't remember if
> > it ever dropped tables. It was great, I would modify models.py and
> > syncdb and it would just work. Then something changed, and I don't
> > know why.
>
> > Now, syncdb never modifies or drops tables. It can still add tables.
> > This is very annoying. What's worse, this command:
> > python manage.py sqlclear appname
> > Doesn't do anything at all.
>
> > What is going wrong? Has anyone else seen this?
>
> > Thank you.
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: Why doesn't syncdb ever modify or drop tables anymore?

2008-12-25 Thread Chris Czub

syncdb has never been able to modify existing models. In order to get
some functionality like that, look into django-evolution:
http://code.google.com/p/django-evolution/

-Chris

On Thu, Dec 25, 2008 at 1:11 AM, Fluoborate  wrote:
>
> Running the command:
> python manage.py syncdb
> Used to add tables and modify tables if necessary. I don't remember if
> it ever dropped tables. It was great, I would modify models.py and
> syncdb and it would just work. Then something changed, and I don't
> know why.
>
> Now, syncdb never modifies or drops tables. It can still add tables.
> This is very annoying. What's worse, this command:
> python manage.py sqlclear appname
> Doesn't do anything at all.
>
> What is going wrong? Has anyone else seen this?
>
> Thank you.
>
> >
>

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Re: Why doesn't syncdb ever modify or drop tables anymore?

2008-12-25 Thread Kenneth Gonsalves

On Thursday 25 Dec 2008 11:41:38 am Fluoborate wrote:
> Used to add tables and modify tables if necessary. I don't remember if
> it ever dropped tables. It was great, I would modify models.py and
> syncdb and it would just work

afaik it never modified tables and never will

-- 
regards
KG
http://lawgon.livejournal.com

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



Why doesn't syncdb ever modify or drop tables anymore?

2008-12-25 Thread Fluoborate

Running the command:
python manage.py syncdb
Used to add tables and modify tables if necessary. I don't remember if
it ever dropped tables. It was great, I would modify models.py and
syncdb and it would just work. Then something changed, and I don't
know why.

Now, syncdb never modifies or drops tables. It can still add tables.
This is very annoying. What's worse, this command:
python manage.py sqlclear appname
Doesn't do anything at all.

What is going wrong? Has anyone else seen this?

Thank you.

--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---