{-# LANGUAGE
DataKinds
, OverloadedStrings
, RankNTypes
, ScopedTypeVariables
, TypeOperators
#-}
module Squeal.PostgreSQL.Expression.Text
(
lower
, upper
, charLength
, like
, ilike
, replace
, strpos
) where
import Squeal.PostgreSQL.Expression
import Squeal.PostgreSQL.Type.Schema
lower :: null 'PGtext --> null 'PGtext
lower :: forall (null :: PGType -> NullType). null 'PGtext --> null 'PGtext
lower = forall (x :: NullType) (y :: NullType). ByteString -> x --> y
unsafeFunction ByteString
"lower"
upper :: null 'PGtext --> null 'PGtext
upper :: forall (null :: PGType -> NullType). null 'PGtext --> null 'PGtext
upper = forall (x :: NullType) (y :: NullType). ByteString -> x --> y
unsafeFunction ByteString
"upper"
charLength :: null 'PGtext --> null 'PGint4
charLength :: forall (null :: PGType -> NullType). null 'PGtext --> null 'PGint4
charLength = forall (x :: NullType) (y :: NullType). ByteString -> x --> y
unsafeFunction ByteString
"char_length"
like :: Operator (null 'PGtext) (null 'PGtext) ('Null 'PGbool)
like :: forall (null :: PGType -> NullType).
Operator (null 'PGtext) (null 'PGtext) ('Null 'PGbool)
like = forall (ty0 :: NullType) (ty1 :: NullType) (ty2 :: NullType).
ByteString -> Operator ty0 ty1 ty2
unsafeBinaryOp ByteString
"LIKE"
ilike :: Operator (null 'PGtext) (null 'PGtext) ('Null 'PGbool)
ilike :: forall (null :: PGType -> NullType).
Operator (null 'PGtext) (null 'PGtext) ('Null 'PGbool)
ilike = forall (ty0 :: NullType) (ty1 :: NullType) (ty2 :: NullType).
ByteString -> Operator ty0 ty1 ty2
unsafeBinaryOp ByteString
"ILIKE"
strpos
:: '[null 'PGtext, null 'PGtext] ---> null 'PGint4
strpos :: forall (null :: PGType -> NullType).
'[null 'PGtext, null 'PGtext] ---> null 'PGint4
strpos = forall (xs :: [NullType]) (y :: NullType).
SListI xs =>
ByteString -> xs ---> y
unsafeFunctionN ByteString
"strpos"
replace
:: '[ null 'PGtext, null 'PGtext, null 'PGtext ] ---> null 'PGtext
replace :: forall (null :: PGType -> NullType).
'[null 'PGtext, null 'PGtext, null 'PGtext] ---> null 'PGtext
replace = forall (xs :: [NullType]) (y :: NullType).
SListI xs =>
ByteString -> xs ---> y
unsafeFunctionN ByteString
"replace"