
Hi All! I'am trying to use Persist to select all entities from table but can't figure out syntax to use. Now I was able to select using fake Filter. How can I avoid fake filter and select all record?

On Wed, Apr 13, 2011 at 3:17 PM, Konstantin Litvinenko < to.darkangel@gmail.com> wrote:
Hi All!
I'am trying to use Persist to select all entities from table but can't figure out syntax to use. Now I was able to select using fake Filter. How can I avoid fake filter and select all record?
Just use an empty list of filters, eg:
selectList [] [] 0 0 If you haven't specified types elsewhere, you can do so with a type signature like this: selectList ([] :: [Filter MyEntity]) [] 0 0 HTH, Michael

Michael Snoyman пишет:
I'am trying to use Persist to select all entities from table but can't figure out syntax to use. Now I was able to select using fake Filter. How can I avoid fake filter and select all record?
If you haven't specified types elsewhere, you can do so with a type signature like this:
selectList ([] :: [Filter MyEntity]) [] 0 0
That is what I looking for. Thanx Michael! PS. I'am 3 month haskeller - sorry for newby question.

On Wed, Apr 13, 2011 at 3:37 PM, Konstantin Litvinenko < to.darkangel@gmail.com> wrote:
Michael Snoyman пишет:
I'am trying to use Persist to select all entities from table but can't figure out syntax to use. Now I was able to select using fake Filter. How can I avoid fake filter and select all record?
If you haven't specified types elsewhere, you can do so with a type signature like this:
selectList ([] :: [Filter MyEntity]) [] 0 0
That is what I looking for. Thanx Michael! PS. I'am 3 month haskeller - sorry for newby question.
No worries. Good luck learning Haskell (and Yesod)!
Michael
participants (2)
-
Konstantin Litvinenko
-
Michael Snoyman