Initializes a typed iterator that concatenates one sequence field across all class objects visited by a cursor.
MCO_RET classname_fieldname_from_cursor(
mco_trans_h transaction,
mco_seq_iterator_h iterator,
mco_cursor_h cursor);
Traversal starts at the first cursor entry, visits objects in cursor order, skips empty sequence fields, and yields every logical field element before moving to the next object. No delimiter or object identifier is inserted between fields.
The iterator is lazy and borrows both transaction and cursor. Do not close,
reposition, or reuse the cursor independently while the sequence iterator is active. The cursor must
address the class for which the generated function was created.
mco_cursor_t cursor;
mco_seq_iterator_t all_readings;
MCO_RET rc;
rc = Sensor_by_id_index_cursor(transaction, &cursor);
if (rc == MCO_S_OK) {
rc = Sensor_readings_from_cursor(transaction, &all_readings, &cursor);
}
Initialization normally returns MCO_S_OK. Cursor, object, and field access errors can also be
reported during lazy traversal. Successful traversal ends with MCO_S_CURSOR_END.