Hi there,
I've some basic models like PERSON, GROUP and ROLE:
class PERSON (models.Model):
first = models.CharField ('first name', max_length=256)
last = models.CharField ('last name', max_length=256)
class GROUP (models.Model):
name = models.CharField (max_length=256)
members
Hey,
thanx for the reply! No, the bid is *not* ordered randomly, but you
know what, your solution works anyway! ;) Test this and you'll notice
that it works.. (still haven't figured out why!):
* bs = BID.objects.all ()
* idx=81; bid=bs[idx];
* bs.order_by ('?').filter (pk__lt=bid.id).count ()
Although it works in my interactive environment.. it does not work in
my actual script.. ??
On Mar 9, 7:02 pm, Calaganne wrote:
> Hey,
>
> thanx for the reply! No, the bid is *not* ordered randomly, but you
> know what, your solution works anyway! ;) Test this and you'll notic
3 matches
Mail list logo