How to return a ref cursor from this dbms_sql?

Hi,
Can anyone show me how to return a ref cursor from this dbms_sql based procedure? I see 11g has a dbms_sql.to_refcursor(cursor_handle). How can this be done is 10g?
Thx.
CREATE OR REPLACE PROCEDURE Sample_Get_t
p_sample_id sample.sample_id%TYPE,
p_contract_id sample.contr_id%TYPE
IS
cursor_handle INT;
sql_stmnt varchar2(500);
rows_processed NUMBER;
BEGIN
sql_stmnt :=
'SELECT
sample_id,
contr_id,
rcpt_id
FROM
sample s
WHERE
s.contr_id = :1
and s.sample_id = :2
ORDER BY
sample_id';
cursor_handle := dbms_sql.open_cursor;
dbms_sql.parse(cursor_handle, sql_stmnt, dbms_sql.native);
dbms_sql.bind_variable(cursor_handle, ':1', p_contract_id);
dbms_sql.bind_variable(cursor_handle, ':2', p_sample_id);
rows_processed := dbms_sql.execute(cursor_handle);
dbms_sql.close_cursor(cursor_handle);
END Sample_Get_t;

In 10 this cannot be done with dbms_sql (to my knowledge). There are a couple of other options.
1) open the ref cursor for the dynamic statement using bind variables (or SYS_CONTEXT variables, which i prefer since they are much easier to deal with when you are dynamically adding predicates).
declare
   wRefCursor  SYS_REFCURSOR;
begin
   open wRefCursor for 'select * from all_objects where owner = :Logged_in_user' using user;
end;
/or using the context (the context will bind for you)
declare
   wRefCursor  SYS_REFCURSOR;
begin
   open wRefCursor for 'select * from all_objects where owner = SYS_CONTEXT(''CONTEXT_NAME'', ''VARIABLE_NAME'') ';
end;
/Be aware that contexts ALWAYS return varchar values, so if you are comparing to a number you should wrap it in TO_NUMBER, a date, TO_DATE and so on....
2) change the DBMS_SQL to do an insert into a global temporary table and return the ref cursor which select's * from GTT;
3) upgrade to Oracle 11 :)

