Re: Finding numbers of visitors

2005-11-22 Thread Adrian Holovaty
On 11/22/05, PythonistL <[EMAIL PROTECTED]> wrote: > Adrian, thank you for your reply. > I checked http://www.djangoproject.com/documentation/sessions/ and you > say:``Session dictionary keys that begin with an underscore are > reserved for internal use by Django. `` > So,

Django job in Dallas, Texas

2005-11-22 Thread Adrian Holovaty
s.craigslist.org/art/112889763.html Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: ManyToMany problems

2005-11-22 Thread Adrian Holovaty
ay to test things in this case is to use users.get_list(). If the parameters aren't valid there, they won't be valid in pc.get_user_list(). Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Form Value Array

2005-11-22 Thread Adrian Holovaty
's nothing forcing you to use the square brackets. You could just use a hyphen: ...or no character at all: All that matters is that the view code that processes this knows what format to expect. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Atom and web services interfaces

2005-11-23 Thread Adrian Holovaty
oughts gratefully received. Hi Tone, Django's very REST-friendly, so the task should be straightforward. Feel free to post specific questions, and keep us posted on how it's coming! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: init fails

2005-11-23 Thread Adrian Holovaty
it =). As of changeset 1314 (http://code.djangoproject.com/changeset/1314), the model validator (which runs automatically during "django-admin runserver") complains if you don't max_digits and decimal_places on FloatFields. Is it missing an edge case? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: raw_id_admin

2005-11-23 Thread Adrian Holovaty
ors|join:", " }} > {% endif % } > > If the field is filled by username, form give an error. If it filled > user_id form works correct. How to make form that can be filled by > username insted of user_id? Hi Grigory, raw_id_admin supports only entry of IDs (primary k

Re: Extend list template of admin app?

2005-11-23 Thread Adrian Holovaty
t or tomorrow, if I can flee the Thanksgiving festivities effectively. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django Trac Spam

2005-11-23 Thread Adrian Holovaty
nores comments that include naughty words. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: new password(s)

2005-11-24 Thread Adrian Holovaty
his would mirror the "real" User.create_user(), so you'd be able to create users in Python, which is best. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: _pre_save and _post_save for "set_thingie" methods

2005-11-24 Thread Adrian Holovaty
you to put the pre- and post-saving logic in your own code, or does it absolutely have to be part of Django itself? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

ANN: new-admin branch merged to trunk

2005-11-25 Thread Adrian Holovaty
ourse, to Robert Wittams for his hard work on new-admin. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: mod_python log

2005-11-25 Thread Adrian Holovaty
Django/mod_python docs. Thanks for the question. http://www.djangoproject.com/documentation/modpython/#error-handling Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Documentation for Django on TextDrive

2005-11-25 Thread Adrian Holovaty
ed mentioned this, but I didn't see it during my cursory read. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: django breaks not null in postgresql?

2005-11-26 Thread Adrian Holovaty
at's happening in your case is that the title and blurb fields are getting their default value, which is "" (the empty string). Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: problem marketing django to php folk

2005-11-26 Thread Adrian Holovaty
behavior not to display the database password and secret key, but that's hardly a huge thing. Jacob has drafted a "Contributing to Django" page, which has a full section on how we handle security bugs/alerts, but he hasn't posted that to the site yet. It will have the full scoop o

ANN: Backwards-incompatible change in trunk, for custom template tags/filters

2005-11-26 Thread Adrian Holovaty
ere: http://code.djangoproject.com/wiki/BackwardsIncompatibleChanges#Changedthewaycustomtemplatetagsandfiltersareregistered Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: mod_python log

2005-11-27 Thread Adrian Holovaty
do the print statements end up? When you use mod_python, print statements don't end up anywhere. The best way to print out debugging statements is to either "assert False, 'hello world'" or add the debug output to the outputted page. I've updated the mod

Re: static media using development server?

2005-11-27 Thread Adrian Holovaty
nly-asked question. Here it is: http://www.djangoproject.com/documentation/static_files/ Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

ANN: New document: How to serve static files

2005-11-27 Thread Adrian Holovaty
A commonly asked question is how to serve static files with Django. Here's the answer, finally documented. How to serve static files http://www.djangoproject.com/documentation/static_files/ Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: ANN: New document: How to serve static files

2005-11-27 Thread Adrian Holovaty
dited, doesn't have any error handling, etc. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: admin and auto total rows

2005-11-27 Thread Adrian Holovaty
On 11/27/05, Medium <[EMAIL PROTECTED]> wrote: > Also, i've been hearing about this new admin and reusing of the admin > code, but cannot find any examples. Are there any at the moment ? We'll have docs within a couple of days. Adrian -- Adrian Holovaty holovaty.c

Re: debug tag

2005-11-28 Thread Adrian Holovaty
t; it doesn't show up in the admin tag docs, either. Do an "svn update", and you'll get it. Looks like the {% debug %} tag was inadvertently deleted in revision [1443]. Thanks for the pointer! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: replaces_module

2005-11-29 Thread Adrian Holovaty
dmin() # field names to remove from parent model remove_fields = ['password', 'is_staff', 'is_superuser'] Hope this answers your question, Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Adding a validator a custom manipulator

2005-11-30 Thread Adrian Holovaty
are of that validation for you. Would this solve your problem? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: What is the best way to do related items?

2005-12-01 Thread Adrian Holovaty
On 12/1/05, Milton Waddams <[EMAIL PROTECTED]> wrote: > I've tried self.get_list though obviously it doesn't exist. Just plain "get_list" should work. Give that a shot. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Newbie needs help with real-world example...

2005-12-02 Thread Adrian Holovaty
date [appname]" at any time to get that same validation information. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Declare a variable in a template

2005-12-02 Thread Adrian Holovaty
uot;" This would give you the flexibility of defining that HTML in a template rather than in Python. See the source code of django/contrib/admin/templatetags/admin_modify.py for more custom-tag examples. Also check out http://www.djangoproject.com/documentation/templates_python/#writing-custom-template-tags , which doesn't yet include simple_tag and inclusion_tag but still has a lot of information. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

ANN: Django site on washingtonpost.com

2005-12-05 Thread Adrian Holovaty
Check it out: The first Django app at washingtonpost.com! The U.S. Congress Votes Database http://projects.washingtonpost.com/congress/ It lets you browse every vote in the U.S. Congress since 1991. This is the first of many Django apps at The Post. :) Adrian -- Adrian Holovaty holovaty.com

Re: ANN: Django site on washingtonpost.com

2005-12-05 Thread Adrian Holovaty
'll update it on the site tomorrow. Thanks very much. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: ANN: Django site on washingtonpost.com

2005-12-06 Thread Adrian Holovaty
> or No in the entry afaict. Right -- a bunch of other people have mentioned this, so I'll be rolling in the change. Thanks. :) Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: install admin won´t work

2005-12-08 Thread Adrian Holovaty
xist. Hmmm, I'm not sure what to say about this other than: Are you sure the table doesn't already exist? Are you sure you're thinking of the same database that Django is thinking about? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: choices in BooleanField: bug or feature?

2005-12-08 Thread Adrian Holovaty
) you get an > error because there is no validation that takes into account > "bank=False" and so the INSERT statement is obviously wrong: BooleanFields aren't allowed to have the "choices" parameter, because that would be meaningless. By definition, a boolean only h

