create or replace package PkgTest is
  type TCursor is ref cursor;  procedure GetTableUsers(Pr_id in varchar2, p_Cursor out TCursor);
end PkgTest;
/
create or replace package body PkgTest is
  procedure GetTableUsers(Pr_id in varchar2, p_Cursor out TCursor) is
    v_SQL varchar2(1024);
  begin
    v_SQL  := 'select * from users where pr_id=' || Pr_id;
    open p_Cursor for
      v_SQL;
  end GetTableUsers;
end PkgTest;
/