Close a database

saf_close_database is a function defined in db.c.

Synopsis:

int saf_close_database(SAF_Db *database)

Formal Arguments:

  • database: The open database to be closed.

Description: This function closes an open database, database, freeing all resources associated with that database.

Preconditions:

  • database must be a database handle. (low-cost)
  • database must currently be open. (low-cost)

Return Value: The constant SAF__SUCCESS is returned when this function is successful. Otherwise this function either returns an error number or throws an exception, depending on the value of the library’s error handling property.

Parallel Notes: This is a collective, SAF__ALL mode function which should be called across all processes in the database’s communicator.

See Also:

  • Databases: Introduction for current chapter