db_lookup

Function db_lookup 

Source
pub fn db_lookup(
    contract_id: ContractId,
    db_name: &str,
) -> GenericResult<DbHandle>
Expand description

Open an existing on-chain database instance for the given contract. A contract is able to read any on-chain database.

Returns a DbHandle which is used with methods for reading and writing.

ยงPermissions

  • ContractSection::Deploy
  • ContractSection::Metadata
  • ContractSection::Exec
  • ContractSection::Update