Re: indexes on tables

2005-12-08 Thread Adrian Holovaty
d in your model. Add "db_index=True" to the appropriate field to add an index. Then run "django-admin.py sqlindexes appname" to get the CREATE INDEX statements. > Also -- can a ForeignKey be supplied with a human-readable name, like > other fields? Yes, give it a &qu

Re: indexes on tables

2005-12-09 Thread Adrian Holovaty
se directly according to the schema enough for Django > -- i.e., there's nothing else, or does it keep more secret stuff > somewhere? I'm not sure what you're asking here... Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

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

Re: indexes on tables

2005-12-09 Thread Adrian Holovaty
n tables, and I have to load them via django calls? There's nothing special about Django's own tables -- they just hold stuff like authentication information for the Django admin. You don't have to worry about any magic. :) Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Serving both Django content and plain files with mod_python

2005-12-12 Thread Adrian Holovaty
gt; have some root URLs served by Django and some served by Apache? You can use "SetHandler None" on a particular to turn off Django. http://www.djangoproject.com/documentation/modpython/#serving-media-files Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django screencast

2005-12-13 Thread Adrian Holovaty
ke an official screencast but haven't done so because I know APIs are going to change. So it's great that somebody else stepped in to provide one in the interim. Thanks again, Tom. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: is Django too powerful?

