Execution of query......?

Hello
  Lets assume that I have a query that i want to execute every day evening 5'O clock.
How would i schedule this execution in the reporting?
Please let me know the solution for this
Iam waiting for your inputs
thanks & regards
dj reddy

find more info in the following links:
http://help.sap.com/saphelp_nw04/helpdata/en/28/734d3caa70ea6fe10000000a114084/content.htm
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/biw/2.0/2.0b reporting agent incl. precalculating web templates.pdf

Similar Messages

  • Direct Execution of query having Unicode Characters

    Direct Execution of query having Unicode Characters
    Hi All,
    In my application I am firing a Select Query having Unicode characters in Where Clause under condition like '%%'
    to Oracle 10g DB from a Interface written in VC6.0...
    Application funcationality is working fine for ANSI characters and getting the result of Select properly.
    But in case of Unicode Characters in VC it says 'No Data Found'.
    I know where the exact problem is in my code. But not getting the exact solution for resolving my issue...
    Here with I am adding my code snippet with the comments of what i understand and what i want to understand...
    DBPROCESS Structure used in the functions,_
    typedef struct
    HENV hEnv;
    HDBC hDbc;
    HSTMT hStmt;
    char CmdBuff[[8192]];
    char RpcParamName[[255]];
    SQLINTEGER SpRetVal;
    SQLINTEGER ColIndPtr[[255]];
    SQLINTEGER ParamIndPtr[[255]];
    SQLPOINTER pOutputParam;
    SQLUSMALLINT CurrentParamNo;
    SQLUSMALLINT OutputParamNo;
    SQLUSMALLINT InputParamCtr;
    SQLINTEGER BatchStmtNo;
    SQLINTEGER CmdBuffLen;
    short CurrentStmtType;
    SQLRETURN LastStmtRetcode;
    SQLCHAR SqlState[[10]];
    int ShowDebug;
    SQLCHAR* ParameterValuePtr;
    int ColumnSize;
    DBTYPE DatabaseType;
    DRVTYPE OdbcDriverType;
    BLOCKBIND *ptrBlockBind;
    } DBPROCESS;
    BOOL CDynamicPickList::GetResultSet(DBPROCESS *pDBProc, bstrt& pQuery, short pNumOdbcBindParams, COdbcBindParameter pOdbcBindParams[], CQueryResultSet& pQueryResultSet)
         int               lRetVal,
                        lNumRows;
         bstrt               lResultSet;
         wchar_t               lColName[[256]];     
         SQLUINTEGER          lColSize;
         SQLSMALLINT          lColNameLen,
                        lColDataType,
                        lColNullable,
                        lColDecDigits,                         
                        lNumResultCols;
         wchar_t               lResultRow[[32]][[256]];
    OdbcCmdW(pDBProc, (wchar_t *)pQuery); *//Query is perfectly fine till this point all the Unicode Characters are preserved...*
         if ( OdbcSqlExec(pDBProc) != SUCCEED )
              LogAppError(L"Error In Executing Query %s", (wchar_t *)pQuery);          
              return FALSE;
    Function OdbcCmdW_
    //From this point have no idea what is exactly happening to the Unicode Characters...
    //Actually i have try printing the query that gets stored in CmdBuff... it show junk for Unicode Characters...
    //CmdBuff is the Char type Variable and hence must be showing junk for Unicode data
    //I have also try printing the HexaDecimal of the query... I m not getting the proper output... But till i Understand, I think the HexaDecimal Value is perfect & preserved
    //After the execution of this function the call goes to OdbcSqlExec where actual execution of qurey takes place on DB
    SQLRETURN OdbcCmdW( DBPROCESS p_ptr_dbproc, WCHAR      p_sql_command )
         char *p_sql_commandMBCS;
         int l_ret_val;
         int l_size = wcslen(p_sql_command);
         int l_org_length,
    l_newcmd_length;
    p_sql_commandMBCS = (char *)calloc(sizeof(char) * MAX_CMD_BUFF,1);
    l_ret_val = WideCharToMultiByte(
                        CP_UTF8,
                        NULL,                         // performance and mapping flags
                        p_sql_command,          // wide-character string
                        -1,                         // number of chars in string
                        (LPSTR)p_sql_commandMBCS,// buffer for new string
                        MAX_CMD_BUFF,                    // size of buffer
                        NULL, // default for unmappable chars
                        NULL // set when default char used
    l_org_length = p_ptr_dbproc->CmdBuffLen;
    l_newcmd_length = strlen(p_sql_commandMBCS);
    p_ptr_dbproc->CmdBuff[[l_org_length]] = '\0';
    if( l_org_length )
    l_org_length++;
    if( (l_org_length + l_newcmd_length) >= MAX_CMD_BUFF )
    if( l_org_length == 0 )
    OdbcReuseStmtHandle( p_ptr_dbproc );
    else
    strcat(p_ptr_dbproc->CmdBuff, " ");
         l_org_length +=2;
    strcat(p_ptr_dbproc->CmdBuff, p_sql_commandMBCS);
    p_ptr_dbproc->CmdBuffLen = l_org_length + l_newcmd_length;
    if (p_sql_commandMBCS != NULL)
         free(p_sql_commandMBCS);
    return( SUCCEED );
    Function OdbcSqlExec_
    //SQLExecDirect Requires data of Unsigned Char type. Thus the above process is valid...
    //But i am not getting what is the exact problem...
    SQLRETURN OdbcSqlExec( DBPROCESS *p_ptr_dbproc )
    SQLRETURN l_ret_val;
    SQLINTEGER l_db_error_code=0;
         int     i,l_occur = 1;
         char     *token_list[[50]][[2]] =
    {     /*"to_date(","convert(datetime,",
                                       "'yyyy-mm-dd hh24:mi:ss'","1",*/
                                       "nvl","isnull" ,
                                       "to_number(","convert(int,",
                                       /*"to_char(","convert(char,",*/
                                       /*"'yyyymmdd'","112",
                                       "'hh24miss'","108",*/
                                       "sysdate",     "getdate()",
                                       "format_date", "dbo.format_date",
                                       "format_amount", "dbo.format_amount",
                                       "to_char","dbo.to_char",
                                       "to_date", "dbo.to_date",
                                       "unique","distinct",
                                       "\0","\0"};
    char          *l_qry_lwr;  
    l_qry_lwr = (char *)calloc(sizeof(char) * (MAX_CMD_BUFF), 1);
    l_ret_val = SQLExecDirect( p_ptr_dbproc->hStmt,
    (SQLCHAR *)p_ptr_dbproc->CmdBuff,
    SQL_NTS );
    switch( l_ret_val )
    case SQL_SUCCESS :
    case SQL_NO_DATA :
    ClearCmdBuff( p_ptr_dbproc );
    p_ptr_dbproc->LastStmtRetcode = l_ret_val;
    if (l_qry_lwr != NULL)
         free(l_qry_lwr);
    return( SUCCEED );
    case SQL_NEED_DATA :
    case SQL_ERROR :
    case SQL_SUCCESS_WITH_INFO :
    case SQL_STILL_EXECUTING :
    case SQL_INVALID_HANDLE :
    I do not see much issue in the code... The process flow is quite valid...
    But now i am not getting whether,
    1) storing the string in CmdBuff is creating issue
    2) SQLExecDirect si creating an issue(and some other function can be used here)...
    3) Odbc Driver creating an issue and want some Client Setting to be done(though i have tried doing some permutation combination)...
    Any kind of help would be appreciated,
    Thanks & Regards,
    Pratik
    Edited by: prats on Feb 27, 2009 12:57 PM

    Hey Sergiusz,
    You were bang on target...
    Though it took some time for me to resolve the issue...
    to use SQLExecDirectW I need my query in SQLWCHAR *, which is stored in char * in my case...
    So i converted the incoming query using MultibyteToWideChar Conversion with CodePage as CP_UTF8 and
    then passed it on to SQLExecDirectW...
    It solved my problem
    Thanks,
    Pratik...
    Edited by: prats on Mar 3, 2009 2:41 PM

  • Retrieve data partially without re-execution of query

    I am using Visual Basic.NET for programming.
    Database is Oracle 9i Enterprise Edition Release 9.0.1.1.1
    Platform is Windows XP Professional.
    I am going to execute an Oracle Query (or Stored Procedure) from my VB.NET environment.
    This query returns 1,000,000 records and takes lots of time to be executed.
    I found a way in .NET to fill DataSet with specific number of records. For Example I can show 100 records from position 10 to position 110 by this code:
    MyDataAdapter.Fill (MyDataset, 10, 100,"TEST")
    But my problem happens when I want to show 100 records from position 900,000 to position 900,100 by this code:
    MyDataAdapter.Fill (MyDataset, 900000, 100,"TEST")
    This line takes lots of times to be executed.
    I think each time I run the above line in VB.NET, the query executes once again. And this is not what I expect.
    Besides I used Microsoft.NET Oracle Client too, but still have problem.
    Would you please kindly help me to find a way to retrieve data partially without re-execution of query?
    Thanks for co-operation in advance.

    I am using Visual Basic.NET for programming.
    Database is Oracle 9i Enterprise Edition Release 9.0.1.1.1
    Platform is Windows XP Professional.
    I am going to execute an Oracle Query (or Stored Procedure) from my VB.NET environment.
    This query returns 1,000,000 records and takes lots of time to be executed.
    I found a way in .NET to fill DataSet with specific number of records. For Example I can show 100 records from position 10 to position 110 by this code:
    MyDataAdapter.Fill (MyDataset, 10, 100,"TEST")
    But my problem happens when I want to show 100 records from position 900,000 to position 900,100 by this code:
    MyDataAdapter.Fill (MyDataset, 900000, 100,"TEST")
    This line takes lots of times to be executed.
    I think each time I run the above line in VB.NET, the query executes once again. And this is not what I expect.
    Besides I used Microsoft.NET Oracle Client too, but still have problem.
    Would you please kindly help me to find a way to retrieve data partially without re-execution of query?
    Thanks for co-operation in advance.

  • Oracle 10g Diff in execution plan query with binding var Vs without

    We recently did 10g upgrade. In 10g, execution plan differs for query with binding var(thru jdbc etc) Vs without it as given below. For query with binding var,
    it chooses poor execution plan(no index is used, full scan is done etc). everything worked fine in 9i. To rectify the problem, we have to hint query with right index,join etc. but i dont like this solution.
    I would rather prefer to correct database to choose right execution path instead of eacy query level. but not sure what causes the issue.
    Does anybody came across this issue? if so, Please share your experiences. Thanks for the help. Do let me know if you need more info.
    1. Query without binding bar:
    select * from test where col1 = :1 and col2 = :2
    1. Query without binding bar:
    select * from test where col1 = 'foo' and col2= 'bar'

    I am not an expert but in my humble opinion it is the developer's responsability to ensure the correct explain plan is used before deploying code to production, if the explain plan returned by the DB is bad, then the use of a hint is perfectly acceptable.
    Check this out: http://lcgapp.cern.ch/project/CondDB/snapshot/performance.html
    Excerpt:
    Bind variable peeking. If an SQL query contains bind variables, the optimal execution plan may depend on the values of those variables. When the Oracle query optimizer chooses the execution plan for such a query, it may indeed look at the values of all bind variables involved: this is known as "bind variable peeking".
    In summary, the execution plan used for a given SQL query cannot be predicted a priori because it depends on the presence and quality of statistics and on the values of bind variables used at the time the query was first executed (hard-parsed). As a consequence of this instability of execution plans, very different performances may be observed for the same SQL query. In COOL, this issue is addressed by adding Oracle hints to the queries, to make sure that the same (good) plan is used in all cases, even with unreliable statistics or unfavourable bind variables.
    Edited by: Rodolfo Ferrari on Jun 3, 2009 9:40 PM

  • Strange problem while execution of query....

    Hi Friends
    I am facing a strange problem while executing the query.
    I have one query ,its old one ,till yesterday everday it was working fine ,
    But today i am trying to execute that query ,execution process takes very long time ,finally no response from bw server.
    its an important report in our company
    I checked query , Every thing is ok ,bze i haven't made any changes
    So i need some suggetions  .like where can i check and what can i do?
    ASAP ....  So Please ...its very urgent....
    EVERY THING AND ANY THING WILL BE REWARED
    Thanks in advance
    RK

    Hi
    Stefan
    Thank you for your valuable suggestion
    the problem is solved
    Already i  assigned  points.
    Thnaks & Regards
    RK

  • First execution of query is always best than all the following

    I have a static query that I execute in sql*plus in the same machine as the database and all the time, the first execution is faster than the following executions and it driving me crazy! Any help is appreciated...
    The database is Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    The query has a comment in the there so I can change the query to be "different" form the previous ones.
    I ran it in sql*plus with set autotrace traceonly and timing on and the results are:
    First execution:
    SQL> @route
    35 rows selected.
    Elapsed: 00:00:45.49
    Execution Plan
    Plan hash value: 1336726102
    Statistics
    442 recursive calls
    0 db block gets
    6244491 consistent gets
    0 physical reads
    176 redo size
    3333 bytes sent via SQL*Net to client
    9006 bytes received via SQL*Net from client
    4 SQL*Net roundtrips to/from client
    46 sorts (memory)
    0 sorts (disk)
    35 rows processed
    Second Execution:
    SQL> @route
    35 rows selected.
    Elapsed: 00:05:04.85
    Execution Plan
    Plan hash value: 1336726102
    Statistics
    386 recursive calls
    0 db block gets
    1282647 consistent gets
    0 physical reads
    840 redo size
    3333 bytes sent via SQL*Net to client
    9006 bytes received via SQL*Net from client
    4 SQL*Net roundtrips to/from client
    47 sorts (memory)
    0 sorts (disk)
    35 rows processed

    Second run:
    SQL> select * from table(dbms_xplan.display_cursor(null,null,'allstats last'));
    PLAN_TABLE_OUTPUT
    SQL_ID  f2xgmq6bsd6g1, child number 1
    SELECT /* + opt_param('_optimizer_use_feedback' 'false') zzzzz5 */
    route,  MIN(load_start) load_start,  store,  lc_id,  loading_seq,
    pick_zone_name,  MAX(user_name) user_name,  SUM(colli) colli,
    SUM(colli_picked) colli_picked,  round((1 - ((SUM(colli) -
    SUM(colli_picked)) / (SUM(colli)))) * 100, 2) || '%' colli_ready   FROM
    (SELECT route,                load_start,                store,
           lc_id,                loading_seq,                CASE
           WHEN (nbr_pick_zones > 1) THEN                   'MULTIPLE'
                ELSE                   pick_zone_name                END
    pick_zone_name,                (SELECT u.user_name
    FROM dms_user u                  WHERE u.user_id = tab4.user_id
               AND u.facility_id = 'E1') user_name,                colli,
                 (colli - colli_not_picked) colli_picked           FROM
    (SELECT tab3.route,                        tab3.load_start,
               tab3.store,
    Plan hash value: 2089643899
    | Id  | Operation                                         | Name                      | Starts | E-Rows | A-Rows |   A-Time   | Buffers |  OMem |  1Mem | Used-Mem |
    |   0 | SELECT STATEMENT                                  |                           |      1 |        |     35 |00:01:51.10 |    1286K|       |       |          |
    |   1 |  TABLE ACCESS BY INDEX ROWID                      | DMS_USER                  |     18 |      1 |     18 |00:00:00.01 |      37 |       |       |          |
    |*  2 |   INDEX UNIQUE SCAN                               | DMS_USER1                 |     18 |      1 |     18 |00:00:00.01 |      17 |       |       |          |
    |   3 |  SORT GROUP BY                                    |                           |      1 |      2 |     35 |00:01:51.10 |    1286K|  9216 |  9216 | 8192  (0)|
    |   4 |   VIEW                                            |                           |      1 |      2 |     43 |00:01:51.09 |    1286K|       |       |          |
    |   5 |    WINDOW BUFFER                                  |                           |      1 |      2 |     43 |00:01:51.09 |    1286K|  6144 |  6144 | 6144  (0)|
    |   6 |     SORT GROUP BY                                 |                           |      1 |      2 |     43 |00:01:51.09 |    1286K| 11264 | 11264 |10240  (0)|
    |   7 |      NESTED LOOPS OUTER                           |                           |      1 |      2 |     43 |00:01:51.09 |    1286K|       |       |          |
    |   8 |       VIEW                                        |                           |      1 |      2 |     43 |00:01:51.09 |    1286K|       |       |          |
    |   9 |        UNION-ALL                                  |                           |      1 |        |     43 |00:01:51.09 |    1286K|       |       |          |
    |  10 |         HASH GROUP BY                             |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |   752K|   752K|          |
    |  11 |          VIEW                                     | VM_NWVW_1                 |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |* 12 |           FILTER                                  |                           |      1 |        |      0 |00:00:01.04 |   33948 |       |       |          |
    |  13 |            HASH GROUP BY                          |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |   694K|   694K|          |
    |  14 |             NESTED LOOPS                          |                           |      1 |        |      0 |00:00:01.04 |   33948 |       |       |          |
    |  15 |              NESTED LOOPS                         |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  16 |               NESTED LOOPS                        |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  17 |                NESTED LOOPS                       |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  18 |                 NESTED LOOPS                      |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  19 |                  NESTED LOOPS                     |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  20 |                   NESTED LOOPS                    |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  21 |                    NESTED LOOPS                   |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  22 |                     NESTED LOOPS                  |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  23 |                      NESTED LOOPS                 |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |  24 |                       NESTED LOOPS                |                           |      1 |      1 |      0 |00:00:01.04 |   33948 |       |       |          |
    |* 25 |                        TABLE ACCESS BY INDEX ROWID| CONTAINER                 |      1 |     13 |     36 |00:00:00.01 |      21 |       |       |          |
    |* 26 |                         INDEX SKIP SCAN           | CONTAINER_CARR_SERV_ROUTE |      1 |     28 |     36 |00:00:00.01 |      12 |       |       |          |
    |* 27 |                        TABLE ACCESS BY INDEX ROWID| PICK_DIRECTIVE            |     36 |      1 |      0 |00:00:01.04 |   33927 |       |       |          |
    |* 28 |                         INDEX RANGE SCAN          | PICK_DIRECTIVE_I1         |     36 |      1 |    569K|00:00:00.47 |   12936 |       |       |          |
    |  29 |                       TABLE ACCESS BY INDEX ROWID | PICK_FROM_LOC             |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 30 |                        INDEX RANGE SCAN           | PICK_FROM_LOC_ITEM        |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |  31 |                      TABLE ACCESS BY INDEX ROWID  | LOCATION                  |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 32 |                       INDEX RANGE SCAN            | LOCATION_ZONE             |      0 |   1053 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 33 |                     TABLE ACCESS BY INDEX ROWID   | STOCK_ALLOCATION          |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    PLAN_TABLE_OUTPUT
    |* 34 |                      INDEX UNIQUE SCAN            | STOCK_ALLOCATION1         |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 35 |                    TABLE ACCESS BY INDEX ROWID    | NB_TMS_INBOUND            |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 36 |                     INDEX RANGE SCAN              | NB_TMS_INBOUND_PK         |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |  37 |                   TABLE ACCESS BY INDEX ROWID     | ROUTE_DEST                |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 38 |                    INDEX RANGE SCAN               | ROUTE_DEST1               |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 39 |                  TABLE ACCESS BY INDEX ROWID      | NB_LANE_SELECTION         |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 40 |                   INDEX UNIQUE SCAN               | NB_LANE_SELECTION_PK      |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |  41 |                 TABLE ACCESS BY INDEX ROWID       | ZONE                      |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 42 |                  INDEX UNIQUE SCAN                | ZONE1                     |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 43 |                TABLE ACCESS BY INDEX ROWID        | LOC_TYPE                  |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 44 |                 INDEX UNIQUE SCAN                 | LOC_TYPE1                 |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |* 45 |               INDEX UNIQUE SCAN                   | ITEM_MASTER1              |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |  46 |              TABLE ACCESS BY INDEX ROWID          | ITEM_MASTER               |      0 |      1 |      0 |00:00:00.01 |       0 |       |       |          |
    |  47 |         HASH GROUP BY                             |                           |      1 |      1 |     43 |00:01:51.09 |    1252K|   759K|   759K| 1336K (0)|
    |  48 |          NESTED LOOPS                             |                           |      1 |        |   1963 |00:13:34.35 |    1252K|       |       |          |
    |  49 |           NESTED LOOPS                            |                           |      1 |      1 |   1963 |00:13:34.33 |    1250K|       |       |          |
    |  50 |            NESTED LOOPS                           |                           |      1 |      1 |   1963 |00:13:34.31 |    1250K|       |       |          |
    |  51 |             NESTED LOOPS                          |                           |      1 |      1 |     37M|00:02:03.09 |     822K|       |       |          |
    |  52 |              MERGE JOIN CARTESIAN                 |                           |      1 |      1 |  41685 |00:00:00.20 |    9793 |       |       |          |
    |  53 |               NESTED LOOPS                        |                           |      1 |        |   1985 |00:00:00.13 |    9790 |       |       |          |
    |  54 |                NESTED LOOPS                       |                           |      1 |      1 |   1985 |00:00:00.10 |    7060 |       |       |          |
    |  55 |                 NESTED LOOPS                      |                           |      1 |     14 |   1985 |00:00:00.08 |    5047 |       |       |          |
    |  56 |                  NESTED LOOPS                     |                           |      1 |     14 |   1985 |00:00:00.03 |    1152 |       |       |          |
    |* 57 |                   HASH JOIN                       |                           |      1 |      1 |     36 |00:00:00.01 |      81 |   774K|   774K|  760K (0)|
    |* 58 |                    HASH JOIN                      |                           |      1 |      7 |     36 |00:00:00.01 |      67 |   779K|   779K|  391K (0)|
    |* 59 |                     HASH JOIN                     |                           |      1 |     36 |     36 |00:00:00.01 |      51 |   835K|   835K|  654K (0)|
    |* 60 |                      TABLE ACCESS BY INDEX ROWID  | CONTAINER                 |      1 |     36 |     36 |00:00:00.01 |      21 |       |       |          |
    |* 61 |                       INDEX SKIP SCAN             | CONTAINER_CARR_SERV_ROUTE |      1 |     28 |     36 |00:00:00.01 |      12 |       |       |          |
    |* 62 |                      TABLE ACCESS FULL            | NB_TMS_INBOUND            |      1 |    144 |    144 |00:00:00.01 |      30 |       |       |          |
    |* 63 |                     TABLE ACCESS FULL             | NB_LANE_SELECTION         |      1 |     64 |     64 |00:00:00.01 |      16 |       |       |          |
    |* 64 |                    TABLE ACCESS FULL              | ROUTE_DEST                |      1 |   2003 |   2149 |00:00:00.01 |      14 |       |       |          |
    |  65 |                   TABLE ACCESS BY INDEX ROWID     | CONTAINER_ITEM            |     36 |     38 |   1985 |00:00:00.02 |    1071 |       |       |          |
    |* 66 |                    INDEX RANGE SCAN               | CONTAINER_ITEM1           |     36 |     38 |   1985 |00:00:00.01 |      94 |       |       |          |
    |  67 |                  TABLE ACCESS BY INDEX ROWID      | ITEM_MASTER               |   1985 |      1 |   1985 |00:00:00.04 |    3895 |       |       |          |
    |* 68 |                   INDEX UNIQUE SCAN               | ITEM_MASTER1              |   1985 |      1 |   1985 |00:00:00.02 |    1910 |       |       |          |
    |* 69 |                 INDEX UNIQUE SCAN                 | STOCK_ALLOCATION1         |   1985 |      1 |   1985 |00:00:00.02 |    2013 |       |       |          |
    |* 70 |                TABLE ACCESS BY INDEX ROWID        | STOCK_ALLOCATION          |   1985 |      1 |   1985 |00:00:00.02 |    2730 |       |       |          |
    |  71 |               BUFFER SORT                         |                           |   1985 |     21 |  41685 |00:00:00.04 |       3 |  2048 |  2048 | 2048  (0)|
    |  72 |                TABLE ACCESS BY INDEX ROWID        | ZONE                      |      1 |     21 |     21 |00:00:00.01 |       3 |       |       |          |
    |* 73 |                 INDEX RANGE SCAN                  | ZONE_ZG_IDX               |      1 |     21 |     21 |00:00:00.01 |       1 |       |       |          |
    |  74 |              TABLE ACCESS BY INDEX ROWID          | LOCATION                  |  41685 |    382 |     37M|00:01:40.75 |     812K|       |       |          |
    |* 75 |               INDEX RANGE SCAN                    | LOCATION_ZONE             |  41685 |   1053 |     37M|00:00:30.18 |     256K|       |       |          |
    |* 76 |             VIEW PUSHED PREDICATE                 |                           |     37M|      1 |   1963 |00:10:49.31 |     428K|       |       |          |
    |* 77 |              FILTER                               |                           |     37M|        |     37M|00:09:39.35 |     428K|       |       |          |
    |  78 |               SORT AGGREGATE                      |                           |     37M|      1 |     37M|00:08:18.42 |     428K|       |       |          |
    |* 79 |                FILTER                             |                           |     37M|        |     37M|00:05:23.60 |     428K|       |       |          |
    |  80 |                 TABLE ACCESS BY INDEX ROWID       | PICK_FROM_LOC             |     37M|      1 |     37M|00:03:59.31 |     428K|       |       |          |
    |* 81 |                  INDEX RANGE SCAN                 | PICK_FROM_LOC_ITEM        |     37M|      1 |     37M|00:02:16.12 |     272K|       |       |          |
    |* 82 |            INDEX UNIQUE SCAN                      | LOC_TYPE1                 |   1963 |      1 |   1963 |00:00:00.01 |       4 |       |       |          |
    |* 83 |           TABLE ACCESS BY INDEX ROWID             | LOC_TYPE                  |   1963 |      1 |   1963 |00:00:00.01 |    1963 |       |       |          |
    |* 84 |       VIEW PUSHED PREDICATE                       |                           |     43 |      1 |     43 |00:00:00.01 |     236 |       |       |          |
    |* 85 |        WINDOW SORT PUSHED RANK                    |                           |     43 |      1 |     86 |00:00:00.01 |     236 |  2048 |  2048 | 2048  (0)|
    |* 86 |         TABLE ACCESS BY INDEX ROWID               | CONTAINER_HISTORY         |     43 |      1 |    160 |00:00:00.01 |     236 |       |       |          |
    |* 87 |          INDEX RANGE SCAN                         | CHST_IDX                  |     43 |      2 |    246 |00:00:00.01 |      90 |       |       |          |
    Predicate Information (identified by operation id):
    PLAN_TABLE_OUTPUT
       2 - access("U"."FACILITY_ID"='E1' AND "U"."USER_ID"=:B1)
      12 - filter(("L"."LOCATION_ID"=MAX("PL"."LOCATION_ID") AND "PD"."PICK_FROM_CONTAINER_ID"=MAX("PL"."LOCATION_ID")))
      25 - filter((INTERNAL_FUNCTION("C"."CONTAINER_STATUS") AND "C"."DEST_ID" IS NOT NULL))
      26 - access("C"."FACILITY_ID"='E1' AND "C"."ROUTE"='556')
           filter("C"."ROUTE"='556')
      27 - filter("C"."CONTAINER_ID"="PD"."PICK_TO_CONTAINER_ID")
      28 - access("PD"."FACILITY_ID"='E1')
      30 - access("PL"."FACILITY_ID"='E1' AND "PL"."ITEM_ID"="PD"."ITEM_ID")
      32 - access("L"."FACILITY_ID"='E1' AND "PD"."ZONE"="L"."ZONE")
      33 - filter(("SA"."ORDER_DETAIL_UDA1"='2012-10-26' AND "SA"."SA_ROUTE" IS NOT NULL))
      34 - access("SA"."FACILITY_ID"='E1' AND "SA"."DISTRO_NBR"="PD"."DISTRO_NBR" AND "SA"."DEST_ID"="C"."DEST_ID" AND "SA"."ITEM_ID"="PD"."ITEM_ID")
      35 - filter(("C"."ROUTE"="A"."ROUTE" AND "SA"."SA_ROUTE"="A"."ROUTE"))
      36 - access("A"."FACILITY_ID"='E1' AND "C"."DEST_ID"="A"."DEST_ID")
           filter((TO_CHAR(INTERNAL_FUNCTION("A"."BUSINESS_DATE"),'YYYY-MM-DD')='2012-10-26' AND
                  "SA"."ORDER_DETAIL_UDA1"=TO_CHAR(INTERNAL_FUNCTION("A"."BUSINESS_DATE"),'YYYY-MM-DD')))
      38 - access("RD"."FACILITY_ID"='E1' AND "C"."ROUTE"="RD"."ROUTE" AND "C"."DEST_ID"="RD"."DEST_ID")
      39 - filter("RD"."SHIP_DATE"=TRUNC(INTERNAL_FUNCTION("LS"."LOAD_START")))
      40 - access("LS"."FACILITY_ID"='E1' AND "LS"."BUSINESS_DATE"="A"."BUSINESS_DATE" AND "LS"."ROUTE"="A"."ROUTE")
      42 - access("Z"."FACILITY_ID"='E1' AND "L"."ZONE"="Z"."ZONE")
      43 - filter(("C"."LOCATION_ID" IS NULL OR "LT"."DOOR_LOCATION_FLAG"='N'))
      44 - access("LT"."FACILITY_ID"='E1' AND "L"."LOCATION_TYPE"="LT"."LOCATION_TYPE")
      45 - access("I"."FACILITY_ID"='E1' AND "PL"."ITEM_ID"="I"."ITEM_ID")
      57 - access("C"."FACILITY_ID"="RD"."FACILITY_ID" AND "C"."ROUTE"="RD"."ROUTE" AND "C"."DEST_ID"="RD"."DEST_ID" AND
                  "RD"."SHIP_DATE"=TRUNC(INTERNAL_FUNCTION("LS"."LOAD_START")))
      58 - access("LS"."FACILITY_ID"="A"."FACILITY_ID" AND "LS"."ROUTE"="A"."ROUTE" AND "LS"."BUSINESS_DATE"="A"."BUSINESS_DATE")
      59 - access("C"."DEST_ID"="A"."DEST_ID" AND "C"."ROUTE"="A"."ROUTE")
      60 - filter(("C"."USER_ID" IS NOT NULL AND INTERNAL_FUNCTION("C"."CONTAINER_STATUS") AND "C"."DEST_ID" IS NOT NULL))
      61 - access("C"."FACILITY_ID"='E1' AND "C"."ROUTE"='556')
           filter("C"."ROUTE"='556')
      62 - filter(("A"."BUSINESS_DATE"=TO_DATE(' 2012-10-26 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND "A"."FACILITY_ID"='E1'))
      63 - filter(("LS"."BUSINESS_DATE"=TO_DATE(' 2012-10-26 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND "LS"."FACILITY_ID"='E1'))
      64 - filter("RD"."FACILITY_ID"='E1')
      66 - access("CI"."FACILITY_ID"='E1' AND "CI"."CONTAINER_ID"="C"."CONTAINER_ID")
      68 - access("I"."FACILITY_ID"='E1' AND "CI"."ITEM_ID"="I"."ITEM_ID")
      69 - access("SA"."FACILITY_ID"='E1' AND "SA"."DISTRO_NBR"="CI"."DISTRO_NBR" AND "SA"."DEST_ID"="A"."DEST_ID" AND "SA"."ITEM_ID"="CI"."ITEM_ID")
      70 - filter(("SA"."ORDER_DETAIL_UDA1"='2012-10-26' AND "SA"."SA_ROUTE" IS NOT NULL AND "SA"."SA_ROUTE"="A"."ROUTE"))
      73 - access("Z"."FACILITY_ID"='E1')
      75 - access("L"."FACILITY_ID"='E1' AND "L"."ZONE"="Z"."ZONE")
      76 - filter(("L"."LOCATION_ID"="P"."LOCATION_ID" AND "C"."PICK_TYPE"=DECODE(TO_CHAR(NVL("P"."CASEPACK",0)),'0','U','CF')))
      77 - filter(COUNT(*)>0)
      79 - filter(('E1'="CI"."FACILITY_ID" AND 'E1'="L"."FACILITY_ID"))
      81 - access("PL"."FACILITY_ID"='E1' AND "PL"."ITEM_ID"="CI"."ITEM_ID")
      82 - access("LT"."FACILITY_ID"='E1' AND "L"."LOCATION_TYPE"="LT"."LOCATION_TYPE")
      83 - filter(("C"."LOCATION_ID" IS NULL OR "LT"."DOOR_LOCATION_FLAG"='N'))
      84 - filter("LAST_USER"=1)
      85 - filter(ROW_NUMBER() OVER ( PARTITION BY "CH"."FACILITY_ID","CH"."CONTAINER_ID" ORDER BY INTERNAL_FUNCTION("CH"."ACTION_TS") DESC )<=1)
      86 - filter((INTERNAL_FUNCTION("CH"."CONTAINER_STATUS") AND "CH"."USER_ID"<>'WMS_OWNER'))
      87 - access("CH"."FACILITY_ID"="TAB1"."FACILITY_ID" AND "CH"."CONTAINER_ID"="TAB1"."LC_ID" AND "CH"."TABLE_NAME"='C' AND "CH"."ACTION_TYPE"='M')
    Note
       - cardinality feedback used for this statement
    169 rows selected.

  • On click of cancel button avoid execution of query

    Hi,
    I am going from one jsff page to other on click of a button
    In the second page i am coming back to the 1st page on click of the cancel button
    But on click of this cancel button my query is getting executed again and is taking long time to come back to the 1st page
    It is a read only vo query... how can i avoid query execution on click of cancel button
    Thanks,

    Hi,
    Immediate = true is already been set for cancel button
    The problem is when i come back to the 1st page vo is getting executed again and is taking lot of time.. i need to see that vo does not get executed again
    in the vo for view criteria -- query execution mode , i have made as in memory and now it has become fast on click of cancel button. But i am getting the following error when i perform search in the first page
    Missing FROM in a SELECT statement
    An unexpected expression token is found.
    Thanks,
    .

  • Xcelsius BICS query execution - Whole query or only defined set

    Hello All,
    I am wondering about how the BICS exactly works in relation to the query handling while running a dashboard.
    Let's say i have a dashboard with a graphic that shows the sales quantities per sales organisation.
    In XCELSIUS i will make the query lay-out giving only this row and column.
    Now i could have two options for the source query:
    1. containing all characteristics from the infocube (let's say 10 chars), all put in the Free Characteristic section.
    2. containing only salesorg characteristic and sales quantity.
    What is the difference in execution when running the dashboard?
    What is extracted from the infocube in both cases? Is all data extracted and later on filtered by the BICS, or do we really only get what i defined in the xcelsius query part.
    Did anybody do some testing about this?
    Thanks for the replies!

    The 'in memory' flag means don't ask the db. If your second part of the VC needs to do an exists (which need to be done using the db) this part isn't executed.
    Timo

  • Parallel execution of query

    Hi Everyone,
    I am using following version oracle version
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
    PL/SQL Release 10.2.0.4.0 - Production
    "CORE 10.2.0.4.0 Production"
    TNS for Solaris: Version 10.2.0.4.0 - Production
    NLSRTL Version 10.2.0.4.0 - Production
    Parameter for parallel execution.
    Name        Type Value
    parallel_server      1 FALSE
    parallel_server_instances   3 1
    recovery_parallelism    3 0
    fast_start_parallel_rollback  2 LOW
    parallel_min_percent    3 0
    parallel_min_servers     3 4
    parallel_max_servers    3 10
    parallel_instance_group    2
    parallel_execution_message_size 3 2152
    parallel_adaptive_multi_user  1 TRUE
    parallel_threads_per_cpu   3 2
    parallel_automatic_tuning   1 FALSE
    If i execute two or more SQL with parallel hint, i realised that the SQL which is first executed is using the parallelism functionality and rest are sequentially.
    select /*+ parallel(a) */  max(sal)  from emp a;
    SELECT /*+ parallel(a) parallel(b) */ a.empno, b.deptno FROM emp a,  dept b
    WHERE a.deptno = b.deptno
    I have following queries.
    1. How can i find out how many Degree of parallalism is being used by SQL
    2. What needs to be done so that both SQL can be executed using parallel execution.
    3. How to find out how many 'Query server' are being used by SQL and how many left for another SQL
       to use 'Query server'
    Regards,
    Sandeep

    Did you already consult the documentation? "Rules for Parallelizing Queries":  Types of Parallelism
    And you can find several threads on AskTom, for example: Ask Tom &amp;quot;Number of CPUs and Degree of Parallelism&amp;quot;

  • Execution of query in background

    Hi,
    We are using excel report output.
    We are facing issue of longer report runtime, when we run the report for the first time after data load. There on, the further runs are not taking that a long, to get the report output.
    We have been observing this for more than a week. We got a confitmation that this is not much to do with the workprocess(Basis).
    So the solution we are looking at is to run the report in background and get the output cached, so that, when the users run the report, they get the report from Cache.
    We are using 3.5 version and the output, we are looking at is excel.
    Any thoughts, about how to proceed with this.
    Thanks.
    Naveen.A

    Hi Naveen,
    You can run the query in the background using tyhe reporting agent:
    1.Create a web template of the report and select the web template in the reporting agent.
    2. from the rules\favoraites create new setting. give it a technican name and description.
    3. in the parameters tab check all the check boxes under calculate. tou can also choose a language.
    4. save & activate .
    5. Create a new schedualing package and drag&drop your reporting agent setting under it.
    6. schedual the schedualing package.
    Hope it helps.
    Amir

  • Error in execution of query's from Query Designer

    Hi,
    We have recently installed the BI 7 server, when i execute the query from query designer i got the following URL:
    http:///irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=TEST_REP&VARIABLE_SCREEN=X&DUMMY=2
    due to that page is not displayed, i guess there is some sort of hostname setting need to be done.
    Can anybody please guide me where all these settings are done, help required urgently ?
    Thanks in advance

    In fact the query's are not running because this entry needs to be maintained in the below path:
    C:\WINDOWS\system32\drivers\etc\hosts
    Maintain this as the last entry below the localhost
    <bi server ip> <host name>.
    This entry is to be maintained whenever we dont see the host name in the url.

  • Error in query execution from Query designer

    Hi,
    We have recently installed the BI 7 server, when i execute the query from query designer i got the following URL:
    http:///irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=TEST_REP&VARIABLE_SCREEN=X&DUMMY=2
    due to that page is not displayed, i guess there is some sort of hostname setting need to be done.
    Can anybody please guide me where all these settings are done, help required urgently ?
    Thanks in advance

    Hello Dipika
    May be you have not included host string in logon pad.
    1. Open SAP log on pad
    2. Select the system and go to change mode
    3. you have IP defined for the system, here you need to put host string name which u can get from C:\WINDOWS\system32\drivers\etc file for your SAP system in your system.
    4. Save and exit.and run query again
    Thanks
    Tripple k

  • Custom execution of query's

    hi friends,
    execute any one of the query below in plsql.
    Querys >
    select count(*) from [email protected] where title = &arg;
    select count(*) from [email protected] where title = &arg;
    select count(*) from [email protected] where title = &arg;
    select count(*) from bookings_detail_current@ougt1prd where title = &arg;
    Reasult expected >
    If the any one Query has the value then do not run the balance 3 query's

    Karthick,
    I don't think the NO_DATA_FOUND exception will be thrown if COUNT(*) is being used. COUNT will always return 1 value (0 when the table is empty). Hope the following example proves it.
    SQL> DROP TABLE TEST_TAB
      2  /
    Table dropped.
    SQL> CREATE TABLE TEST_TAB
      2  AS
      3  SELECT * FROM EMP where 1=2
      4  /
    Table created.
    SQL> SELECT * FROM TEST_TAB;
    no rows selected
    SQL>  declare
      2   var_count NUMBER;
      3   begin
      4   SELECT COUNT(*) INTO var_count FROM test_tab where empno =  '500';
      5   DBMS_OUTPUT.PUT_LINE('The value of Count is: ' || to_char(var_count));
      6   exception
      7   WHEN NO_DATA_FOUND THEN
      8       DBMS_OUTPUT.PUT_LINE('Exception Caught');
      9   END;
    10  /
    The value of Count is: 0
    PL/SQL procedure successfully completed.
    SQL> declare
      2   var_count NUMBER;
      3   begin
      4   SELECT empno INTO var_count FROM test_tab where empno =  '500';
      5   DBMS_OUTPUT.PUT_LINE('The value of Count is: ' || to_char(var_count));
      6   exception
      7   WHEN NO_DATA_FOUND THEN
      8       DBMS_OUTPUT.PUT_LINE('Exception Caught');
      9   END;
    10  /
    Exception Caught
    PL/SQL procedure successfully completed.
    SQL> Raj,
    I think you can try something on the lines of
    declare
    var_count NUMBER;
    begin
    select count(*) into var_count from [email protected] where title = &arg;
    if var_count = 0 then
    select count(*) into var_count from [email protected] where title = &arg;
    elsif var_count = 0 then
    select count(*) into var_count from [email protected] where title = &arg;
    elsif var_count = 0
    select count(*) into var_count from bookings_detail_current@ougt1prd where title = &arg;
    END IF;
    -- Remaining code logic
    exception
       -- Your Exception Handling --
    END;Hope this helps.
    Regards,
    Jo

  • Schedule the Execution of Query

    Hi,
    I want to schedule the excution of Query in BI7 periodcally like weekly or monthly.
    I dont want to use Broadcasting or Reporting Agent.
    Is there any way..
    please help...

    Hi,
    What is the purpose and where do you want to store the information(out put of the query).
    Regards
    PV

  • Reporting error while execution of query in BI?

    hi friends,
    http:///irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=Q001_SALES&VARIABLE_SCREEN=X&DUMMY=1
    when i am executing my query in 7.0 i am getting 1 extra window with this message. ple let me know solution for this.
    regards
    suneel.

    hi banu,
    whether i need look here bex analyzer or query designer, if i open bex analyzer its showing only 3.x reporting, when i am usnig query designer its showing 7.x reporting, i know reporting well in 3.5 .
    i am using there bex analyzer?
    here in BI what  can i use? analyzer or query designer?
    if i need analyzer why its showing only 3.x reporting.
    if i need 7.x reporting what can i do for my system?
    and also help me that new data to activae data for dso for my demo version wher can i check my oss nores.
    regards
    suneel.

Maybe you are looking for