WYRDTEK Home Features Reference Downloads About


Reference/es_mbi_copyrelfetch

Syntax

int es_mbi_copyrelfetch( struct es_mbi *tgtiter, struct es_mbn *tgtnode, struct es_mbi *srciter );

Arguments

struct es_mbi *tgtiter Target database node iterator.
struct es_mbn *tgtnode Database node.
struct es_mbi *srciter Source database node iterator.

Return Codes

ES_ERROR_NONE Success. No errors.
ES_INVALIDBINDING Field-binding associated with tgtiter is for a different database class than that of tgtnode.
ES_ERROR_FAILTOFIND Failed to locate relative iterator position.

Description

Copy relative iterator position to tgtiter with respect to tgtnode node and fetch row contents. This effectively looks up the row in tgtnode that has the same index field values as the row currently pointed at by the srciter iterator.

This operation is only relevent for nodes that have a ES_INDEX_SHARED index type as all such node instances share a common index.

tgtnode must share the same class (or a valid subclass) as the node currently pointed at by srciter.

Even though two nodes may share a common index, not all rows may be populated so this function may return ES_ERROR_FAILTOFIND if the corresponding row in tgtnd does not exist.

[Back To Reference] [Back To Reference/es_mbi]