2005-12-13 Thread Adrian Holovaty
nd what goes in the app repository, becomes even more subjective. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Caching partial templates

2005-12-14 Thread Adrian Holovaty
e %} for a certain number of seconds: {% cache '500' %} This will be cached for 500 seconds. {% endcache %} If you write it and submit a patch, we'd definitely consider adding this to the Django distribution. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: ifequal

2005-12-15 Thread Adrian Holovaty
he problem was that the "1" in that example was being compared as a string, not an integer. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: check constraints

2005-12-17 Thread Adrian Holovaty
and add the constraints that way. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Adding features to several models

2005-12-18 Thread Adrian Holovaty
Stay tuned for more information on when those changes will be made a bona-fide part of Django. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: forwarding email to a django application

2005-12-19 Thread Adrian Holovaty
cific about this technique; the handler script can do whatever you want, whether it's interacting with Django models or whatever. The docs you pointed out should be just as helpful for Django as Rails. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: get_list() with foreignkey-parameters

2005-12-19 Thread Adrian Holovaty
7;]) > > the model looks like; > responsible = meta.ForeignKey(auth.User) Try this: milestone_list = milestones.get_list(responsible__id__exact=1) You can also do something like this: milestone_list = milestones.get_list(responsible__username__exact='patrick') Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Upgrading models...

2005-12-20 Thread Adrian Holovaty
ays get them right the > first time. :-) Is there an easy way to help migrate the data from an old > model to a new one? What's the preferred method? Hey John, Check this out: http://www.djangoproject.com/documentation/faq/#if-i-make-changes-to-a-model-how-do-i-update-the-database

Re: url hierarchy

2005-12-20 Thread Adrian Holovaty
tation of regular expressions, anyone know a way > around it? Capture the whole thing, then parse it in your view by splitting on the slash. (r'^/albums/([a-z0-9_/]+))+/$', 'mydomain.views.view_album') def view_album(request, url): bits = url.split('/') # Lookup page by bits. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: downloadable django documentation?

2005-12-20 Thread Adrian Holovaty
tribution, which, it seems, you've already found. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: SQL Injection

2005-12-20 Thread Adrian Holovaty
to > get_object()? All the standard Django ORM functions, such as get_object() and get_list(), automatically quote all parameters within the SQL queries. So you don't have to worry about SQL injection. I'm hoping to write up a document about this soon. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Importing stuff in your app's models module?

2005-12-21 Thread Adrian Holovaty
r much longer. For now, put the "from socket import..." within _pre_save(). Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Problem in Admin section, in shell works great

2005-12-21 Thread Adrian Holovaty
y isn't a reserved name. It must be something else. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Seg fault with Django & mod_python on Redhat 9

2005-12-22 Thread Adrian Holovaty
ng, of course, mod_python and any other essential ones) until it works. Good luck, and keep us posted! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: admin-interface: some questions

2005-12-27 Thread Adrian Holovaty
ht need to include some JavaScript in your custom HTML page for that. See django/contrib/admin/media/js/SelectFilter.js. Hope this helps! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: problems importing an app

