Re: Inserting literal % sign in QuerySet.extra()

2015-03-29 Thread Tim Graham
No, it won't. See https://docs.djangoproject.com/en/dev/internals/release-process/#supported-versions for the guidelines on which changes are backported. On Saturday, March 28, 2015 at 2:49:21 AM UTC-4, Gergely Polonkai wrote: > > Great, thank you! > > Although I'm more than willing to upgrade,

Re: Inserting literal % sign in QuerySet.extra()

2015-03-27 Thread Gergely Polonkai
Great, thank you! Although I'm more than willing to upgrade, I still wonder if this fix will be backported to 1.7… On 28 Mar 2015 02:15, "Tim Graham" wrote: > This is fixed in Django 1.8. See the fifth item in > https://docs.djangoproject.com/en/dev/releases/1.8/#models. > > On Friday, March 27,

Re: Inserting literal % sign in QuerySet.extra()

2015-03-27 Thread Tim Graham
This is fixed in Django 1.8. See the fifth item in https://docs.djangoproject.com/en/dev/releases/1.8/#models. On Friday, March 27, 2015 at 5:38:15 PM UTC-4, Gergely Polonkai wrote: > > Hello, > > I’d like to execute the following code: > > Booking.objects.filter(start_ts__isnull = False, end_ts_

Inserting literal % sign in QuerySet.extra()

2015-03-27 Thread Gergely Polonkai
Hello, I’d like to execute the following code: Booking.objects.filter(start_ts__isnull = False, end_ts__isnull = False).extra(select = {'amount': "strftime('%s', end_ts) - strftime('%s', start_ts)"}) However, in the shell, I get the following error: Traceback (most recent call last): File "", l