Re: application of migration fails

2016-12-12 Thread Francis Fisher
So it turns out that a different user owned the non-managed tables, which seemed to prevent the django user from accessing certain information about those tables. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group

Re: application of migration fails

2016-12-12 Thread Francis Fisher
I can see why django is crashing at File "/usr/local/lib/python2.7/dist-packages/django/db/backends/postgresql/introspection.py", line 178, in get_constraints If I run the query at that line in postgres, I get the following response: constraint_name|

Re: application of migration fails

2016-12-12 Thread Francis Fisher
The above migration crash was when applying to a postgres database, I've tried applying this migration to a mysql database and it still crashes, albeit differently. -- File "evetools/manage.py", line 10, in execute_from_command_line(sys.argv) File

Re: makemigrations generates new migration when nothing has changed

2016-12-12 Thread Francis Fisher
On Wednesday, 30 November 2016 22:43:55 UTC, Mike Dewhirst wrote: > > On 1/12/2016 3:56 AM, Francis Fisher wrote: > > Any idea why makemigrations would fail to recognise that a migration > > has already been generated? > > I think migrations is seeing field choic

application of migration fails

2016-12-12 Thread Francis Fisher
Any idea if I'm doing something wrong or if I'm running into a bug? I added some fields to a model, and generated a migration. When I apply the migration, the migrate command crashes, with both django 1.10.3 and 1.10.4. I had a similar migration issue with another app in the same project, that

makemigrations generates new migration when nothing has changed

2016-11-30 Thread Francis Fisher
Any idea why makemigrations would fail to recognise that a migration has already been generated? makemigrations.py is a script which calls makemigrations with appropriate django settings. If I run this once, it will generate the initial migration, but every time I run it subsequently, it will

multi-table inheritance: getting instances of parent class which are also instances of child class

2009-10-29 Thread James Harrison Fisher
rants and all Places"? If I can't find a solution using multi-table inheritance then I imagine I'm going to have to use an abstract base class (which would involve rethinking my architecture). Thanks in advance and all the best James Fisher --~--~-~--~~~---~--

Re: query with field name only known at runtime

2009-10-27 Thread James Harrison Fisher
a-HA. Simple. I had a suspicion this would be a python solution rather than Django-specific solution. Thanks! On Oct 27, 11:14 am, Daniel Roseman <dan...@roseman.org.uk> wrote: > On Oct 27, 10:48 am, James Harrison Fisher <jameshfis...@gmail.com> > wrote: > > >

query with field name only known at runtime

2009-10-27 Thread James Harrison Fisher
Hi, I've recently come across something that's stumped me. I am creating a 'shortcut' function for easier creation of add/edit views. This function needs to make a query on a model in the simple form: model.objects.get(field_name=value) where the variables "model", "field_name", and "value"

Re: template variables

2007-10-26 Thread fisher
On Oct 13, 8:09 am, Goon <[EMAIL PROTECTED]> wrote: > can you use variables in django's templates? > > so like {% for x in y %} > > and then something like > > {% int x =3; x++ %} Recently I found some handy django snippet which can be usefull for you. http://www.djangosnippets.org/snippets/9/