2005-12-28 Thread Adrian Holovaty
ject/apps", and give it another shot. You're trying to import myproject.apps.polls, but that directory doesn't exist. Good luck! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: MultiValueDict

2005-12-28 Thread Adrian Holovaty
x27;], > 'byuser': ['1']} > > now i´m trying to get all "users" to send them an email. > but with something like post_data["user"] i only get "[EMAIL PROTECTED]". > > so, how can i get all the values for "user" within

Re: Django and Multiple Database Support

2005-12-29 Thread Adrian Holovaty
app here: http://feh.holsman.net/articles/2005/12/15/django-captcha-app I haven't looked at the code myself, but it could be helpful. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: how to create a custom selectfield?

2005-12-29 Thread Adrian Holovaty
thing like that, django.core.formfields.CheckboxSelectMultipleField will probably do the trick. The formfields module isn't that well documented at the moment, but there's some here: http://www.djangoproject.com/documentation/forms/#custom-forms-and-manipulators Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: problems importing an app

2005-12-29 Thread Adrian Holovaty
on and should be integrated into Django proper within a couple of weeks. For more information, see http://code.djangoproject.com/wiki/RemovingTheMagic . Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Search Functionality

2005-12-29 Thread Adrian Holovaty
. (Trivia: get_in_bulk() was created to solve this exact problem.) Hope that helps! It would be pretty cool to open-source this mini search framework and pop it in django/contrib, but that would be up to Jacob to decide. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: One-sided ManyToMany options

2005-12-29 Thread Adrian Holovaty
nt from the table including the > relationship. This is something we'll be adding in the magic-removal branch. See http://code.djangoproject.com/wiki/DescriptorFields . Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: unreserved praise for performance

2005-12-29 Thread Adrian Holovaty
Thanks, Patrick! Performance has consistently been a key goal while developing Django. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Email documentation

2005-12-29 Thread Adrian Holovaty
eaders? Good call! I've updated docs/email.txt to point out input needs to be validated. Also, in revision 1795, I tightended up the Django mail functions so that they don't accept newlines in any header. Docs are updated for that as well. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Problem adding new classes to a model

2005-12-30 Thread Adrian Holovaty
ist > Exception Value:ContentType does not exist for > {'package__label__exact': > 'python_module_name__exact': } Hi Antoni, When you copy the CREATE TABLE statements for your new models, make sure to copy the "INSERT INTO content_types" and "INSERT INT

Re: Really basic question...

2005-12-30 Thread Adrian Holovaty
, documented here: http://www.djangoproject.com/documentation/generic_views/#using-simple-generic-views Here's the URLconf you'd use: urlpatterns = patterns('', (r'.*', 'django.views.generic.simple.direct_to_template', {'template': 'base&#

Re: Really basic question...

2005-12-30 Thread Adrian Holovaty
've updated the docs: http://www.djangoproject.com/documentation/templates_python/#the-template-dirs-setting http://www.djangoproject.com/documentation/settings/#template-dirs Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Really basic question...

2005-12-30 Thread Adrian Holovaty
ates". > ) > > Perhaps add "# Always use Unix-style forward slashes, even on Windows." Good call. I've put that note in the default generated settings.py. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: A very simple application

2005-12-30 Thread Adrian Holovaty
I wanted to see the value of variable foo, I'd do this: assert False, foo Hope that helps, Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Is django authentication right for me?

2006-01-03 Thread Adrian Holovaty
then again I could implement them myself to have groups > and rights and so forth. What would you do? Utilize Django's or > create your own for my situation? Hi Mike, Seems like you're saying Django's built-in auth will work for you. In that case, I'd suggest you u

Re: Limiting selected records and distinct as a keyword

2006-01-03 Thread Adrian Holovaty
t.com/ticket/1152. See http://www.djangoproject.com/documentation/db_api/#limiting-selected-rows for an example. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Additional User Data?

