Hoogle Search

Within LTS Haskell 24.57 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. repsertMany :: forall record (m :: Type -> Type) . (PersistStoreWrite backend, MonadIO m, PersistRecordBackend record backend) => [(Key record, record)] -> ReaderT backend m ()

    persistent-redis Database.Persist.Redis

    Put many entities into the database. Batch version of repsert for SQL backends. Useful when migrating data from one entity to another and want to preserve ids.

    Example usage

    With schema-1 and dataset-1,
    repsertManyUsers :: MonadIO m =>ReaderT SqlBackend m ()
    repsertManyusers = repsertMany [(simonId, User "Philip" 20), (unknownId999, User "Mr. X" 999)]
    
    The above query when applied on dataset-1, will produce this:
    +-----+----------------+---------+
    |id   |name            |age      |
    +-----+----------------+---------+
    |1    |SPJ             |40       |
    +-----+----------------+---------+
    |2    |Simon -> Philip |41 -> 20 |
    +-----+----------------+---------+
    |999  |Mr. X           |999      |
    +-----+----------------+---------+
    

  2. executeMany :: forall q (m :: Type -> Type) . (ToRow q, MonadIO m) => Query -> [q] -> DBT m Int64

    pg-transact Database.PostgreSQL.Transact

    Execute a multi-row INSERT, UPDATE, or other SQL query that is not expected to return results. Returns the number of rows affected. If the list of parameters is empty, this function will simply return 0 without issuing the query to the backend. If this is not desired, consider using the Values constructor instead. Throws FormatError if the query could not be formatted correctly, or a SqlError exception if the backend returns an error. For example, here's a command that inserts two rows into a table with two columns:

    executeMany [sql|
    INSERT INTO sometable VALUES (?,?)
    |] [(1, "hello"),(2, "world")]
    
    Here's an canonical example of a multi-row update command:
    executeMany [sql|
    UPDATE sometable
    SET sometable.y = upd.y
    FROM (VALUES (?,?)) as upd(x,y)
    WHERE sometable.x = upd.x
    |] [(1, "hello"),(2, "world")]
    

  3. RestartOnAny :: TerminalMode

    posix-pty System.Posix.Pty

    IXANY - Enable any character to restart output

  4. fdw_too_many_handles :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    FDW_TOO_MANY_HANDLES: HV014 (Error)

  5. too_many_arguments :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_ARGUMENTS: 54023 (Error)

  6. too_many_columns :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_COLUMNS: 54011 (Error)

  7. too_many_connections :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_CONNECTIONS: 53300 (Error)

  8. too_many_json_array_elements :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_JSON_ARRAY_ELEMENTS: 2203D (Error)

  9. too_many_json_object_members :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_JSON_OBJECT_MEMBERS: 2203E (Error)

  10. too_many_rows :: ByteString

    postgresql-typed Database.PostgreSQL.Typed.ErrCodes

    TOO_MANY_ROWS: P0003 (Error)

Page 245 of many | Previous | Next