Has - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


PersistentTable

  

Has

  

query a PersistentTable connection for the existence of a row

 

Calling Sequence

Parameters

Description

Thread Safety

Examples

Compatibility

Calling Sequence

Has(connection, keys)

Parameters

connection

-

PersistentTable object created with the Open command

keys

-

expression sequence of values for the key columns

Description

• 

The Has command returns true if the given connection contains a row with the given values in the primary key columns, and false otherwise.

Thread Safety

• 

Persistent tables are in general thread safe as of Maple 2021; see the Thread Safety section of the PersistentTable overview page for more details and caveats.

• 

For more information on thread safety, see index/threadsafe.

Examples

withPersistentTable

Close,Count,Get,GetAll,GetKeys,Has,MaybeGet,Open,RawCommand,Set

(1)

connectionOpen:memory:,style=k1::anything,k2::integer,v::anything,primarykey=2

connection<< 3-column persistent table at :memory: >>

(2)

connectionx,3y2

connectionx,3y2

(3)

connectionz,5y3

connectionz,5y3

(4)

Hasconnection&comma;x&comma;3

true

(5)

Hasconnection&comma;a&comma;4

false

(6)

Closeconnection

Compatibility

• 

The PersistentTable[Has] command was introduced in Maple 2021.

• 

For more information on Maple 2021 changes, see Updates in Maple 2021.

See Also

PersistentTable

PersistentTable[Open]