2006-01-03 Thread Adrian Holovaty
gt; --- cut --- Try specifying an "ordering" parameter in the admin options for your custom user-info model. http://www.djangoproject.com/documentation/model_api/#admin-options Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

ANN: Another Django app at washingtonpost.com

2006-01-03 Thread Adrian Holovaty
I created this Django app on deadline, as a supplement to a Washington Post analysis of previous court rulings by Supreme Court nominee Samuel Alito. http://projects.washingtonpost.com/2006/alito/cases/ Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: ANN: Another Django app at washingtonpost.com

2006-01-04 Thread Adrian Holovaty
On 1/3/06, Jeremy Dunck <[EMAIL PROTECTED]> wrote: > Who did the info graphic on top here: > http://www.washingtonpost.com/wp-dyn/content/custom/2005/12/30/CU2005123001137.html The graphics staff. See the bottom of that page for info. Adrian -- Adrian Holovaty holovaty.com | djang

ANN: "Snakes and Rubies" (Django/Rails meetup) video/audio available

2006-01-05 Thread Adrian Holovaty
cely edited files for your downloading pleasure. Check them out here: http://www.djangoproject.com/snakesandrubies/ Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: per-view cache system

2006-01-06 Thread Adrian Holovaty
ion. Using the 2.3 syntax is a safe bet. Feel free to show us your full traceback -- that'd help us debug your problem. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: customizing appearance of foreign key edited inline

2006-01-06 Thread Adrian Holovaty
s/choices are displayed, change the field order in the Choice model. Hope this helps! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Apache Authentication

2006-01-06 Thread Adrian Holovaty
ache auth (against, say, an htpasswd file) to authenticate Django users (creating request.user from generic Apache auth rather than from the Django users database table). That's a subtle difference; hope that makes sense. If you're still having problems, go ahead and show us the section of y

Re: Apache Authentication

2006-01-07 Thread Adrian Holovaty
t; TypeError: 'tuple' object is not callable Ooooh, that looks like a bug in the Django mod_python authentication handler that's triggered if DjangoRequireStaffStatus isn't set in httpd.conf. Can you try putting the following in your and seeing whether you get the same error?

Re: Apache Authentication

2006-01-07 Thread Adrian Holovaty
On 1/7/06, Brian Ray <[EMAIL PROTECTED]> wrote: > btw, I will fill out a Trac ticket for the modpython.py fix, just in > case this thread get's lost in cyberspace. Thanks for the ticket and patch! I've committed it. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Accessin actual object inside a for loop

2006-01-08 Thread Adrian Holovaty
of things? I'm not sure what you mean here...What's the exact error you get? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Session disposal

2006-01-08 Thread Adrian Holovaty
ssion that I don't want carried through logout/login sequences, > and I'm wondering when and how to get rid of them. Hey John, Deleting an object from a session is simple: del request.session['foo'] Hope this answers your question. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Session disposal

2006-01-09 Thread Adrian Holovaty
On 1/8/06, John Martin <[EMAIL PROTECTED]> wrote: > Thanks Adrian. What I'm actually wondering about though is whether > there is a "proper" way to clear out a session entirely? Is it just a > matter of iterating through all of the keys and clearing them one by &

Re: Django DB Design Question (help please!)

2006-01-09 Thread Adrian Holovaty
his takes advantage of the fact that the lookup parameters are capable of performing joins behind the scenes. Let me know if this doesn't make sense or if I misunderstood your question. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django DB Design Question (help please!)

2006-01-09 Thread Adrian Holovaty
y not? I wouldn't recommend approach #2, because it's a slightly messy database layout, but it would still work with Django as long as the "user" field of NewsPosting was a ForeignKey(User). Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django and Multiple Database Support

2006-01-10 Thread Adrian Holovaty
to add a > db_schema attribute or something instead. (Should I submit a patch? :-) Perhaps we could have the best of both worlds, and have the Model constructor split on period, storing db_schema internally if a schema was provided. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django and MS SQL

