Re: IntegrityError: duplicate key violates unique constraint

2008-03-28 Thread Brian Armstrong
Also, if you have access to the old DB still, consider exporting the entire thing out again. Make sure that you include the structural part as well as the data itself. It should export it directly as a series of SQL statements. A complete dump will provide information about the sequences. --~-

Re: Using ModelForm...not populating my choices

2008-03-27 Thread Brian Armstrong
On Thu, Mar 27, 2008 at 9:27 PM, Greg <[EMAIL PROTECTED]> wrote: > > Hello, > My experience field by default gets displayed as a drop > down..everything works fine when it is displayed this way. However I > want the field to be displayed in my template as Radio Buttons. So I > added the lin

Re: css problem

2008-03-27 Thread Brian Armstrong
Greg, check out settings.py. CSS counts as media -- it's a static file you want to serve up to the outside. The exact details of how this works depend on how the server you're on is set up, but essentially you have two options. You go into settings.py and fill in values for media_root and medi

Re: Using an INSERT...SELECT... type of query

2008-03-26 Thread Brian Armstrong
Sorry for the spam here, but I came across something going through the code switching process that I think may actually call for more than the standard MtM Field. What happens if you need to add additional fields to your join table? For example, let's say you had an employees table and a project

Re: Loop Counter

2008-03-26 Thread Brian Armstrong
On Mar 26, 6:56 pm, DuncanM <[EMAIL PROTECTED]> wrote: > I have a template that looks like such: > > {% if object_list %} > > {% for menu in object_list %} > > {{ menu.name }} > Description: {{ menu.description }} > > > {% endfor %} >

Re: Using an INSERT...SELECT... type of query

2008-03-26 Thread Brian Armstrong
Oh, wait, duh, that's what the Many-to-Many relationship is. Sorry about that. I feel rather dumb now. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to djang

Re: Using an INSERT...SELECT... type of query

2008-03-26 Thread Brian Armstrong
On Mar 26, 4:40 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > What is the use-case for something like this in Django? The only times > we do SQL inserts are when we're saving a model instance or updating a > many-to-many relation. I can't see either of those really needing this > type of fun