I have the following procedure executing some business logic (looping through a cursor):
PROCEDURE myproc() AS
  CURSOR mycur IS
    SELECT * FROM mytable;
BEGIN
  FOR c IN mycur LOOP
    ...business logic here...
    ...many lines of code...
  END LOOP;
END myproc;
I'd like to have different procedures and execute the same business logic for different cursors (sets of data). For example I'd like to have one procedure myproc_adopters() for:
SELECT * FROM mytable WHERE cutomer_type='Adopters'
and another procedure myproc_others() for others:
SELECT * FROM mytable WHERE customer_type!='Adopters'
So I'd like to have one main procedure mainproc() containing cursor loop and business logic and other procedures calling this main procedure and sending different cursors as parameters. The problem is that it seems that cursor FOR loop does not accept cursor as variable that I can send as procedure call parameter:
PROCEDURE myproc_adopters() AS
  CURSOR mycur IS
    SELECT * FROM mytable WHERE customer_type='Adopters';
BEGIN
  mainproc(mycur);
END myproc_adopters;
PROCEDURE myproc_others() AS
  CURSOR mycur IS
    SELECT * FROM mytable WHERE customer_type!='Adopters';
BEGIN
  mainproc(mycur);
END myproc_others;
PROCEDURE mainproc(mycur IN SYS_REFCURSOR) AS
BEGIN
  FOR c IN mycur LOOP <-- does not accept cursor as variable
  ...
  END LOOP;
END mainproc;
How to send different cursor to the same cursor FOR LOOP?