searchArray :: String -> SearchTerm -> [SqlValue]
searchArray query (ByName s) = replicate (paramNumber query) 
                                $ toSql $ "%" ++ s ++ "%"
    where 
        paramNumber = length . filter ('?' ==)
searchArray :: String -> SearchTerm -> [SqlValue]
searchArray query (ByName s) = replicate (paramNumber query) 
                                $ toSql $ "%" ++ s ++ "%"
    where 
        paramNumber = length . filter ('?' ==)
searchArray query (ByName s) = replicate (paramNumber query) 
                                $ toSql $ "%" ++ s ++ "%"
    where 
        paramNumber = length . filter ('?' ==)