-## retrieve (list_id = m.#list_id, member_id = m.#member_id,
-## mtype = m.member_type, ref_count = m.#ref_count,
-## dflag = m.#direct) {
+/* retrieve (list_id = m.#list_id, member_id = m.#member_id,
+ * mtype = m.member_type, ref_count = m.#ref_count,
+ * dflag = m.#direct) { */
+ EXEC SQL DECLARE csrm2 CURSOR FOR
+ SELECT list_id, member_id, member_type, ref_count, direct
+ FROM imembers;
+ EXEC SQL OPEN csrm2;
+ while(1) {
+ EXEC SQL FETCH csrm2
+ INTO :list_id, :member_id, :mtype, :ref_count, :dflag;
+ if(sqlca.sqlcode != 0) break;
+