!wPm      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijkl None"#6`e esqueleto|A type representing the access of a table value. In Esqueleto, we get a guarantee that the access will look something like: escape-char [character] escape-char . escape-char [character] escape-char ^^^^^^^^^^^ ^^^^^^^^^^^ table name column name i esqueletoParse a SqlExpr (Value Bool)*'s textual representation into a list of ej esqueletoThis function uses the [ function in the h with an empty identifier to pull out an escape character. This implementation works with postgresql, mysql, and sqlite backends. defhgijklmno efhgijdklmno None6e  !"#$%&'(,+*).-/01:98765432=<;>?@ABCFEDGHIJNMLKTSRQPOhgfedcba`_^]\[ZYXWVUkjinmlopqrstuwvx|{zy~}     $#"! +*)('&%;:9876543210/.-,GFEDCBA@?>=<PONMLKJIHSRQUT\[ZYXWVcba`_^]None&',/2=>?@ACHSVXCs esqueletoAn exception thrown by  RenderExprT - it's not designed to handle composite keys, and will blow up if you give it one.u esqueleto1(Internal) Class for mapping results coming from  into actual results.This looks very similar to RawSqle, and it is! However, there are some crucial differences and ultimately they're different classes.v esqueleto!Creates the variable part of the SELECT query and returns the list of ;s that will be given to (.w esqueleto(Number of columns that will be consumed.x esqueleto1Transform a row of the result into the data type.y esqueletoCreate  INSERT INTO clause instead.z esqueleto,(Internal) Mode of query being converted by . esqueleto(Internal) This class allows  to work with different numbers of arguments; specifically it allows providing arguments to a sql function via an n-tuple of SqlExpr (Value _) values, which are not all necessarily required to be the same type. There are instances for up to 10-tuples, but for sql functions which take more than 10 arguments, you can also nest tuples, as e.g. toArgList ((a,b),(c,d)) is the same as toArgList (a,b,c,d). esqueletoPhantom type used to mark a  INSERT INTO query. esqueleto!An expression on the SQL backend.There are many comments describing the constructors of this data type. However, Haddock doesn't like GADTs, so you'll have to read them by hitting "Source". esqueleto1Information needed to escape and use identifiers. esqueletoHList of identifiers already in use and supply of temporary identifiers. esqueleto Identifier used for table names. esqueletoA locking clause. esqueletoA LIMIT clause. esqueletoA ORDER BY clause. esqueletoA HAVING cause. esqueletoA GROUP BY clause. esqueleto A complete WHERE clause. esqueleto A part of a SET clause. esqueleto A part of a FROM clause. esqueletoThe DISTINCT "clause". esqueletoThe default, everything. esqueletoOnly DISTINCT, SQL standard. esqueleto DISTINCT ON, PostgreSQL extension. esqueletoSide data written by . esqueletoConstraint synonym for  persistent entities whose backend is >. esqueletoSQL backend for  esqueleto using >. esqueletoException data type for  esqueleto internal errors esqueleto%(Internal) Class that implements the JOIN q magic (see ). esqueleto+(Internal) Class that implements the tuple q magic (see ). esqueletoClass that enables one to use k: to convert an entity's key on a query into another (cf. k). esqueletoPhantom class of data types that are treated as strings by the RDBMS. It has no methods because it's only used to avoid type errors such as trying to concatenate integers."If you have a custom data type or newtype2, feel free to make it an instance of this class. Since: 2.4.0 esqueleto0Different kinds of locking clauses supported by  .iNote that each RDBMS has different locking support. The constructors of this datatype specify only the syntax$ of the locking mechanism, not its  semantics?. For example, even though both MySQL and PostgreSQL support :, there are no guarantees that they will behave the same. Since: 2.2.7 esqueleto FOR UPDATE5 syntax. Supported by MySQL, Oracle and PostgreSQL. Since: 2.2.7 esqueletoFOR UPDATE SKIP LOCKED5 syntax. Supported by MySQL, Oracle and PostgreSQL. Since: 2.2.7 esqueleto FOR SHARE" syntax. Supported by PostgreSQL. Since: 2.2.7 esqueletoLOCK IN SHARE MODE syntax. Supported by MySQL. Since: 2.2.7 esqueletoPhantom type used by . esqueletoPhantom type for a SET0 operation on an entity of the given type (see b and '(=.)'). esqueletoPhantom type used by  and . esqueletoPhantom type used by ,  and . esqueleto((Internal) Phantom type used to process q (see ). esqueletoException thrown whenever  is used to create an ON clause but no matching JOIN is found. esqueletoE(Internal) Functions that operate on types (that should be) of kind . esqueleto (Internal)  smartJoin a b is a JOIN of the correct kind. esqueleto(Internal) Reify a JoinKind from a JOIN . This function is non-strict. esqueleto(Internal) A kind of JOIN. esqueleto  INNER JOIN esqueleto  CROSS JOIN esqueleto LEFT OUTER JOIN esqueleto RIGHT OUTER JOIN esqueleto FULL OUTER JOIN esqueletoData type that represents a FULL OUTER JOIN (see  for an example). esqueletoData type that represents a RIGHT OUTER JOIN (see  for an example). esqueletoData type that represents a LEFT OUTER JOIN. For example,  select $ q $ \(person `` pet) -> ... is translated into /SELECT ... FROM Person LEFT OUTER JOIN Pet ...  See also: q. esqueletoData type that represents a  CROSS JOIN (see  for an example). esqueletoData type that represents an  INNER JOIN (see  for an example). esqueleto@A class for constructors or function which result type is known. esqueletouA class of things that can be converted into a list of SomeValue. It has instances for tuples and is the reason why  can take tuples, like  (foo ( FooId, foo ( FooName, foo ( FooType). esqueletoA wrapper type for for any expr (Value a) for all a.  esqueletohA list of single values. There's a limited set of functions able to work with this data type (such as [, \, ^ and `).  esqueleto=A single value (as opposed to a whole entity). You may use (() or (*) to get a   from an . esqueleto(Internal) Start a q query with an entity. q does two kinds of magic using ,  and : >The simple but tedious magic of allowing tuples to be used.$The more advanced magic of creating JOIN s. The JOINB is processed from right to left. The rightmost entity of the JOIN is created with  . Each JOIN( step is then translated into a call to . In the end, ! is called to materialize the JOIN. esqueleto(Internal) Same as , but entity may be missing. esqueleto(Internal) Do a JOIN. esqueleto(Internal) Finish a JOIN. esqueletoWHERE% clause: restrict the query's result. esqueletoAn ONd clause, useful to describe how two tables are related. Cross joins and tuple-joins do not need an  clause, but ! and the various outer joins do.If you don't include an H clause (or include too many!) then a runtime exception will be thrown.)As an example, consider this simple join:  $ q $ \(foo `` bar) -> do  (foo ( FooId 4 bar ( BarFooId) ... TWe need to specify the clause for joining the two columns together. If we had this:  $ q $ \(foo `` bar) -> do ... Then we can safely omit the I clause, because the cross join will make pairs of all records possible.You can do multiple A clauses in a query. This query joins three tables, and has two  clauses:  $ q $ \(foo `` bar `` baz) -> do  (baz ( BazId 4 bar ( BarBazId)  (foo ( FooId 4 bar ( BarFooId) ... 8Old versions of esqueleto required that you provide the S clauses in reverse order. This restriction has been lifted - you can now provide o clauses in any order, and the SQL should work itself out. The above query is now totally equivalent to this:  $ q $ \(foo `` bar `` baz) -> do  (foo ( FooId 4 bar ( BarFooId)  (baz ( BazId 4 bar ( BarBazId) ...  esqueletoGROUP BY6 clause. You can enclose multiple columns in a tuple.  select $ q \(foo `` bar) -> do  (foo ( FooBarId 4 bar ( BarId)  (bar ( BarId, bar ( BarName) return (bar ( BarId, bar ( BarName, countRows) DWith groupBy you can sort by aggregate functions, like so (we used let to restrict the more general 0 to SqlSqlExpr (Value Int)) to avoid ambiguity---the second use of 0 has its type restricted by the :: Int below): r <- select $ q \(foo `` bar) -> do  (foo ( FooBarId 4 bar ( BarId)  $ bar ( BarName let countRows' = 0  [ countRows'] return (bar (" BarName, countRows') forM_ r $ \(  name,  2 count) -> do print name print (count :: Int)  esqueletoORDER BY clause. See also  and .Multiple calls to 1 get concatenated on the final query, including . esqueleto/Ascending order of this field or SqlExpression. esqueleto0Descending order of this field or SqlExpression. esqueletoLIMIT%. Limit the number of returned rows. esqueletoOFFSET. Usually used with . esqueletoDISTINCT. Change the current SELECT into SELECT DISTINCT. For example: select $ distinct $ q \foo -> do ... (Note that this also has the same effect:  select $ q) \foo -> do distinct (return ()) ...  Since: 2.2.4 esqueleto DISTINCT ON. Change the current SELECT into #SELECT DISTINCT ON (SqlExpressions). For example:  select $ q \foo ->  [ (foo ^. FooName),  (foo ^. FooState)] $ do ... &You can also chain different calls to . The above is equivalent to:  select $ q \foo ->  [ (foo ^. FooName)] $  [ (foo ^. FooState)] $ do ...  Each call to & adds more SqlExpressions. Calls to  override any calls to .4Note that PostgreSQL requires the SqlExpressions on  DISTINCT ON% to be the first ones to appear on a ORDER BYi. This is not managed automatically by esqueleto, keeping its spirit of trying to be close to raw SQL.Supported by PostgreSQL only. Since: 2.2.4 esqueletoCErase an SqlExpression's type so that it's suitable to be used by . Since: 2.2.4 esqueleto'A convenience function that calls both  and . In other words, + [asc foo, desc bar, desc quux] $ do ... is the same as: ' [don foo, don bar, don quux] $ do ' [asc foo, desc bar, desc quux] ...  Since: 2.2.4 esqueletoORDER BY random() clause. Since: 1.3.10 esqueletoHAVING. Since: 1.2.2  esqueleto1Add a locking clause to the query. Please read % documentation and your RDBMS manual.If multiple calls to  3 are made on the same query, the last one is used. Since: 2.2.7! esqueletoExecute a subquery SELECTO in an SqlExpression. Returns a simple value so should be used only when the SELECT- query is guaranteed to return just one row.Deprecated in 3.2.0." esqueletoExecute a subquery SELECT in a Q. The query passed to this function will only return a single result - it has a LIMIT 1A passed in to the query to make it safe, and the return type is m7 to indicate that the subquery might result in 0 rows.If you find yourself writing / . ", then consider using #.If you're performing a 0, then you can use $ which is safe.If you know that the subquery will always return exactly one row (eg a foreign key constraint guarantees that you'll get exactly one row), then consider '1, along with a comment explaining why it is safe.# esqueletoExecute a subquery SELECT in a /. This function is a shorthand for the common / . " idiom, where you are calling " on an expression that would be m already.8As an example, you would use this function when calling E or G, which have m( in the result type (for a 0 row query).$ esqueleto Performs a COUNT of the given query in a  subSelectU manner. This is always guaranteed to return a result value, and is completely safe.% esqueletoExecute a subquery SELECT in a , that returns a list. This is an alias for [G and is provided for symmetry with the other safe subselect functions.& esqueletoPerforms a sub-select using the given foreign key on the entity. This is useful to extract values that are known to be present by the database schema.<As an example, consider the following persistent definition: 1User profile ProfileId Profile name Text 5The following query will return the name of the user. getUserWithName =  $ q $ user -> n (user, &# user UserProfile (^. ProfileName) ' esqueletoExecute a subquery SELECT in a Q. This function is unsafe, because it can throw runtime exceptions in two cases: =If the query passed has 0 result rows, then it will return a NULL value. The  persistent/ parsing operations will fail on an unexpected NULL.If the query passed returns more than one row, then the SQL engine will fail with an error like "More than one row returned by a subquery used as an expression".nThis function is safe if you guarantee that exactly one row will be returned, or if the result already has a m type for some reason.2For variants with the safety encoded already, see " and #,. For the most common safe use of this, see $.( esqueletoProject a field of an entity.) esqueletoGProject an SqlExpression that may be null, guarding against null cases.* esqueleto.Project a field of an entity that may be null.+ esqueleto5Lift a constant value from Haskell-land to the query., esqueletoIS NULL comparison.- esqueleto Analogous to o, promotes a value of type typ into one of type  Maybe typ. It should hold that + . Just === just . +.. esqueletoNULL value./ esqueleto Join nested ms in a  O into one. This is useful when calling aggregate functions on nullable fields.0 esqueletoCOUNT(*) value.1 esqueletoCOUNT.2 esqueletoCOUNT(DISTINCT x). Since: 2.4.1@ esqueletoBETWEEN. @since: 3.1.0I esqueletoAllow a number of one type to be used as one of another type via an implicit cast. An explicit cast is not made, this function changes only the types on the Haskell side.Caveat: Trying to use castNum from Double to IntZ will not result in an integer, the original fractional number will still be used! Use B, C or D instead.Safety+: This operation is mostly safe due to the p constraint between the types and the fact that RDBMSs usually allow numbers of different types to be used interchangeably. However, there may still be issues with the query not being accepted by the RDBMS or  persistent not being able to parse it. Since: 2.2.9J esqueletoSame as I, but for nullable values. Since: 2.2.9K esqueletoCOALESCE function. Evaluates the arguments in order and returns the value of the first non-NULL SqlExpression, or NULL (Nothing) otherwise. Some RDBMSs (such as SQLite) require at least two arguments; please refer to the appropriate documentation. Since: 1.4.3L esqueletoLike coalesce{, but takes a non-nullable SqlExpression placed at the end of the SqlExpression list, which guarantees a non-NULL result. Since: 1.4.3M esqueletoLOWER function.N esqueletoUPPER function.  Since: 3.3.0O esqueletoTRIM function.  Since: 3.3.0P esqueletoRTRIM function.  Since: 3.3.0Q esqueletoLTRIM function.  Since: 3.3.0R esqueletoLENGTH function.  Since: 3.3.0S esqueletoLEFT function.  Since: 3.3.0T esqueletoRIGHT function.  Since: 3.3.0U esqueletoLIKE operator.V esqueletoILIKE operator (case-insensitive LIKE).Supported by PostgreSQL only. Since: 2.2.3W esqueleto The string W. May be useful while using U and concatenation (X or Ya, depending on your database). Note that you always have to type the parenthesis, for example: name `U ` (%) ++. + "John" ++. (%) X esqueletoThe CONCATT function with a variable number of parameters. Supported by MySQL and PostgreSQL.Y esqueletoThe ||7 string concatenation operator (named after Haskell's q% in order to avoid naming clash with ;'). Supported by SQLite and PostgreSQL.Z esqueletoCast a string type into Text4. This function is very useful if you want to use newtype.s, or if you want to apply functions such as U to strings of different types.Safety:[ This is a slightly unsafe function, especially if you have defined your own instances of . Also, since m is an instance of k, it's possible to turn a nullable value into a non-nullable one. Avoid using this function if possible.[ esqueletoExecute a subquery SELECT1 in an SqlExpression. Returns a list of values.\ esqueleto=Lift a list of constant value from Haskell-land to the query.] esqueletoSame as - but for  D. Most of the time you won't need it, though, because you can use - from inside [ or o from inside \. Since: 2.2.12^ esqueletoIN1 operator. For example if you want to select all Persons by a list of IDs: ,SELECT * FROM Person WHERE Person.id IN (?) In  esqueleto', we may write the same query above as:  select $ q $ \person -> do  $ person ( PersonId `^` \ personIds return person Where  personIds is of type  [Key Person]._ esqueletoNOT IN operator.` esqueletoEXISTS operator. For example:  select $ q $ \person -> do  $ ` $ q $ \post -> do  (post ( BlogPostAuthorId 4 person ( PersonId) return person a esqueleto NOT EXISTS operator.b esqueletoSET clause used on UPDATEEs. Note that while it's not a type error to use this function on a SELECT4, it will most certainly result in a runtime error.h esqueletoApply a  constructor to  SqlExpr Value arguments.i esqueleto Apply extra  SqlExpr Value arguments to a  constructorj esqueletoCASE statement. For example: select $ return $ j [ l (` $ q $ \p -> do  (p ( PersonName 4 + "Mike")) m (! $ q, $ \v -> do let sub = q $ \c -> do  (c ( PersonName 4 +" "Mike") return (c ( PersonFavNum)  (v ( PersonFavNum >. ! sub) return $ 1 (v ( PersonName) +. + (1 :: Int)) ] (n $ + (-1)) LThis query is a bit complicated, but basically it checks if a person named "Mike"x exists, and if that person does, run the subquery to find out how many people have a ranking (by Fav Num) higher than "Mike".NOTE:9 There are a few things to be aware about this statement.fThis only implements the full CASE statement, it does not implement the "simple" CASE statement. At least one l and m4 is mandatory otherwise it will emit an error.The nC is also mandatory, unlike the SQL statement in which if the ELSE is omitted it will return a NULL#. You can reproduce this via .. Since: 2.1.2k esqueleto.Convert an entity's key into another entity's.8This function is to be used when you change an entity's Id- to be that of another entity. For example: <Bar barNum Int Foo bar BarId fooNum Int Primary bar For this example, declare: Pinstance ToBaseId Foo where type BaseEnt Foo = Bar toBaseIdWitness = FooKey )Now you're able to write queries such as:  $ q $ (bar ` ` foo) -> do  (k (foo ( FooId) 4 bar ( BarId) return (bar, foo) ^Note: this function may be unsafe to use in conditions not like the one of the example above. Since: 2.4.3l esqueletoSyntax sugar for j. Since: 2.1.2m esqueletoSyntax sugar for j. Since: 2.1.2n esqueletoSyntax sugar for j. Since: 2.1.2o esqueletoConvert a constructor for a  key on a record to the  that defines it. You can supply just the constructor itself, or a value of the type - the library is capable of figuring it out from there.p esqueletoARender updates to be use in a SET clause for a given sql backend.q esqueletoFROM# clause: bring entities into scope.This function internally uses two type classes in order to provide some flexibility of how you may call it. Internally we refer to these type classes as the two different magics.&The innermost magic allows you to use from with the following types:expr (Entity val),, which brings a single entity into scope.expr (Maybe (Entity val))-, which brings a single entity that may be NULL into scope. Used for  OUTER JOINs.A JOINB of any other two types allowed by the innermost magic, where a JOIN may be an , a , a , a , or a . The JOINs have left fixity.&The outermost magic allows you to use fromn on any tuples of types supported by innermost magic (and also tuples of tuples, and so on), up to 8-tuples.Note that using fromz for the same entity twice does work and corresponds to a self-join. You don't even need to use two different calls to from, you may use a JOIN or a tuple.,The following are valid examples of uses of fromH (the types of the arguments of the lambda are inside square brackets): q $ \person -> ... q $ \(person, blogPost) -> ... q $ \(p ` ` mb) -> ... q $ \(p1 `` f ` ` p2) -> ... q $ \((p1 `` f) ` ` p2) -> ... CThe types of the arguments to the lambdas above are, respectively: person :: ( Esqueleto query expr backend , PersistEntity Person , PersistEntityBackend Person ~ backend ) => expr (Entity Person) (person, blogPost) :: (...) => (expr (Entity Person), expr (Entity BlogPost)) (p `[` mb) :: (...) => InnerJoin (expr (Entity Person)) (expr (Maybe (Entity BlogPost))) (p1 `` f `` p2) :: (...) => InnerJoin (InnerJoin (expr (Entity Person)) (expr (Entity Follow))) (expr (Entity Person)) (p1 `` (f `` p2)) :: :: (...) => InnerJoin (expr (Entity Person)) (InnerJoin (expr (Entity Follow)) (expr (Entity Person))) 5Note that some backends may not support all kinds of JOINs.s esqueletoCollect s on !s. Returns the first unmatched *s data on error. Returns a list without  OnClauses on success.u esqueletoCreate a fresh . If possible, use the given .v esqueletoUse an identifier. esqueleto#(Internal) Create a case statement. Since: 2.1.1 esqueleto1(Internal) Create a custom binary operator. You should not use this function directly since its type is very general, you should always use it with an explicit type signature. For example: e(==.) :: SqlExpr (Value a) -> SqlExpr (Value a) -> SqlExpr (Value Bool) (==.) = unsafeSqlBinOp " = " zIn the example above, we constraint the arguments to be of the same type and constraint the result to be a boolean value. esqueleto Similar to , but may also be applied to composite keys. Uses the operator given as the second argument whenever applied to composite keys.Usage example: v(==.) :: SqlExpr (Value a) -> SqlExpr (Value a) -> SqlExpr (Value Bool) (==.) = unsafeSqlBinOpComposite " = " " AND " <Persistent has a hack for implementing composite keys (see U doc for more details), so we're forced to use a hack here as well. We deconstruct  values based on two rules:HIf it is a single placeholder, then it's assumed to be coming from a 0Y and thus its components are separated so that they may be applied to a composite key.If it is not a single placeholder, then it's assumed to be a foreign (composite or not) key, so we enforce that it has no placeholders and split it on the commas. esqueleto4(Internal) A raw SQL value. The same warning from " applies to this function as well. esqueletoC(Internal) A raw SQL function. Once again, the same warning from " applies to this function as well. esqueletoc(Internal) An unsafe SQL function to extract a subfield from a compound field, e.g. datetime. See  for warnings. Since: 1.3.6. esqueletoL(Internal) A raw SQL function. Preserves parentheses around arguments. See  for warnings. esqueletoE(Internal) An explicit SQL type cast using CAST(value as type). See  for warnings. esqueleto_(Internal) Coerce a value's type from 'SqlExpr (Value a)' to 'SqlExpr (Value b)'. You should not6 use this function unless you know what you're doing! esqueletow(Internal) Coerce a value's type from 'SqlExpr (ValueList a)' to 'SqlExpr (Value a)'. Does not work with empty lists. esqueleto(Internal) Execute an  esqueleto SELECT  inside  persistent's > monad. esqueleto Execute an  esqueleto SELECT query inside  persistent's > monad and return a r of rows. esqueleto Execute an  esqueleto SELECT query inside  persistent's >! monad and return a list of rows.We've seen that qM has some magic about which kinds of things you may bring into scope. This f function also has some magic for which kinds of things you may bring back to Haskell-land by using SqlQuery's return:You may return a  SqlExpr ( v) for an entity v (i.e., like the *; in SQL), which is then returned to Haskell-land as just Entity v.You may return a SqlExpr (Maybe (Entity v)) for an entity v that may be NULL., which is then returned to Haskell-land as Maybe (Entity v) . Used for  OUTER JOINs.You may return a  SqlExpr (  t) for a value t" (i.e., a single column), where t is any instance of ., which is then returned to Haskell-land as Value t. You may use Value to return projections of an Entity (see (() and (*)@) or to return any other value calculated on the query (e.g., 0 or ").The  SqlSelect a rR class has functional dependencies that allow type information to flow both from a to r] and vice-versa. This means that you'll almost never have to give any type signatures for  esqueleto# queries. For example, the query  $ from $ \p -> return p+ alone is ambiguous, but in the context of  do ps <-  $ qT $ \p -> return p liftIO $ mapM_ (putStrLn . personName . entityVal) ps &we are able to infer from that single personName . entityVal function composition that the p inside the query is of type SqlExpr (Entity Person). esqueleto(Internal) Run a r of rows. esqueleto(Internal) Execute an  esqueleto statement inside  persistent's > monad. esqueleto Execute an  esqueleto DELETE query inside  persistent's >b monad. Note that currently there are no type checks for statements that should not appear on a DELETE query.Example of usage:  $ q $ \appointment ->  (appointment ( AppointmentDate 8 + now) Unlike !, there is a useful way of using Q that will lead to type ambiguities. If you want to delete all rows (i.e., no . clause), you'll have to use a type signature:  $ q $ \(appointment ::  ( Appointment)) -> return ()  esqueletoSame as *, but returns the number of rows affected. esqueleto Execute an  esqueleto UPDATE query inside  persistent's >b monad. Note that currently there are no type checks for statements that should not appear on a UPDATE query.Example of usage:  $ \p -> do b p [ PersonAge c - (+ thisYear) -. p ( PersonBorn ]  $ isNothing (p ( PersonAge)  esqueletoSame as *, but returns the number of rows affected. esqueleto(Internal) Pretty prints a  into a SQL query.@Note: if you're curious about the SQL query being generated by  esqueletoT, instead of manually using this function (which is possible but tedious), see the  function (along with , , etc). esqueleto Renders a  into a Text value along with the list of ;-s that would be supplied to the database for ? placeholders.You must ensure that the z8 you pass to this function corresponds with the actual @. If you pass a query that uses incompatible features (like an INSERT statement with a SELECT' mode) then you'll get a weird result. esqueleto Renders a  into a Text value along with the list of ;-s that would be supplied to the database for ? placeholders.You must ensure that the z8 you pass to this function corresponds with the actual @. If you pass a query that uses incompatible features (like an INSERT statement with a SELECT' mode) then you'll get a weird result. esqueleto Renders a  into a Text value along with the list of ;-s that would be supplied to the database for ? placeholders.You must ensure that the z8 you pass to this function corresponds with the actual @. If you pass a query that uses incompatible features (like an INSERT statement with a SELECT' mode) then you'll get a weird result. esqueleto Renders a  into a Text value along with the list of ;-s that would be supplied to the database for ? placeholders.You must ensure that the z8 you pass to this function corresponds with the actual @. If you pass a query that uses incompatible features (like an INSERT statement with a SELECT' mode) then you'll get a weird result. esqueleto Renders a  into a Text value along with the list of ;-s that would be supplied to the database for ? placeholders.You must ensure that the z8 you pass to this function corresponds with the actual @. If you pass a query that uses incompatible features (like an INSERT statement with a SELECT' mode) then you'll get a weird result. esqueletoMaterialize a SqlExpr (Value a). esqueleto Insert a  for every selected value. Since: 2.4.2 esqueleto Insert a 5 for every selected value, return the count afterward esqueletoRenders an expression into TextQ. Only useful for creating a textual representation of the clauses passed to an On clause. esqueleto Since: 1.4.4 esqueleto Since: 2.4.0 esqueleto Since: 2.3.0 esqueleto Since: 2.3.0 esqueleto Since: 2.3.0 esqueleto Since: 2.3.0 esqueleto Since: 2.3.0  esqueleto  esqueleto  esqueleto  esqueleto esqueleto esqueleto esqueleto&Useful for 0-argument functions, like now in Postgresql.$ esqueletoEYou may return tuples (up to 16-tuples) and tuples of tuples from a  query.% esqueleto?You may return any single value (i.e. a single column) from a  query.& esqueletoYou may return a possibly-NULL  from a  query.' esqueletoYou may return an  from a  query.( esqueletoNot useful for , but used for  and .) esqueleto INSERT INTO hack.* esqueleto& esqueleto<An expression representing the table you have access to now. esqueleto#The foreign key field on the table. esqueleto?A function to extract a value from the foreign reference table. esqueletoWhether to render as an {, |, etc. esqueleto!The SQL query you want to render. esqueleto!The SQL query you want to render. esqueleto!The SQL query you want to render. esqueleto!The SQL query you want to render. esqueleto!The SQL query you want to render.^stuwvyxz~}{|      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~^ !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmn     opqrstuvwxyz{|}~z~}{|uwvyxst2222222222(9 445464748494:3;2<6=6>7?7U2V2Y5c3d3e3f3g3None&'2=>?@ACHV.      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnqq     lmn !(*+,-./)0123456789:;@<=>?ABCDFGEHIJKLMNOQPRSTUVWXYZ[\]^_`abcdefgjkhi"#$%&' None&',/2=>?@ACHSVX!|Duxyvwz|{}~tDz|{}~tuxyvwNone&'=>?SX4> esqueleto valkey i = + .  ( 2https://github.com/prowdsponsor/esqueleto/issues/9).? esqueletovalJ is like val% but for something that is already a Value0. The use case it was written for was, given a Value lift the Key for that Valueu into the query expression in a type safe way. However, the implementation is more generic than that so we call it valJ.Its important to note that the input entity and the output entity are constrained to be the same by the type signature on the function ( 1https://github.com/prowdsponsor/esqueleto/pull/69). Since: 1.4.2@ esqueleto Synonym for   that does not clash with  esqueleto's .A esqueleto:Avoid N+1 queries and join entities into a map structure  getFoosAndNestedBarsFromParent :: ParentId -> (Map (Key Foo) (Foo, [Maybe (Entity Bar)])) getFoosAndNestedBarsFromParent parentId = s associateJoin $  $ q $ \(foo `` bar) -> do  (bar * BarFooId 4 foo ( FooId)  (foo ( FooParentId 4 + parentId) n (foo, bar)   Since: 3.1.2  !"#$%&'(,+*).-/01:98765432=<;>?@ABCFEDGHIJNMLKTSRQPOhgfedcba`_^]\[ZYXWVUkjinmlopqrstuwvx|{zy~}     $#"! +*)('&%;:9876543210/.-,GFEDCBA@?>=<PONMLKJIHSRQUT\[ZYXWVcba`_^]      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnq>?@A !(*+,-./)0123456789:;@<=>?ABCDFGEHIJKLMNOQPRSTUVWXYZ[\]^_`abcdefgjk"#$&%'lmnq     hi>?A@/x10   $&%('#! "GHIutwvcba`_^]|{zy~}.-,+*)A:98765432CB=<;FED@?>NMLKsJhgfedcba`_^]\[ZYXWVUopkjiqnmlrTSRQPO     $#"! UT+*)('&%PONMLKJIH\[ZYXWV;:9876543210/.-,GFEDCBA@?>=<SRQNoneEB esqueleto(random()H) Split out into database specific modules because MySQL uses `rand()`. Since: 2.6.0BBNone &'>SXrC esqueletoAggregate modeD esqueletoALLE esqueletoDISTINCTF esqueleto(random()H) Split out into database specific modules because MySQL uses `rand()`. Since: 2.6.0t esqueletoEmpty array literal. (val []) does unfortunately not workG esqueleto-Coalesce an array with an empty default valueH esqueletoB(Internal) Create a custom aggregate functions with aggregate modeDo notT use this function directly, instead define a new function and give it a type (see )K esqueleto( array_agg/) Concatenate distinct input values, including NULLs, into an array. Since: 2.5.3L esqueleto( array_remove?) Remove all elements equal to the given value from the array. Since: 2.5.3M esqueletoRemove NULL values from an arrayN esqueleto( string_agg5) Concatenate input values separated by a delimiter.O esqueleto( string_agg5) Concatenate input values separated by a delimiter. Since: 2.2.8P esqueleto(chrs) Translate the given integer to a character. (Note the result will depend on the character set of your database.) Since: 2.2.11T esqueleto7Inserts into a table the results of a query similar to J but allows to update values that violate a constraint during insertions.Example of usage: share [ mkPersist sqlSettings , mkDeleteCascade sqlSettings , mkMigrate "migrate" ] [persistLowerCase| Bar num Int deriving Eq Show Foo num Int UniqueFoo num deriving Eq Show |] insertSelectWithConflict UniqueFoo -- (UniqueFoo undefined) or (UniqueFoo anyNumber) would also work (from $ b -> return $ Foo <# (b ^. BarNum) ) (current excluded -> [FooNum =. (current ^. FooNum) +. (excluded ^. FooNum)] ) Inserts to table Foo all Bar.num values and in case of conflict SomeFooUnique, the conflicting value is updated to the current plus the excluded.U esqueletoSame as T) but returns the number of rows affected.N esqueleto Aggregate mode (ALL or DISTINCT) esqueleto Input values. esqueleto Delimiter. esqueletoORDER BY clauses esqueletoConcatenation.O esqueleto Input values. esqueleto Delimiter. esqueletoConcatenation.R esqueletonew record to insert esqueleto/updates to perform if the record already exists esqueleto.the record in the database after the operationS esqueleto uniqueness constraint to find by esqueletonew record to insert esqueleto/updates to perform if the record already exists esqueleto.the record in the database after the operationT esqueletoUnique constructor or a unique, this is used just to get the name of the postgres constraint, the value(s) is(are) never used, so if you have a unique "MyUnique 0", "MyUnique undefined" would work as well. esqueleto Insert query. esqueletoA list of updates to be applied in case of the constraint being violated. The expression takes the current and excluded value to produce the updates.CDEFGHIJKLMNOPQRSTUCDEKJILMONGPQFRSTUH None4567MW esqueleto!Used with certain JSON operators.This data type has p and uA instances for ease of use by using integer and string literals.3 :: JSONAccessor JSONIndex 3-3 :: JSONAccessor JSONIndex -3"name" :: JSONAccessorJSONKey "name"NOTE: DO NOT USE ANY OF THE p METHODS ON THIS TYPE!Z esqueleto of a NULL-able [ value. Hence the m.1Note: NULL here is a PostgreSQL NULL, not a JSON v[ esqueleto;Newtype wrapper around any type with a JSON representation.^ esqueleto5Convenience function to lift a regular value into a [ expression.w esqueletojsonbx esqueletoy esqueleto+I repeat, DO NOT use any method other than z!{ esqueletoODatabase type(s), should appear different from Haskell name, e.g. "integer" or INT, not Int. esqueletoIncorrect value esqueleto Error message| esqueletoReceived value esqueletoAdditional error esqueleto Error message WYXZ[\]^}~{|NonesZ _ esqueleto"Requires PostgreSQL version >= 9.3eThis function extracts the jsonb value from a JSON array or object, depending on whether you use an int or a text. (cf. W)As long as the left operand is jsonb>, this function will not throw an exception, but will return NULL when an int4 is used on anything other than a JSON array, or a text/ is used on anything other than a JSON object.PostgreSQL Documentation  | Type | Description | Example | Example Result ----+------+--------------------------------------------+--------------------------------------------------+---------------- -> | int | Get JSON array element (indexed from zero) | '[{"a":"foo"},{"b":"bar"},{"c":"baz"}]'::json->2 | {"c":"baz"} -> | text | Get JSON object field by key | '{"a": {"b":"foo"}} '::json->'a' | {"b":"foo"} ` esqueleto"Requires PostgreSQL version >= 9.3 Identical to _!, but the resulting DB type is a text2, so it could be chained with anything that uses text.$CAUTION: if the "scalar" JSON value null is the result 3of this function, PostgreSQL will interpret it as a  PostgreSQL NULL value, and will therefore be  instead of (Just "null")PostgreSQL Documentation E | Type | Description | Example | Example Result -----+------+--------------------------------+-----------------------------+---------------- ->> | int | Get JSON array element as text | '[1,2,3]'::json->>2 | 3 ->> | text | Get JSON object field as text | '{"a":1,"b":2} '::json->>'b' | 2 a esqueleto"Requires PostgreSQL version >= 9.3This operator can be used to select a JSON value from deep inside another one. It only works on objects and arrays and will result in NULL ()) when encountering any other JSON type.The s used in the right operand list will always select an object field, but can also select an index from a JSON array if that text is parsable as an integer.Consider the following: x ^. TestBody #>. ["0","1"] !The following JSON values in the test table's body column will be affected:  Values in column | Resulting value --------------------------------------+---------------------------- {"0":{"1":"Got it!"}} | "Got it!" {"0":[null,["Got it!","Even here!"]]} | ["Got it!", "Even here!"] [{"1":"Got it again!"}] | "Got it again!" [[null,{"Wow":"so deep!"}]] | {"Wow": "so deep!"} false | NULL "nope" | NULL 3.14 | NULL PostgreSQL Documentation / | Type | Description | Example | Example Result -----+--------+-----------------------------------+--------------------------------------------+---------------- #> | text[] | Get JSON object at specified path | '{"a": {"b":{"c": "foo"}}} '::json#>'{a,b}' | {"c": "foo"} b esqueleto"Requires PostgreSQL version >= 9.3This function is to a as ` is to _$CAUTION: if the "scalar" JSON value null is the result 3of this function, PostgreSQL will interpret it as a  PostgreSQL NULL value, and will therefore be  instead of (Just "null")PostgreSQL Documentation I | Type | Description | Example | Example Result -----+--------+-------------------------------------------+---------------------------------------------+---------------- #>> | text[] | Get JSON object at specified path as text | '{"a":[1,2,3],"b":[4,5,6]} '::json#>>' {a,2}' | 3 c esqueleto"Requires PostgreSQL version >= 9.4cThis operator checks for the JSON value on the right to be a subset of the JSON value on the left.dExamples of the usage of this operator can be found in the Database.Persist.Postgresql.JSON module.(here:  khttps://hackage.haskell.org/package/persistent-postgresql-2.10.0/docs/Database-Persist-Postgresql-JSON.html)PostgreSQL Documentation F | Type | Description | Example ----+-------+-------------------------------------------------------------+--------------------------------------------- @> | jsonb | Does the left JSON value contain within it the right value? | '{"a":1, "b":2}'::jsonb @> '{"b":2}'::jsonb d esqueleto"Requires PostgreSQL version >= 9.4 This operator works the same as cz, just with the arguments flipped. So it checks for the JSON value on the left to be a subset of JSON value on the right.dExamples of the usage of this operator can be found in the Database.Persist.Postgresql.JSON module.(here:  khttps://hackage.haskell.org/package/persistent-postgresql-2.10.0/docs/Database-Persist-Postgresql-JSON.html)PostgreSQL Documentation = | Type | Description | Example ----+-------+----------------------------------------------------------+--------------------------------------------- <@ | jsonb | Is the left JSON value contained within the right value? | '{"b":2}'::jsonb <@ '{"a":1, "b":2}'::jsonb e esqueleto"Requires PostgreSQL version >= 9.4This operator checks if the given text is a top-level member of the JSON value on the left. This means a top-level field in an object, a top-level string in an array or just a string value.dExamples of the usage of this operator can be found in the Database.Persist.Postgresql.JSON module.(here:  khttps://hackage.haskell.org/package/persistent-postgresql-2.10.0/docs/Database-Persist-Postgresql-JSON.html)PostgreSQL Documentation , | Type | Description | Example ---+------+-----------------------------------------------------------------+------------------------------- ? | text | Does the string exist as a top-level key within the JSON value? | '{"a":1, "b":2}'::jsonb ? b f esqueleto"Requires PostgreSQL version >= 9.4This operator checks if ANY of the given texts is a top-level member of the JSON value on the left. This means any top-level field in an object, any top-level string in an array or just a string value.dExamples of the usage of this operator can be found in the Database.Persist.Postgresql.JSON module.(here:  khttps://hackage.haskell.org/package/persistent-postgresql-2.10.0/docs/Database-Persist-Postgresql-JSON.html)PostgreSQL Documentation < | Type | Description | Example ----+--------+--------------------------------------------------------+--------------------------------------------------- ?| | text[] | Do any of these array strings exist as top-level keys? | '{"a":1, "b":2, "c":3}'::jsonb ?| array[b, c] g esqueleto"Requires PostgreSQL version >= 9.4This operator checks if ALL of the given texts are top-level members of the JSON value on the left. This means a top-level field in an object, a top-level string in an array or just a string value.dExamples of the usage of this operator can be found in the Database.Persist.Postgresql.JSON module.(here:  khttps://hackage.haskell.org/package/persistent-postgresql-2.10.0/docs/Database-Persist-Postgresql-JSON.html)PostgreSQL Documentation & | Type | Description | Example ----+--------+--------------------------------------------------------+---------------------------------------- ?& | text[] | Do all of these array strings exist as top-level keys? | '["a", "b"]'::jsonb ?& array[a, b] h esqueleto"Requires PostgreSQL version >= 9.5This operator concatenates two JSON values. The behaviour is self-evident when used on two arrays, but the behaviour on different combinations of JSON values might behave unexpectedly.=CAUTION: THIS FUNCTION THROWS AN EXCEPTION WHEN CONCATENATING 'A JSON OBJECT WITH A JSON SCALAR VALUE!ArraysGThis operator is a standard concatenation function when used on arrays: \[1,2] || [2,3] == [1,2,2,3] [] || [1,2,3] == [1,2,3] [1,2,3] || [] == [1,2,3] ObjectsDWhen concatenating JSON objects with other JSON objects, the fields from the JSON object on the right are added to the JSON object on the left. When concatenating a JSON object with a JSON array, the object will be inserted into the array; either on the left or right, depending on the position relative to the operator.GWhen concatening an object with a scalar value, an exception is thrown. L{"a": 3.14} || {"b": true} == {"a": 3.14, "b": true} {"a": "b"} || {"a": null} == {"a": null} {"a": {"b": true, "c": false}} || {"a": {"b": false}} == {"a": {"b": false}} {"a": 3.14} || [1,null] == [{"a": 3.14},1,null] [1,null] || {"a": 3.14} == [1,null,{"a": 3.14}] 1 || {"a": 3.14} == ERROR: invalid concatenation of jsonb objects {"a": 3.14} || false == ERROR: invalid concatenation of jsonb objects  Scalar valuesScalar values can be thought of as being singleton arrays when used with this operator. This rule does not apply when concatenating with JSON objects. 1 || null == [1,null] true || "a" == [true,"a"] [1,2] || false == [1,2,false] null || [1,"a"] == [null,1,"a"] {"a":3.14} || true == ERROR: invalid concatenation of jsonb objects 3.14 || {"a":3.14} == ERROR: invalid concatenation of jsonb objects {"a":3.14} || [true] == [{"a":3.14},true] [false] || {"a":3.14} == [false,{"a":3.14}] PostgreSQL Documentation , | Type | Description | Example ----+-------+-----------------------------------------------------+-------------------------------------------- || | jsonb | Concatenate two jsonb values into a new jsonb value | '["a", "b"]'::jsonb || '["c", "d"]'::jsonb  Note: The ||7 operator concatenates the elements at the top level of 6each of its operands. It does not operate recursively.GFor example, if both operands are objects with a common key field name, Jthe value of the field in the result will just be the value from the right  hand operand.i esqueleto"Requires PostgreSQL version >= 9.5This operator can remove a key from an object or a string element from an array when using text, and remove certain elements by index from an array when using integers.DNegative integers delete counting from the end of the array. (e.g. -1 being the last element, -2 being the second to last, etc.)FCAUTION: THIS FUNCTION THROWS AN EXCEPTION WHEN USED ON ANYTHING OTHER FTHAN OBJECTS OR ARRAYS WHEN USING TEXT, AND ANYTHING OTHER THAN ARRAYS WHEN USING INTEGERS!Objects and arrays {"a": 3.14} - "a" == {} {"a": "b"} - "b" == {"a": "b"} {"a": 3.14} - "a" == {} {"a": 3.14, "c": true} - "a" == {"c": true} ["a", 2, "c"] - "a" == [2, "c"] -- can remove strings from arrays [true, "b", 5] - 0 == ["b", 5] [true, "b", 5] - 3 == [true, "b", 5] [true, "b", 5] - -1 == [true, "b"] [true, "b", 5] - -4 == [true, "b", 5] [] - 1 == [] {"1": true} - 1 == ERROR: cannot delete from object using integer index 1 - <anything> == ERROR: cannot delete from scalar "a" - <anything> == ERROR: cannot delete from scalar true - <anything> == ERROR: cannot delete from scalar null - <anything> == ERROR: cannot delete from scalar PostgreSQL Documentation X | Type | Description | Example ---+---------+------------------------------------------------------------------------+------------------------------------------------- - | text | Delete key/value pair or string element from left operand. | '{"a": "b"}'::jsonb - a! | | Key/value pairs are matched based on their key value. | - | integer | Delete the array element with specified index (Negative integers count | '["a", "b"]'::jsonb - 1 | | from the end). Throws an error if top level container is not an array. | j esqueleto!Requires PostgreSQL version >= 10GRemoves a set of keys from an object, or string elements from an array.(This is the same operator internally as i, but the option to use a  text array , instead of text or integerJ was only added in version 10. That's why this function is seperate from i"NOTE: The following is equivalent: ${some JSON expression} -. "a" -. "b"is equivalent to ${some JSON expression} --. ["a","b"]PostgreSQL Documentation  | Type | Description | Example ---+---------+------------------------------------------------------------------------+------------------------------------------------- - | text[] | Delete multiple key/value pairs or string elements from left operand. | '{"a": "b", "c": "d"}'::jsonb - '{a,c}'::text[] | | Key/value pairs are matched based on their key value. | k esqueleto"Requires PostgreSQL version >= 9.56This operator can remove elements nested in an object.If a  is not parsable as a number when selecting in an array (even when halfway through the selection) an exception will be thrown.CNegative integers delete counting from the end of an array. (e.g. -1 being the last element, -2 being the second to last, etc.)4CAUTION: THIS FUNCTION THROWS AN EXCEPTION WHEN USED 2ON ANYTHING OTHER THAN OBJECTS OR ARRAYS, AND WILL 6ALSO THROW WHEN TRYING TO SELECT AN ARRAY ELEMENT WITH A NON-INTEGER TEXTObjects {"a": 3.14, "b": null} #- [] == {"a": 3.14, "b": null} {"a": 3.14, "b": null} #- ["a"] == {"b": null} {"a": 3.14, "b": null} #- ["a","b"] == {"a": 3.14, "b": null} {"a": {"b":false}, "b": null} #- ["a","b"] == {"a": {}, "b": null} Arrays rue, {"b":null}, 5] #- [] == [true, {"b":null}, 5] [true, {"b":null}, 5] #- ["0"] == [{"b":null}, 5] [true, {"b":null}, 5] #- ["b"] == ERROR: path element at position 1 is not an integer: "b" [true, {"b":null}, 5] #- ["1","b"] == [true, {}, 5] [true, {"b":null}, 5] #- ["-2","b"] == [true, {}, 5] {"a": {"b":[false,4,null]}} #- ["a","b","2"] == {"a": {"b":[false,4]}} {"a": {"b":[false,4,null]}} #- ["a","b","c"] == ERROR: path element at position 3 is not an integer: "c"  Other values 1 #- {anything} == ERROR: cannot delete from scalar "a" #- {anything} == ERROR: cannot delete from scalar true #- {anything} == ERROR: cannot delete from scalar null #- {anything} == ERROR: cannot delete from scalar PostgreSQL Documentation t | Type | Description | Example ----+--------+---------------------------------------------------------+------------------------------------ #- | text[] | Delete the field or element with specified path | '["a", {"b":1}]'::jsonb #- '{1,b}' | | (for JSON arrays, negative integers count from the end) | WXYZ[\]^_`abcdefghijk[\]Z^WXY_`abcdefgijkh _6`6a6b6c6d6e6f6g6h6i6j6k6Nonevl esqueleto(random()H) Split out into database specific modules because MySQL uses `rand()`. Since: 2.6.0llSafew+ !"#$%&'()*+,-.-/-0-1-2-3-4-5-6-7898:8;8<8=8>?@?A?B?C?D?EFGHIHJKLKMKNKOKPKQKRKSKSKTKUKVKWKXKYKZK[K\K]K^K^_`_a_b_c_d_e_f_g_h_i_j_k_l_l_m_n_o_p_q_r_s_t_u_v_w_x_y_z_{_|_}_~_____________       !!"#$%%&'()**+,--./01234566789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdeffghijklmnmompmqmrmsmtuvvwxyz{|}~X        !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~       !"#$%&'()*+,-./0123456789:;<=>?@ABCCDECFGHIJKLMNOPQRS T U V W X X Y Z[\]^_`,ab=?cdCefgehiefjeklehmnopehqresteuv w x yekz { | } ~ef&esqueleto-3.3.1-1VGvbZZY4YK5w18wmPzJh2Database.Esqueleto$Database.Esqueleto.Internal.Language&Database.Esqueleto.Internal.ExprParser$Database.Esqueleto.Internal.InternalDatabase.Esqueleto.MySQLDatabase.Esqueleto.PostgreSQL"Database.Esqueleto.PostgreSQL.JSONDatabase.Esqueleto.SQLite,Database.Esqueleto.Internal.PersistentImportDatabase.Esqueleto.Internal.SqlDatabase.Persist.Storedelete,Database.Esqueleto.PostgreSQL.JSON.InstancesPaths_esqueleto(persistent-2.10.4-47SA96grBd4HGk6O3e9MG4Database.Persist.SqltransactionUndotransactionSaveDatabase.Persist.Sql.MigrationmigraterunMigrationUnsaferunMigrationSilent runMigration getMigration showMigrationprintMigrationparseMigration'parseMigration(Database.Persist.Sql.Orphan.PersistQuerydecorateSQLWithLimitOffset(Database.Persist.Sql.Orphan.PersistStore fieldDBName getFieldName tableDBName getTableName fromSqlKeytoSqlKey withRawQueryunSqlBackendKey SqlBackendKeyunSqlReadBackendKeySqlReadBackendKeyunSqlWriteBackendKeySqlWriteBackendKeyDatabase.Persist.Sql.Runclose' withSqlConn askLogFunc createSqlPool withSqlPoolliftSqlPersistMPoolrunSqlPersistMPoolrunSqlPersistM runSqlConn runSqlPoolDatabase.Persist.Sql.RawrawSql getStmtConnrawExecuteCount rawExecute rawQueryResrawQueryDatabase.Persist.Sql.ClassrawSqlProcessRowrawSqlColCountReason rawSqlColsRawSqlsqlTypePersistFieldSqlDatabase.Persist toJsonTextDatabase.Persist.Sql.Internal mkColumnsdefaultAttributeDatabase.Persist.Sql.Types cReferencecMaxLencDefaultConstraintNamecDefaultcSqlTypecNullcNameColumnCouldn'tGetSQLConnectionStatementAlreadyFinalizedPersistentSqlException SqlPersistT SqlPersistMSqlCautiousMigration MigrationConnectionPoolunSingleSingle#Database.Persist.Sql.Types.Internal readToUnknown readToWritewriteToUnknownLogFunc ISRManyKeys ISRInsertGet ISRSingleInsertSqlResult stmtQuery stmtExecute stmtReset stmtFinalize StatementconnRepsertManySql connMaxParams connLogFuncconnLimitOffset connRDBMS connNoLimitconnEscapeName connRollback connCommit connBeginconnMigrateSql connClose connStmtMapconnPutManySql connUpsertSqlconnInsertManySql connInsertSql connPrepare SqlBackendunSqlReadBackendSqlReadBackendunSqlWriteBackendSqlWriteBackendSqlBackendCanReadSqlBackendCanWriteSqlReadT SqlWriteT IsSqlBackendDatabase.Persist.Class PersistUnique PersistStore$Database.Persist.Class.DeleteCascade deleteCascade DeleteCascade#Database.Persist.Class.PersistQuery selectKeys selectKeysRes selectFirstselectSourceResPersistQueryRead deleteWhere updateWherePersistQueryWrite$Database.Persist.Class.PersistUnique checkUnique replaceUnique getByValue onlyUniqueinsertUniqueEntityinsertBygetByPersistUniqueReadputManyupsertByupsert insertUniquedeleteByPersistUniqueWrite#Database.Persist.Class.PersistStore insertRecord getEntity insertEntity belongsToJust belongsTo getJustEntitygetJust liftPersistpersistBackend BaseBackendHasPersistBackendIsPersistBackendprojectBackendBackendCompatiblePersistRecordBackendfromBackendKey toBackendKey ToBackendKey BackendKey PersistCoregetManygetPersistStoreRead updateGetreplace repsertManyrepsert insertKeyinsertEntityMany insertMany_ insertManyinsert_insertPersistStoreWrite$Database.Persist.Class.PersistEntityfromPersistValueJSONtoPersistValueJSONentityIdFromJSONentityIdToJSONkeyValueEntityFromJSONkeyValueEntityToJSON entityValues fieldLenspersistUniqueToValuespersistUniqueToFieldNamespersistUniqueKeysfromPersistValuestoPersistFieldspersistFieldDef entityDefpersistIdField keyFromValues keyToValuesUnique EntityFieldKeyPersistEntityBackend PersistEntityBackendSpecificUpdate entityVal entityKeyEntity#Database.Persist.Class.PersistFieldfromPersistValuetoPersistValue PersistFieldSomePersistFieldDatabase.Persist.Types.BasefromPersistValueTexttoEmbedEntityDefkeyAndEntityFieldsentityKeyFields entityPrimaryInactiveActive Checkmark NotNullableNullable IsNullableByNullableAttr ByMaybeAttr WhyNullableentityComments entitySum entityExtra entityDerivesentityForeigns entityUniques entityFields entityAttrsentityIdentityDB entityHaskell EntityDef ExtraLine unHaskellName HaskellNameunDBNameDBNameAttrFTListFTApp FTTypeCon FieldType fieldCommentsfieldReference fieldStrict fieldAttrs fieldSqlType fieldTypefieldDB fieldHaskellFieldDef SelfReference CompositeRefEmbedRef ForeignRef NoReference ReferenceDefembeddedFieldsembeddedHaskellEmbedEntityDef emFieldCycle emFieldEmbed emFieldDB EmbedFieldDef uniqueAttrs uniqueFields uniqueDBName uniqueHaskell UniqueDefcompositeAttrscompositeFields CompositeDefForeignFieldDefforeignNullable foreignAttrs foreignFieldsforeignConstraintNameDBNameforeignConstraintNameHaskellforeignRefTableDBNameforeignRefTableHaskell ForeignDefPersistMongoDBUnsupportedPersistMongoDBErrorPersistForeignConstraintUnmetPersistInvalidFieldPersistMarshalError PersistErrorPersistExceptionPersistDbSpecific PersistArrayPersistObjectId PersistMap PersistList PersistNullPersistUTCTimePersistTimeOfDay PersistDay PersistBoolPersistRational PersistDouble PersistInt64PersistByteString PersistText PersistValueSqlOtherSqlBlob SqlDayTimeSqlTimeSqlDaySqlBool SqlNumericSqlRealSqlInt64SqlInt32 SqlStringSqlTypeNotInInLeGeLtGtNeEq PersistFilter UpsertError KeyNotFoundUpdateExceptionOnlyUniqueExceptionDivideMultiplySubtractAddAssign PersistUpdate$Database.Persist.Class.PersistConfigrunPoolcreatePoolConfigapplyEnv loadConfigPersistConfigPoolPersistConfigBackend PersistConfig ExprParser TableAccesstableAccessTabletableAccessColumn parseOnExpr mkEscapeCharonExpr skipToEscapeparseEscapedIdentifierparseTableAccessparseEscapedChars$fEqTableAccess$fOrdTableAccess$fShowTableAccessRenderExprException!RenderExprUnexpectedECompositeKey SqlSelect sqlSelectColssqlSelectColCountsqlSelectProcessRow sqlInsertIntoModeSELECTDELETEUPDATE INSERT_INTOUnsafeSqlFunctionArgument toArgList OrderByTypeASCDESC NeedParensParensNever InsertFinalSqlExprEEntityEMaybeERaw ECompositeKeyEList EEmptyListEOrderBy EOrderRandom EDistinctOnESetEPreprocessedFromEInsert EInsertFinal IdentInfo IdentStateinUseIdentI LockingClause LimitClauseLimit OrderByClause HavingClause GroupByClauseGroupBy WhereClauseWhereNoWhere SetClause FromClause FromStartFromJoinOnClauseDistinctClause DistinctAllDistinctStandard DistinctOnSideDatasdDistinctClause sdFromClause sdSetClause sdWhereClausesdGroupByClausesdHavingClausesdOrderByClause sdLimitClausesdLockingClause SqlEntitySqlQueryQunQSqlBinOpCompositeErrorMismatchingLengthsErrorNullPlaceholdersErrorDeconstructionErrorUnexpectedCaseErrorEmptySqlExprValueList MakeFromErrorUnsupportedSqlInsertIntoTypeInsertionFinalErrorNewIdentForErrorUnsafeSqlCaseErrorOperationNotSupportedCompositeKeyErrorNotErrorToInsertionErrorCombineInsertionError FoldHelpError SqlCaseErrorSqlCastAsErrorMakeOnClauseError MakeExcError MakeSetErrorMakeWhereErrorMakeHavingErrorEsqueletoErrorCompositeKeyErrUnexpectedCaseErrSqlBinOpCompositeErrFromPreprocessfromPreprocessFromfrom_ToBaseIdBaseEnttoBaseIdWitness LockingKind ForUpdateForUpdateSkipLockedForShareLockInShareMode InsertionUpdateOrderByPreprocessedFrom$OnClauseWithoutMatchingJoinException IsJoinKind smartJoin reifyJoinKindJoinKind InnerJoinKind CrossJoinKindLeftOuterJoinKindRightOuterJoinKindFullOuterJoinKind FullOuterJoinRightOuterJoin LeftOuterJoin CrossJoin InnerJoin FinalResultfinalR KnowResult ToSomeValues toSomeValues SomeValue ValueListValueunValue fromStartfromStartMaybefromJoin fromFinishwhere_ongroupByorderByascdesclimitoffsetdistinct distinctOndondistinctOnOrderByrandhavinglocking sub_select subSelectsubSelectMaybesubSelectCount subSelectListsubSelectForeignsubSelectUnsafe^. withNonNull?.val isNothingjustnothingjoinV countRowscount countDistinctnot_==.>=.>.<=.<.!=.&&.||.+.-./.*.betweenrandom_round_ceiling_floor_sum_min_max_avg_castNumcastNumMcoalescecoalesceDefaultlower_upper_trim_rtrim_ltrim_length_left_right_likeilike%concat_++. castStringsubList_selectvalListjustListin_notInexists notExistsset=.+=.-=.*=./=.<#<&>case_toBaseIdwhen_then_else_ toUniqueDef renderUpdatesfrom collectIdentscollectOnClausesinitialIdentState newIdentForuseIdentparensM fieldNamesetAuxsub fromDBName existsHelperifNotEmptyList countHelper unsafeSqlCaseunsafeSqlBinOpunsafeSqlBinOpCompositeunsafeSqlValueunsafeSqlFunctionunsafeSqlExtractSubFieldunsafeSqlFunctionParensunsafeSqlCastAsveryUnsafeCoerceSqlExprValue veryUnsafeCoerceSqlExprValueListrawSelectSource selectSourceselect runSource rawEsqueleto deleteCountupdate updateCount builderToTexttoRawSqlrenderQueryToTextrenderQuerySelectrenderQueryDeleterenderQueryUpdaterenderQueryInsertIntouncommas intersperseB uncommas'makeInsertInto makeSelectmakeFrommakeSet makeWhere makeGroupBy makeHavingmakeOrderByNoNewline makeOrderBy makeLimit makeLockingparens getEntityValmaterializeExprfrom3Pfrom3to3from4Pfrom4to4from5Pfrom5to5from6Pfrom6to6from7Pfrom7to7from8Pfrom8to8from9Pfrom9to9from10Pfrom10to10from11Pto11from12Pto12from13Pto13from14Pto14from15Pto15from16Pto16 insertSelectinsertSelectCount renderExpr $fMonadValue$fApplicativeValue$fFunctorValue$fFinalResult->$fFinalResultUnique$fIsJoinKindFullOuterJoin$fIsJoinKindRightOuterJoin$fIsJoinKindLeftOuterJoin$fIsJoinKindCrossJoin$fIsJoinKindInnerJoin/$fExceptionOnClauseWithoutMatchingJoinException$fSqlStringMaybe$fSqlStringMarkupM$fSqlStringByteString$fSqlStringText$fSqlStringText0 $fSqlString[]$fExceptionEsqueletoError$fMonoidLimitClause$fSemigroupLimitClause$fShowFromClause$fMonoidWhereClause$fSemigroupWhereClause$fMonoidDistinctClause$fSemigroupDistinctClause$fMonoidGroupByClause$fSemigroupGroupByClause$fMonoidSideData$fSemigroupSideData$fApplicativeSqlQuery$fMonadSqlQuery$fFunctorSqlQuery$fFromPreprocessjoin$fFromPreprocessSqlExpr$fFromPreprocessSqlExpr0$fFrom(,,,,,,,)$fFrom(,,,,,,) $fFrom(,,,,,) $fFrom(,,,,) $fFrom(,,,) $fFrom(,,) $fFrom(,)$fFromFullOuterJoin$fFromRightOuterJoin$fFromLeftOuterJoin$fFromCrossJoin$fFromInnerJoin $fFromSqlExpr$fFromSqlExpr0$fToSomeValuesSqlExpr$fToSomeValues(,,,,,,,)$fToSomeValues(,,,,,,)$fToSomeValues(,,,,,)$fToSomeValues(,,,,)$fToSomeValues(,,,)$fToSomeValues(,,)$fToSomeValues(,)&$fUnsafeSqlFunctionArgument(,,,,,,,,,)%$fUnsafeSqlFunctionArgument(,,,,,,,,)$$fUnsafeSqlFunctionArgument(,,,,,,,)#$fUnsafeSqlFunctionArgument(,,,,,,)"$fUnsafeSqlFunctionArgument(,,,,,)!$fUnsafeSqlFunctionArgument(,,,,) $fUnsafeSqlFunctionArgument(,,,)$fUnsafeSqlFunctionArgument(,,)$fUnsafeSqlFunctionArgument(,)$fUnsafeSqlFunctionArgument[]"$fUnsafeSqlFunctionArgumentSqlExpr$fUnsafeSqlFunctionArgument()-$fSqlSelect(,,,,,,,,,,,,,,,)(,,,,,,,,,,,,,,,)+$fSqlSelect(,,,,,,,,,,,,,,)(,,,,,,,,,,,,,,))$fSqlSelect(,,,,,,,,,,,,,)(,,,,,,,,,,,,,)'$fSqlSelect(,,,,,,,,,,,,)(,,,,,,,,,,,,)%$fSqlSelect(,,,,,,,,,,,)(,,,,,,,,,,,)#$fSqlSelect(,,,,,,,,,,)(,,,,,,,,,,)!$fSqlSelect(,,,,,,,,,)(,,,,,,,,,)$fSqlSelect(,,,,,,,,)(,,,,,,,,)$fSqlSelect(,,,,,,,)(,,,,,,,)$fSqlSelect(,,,,,,)(,,,,,,)$fSqlSelect(,,,,,)(,,,,,)$fSqlSelect(,,,,)(,,,,)$fSqlSelect(,,,)(,,,)$fSqlSelect(,,)(,,)$fSqlSelect(,)(,)$fSqlSelectSqlExprValue$fSqlSelectSqlExprMaybe$fSqlSelectSqlExprEntity$fSqlSelect()()$fSqlSelectSqlExprInsertFinal$fExceptionRenderExprException $fEqValue $fOrdValue $fShowValue $fEqValueList$fOrdValueList$fShowValueList $fEqJoinKind$fShowJoinKind($fEqOnClauseWithoutMatchingJoinException)$fOrdOnClauseWithoutMatchingJoinException*$fShowOnClauseWithoutMatchingJoinException$fShowCompositeKeyError$fShowUnexpectedCaseError$fShowSqlBinOpCompositeError$fShowEsqueletoError $fEqIdent $fOrdIdent $fShowIdent$fShowRenderExprExceptionvalkeyvalJ deleteKey associateJoinAggMode AggModeAllAggModeDistinct maybeArrayunsafeSqlAggregateFunction arrayAggWitharrayAggarrayAggDistinct arrayRemovearrayRemoveNull stringAggWith stringAggchrnow_insertSelectWithConflictinsertSelectWithConflictCount $fShowAggMode JSONAccessor JSONIndexJSONKey JSONBExprJSONBunJSONBjsonbVal->.->>.#>.#>>.@>.<@.?|.?&.--.#-.base GHC.MaybeMaybeGHC.BasepureJustGHC.NumNum++&conduit-1.3.1.2-5UXb8HNx6uWHASv7zhhQVmData.Conduit.Internal.ConduitSourcefmap emptyArray Data.StringIsString Data.Foldablenull$fPersistFieldSqlJSONB$fPersistFieldJSONB$fNumJSONAccessor fromIntegerfromPersistValueErrorfromPersistValueParseErrornumErrbadParseNothing text-1.2.3.1Data.Text.InternalTextversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName