Powerbuilder/DBMS2010. 1. 14. 14:46
//해당 조건에 해당하는 pin 찾기
DECLARE out_pin DYNAMIC CURSOR FOR SQLSA;

ls_sql += "Select pid, contno From p_cardmst where sale_flag <> '0' And " + &
        "status = '" + ls_status_1 + "' "//And partner_prefix = '" + ls_mainoffice + "' "
If ls_where <> "" Then ls_sql += ls_where
ls_sql += "Order by contno, pid"

      PREPARE SQLSA FROM :ls_sql;
OPEN DYNAMIC out_pin;
Do While(True)
Yield()
FETCH out_pin
INTO :ls_pid, :ls_contno;










Posted by Julyus