[storm] Limit clause

akira nhytro-python at web.de
Thu Aug 2 08:40:48 BST 2007


Thanks Jamu! What is the Percent sign for in the clause?

Jamu Kakar wrote:
> Hi Akira,
>
> akira wrote:
>   
>> Is there an actual LIMIT clause? If yes, could someone show an example
>> of its use?
>>     
>
> You can use the following, in addition to the slicing method Chris
> suggested:
>
> result = store.find(Person, Person.name.like("Bob%"))
> result.config(limit=5, offset=2)
>
> Note, that you can also pass 'distinct=True' to ResultSet.config to
> make it use 'SELECT DISTINCT' queries.
>
> Hope this helps,
> J.
>
>
>   




More information about the storm mailing list