
23 Nov
2012
23 Nov
'12
5:15 p.m.
Erik de Castro Lopo wrote:
There are still some problems typing all these and they all still return a list instead of a value whereas the SQL statement returns a single value.
I stand corrected! This: queryTableNameCount :: SqlPersist IO [Value Int64] queryTableNameCount = select . from $ \(_ :: SqlExpr (Entity TableName)) -> return countRows returns a singleton list with the correct value and no type checker warnings. Erik -- ---------------------------------------------------------------------- Erik de Castro Lopo http://www.mega-nerd.com/