unable to open /usr/lib/python2.4/config/Makefile (No such file or directory)

2005-12-09 Thread peter ma
OS is debian SID error: invalid Python installation: unable to open /usr/lib/python2.4/config/Makefile (No such file or directory)

Re: indexes on tables

2005-12-09 Thread Adrian Holovaty
On 12/9/05, braver <[EMAIL PROTECTED]> wrote: > Basically, if I stuff data into the database as defined by > django-admin.py sql app, via an external loader, and then open it in > django, will I see proper objects -- or there's more to objects stored > in django's own tables, and I have to load th

Re: indexes on tables

2005-12-09 Thread braver
Basically, if I stuff data into the database as defined by django-admin.py sql app, via an external loader, and then open it in django, will I see proper objects -- or there's more to objects stored in django's own tables, and I have to load them via django calls?

Re: choices in BooleanField: bug or feature?

2005-12-09 Thread Emanuele
Hi rob, thanks for your info. I tried NullBoleanField as you said one month ago but without any success (see my post of Oct 28th). Now I'm trying again and IT WORKS :) . This is a working example, related to my problem: choice = meta.NullBooleanField("Null Boolean", choices=((True,"It's true"),(Fa

Re: choices in BooleanField: bug or feature?

2005-12-09 Thread oggie rob
Hi Emanuele, To force a user to make a choice wrt boolean fields, you have two options: a BooleanField or (as you seem to be looking for) a NullBooleanField, which actually represents three states (including 'unselected'). This will mirror what you are trying to achieve with the CharField solution

Re: Paginator - a problem

2005-12-09 Thread PythonistL
Solved. Instead of paginator=ObjectPaginator('tradeleads',{'id__gt':1},2) i had to use paginator=ObjectPaginator(tradeleads,{'id__gt':1},2)

Re: Paginator - a problem

2005-12-09 Thread Adrian Holovaty
On 12/9/05, PythonistL <[EMAIL PROTECTED]> wrote: > paginator=ObjectPaginator('tradeleads',{'id__gt':1},2) The first argument to ObjectPaginator should be tradeleads (without quotes), not 'tradeleads' (a string). Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Paginator - a problem

2005-12-09 Thread PythonistL
Hi, I would like to use Paginator in my scripts. So I tried this, very simple view ## def SearchP(request): paginator=ObjectPaginator('tradeleads',{'id__gt':1},2) page=request.GET.get('page',0) Results=paginator.get_page(page) return render_to_response('board/Pomo', {'

Re: Migrating existing data into Django models

2005-12-09 Thread Grigory Fateyev
Hello tonemcd! On Thu, 08 Dec 2005 07:07:41 -0800 you wrote: > > What does your auth model look like? > class User(auth.User): user_id = meta.CharField(maxlength=12, primary_key=True) user_active = meta.BooleanField(default=True) username = meta.CharField(maxlength=25) user_pass

Re: indexes on tables

2005-12-09 Thread Adrian Holovaty
On 12/9/05, braver <[EMAIL PROTECTED]> wrote: > unique_together = (("key","date",...),) > > Is it the way? It creates proper SQL. What about indexes on several > columns? Yes, that's the way to do multiple unique fields. There's no way to do indexes across several columns -- you can do

Re: choices in BooleanField: bug or feature?

2005-12-09 Thread Emanuele
Thanks for the answer Adrian. But let me say this: - BooleanFields _are_ currently allowed to have "choices" parameter, as I can see from my admin interface and docs (svn ~ rev1580). And they behave differently from other Fields. - Boolean has obviously only two choices, but if I want to force th

Re: Auto-reload is not working

2005-12-09 Thread PythonistL
On my XP happens that sometims too.I noticed that happens if I have a lot of other programs running Regards, L

Re: ID of the record

2005-12-09 Thread PythonistL
Thank you for the reply L,

Re: indexes on tables

2005-12-09 Thread braver
OK. In addition, I need UNIQUE with several fields in a list. I've found the following way to do it: class Log(meta.Model): key = ... date = ... class META: unique_together = (("key","date",...),) Is it the way? It creates proper SQL. What about indexes on several columns