2006-01-10 Thread Adrian Holovaty
SQL users in the audience be able to help? Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Django and MS SQL

2006-01-10 Thread Adrian Holovaty
On 1/10/06, Jeroen Ruigrok van der Werven <[EMAIL PROTECTED]> wrote: > Which version of MS SQL do you initially want to target Adrian? I can > probably get some basic testing done here to clear the majority of the > issues. Thanks for the offer! Knowing next to nothing about MS SQ

Re: Django and MS SQL

2006-01-10 Thread Adrian Holovaty
nd if it is not, why waste our time? Hey Kenneth, Making Django available to SQL Server users is hardly a waste of time -- it's a win for the framework. Similarly, we've got an Oracle driver in the works. If you're not a fan of closed-source databases, continue to use open-sourc

Re: migrating from winxp to linux problems

2006-01-10 Thread Adrian Holovaty
of Python on this box? Another thing to check is that you're able to do the following import statement: from pysqlite2 import dbapi2 Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: customizing appearance of foreign key edited inline

2006-01-10 Thread Adrian Holovaty
On 1/10/06, Colleen Owens <[EMAIL PROTECTED]> wrote: > Thanks for the reply, Adrian. I want to be able to change the field order > and which fields are displayed while I'm editing something inline. Changing > the field order and which fields are displayed for the Choice model

Re: Django and MS SQL

2006-01-10 Thread Adrian Holovaty
e backend (the "adodbapi" library) assumes placeholders use "?" for placeholders. So the Django layer needs to convert all "%s" placeholders in the query to "?". It looks like the current way this is happening (in django/core/db/backends/ado_mssql.py)

ANN: Django 0.91 released

2006-01-11 Thread Adrian Holovaty
release before the magic-removal branch is merged. The next release will be a big one. Many thanks to all the great people who've contributed to this project. You can check them out in the AUTHORS file: http://code.djangoproject.com/browser/django/trunk/AUTHORS Enjoy! The Django team -

Re: scheduling capabilities?

2006-01-11 Thread Adrian Holovaty
we generally just create small Python scripts and run 'em via cron. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: multiple levels of join

2006-01-11 Thread Adrian Holovaty
t_list(myself__exact=my_id) entries.get_list(submission_user__in=[f.id for f in my_friends]) Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Common Practice with Models and Views

2006-01-11 Thread Adrian Holovaty
y don't even have to be in the app package. All the Django cares about is that they're accessible via Python "dotted-path" notation, e.g., 'adrian.views.homepage'. Viva decoupling! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Duplicate object

2006-01-11 Thread Adrian Holovaty
lue into keyword arguments. For example the following two statements are functionally identical: write_love_letter(to='python', from='adrian') write_love_letter(**{'to': 'python', 'from': 'adrian'}) Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Duplicate object

2006-01-11 Thread Adrian Holovaty
(0, None, or False), and thus force the saving routine to generate > a new one and do an insert query: > > a.id = None > a.save() You're right -- my mistake! Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: Postgre's with Django Model

2006-01-11 Thread Adrian Holovaty
odel provides > support for bytea? No, we've avoided supporting BLOB fields because it opens a can of mutated worms. That said, if somebody can come up with a logical, clean design for that feature, let's make it happen. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

Re: application level settings

2006-01-11 Thread Adrian Holovaty
> though, so I was wondering if Django has some built-in way of handling this. Hey Colleen, I'm not sure this answers your question, but feel free to make up your own settings. See the docs here: http://www.djangoproject.com/documentation/settings/#creating-your-own-settings

Re: Templates for Python Programmers error

2006-01-11 Thread Adrian Holovaty
ing that look very similar from the documentation. Good call. I've removed that section from the docs. Adrian -- Adrian Holovaty holovaty.com | djangoproject.com | chicagocrime.org

<    3   4   5   6   7   8   9   10   11   >