| cqgnrecord | "Catquery | cqgnrecord |
cqgnrecord -- get the next record from the catalog results
stat = cq_gnrecord (res, buf, maxch, nextrec)
pointer res # the results descriptor char buf # the output record buffer int maxch # the maximum size of the output record buffer int recno # the next available record number
Cq_gnrecord returns the requested record. Cq_grecord is an integer function which returns BOF, the number of characters in the record, or EOF as its function value.
In most cases allocating a buffer size that is SZ_LINE chars long will be adequate to hold the output record. If the integer results parameter CQRECSIZE is defined, i.e. non-zero, then an output buffer CQRECSIZE chars long can be allocated.
pointer cq_query() int cq_gnrecord()
res = cq_query (cq) recno = 0 while (cq_gnrecord (res, record, SZ_LINE, recno) != EOF) { call printf ("%s") call pargstr (record) } call cq_rclose (res)