On 6/25/06, Russell Keith-Magee <[EMAIL PROTECTED]> wrote:
> Interesting - I get the same behaviour. I've opened ticket #2231 for
> this problem - I'll look into it.
Ok - I take that back - I don't get the same behaviour.
True - the SQL doesn't get a default clause. This is by design.
Default
Interesting - I get the same behaviour. I've opened ticket #2231 for
this problem - I'll look into it.
> I'm using Django-0.95-py2.3.egg.
Where did you get a 0.95 egg? v0.95 hasn't been released - it will be
the version number of the next official release, but that hasn't
happened yet.
Yours,
Hi Russel.
Thanks for the patch. I am sure this one will save newbies a few hours
of starting blankly at the screen.
cheers
Arthur
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to
On 6/24/06, arthur debert <[EMAIL PROTECTED]> wrote:
> this one got me stuck for hours (grin).
> if your INSTALLED_APPS is right and your admin inner class too, you
> probably have an error on an import on your model class.
FYI - To help avoid this problem in the future, I have just committed
a
Scott Anderson wrote:
> You could also do this:
>
> ContentType.objects.filter(app_label__exact='aiyo',
> model__in=('content', 'product'))
>
> which is more concise and may treat the query optimizer in your database
> better.
hi Scott,
this is great! however, I'm having another problem, let me
On Sun, 2006-06-25 at 00:18 +, Scott McCracken wrote:
> Don,
>
> Thank you for that tip - it does have something to do with the
> indenting. I am a bit confused as to why that is happening as I was
> simply trying to follow the example which shows code like:
>
> class Poll(models.Model):
>
On 6/24/06, Andrew <[EMAIL PROTECTED]> wrote:
> import mysite.myapp.testdir.foo doesn't work. Why?
Via IRC, we were able to help Andrew figure out he needed to add an
__init__.py in the directory he wanted to import from; roughly
speaking, this tells Python that the directory is a module from
On Jun 24, 2006, at 11:18 AM, Scott McCracken wrote:from webmules.polls.models import Poll, Choice Traceback (most recent call last): File "", line 1, in ? File "/Users/swm/Sites/webmules/../webmules/polls/models.py", line 8 def __str__(self): ^ When you get a syntax error where it's
Say I have a file structure like this:
mysite
myapp
__init__.py
models.py
views.py
testdir
foo.py
import mysite.myapp.testdir.foo doesn't work. Why?
Is testdir not in my pythonpath?
Am I missing something?
Thanks in advance.
Sorry, I didn't know this forum doesn't accept HTML in it's message
bodies. Hopefully my message is still readable.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send
This is my second time going through the http://www.djangoproject.com/documentation/tutorial1/;>Django
tutorials. The first time I ran through the whole process on my
dreamhost server without any errors. This time I'm using the local
development server on my computer (Mac OS X v10.4.6 / Python
Not a problem, Eric, glad to be of help.
You could also do this:
ContentType.objects.filter(app_label__exact='aiyo',
model__in=('content', 'product'))
which is more concise and may treat the query optimizer in your database
better.
Regards,
-scott
On Sat, 2006-06-24 at 17:00 +, nkeric
James Bennett wrote:
> Also keep in mind that as a query gets more and more complex, the odds
> of any ORM syntax being able to express it cleanly and concisely get
> smaller and smaller; there will be times when it'll be faster and
> easier (well, easier so long as you know SQL) to drop down
On 6/23/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Maybe there should be a check in django-admin.py startapp if the
> project i am in has the same name, or a better errormessage.
Hi Kim,
"django-admin.py startapp" does indeed throw an error if the app has
the same name as the project.
Hi,
I'm working up a simple, one-off web-based survey (so pls don't knock
me for not normalizing).
Here's my model:
class Response(models.Model):
email = models.EmailField(maxlength=24)
code = models.CharField(maxlength=24)
response_ts = models.DateTimeField(null=True)
On 6/24/06, Scott Anderson <[EMAIL PROTECTED]> wrote:
> ContentType.objects.filter(
>(Q(app_label__exact='aiyo') & Q(model__exact='content')) |
>(Q(app_label__exact='aiyo') & Q(model__exact='product'))
>)
Also keep in mind that as a query gets more and more complex, the odds
of any
>>> ContentType.objects.filter((Q(app_label__exact='aiyo') &
>>> Q(model__exact='content')) | (Q(app_label__exact='aiyo') &
>>> Q(model__exact='product')))
[, ]
>>> c.queries [{'time': '0.000', 'sql': 'SELECT
>>>
Try:
ContentType.objects.filter(
(Q(app_label__exact='aiyo') & Q(model__exact='content')) |
(Q(app_label__exact='aiyo') & Q(model__exact='product'))
)
Regards,
-scott
On Sat, 2006-06-24 at 09:06 -0700, nkeric wrote:
> sqlite> select * from django_content_type where (app_label='aiyo'
sqlite> select * from django_content_type where (app_label='aiyo' and
model='content') or (app_label='aiyo' and model='product');
17|Product|aiyo|product
24|Content|aiyo|content
hi all,
I've tried:
ContentType.objects.filter(Q(app_label__exact='aiyo',
model__exact='content') |
I would suggest that, before you attempt to setup Django with
Apache/FCGI, you try the built-in development server. It's faster to
get up and running with it and you will know quickly if anything is
wrong with your installation. With the Apache/FCGI setup, it would be
difficult to track down any
Thanks Rajesh, you were right on! The 'pwd' was the culprit and now I
know for future reference. Thank you so much.
One more UNIX question. According to the documentation to http://code.djangoproject.com/wiki/OsxFcgi;>Setup Django with
Apache 1.3 and FCGI I can check to see if Django is running
Open a terminal and check which version of Python you have (python -V).
Chances are that you are running 2.3. The instructions you tried above
assume 2.4.
You can get 2.4 for Mac from here: http://www.python.org/download/mac/
I am running Django with Python installed from the Universal Installer
On 24/06/06, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote:
>
> On Fri, 2006-06-23 at 17:58 +0100, Frankie Robertson wrote:
> > Please, is there any way of doing this? I've dumped the last approach,
> > I'm planning on using inclusion tags to query the database, but the
> > templates would still
Yes this is exact what i was searching for. Thank you very much.
regards, Kim
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
24 matches
Mail list logo