Used to fetch data from the REFCURSOR parameter or REFCURSOR field.
property Cursor: TPgRefCursor;
Use the Cursor property to fetch data from the REFCURSOR parameter or REFCURSOR field. You can assign the value of TPgParam.AsCursor or TPgCursorField.AsCursor to the Cursor property. After assigning you can open the dataset once.
PgQuery1.Cursor := PgSQL1.ParamByName('Cur').AsCursor;
PgQuery1.Open;