Similar Messages

  • How return parameter ref Cursor from procedure using dynamic SQL?

    I sorry, but i very need help.
    I using Oracle 8.0.6
    I need to return parameter of type ref Cursor from procedure.
    create or replace package PlanExp is
    type cursortype is ref cursor;
    procedure ShowPlan (cursorparam out
    cursortype.............);
    end PlanExp;
    create or replace package body PlanExp is
    procedure ShowPlan (cursorparam out cursortype,
    .............) Is
    sql_str varchar2(1000);
    sql_str_select varchar2(100);
    sql_str_from varchar2(100);
    sql_str_where varchar2(500);
    Return_Code integer;
    Num_Rows integer;
    cur_id_sel integer;
    tSum_Plan DBMS_SQL.NUMBER_TABLE;
    tSum_Plan_Ch DBMS_SQL.NUMBER_TABLE;
    tSum_Plan_Day DBMS_SQL.NUMBER_TABLE;
    begin
    /* calculating string variables ........... /*
    sql_str := 'select ' || sql_str_select ||
    'from ' || sql_str_from ||
    'where ' || sql_str_where ||
    'group by ' || sql_str_select;
    cur_id_sel := dbms_sql.open_cursor;
    dbms_sql.parse(cur_id_sel, sql_str, dbms_sql.native);
    dbms_sql.define_array(cur_id_sel, 1, tSum_Plan, 20, 1);
    dbms_sql.define_array(cur_id_sel, 2, tSum_Plan_Ch, 20, 1);
    dbms_sql.define_array(cur_id_sel, 3, tSum_Plan_Day, 20, 1);
    Return_Code := dbms_sql.execute(cur_id_sel);
    delete from TEMP_SHOWPLAN;
    Loop
    Num_Rows := dbms_sql.Fetch_Rows(cur_id_sel);
    dbms_sql.column_value(cur_id_sel, 1, tSum_Plan);
    dbms_sql.column_value(cur_id_sel, 2, tSum_Plan_Ch);
    dbms_sql.column_value(cur_id_sel, 3, tSum_Plan_Day);
    if Num_Rows = 0 then
    exit;
    end if;
    Exit When Num_Rows < 20;
    End Loop;
    dbms_sql.close_cursor(cur_id_sel);
    end;
    end PlanExp;
    How return cursor (cursorparam) from 3 dbms_sql.column_value-s ?

    I am using Oracle 8.1.7, so I don't know if this will work in
    8.0.6 or not:
    SQL> CREATE TABLE test
      2    (col1                    NUMBER,
      3     col2                    NUMBER,
      4     col3                    NUMBER)
      5  /
    Table created.
    SQL> INSERT INTO test
      2  VALUES (1,1,1)
      3  /
    1 row created.
    SQL> INSERT INTO test
      2  VALUES (2,2,2)
      3  /
    1 row created.
    SQL> INSERT INTO test
      2  VALUES (3,3,3)
      3  /
    1 row created.
    SQL> CREATE TABLE temp_showplan
      2    (tSum_Plan               NUMBER,
      3     tSum_Plan_Ch            NUMBER,
      4     tSum_Plan_Day           NUMBER)
      5  /
    Table created.
    SQL> EDIT planexp
    CREATE OR REPLACE PACKAGE PlanExp
    IS
      TYPE CursorType IS REF CURSOR;
      PROCEDURE ShowPlan
        (cursorparam    IN OUT CursorType,
         sql_str_select IN     VARCHAR2,
         sql_str_from   IN     VARCHAR2,
         sql_str_where  IN     VARCHAR2);
    END PlanExp;
    CREATE OR REPLACE PACKAGE BODY PlanExp
    IS
      PROCEDURE ShowPlan
        (cursorparam    IN OUT CursorType,
         sql_str_select IN     VARCHAR2,
         sql_str_from   IN     VARCHAR2,
         sql_str_where  IN     VARCHAR2)
      IS
        sql_str                VARCHAR2 (1000);
        cur_id_sel             INTEGER;
        return_code            INTEGER;
      BEGIN
        DELETE FROM temp_showplan;
        sql_str := 'INSERT INTO   temp_showplan '
               || ' SELECT '   || sql_str_select
               || ' FROM '     || sql_str_from
               || ' WHERE '    || sql_str_where;
        cur_id_sel := DBMS_SQL.OPEN_CURSOR;
        DBMS_SQL.PARSE (cur_id_sel, sql_str, DBMS_SQL.NATIVE);
        return_code := DBMS_SQL.EXECUTE (cur_id_sel);
        DBMS_SQL.CLOSE_CURSOR (cur_id_sel);
        OPEN cursorparam FOR SELECT * FROM temp_showplan;
      END ShowPlan;
    END PlanExp;
    SQL> START planexp
    Package created.
    Package body created.
    SQL> VARIABLE g_ref REFCURSOR
    SQL> EXEC PlanExp.ShowPlan (:g_ref, 'col1, col2,
    col3', 'test', ' 1 = 1 ')
    PL/SQL procedure successfully completed.
    SQL> PRINT g_ref
    TSUM_PLAN TSUM_PLAN_CH TSUM_PLAN_DAY
             1            1             1
             2            2             2
             3            3             3

  • How to out Dynamic ref cursor from Procedure to Forms

    Hi
    I am trying to out Dynamic ref cursor from Procedure to Forms, But I am unable to do so. however cursor return the value within procedure but I am failed to capture the same in Forms
    Pl advice suggestion if any, Here I am attaching full procedure for reference
    CREATE PACKAGE winepkg
    IS
    TYPE wine IS RECORD ( mynumber number);
    /* Define the REF CURSOR type. */
    TYPE wine_type IS REF CURSOR RETURN wine;
    END winepkg;
    CREATE procedure find_wine
    (col1_in in number,
    c1 out winepkg.wine_type) as
    vsql varchar2(1000);
    cur sys_refcursor;
    x number;
    BEGIN
    vsql:='select bo_id from bo_details where bo_details.bo_id = '||col1_in ;
    open cur for vsql;
    c1:=cur;
    --fetch c1 into x;
    --dbms_output.put_line(x);
    END find_wine;
    In front end forms
    Declare
    TYPE F is REF CURSOR;
    CUR_F F;
    rec number;
    Begin
    break;
    find_wine( 1601480000011078,cur_f ) ;
    Loop
    fetch cur_f into rec ;
    Message(rec ) ;pause;
    exit when cur_f%notfound ;
    End loop ;
    exception
    when others then
    Message(sqlerrm) ;pause;
    End ;

    yo can use
    declare
    c_cursor EXEC_SQL.CursType;
    v_stmt varchar2(2000) = 'select a, b, c from mytab where cond1'; -- you can create this value dynamically
    begin
    c_cursor := Exec_SQL.Open_cursor;
    EXEC_SQL.PARSE(c_articulos, v_stmt);
    EXEC_SQL.DEFINE_COLUMN(c_articulos,1, v_colchar1, 30);
    EXEC_SQL.DEFINE_COLUMN(c_articulos,2, v_colchar2, 15);
    EXEC_SQL.DEFINE_COLUMN(c_articulos,3, v_colchar3, 30);
    v_exec := EXEC_SQL.EXECUTE(c_cursor);
    WHILE EXEC_SQL.FETCH_ROWS(c_cursor) > 0 LOOP
    EXEC_SQL.COLUMN_VALUE(c_cursor,1,v_colchar1);
    EXEC_SQL.COLUMN_VALUE(c_c_cursor,2,v_colchar2);
    EXEC_SQL.COLUMN_VALUE(c_c_cursor,3,v_colchar3);
    assign_values_to_block;
    END LOOP;
    EXEC_SQL.CLOSE_CURSOR(c_cursor);
    end;
    and WORKS IN FORMS 6

  • How to descrbe a ref cursor from a PL/SQL prog?

    Hi,
    here is a sample of the my problem
    let suppose a table country :
    create table country(country_code VARCHAR2(3), country_name VARCHAR2(50));
    then a package containing different procedures among them, this one :
    PL/SQL prog
    create or replace package country_pkg as
    type rec1 is ref cursor return country%rowtype;
    Procedure get_all_countries(rec in out rec1);
    blablabla ...
    END country_pkg;
    in the package body, i have the following code :
    create or replace package body country_pkg as
    procedure get_all_countries(rec IN OUT rec1) is
    begin
    if not rec%open then
    open rec for select * from country order by country_name;
    end if;
    exception
    when NO_DATA_FOUND then
    close rec;
    end get_all_countries;
    blablabla....
    end;
    Then in the C program
    (*proc)->request->command = "begin get_all_countries(:rec); end;"
    checkerr(&connect, \
         OCIStmtPrepare(connect->stmthp,\
         connect->errhp,\
         (*proc)->request->command,\
         strlen((*proc)->request->command),\
         OCI_NTV_SYNTAX, OCI_DEFAULT));
    checkerr(&connect, \
         OCIHandleAlloc((dvoid*)(connect->envhp),\
         (dvoid**) &((*proc)->stmthp), OCI_HTYPE_STMT,
    (size_t) 0,\
         (dvoid**) 0));
    bndhp = (OCIBind**) g_malloc0((*proc)->argnum*sizeof(OCIBind*));
    for(i = 0; i < (*proc)->argnum; i++)
    switch ((*proc)->desc->type)
    case 102:
    checkerr(&connect,
    OCIBindByPos(connect->stmthp, &bndhp[j],
    connect->errhp,
         i+1,&((*proc)->stmthp), (sb4) 0,
         SQLT_REF, (dvoid*) 0, (ub2*) 0, (ub2*) 0,
    (ub4) 0,
         (ub4*) 0, (ub4) OCI_DEFAULT));
    default:
    some code ....
    checkerr(&connect, \
         OCIStmtExecute(connect->svchp, connect->stmthp,\
         connect->errhp, 1, (ub4) 0, (OCISnapshot*) 0,\
         (OCISnapshot*) 0, OCI_DEFAULT));
    parm_status = OCIParamGet(connect->stmthp, OCI_HTYPE_STMT,connect->errhp, (dvoid**)&arg, 0);
    while(parm_status == OCI_SUCCESS)
    OCIAttrGet((dvoid*) arg, OCI_DTYPE_PARAM,
    (dvoid*)type,0, (ub4) OCI_ATTR_NUM_PARAMS,
    connect->errhp);
    counter++;
    parm_status = OCIParamGet(connect->stmthp,
    OCII_HTYPE_STMT,connect->errhp,
    (dvoid**)&arg, counter);
    This piece of code doesn't work as 'arg' is always NULL
    and OCIParamGet retruns OCI_SUCCESS.
    I'm certainly missing something but I don't see what. Could anyone help me to get that piece of code working?
    regards,
    Raphael

    unfortunately, not yet!
    I dropped the matter for now, I'll come back on it later.
    On your side, let me know if you find something interesting on that topic by posting a message here.

  • How to get an UPDATABLE REF CURSOR from the STORED PROCEDURE

    using C# with
    ORACLE OLE DB version: 9.0.0.1
    ADO version: 2.7
    I returns a REF CURSOR from a stored procedure seems like:
    type TCursor is ref cursor;
    procedure test_out_cursor(p_Dummy in varchar, p_Cur out TCursor) is
    begin
         open p_Cur for select * from DUAL;
    end;
    I create an ADO Command object and set
    cmd.Properties["IRowsetChange"].Value = true;
    cmd.Properties["Updatability"].Value = 7;
    cmd.Properties["PLSQLRSet"].Value = 1;
    cmd.CommandText = "{CALL OXSYS.TEST.TEST_OUT_CURSOR(?)}";
    and I use a Recordset object to open it:
    rs.Open(cmd, Missing.Value,
    ADODB.CursorTypeEnum.adOpenStatic,
    ADODB.LockTypeEnum.adLockBatchOptimistic,
    (int) ADODB.CommandTypeEnum.adCmdText +
    (int) ADODB.ExecuteOptionEnum.adOptionUnspecified);
    The rs can be opened but can NOT be updated!
    I saved the recordset into a XML file and there's no
    rs:baseschema/rs:basetable/rs:basecolumn
    attributes for "s:AttributeType" element.
    Any one have idea about this?
    thanks very much

    It is not possible through ADO/OLEDB.
    Try ODP.NET currently in Beta, it is possible to update DataSet created with refcursors. You need to specify your custom SQL or SP to send update/insert/delete.
    As I remember there is a sample with ODP.NET Beta 1 just doing this.

  • Return ref cursor from database link/stored proc? do-able?

    Is it possible to return a REF CURSOR from a stored procedure that is being called from a remote database via a database link???
    We are trying from Pro*Cobol on MVS (which has db link pointing to AIX thru db link) and get a 00993 error, which seems to say this is not possible.
    Before I give up, thought I would check with the experts....
    Thanks in advance.

    You can't return Java objects as stored procedure or query results.
    Douglas

  • How to handle the ref cursor which is returning "no rows"

    I have written a function which is returning the REF CURSOR. But in one situation the REF CURSOR returns "no rows selected". To handle this situation an exception is raised "when no data found". But i dont know in this situation how should NULL cursor be returned through this function. Since I want to call this function in another procedure so something should be returned through this function by means of ref cursor. But since i am not able to handle this "no rows selected" situation i am not able move further.
    Thanks in advance........

    I agree.
    You would simply process the returned ref cursor irrespective of any rows actually returned in the cursor or not. You would be able to do at least one FETCH from the cursor (even if it does not actually contain any rows) and then determine the %NOTFOUND status to do the rest of the processing.
    SQL> variable cur refcursor
    SQL> exec open :cur for select * from scott.emp where rownum = 1 ;
    PL/SQL procedure successfully completed.
    SQL> print cur
         EMPNO ENAME      JOB              MGR HIREDATE           SAL       COMM     DEPTNO
          7369 SMITH      CLERK           7902 17-DEC-1980        800                    20
    1 row selected.
    SQL>
    SQL> exec open :cur for select * from scott.emp where 1 = 2 ;
    PL/SQL procedure successfully completed.
    SQL> print cur
    no rows selected
    SQL>
    SQL> SET SERVEROUTPUT ON
    SQL> DECLARE
      2      rec scott.emp%ROWTYPE;
      3      bol BOOLEAN;
      4      cur sys_refcursor;
      5  BEGIN
      6      OPEN cur FOR
      7          SELECT * FROM scott.emp WHERE 1 = 2; /* assume this is your function call returning a ref cursor */
      8      bol := FALSE;
      9      LOOP
    10          FETCH cur
    11              INTO rec;
    12          EXIT WHEN cur%NOTFOUND;
    13          --
    14          -- process the data here
    15          --
    16          bol := TRUE;
    17      END LOOP;
    18      CLOSE cur;
    19      IF (bol)
    20      THEN
    21          dbms_output.put_line('At least one row was found');
    22      ELSE
    23          dbms_output.put_line('No rows were selected');
    24      END IF;
    25  END;
    26  /
    No rows were selected
    PL/SQL procedure successfully completed.
    SQL>

  • Populate a REF CURSOR from regular cursor...

    Hi all,
    I apologize if the answer to this is somewhere...I've been looking on the web for sometime and can't find an answer to the following problem. I have a Significant Events database that contains network based issues and problems. As problems are detected on the network an SE is issued and published. As the SE records are updated, NEW records are entered into the table and "linked" back to the original. Each update results in a new row. Thus, an SE with two updates would have a total of 3 lines. When the SE gets closed (set the column CLOSED to SYSDATE), only the "original" SE is closed, any updates are left open...aka, the CLOSED column is left null.
    That said, I need a way to get the original and/or latest updated SE rows from the table. Thus, I am trying to use a PL/SQL package. The PL/SQL "must" return a REF CURSOR as the results are being passed to a client process.
    My initial approach was within a PL/SQL procedure, I have an SQL statement that returns the SE originals. Once in that cursor I need to do the following:
    - Attempt to fetch any linked SE rows.
    - if no rows then
    - add the original to the REF CURSOR.
    - else
    - find latest SE update
    - add latest SE update to REF CURSOR.
    - end if
    My Question is : How do I manually "add" a row to a REF CURSOR?
    If this is not possible, is there a way to populate a REF CURSOR from maybe another construct like:
    TYPE ian_se_record is RECORD (
    se_id number
    ,linked_se_id number
    ,submitted date
    ,updated date
    ,closed date
    ,segroup varchar2(150)
    ,incident_start_time varchar2(150)
    ,business_units_affected varchar2(150)
    ,officenum varchar2(1500)
    ,sedetails varchar2(4000)
    TYPE ian_se_table is table of ian_se_record index by binary_integer;
    With the above construct I could:
    - Fill ian_se_table with the process described above.
    - And finally select off ian_se_table into the REF CURSOR?
    Any help would be greatly appreciated,
    adym

    Hi michaels,
    I've put your solution in place, but can't seem to get it to run. The two types were moved out of the package and into real types as you said. Here's the function, for brevity, I've remove some of the less important code:
    function ian_se_fetch return sys_refcursor
    is
        p_csr_events            sys_refcursor;
        cursor csr_items is
            select
                 se_id
        ...removed for brevity...
        /* END : csr_items  */
        ian_se_row     ian_se_record;
        ian_se_tbl     ian_se_table;
        l_lng_index    number;
        l_lng_linked   number;
        l_lng_id       number;
    begin
         * OPEN : Open the main cursor of originals...
        for the_item in csr_items loop
             * CHECK : Check for any updates to the original...
            l_lng_linked := 0;
            select count(*)
            into l_lng_linked
            from sig_se_t src
            where src.linked_se_id = the_item.se_id;
            l_lng_id := 0;    /* reset the se-id    */
            /* SE original...no linked records yet.    */
            if ( l_lng_linked = 0 ) then
                l_lng_id := the_item.se_id;
            /* SE updates...one or more updates are present.    */
            else
                begin
                    select
                         se_id
                    into l_lng_id
                    from sig_se_t src
                    where src.linked_se_id = the_item.se_id
                      and rownum = 1
                    order by updated desc; /* latest update    */
                exception
                    when too_many_rows then
                        l_lng_id := the_item.se_id;
                    when others then
                        l_lng_id := 0;
                end;
            end if;
            if ( l_lng_id != 0 ) then
                select
                     se_id
                    ,linked_se_id
                    ,submitted
                    ,updated
                    ,closed
                    ,segroup
                    ,incident_start_time
                    ,business_units_affected
                    ,officenum || decode( nvl(impact,'1')
                                      ,'1',''
                                      ,decode(impact
                                          ,'NA', ''
                                          ,':' || impact
                                  )                           impact
                    ,sedetails
                into ian_se_row.se_id
                    ,ian_se_row.linked_se_id
                    ,ian_se_row.submitted
                    ,ian_se_row.updated
                    ,ian_se_row.closed
                    ,ian_se_row.segroup
                    ,ian_se_row.incident_start_time
                    ,ian_se_row.business_units_affected
                    ,ian_se_row.officenum
                    ,ian_se_row.sedetails
                from sig_se_t src
                where src.se_id = l_lng_id;
                l_lng_index := nvl(ian_se_tbl.last,0)+1;
                ian_se_tbl(l_lng_index).se_id                   := ian_se_row.se_id;
                ian_se_tbl(l_lng_index).linked_se_id            := ian_se_row.linked_se_id;
                ian_se_tbl(l_lng_index).submitted               := ian_se_row.submitted;
                ian_se_tbl(l_lng_index).updated                 := ian_se_row.updated;
                ian_se_tbl(l_lng_index).closed                  := ian_se_row.closed;
                ian_se_tbl(l_lng_index).segroup                 := ian_se_row.segroup;
                ian_se_tbl(l_lng_index).incident_start_time     := ian_se_row.incident_start_time;
                ian_se_tbl(l_lng_index).business_units_affected := ian_se_row.business_units_affected;
                ian_se_tbl(l_lng_index).officenum               := ian_se_row.officenum;
                ian_se_tbl(l_lng_index).sedetails               := ian_se_row.sedetails;
            end if;
        end loop;
         * REF CURSOR : Open the ref cursor on the dataset...
        if ( nvl(ian_se_tbl.last,0) = 0 ) then
            p_csr_events := null;
        else
            open p_csr_events for
            select *
            from table (cast ( ian_se_tbl as ian_se_table ));
        end if;
        return p_csr_events;
    end;Here's the test. I keep getting the same error ORA-06530:
    SQL> variable v refcursor;
    SQL> exec :v:=pkg_ian.ian_se_fetch;
    BEGIN :v:=pkg_ian.ian_se_fetch; END;
    ERROR at line 1:
    ORA-06530: Reference to uninitialized composite
    ORA-06512: at "N0002501.PKG_IAN", line 131
    ORA-06512: at line 1
    SQL> print v
    ERROR:
    ORA-24338: statement handle not executedOther things I tried:
    - The ian_se_fetch() function was a procedure using an in out parameter...same error.
    - Wrote a small anonymous block and tried to LOOP/FETCH. Same ORA-06530 error.
    P.S. Line 131 of pkg_ian is the SELECT ... INTO ian_se_row.se_id, ...
    Any help would be greatly appreciated,
    tia,
    adym
    Message was edited by:
    alink

  • Plsql use a function which returns a ref cursor

    Hi
    I've been using an function which returns a ref cursor. I've been returning this into a java resultset. Fine!
    Now i'm in plsql and want to use the same function. I'm not sure how to get this resultset in plsql.

    It's not very practical to use a refcursor like you want to, but here you go
    create or replace function test_ref
    return sys_refcursor
    is
    v_rc sys_refcursor;
    begin
    open v_rc for select emp_name  from emp ;
    return v_rc;
    end;
    declare
    v_rc sys_refcursor;
    v_emp_name emp.emp_name%type;
    begin
    v_rc :=  test_ref ;
    loop
        fetch v_rc into v_emp_name ;
        exit when v_rc%notfound ;
        dbms_output.put_line('Employee Name: '||v_emp_name );
    end loop;
    end;                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How do I stop the cursor from spontaneously going to Line one space one in Notes?

    How do I stop the cursor from spontaneously going to Line one Space one in Notes?
    I am currently working on a MacBook Pro connected by Wi-Fi or Blue Tooth to my 16GB iPhone 4S; and supposedly to iCloud.  I install every upgrade on each computer till the computer can take no more.  My current MacBook Pro continues to accept upgrades.
    I have been dealing with Address Book foibles since it first came out and the problems seem to get worse rather than resolved.
    Problem #1: When a Company Name is checked to take precedence over a personal name the record/file does not surface during searches.  This has happened for years on all my Macs, including most recently my MacBook Pro and its predecessor PowerBook G4.  How do I fix this?
    Problem #2: The Printing Defaults for Address Book Files are not useful and I can find no way to change them to my own preferences once and for all.  I must reset them for every file every time I choose to print a file.  Is there some way to set the defaults to MY preferences and only occasionally reset them according to my needs?
    Problem #3:  When entering information in "Notes" the cursor randomly and spontaneously goes to line one space one as I am entering information.  How do I stop this?  Then when I cut and paste the misplaced text to where it belongs it may or may not return to once again begin at line one space one and following.
    Problem #4:  When Printing a Record/File from Address Book I would like to use the whole 8.5" x 11" page.  Instead it prints on an 8.5" x 11" page in three columns.  Is there a way to format the output?  I have not found one and the Mac 'Geniuses' do not know of any.
    Problem #5:  Subsequent to one of the upgrades in the last year or so, the search feature does not work.  (I have had this computer since May 2011).  No matter what I type in the search line I am stuck in the 'All' Directory.  To find anyone or anything I must scroll through the address book manually.  Is there a fix to this?
    Problem #6:  Sometimes, when I try to sync my MacBook Pro and my iPhone, the records simply duplicate.  How d I undo this without manually deleting the duplicates?
    Problem #7:  Does anyone know of a third party Address-Book-type App that is better than the Apple version and can easily import over 3000 contacts information?

    '''I had the same problem when I updated to firefox 4. This is how i fixed it:'''
    The problem seems to be caused by the 'New Tab Homepage' add on. So:
    # Disable or remove the 'New Tab Homepage' add on and restart firefox.
    # Download and install the firefox add on called 'NewTabURL' and restart firefox.
    # Click on the Options button for NewTabURL and uncheck 'Select location bar after loading new tab'
    # Under the 'Default URL for new tabs' heading, choose 'Home Page'
    # Click on the Save button.
    Hopefully, problem solved!

  • Function call returned in ref cursor

    We have a ref cursor that calls a function in a package. When ODP.NET reads the cursor, it can't see what the function is returning. OO4O works fine, and if I take the sql that populates the ref cursor and put it into a temporary table, then select from that temporary table to return the ref cursor to ODP, it works fine. Anyone else seen this issue? Any help would be appreciated. Thanks.
    Eric Schrauth
    [email protected]

    Did you set the parameter direction to be ParameterDirection.Input when you created the parameter? Post your code.

  • Returning a ref cursor on a Global Temporary table

    I realize this is probably not feasible but I am manipulating data and storing it in a GTT and I wish to return that transformed data out as a ref cursor is this possible to do? I also dont want a static table because this is a heavily hit procedure and I do not want to have to keep track of which session is which data not to mention contention between them.
    I am using Oracle 10g on Windows server 2008

    You will be able to see the records in the refcursor in the same session
    Example
    SQL> create global temporary table X_GTT as select * from emp where 1=2;
    Table created.
    SQL> insert into x_GTT select * from emp ;
    14 rows created.
    SQL> var rf refcursor ;
    SQL> begin
      2    open :rf for select * from X_GTT ;
      3  end ;
    PL/SQL procedure successfully completed.
    SQL> print rf
         EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM     DEPTNO
          7369 SMITH      CLERK           7902 17-DEC-80        800                    99
          7499 ALLEN      SALESMAN        7698 20-FEB-81       1600        300         30
          7521 WARD       SALESMAN        7698 22-FEB-81       1250        500         30
          7566 JONES      MANAGER         7839 02-APR-81       2975                    20
          7654 MARTIN     SALESMAN        7698 28-SEP-81       1250       1400         30
          7698 BLAKE      MANAGER         7839 01-MAY-81       2850                    30
          7782 CLARK      MANAGER         7839 09-JUN-81       2450                    10
          7788 SCOTT      ANALYST         7566 19-APR-87       3000                    20
          7839 KING       PRESIDENT            17-NOV-81       5000                    10
          7844 TURNER     SALESMAN        7698 08-SEP-81       1500          0         30
          7876 ADAMS      CLERK           7788 23-MAY-87       1100                    20
          7900 JAMES      CLERK           7698 03-DEC-81        950                    30
          7902 FORD       ANALYST         7566 03-DEC-81       3000                    20
          7934 MILLER     CLERK           7782 23-JAN-82       1300                    10
    14 rows selected.SS

  • How to open a Ref cursor in Oracle Reports

    I have a stored procedure that returns a ref cursor as an output parameter. I want to call this stored procedure in Oracle Reports After Form trigger. I am having trouble with the syntax of the output parameter. Event_record is the name of the cursor.
    After Form Trigger
    pkg_DEAL_WHITESHEET_CONCERTS.prc_Event_Information(:p_field_6,event_record);
    Error: Event_record must be declared

    Re-Write the procedure as Package Spec and Body. Declare the REFCursor in the Package Spec. Probably that helps.

  • Ref cursor from anonymous block

    I have no problem to get a ref cursor from a Fill method call with an anonymous pl/sql block. But if my anonymous block contains a DECLARE section, the dataset is not populated.
    ex:
    BEGIN OPEN :cuInscription FOR SELECT column FROM table; END;
    is ok but with
    DECLARE A NUMBER; BEGIN OPEN :cuInscription FOR SELECT column FROM table; END;
    the dataset is not populated (even if the SQL CALL succeed).
    Do you know about that?

    This issue has been fixed in the ODP.NET 92040 release.

  • How do i keep my cursor from jumping around when i am typing

    how do i keep my cursor from jumping around when i am typing [email protected]
    == This happened ==
    Every time Firefox opened
    == none

    Check your settings in System Preferences >  Trackpad
    Try a different Tracking speed.
    Sometimes just cleaning the trackpad can avoid erratic cursor behavior.
    How to clean Apple products

Maybe you are looking for