Query structure number of elements

Hello gururs,
I have a major issue.
I have a query with more than 1000 elements. When i try to run it gives me an error. I contact sap and thay say that this is a limitation of the system.
Does anyone have similar problem, and how can i overcome this issue?
I have SAP-BW 7 and level 13.
Thanks in advance,
Vitor Ramalho

Parag Kalra wrote:
One of my SQL query having 'in' operator failed saying number of elements exceed.
Is there a limit on number of elements that can be used with - 'in' operator.
And if yes can it be increased?You cannot have more than 1000 literals in an IN clause.
Please check
ORA-01795, limit on in clause
Max number of values in IN clause
Edited by: Rajesh Lathwal on May 24, 2010 12:28 PM

Similar Messages

  • How to get the number of elements in DB

    Could you tell me how to get the number of elements in DB??
    My code to get the number is below, but I think it is not efficient
    DB->cursor(DB, NULL, &cursorp, 0);
    while ((ret = cursorp->c_get(cursorp, &key, &data, DB_NEXT)) == 0)
    count++;
    --------------------------------------------------------------------------------------------------------------

    Hi,
    The most efficient way to get a count from the database is using the DB->stat API (http://docs.oracle.com/cd/E17076_02/html/api_reference/C/dbstat.html)
    The code will be something like:
            DB *dbp;
            DB_BTREE_STAT *statp;
            int ret;
            /* Print out the number of records in the database. */
            if ((ret = dbp->stat(dbp, NULL, &statp, 0)) != 0) {
                    dbp->err(dbp, ret, "DB->stat");
                    goto err1;
            printf("%s: database contains %lu records\n",
                progname, (u_long)statp->bt_ndata);
            free(statp);The code comes from the example included in the distribution at examples/c/ex_btrec.c
    If the database isn't a btree, you should update to the appropriate statistics structure and field.
    It's worth noting that retrieving the count is never a "cheap" operation. The count is not stored in the database - since doing so introduced a single point of contention that creates a bottle neck.
    Regards,
    Alex Gorrod
    Oracle Berkeley DB

  • Number of elements in the FP affecting the performance of my application ?

    I developed a simple application which consists of aquiring a signal through a channel of a PXI 5102 module and commanding some relays of a SCXI 1161 module.
    This application has the following features :
    -The user can, at any time, change the configuration of the PXI 5102 module.
    -The signal acquired can be saved to a file whenever the user wants.
    -Instead of showing the signal acquired through the PXI 5102 channel, the user can load a given file which contains a saved signal.
    -The user can increase or decrease the pressure on a line through a VI that commands SCXI 1161 relays.
    As you can see, it is a fairly simple application but the problem is that it have been running for a time the fron
    t panel crashes. Is it because the high number of elements I have in the front panel ?
    To give you more information I tell you that the processes of saving, loading, decreasing and increasing the pressure on the line are event cases of an event structure.
    The front panel consists of a tab structure, 20 controls and indicators and a cluster consisting of 9 controls.

    No error take place. By crashing I mean that after a period of time the frontpanel control´s response to inputs of the user become so slow that after a short time there´s no response at all.
    The problem is that I´ve been dealing with this problem in this aplication for quite a while and although I´ve optimized, I think, its execution time and the way it deals with memory usage this problem persists.
    Since most of the operations performed by it depends on inputs by the user I´ve decided to use an event structure to manage them and decided to load the VIs related to them dynamically into memory to somewoh optimize memory usage.
    In order to make things more clear to you I´m sending you a zipped file containing pics that completely describe the frontpane
    l ad the block diagram of the appliction.
    Any help you can give will be deeply appreciated.
    PS : I´ve tried to sent the zipped file but awindow appeared notifying me that Developer Exchange is down for maintenance. If you need any more information to clarify what I mean please let me know.
    Sincerely,
    Giovani Marcelino Nesi
    DRV Desenvolvimento e Representação Virtual Ltda.

  • Number of elements that can be used with 'in' Operator

    One of my SQL query having 'in' operator failed saying number of elements exceed.
    Is there a limit on number of elements that can be used with - 'in' operator.
    And if yes can it be increased?

    Parag Kalra wrote:
    One of my SQL query having 'in' operator failed saying number of elements exceed.
    Is there a limit on number of elements that can be used with - 'in' operator.
    And if yes can it be increased?You cannot have more than 1000 literals in an IN clause.
    Please check
    ORA-01795, limit on in clause
    Max number of values in IN clause
    Edited by: Rajesh Lathwal on May 24, 2010 12:28 PM

  • Dynamic selection in query structure

    Hi everyone,
    I wonder if it is possible to create dynamic selections in a query structure. Here is my scenario:
    In the columns section of my query I have a structure with all months of a year. Depending on the time of the year, all past months shall contain "actuals" whilst the upcoming months contain "forecast" data. (As far as I know) Using variables, I should be able to fill and name each month dynamically using variables. If it's March now, I would have the following resulting structure:
    - "Jan - Actual"  (containing actuals)
    - "Feb - Actual" (containing actuals)
    - "Mar - Forecast" (containing forecast)
    - "Apr - Forecast" (containing forecast)
    Each month is represented by a selection (if I understand correctly).
    Is it possible, to show or hide such a selection dynamically? The reason I ask: for the current period (March) I also want to display the "current" value (besides the forecast). Unfortunately, this selection moves a long the structure as time moves on: this month, the "current" shall be placed right before "Mar - Forecast".
    - "Jan - Actual"  (containing actuals)
    - "Feb - Actual" (containing actuals)
    - "Mar - Current" (containing currents)
    - "Mar - Forecast" (containing forecast)
    - "Apr - Forecast" (containing forecast)
    Next month it shall be right before "Apr - Forecast".
    - "Jan - Actual"  (containing actuals)
    - "Feb - Actual" (containing actuals)
    - "Mar - Forecast" (containing forecast)
    - "Apr - Current" (containing currents)
    - "Apr - Forecast" (containing forecast)
    Is this possible with BW 3.5? Or otherwise with BI 7? Or is this requirement too dynamic?
    Thanks in advance, Dan

    Hi,
    as already mentionned you can do that with the help of variables.
    For the "moving" column one solution would be to systematically create the column for each month and restrict it to the current month. Only one of this column will get a result different than 0. Then you enable the zero suppresion at query level and allow as well the suppression of the element of your structure (will will hide all the non current columns). This solution is not so elegant but would work.
    Othewise it shoul be also possible to make it with a complex variables implementation (ABAP etc...); in thery that should be possible, the question is it worth the time to develop it so sophisticated??
    hope this helps...
    Olivier.
    Edited by: Olivier Cora on Jan 9, 2008 12:38 PM

  • What is the purpose of Number of elements at this level and ..?

    Hi,
    What is the purpose of Number of elements at this level an how it influences the obi server to optimize the query?
    Thanks in advance.

    Hello,
    Number of elements at this level, specify the number of elements that exist at this logical level.By mentioning this levels we are telling to the BI Server that it is a parent and the next level is a child.
    Mark if helps.

  • Reg Number of elements at this level and Variables

    Hi Experts,
    What is the purpose of Number of elements at this level in the dimensional hierarchy of BMM layer on what basis default it will show 1 if we change this value into 2 what happens .
    Difference between non system session variables and dynamic repository variables in which scenarios we will use these bth variables.

    Hi Rafi,
    Sorry for delay response.
    Nonsystem Session Variables :-
    The procedure for defining nonsystem session variables is the same as for system session variables.
    A common use for nonsystem session variables is setting user filters. For example, we could define a nonsystem variable called SalesRegion that would be initialized to the name of the user’s sales region.
    We could then set a security filter for all members of a group that would allow them to view only data pertinent to their region.
    2. difference between dynamic repository variables and non-system session variables?
    Dynamic Repository Variables:-
    We initialize dynamic repository variables in the same way as static variables, but the values are refreshed by data returned from queries. When defining a dynamic repository variable, we will create an initialization block or use a pre-existing one that contains a SQL query. We will also set up a schedule that the Oracle BI Server will follow to execute the query and periodically refresh the value of the variable.
    Note: When the value of a dynamic repository variable changes, all cache entries associated with a business model that reference the value of that variable will be purged automatically. Each query can refresh several variables—one variable for each column in the query. We schedule these queries to be executed by the Oracle BI Server.
    Hope this help's
    Thanks,
    Satya

  • How to convert amount data element to number data element

    Dear Gurus,
    I have a requirement to get the data by calling BRF+ and then pass them to BAPI 'BAPI_ASSET_ACQUISITION_POST', in the BRF+ export structure, there is a field 'AMOUNT', I bind it to DDIC element 'BF_ANBTR', the type is Number.
    In BRF+, I call another global function to calculate the value, I define a local variant LV_VALUE to get export value from this function, this local variant's type is Amount, now I need to move this local variant value to the export field 'AMOUNT'.
    But BRF+ doesn't allow to convert amount data element to number data element directly, and I find there is no formula function available. Only there is a function 'TO_AMOUNT' to convert number data element to amount data element.
    Please help to get a solution for above solution.
    Thanks.

    Hi,
    within the formula expression within the category "Mathematical functions" you will find the function "TONUMBER". This converts a data element of type currency to a number. According to the help of this function:
    "The following conversion rules apply:
    <Amount>: The number part is returned. The currency unit is omitted."
    This is what you are looking for.
    For the other way round you already mentioned the correct function "TO_AMOUNT"
    BR
    Christian

  • How to configure Level Number of Elements in Dimensional Hierarchies?

    http://gerardnico.com/wiki/dat/obiee/bi_server/design/dimension/level_number_dimension
    Above mentioned link mentions the value to be placed in Level Number of Elements in Dim Hierarchies.But being New to Obiee I am unable to understand.I would appreciate if So one explains in detail.Example would be better.
    Thanks in advance for the cooperation.
    Edited by: user8655160 on Jul 23, 2009 11:46 AM

    Query optimization is based on the order of the tables in the FROM clause of the generated SQL. Tables with many rows appear before tables with fewer rows. This order can be important especially for RDBMS that lack an optimizer feature.
    It's no more the case with the actual databases.
    Example for Oracle : Query optimizer
    http://gerardnico.com/wiki/database/oracle/query_optimizer/start
    By modifying the number of element, you can change their order in the FROM clause but I never test it.
    Cheers
    Nico

  • Number of elements in XML file

    Hi,
    I have an xml file as follows
    <xml>
    <head>
    <h1>xxxx</h1>
    </head>
    <line>
    <name>ravi</name>
    <dept>Oracle</dept>
    </line>
    <line>     
    <name>Kamal</name>
    <dept>Java</dept>
    </line>
    <line>
    <name>Ajay</name>
    <dept>Linux</dept>
    </line>
    </xml>
    I need to insert the above xml file into a table.
    For that i have used the following query.
    insert into dest_table
    SELECT     EXTRACTVALUE (t2.xml_doc, '/xml/head/h1') head,
    EXTRACTVALUE (t2.xml_doc, '/xml/line['||level||']/name') name,
    EXTRACTVALUE (t2.xml_doc, '/xml/line['||level||']/dept')dept
         FROM xml_table t2
         CONNECT BY LEVEL <= n
    Here n in CONNECT BY clause is the number "<line>" elements (3 in the above example).
    If i know the number of <LINE> elements,then i can easily select and insert the xml data.
    BUT How to know the number of particular elements(<line> in above xml) in the above xml using oracle xml oracle.
    any idea psl.
    cheers
    RRK

    select count(1) from table(
        xmlsequence(
            extract(
                XMLType('&lt;root&gt;&lt;a&gt;b&lt;/a&gt;&lt;a&gt;c&lt;/a&gt;&lt;a&gt;d&lt;/a&gt;&lt;x&gt;z&lt;/x&gt;&lt;/root&gt;'),
                '/root/a'
    )

  • How to get the number of elements in a tilelist

    I'm writing test cases for a flex application using FlexSelenium and I need to get the number of elements displayed in the tilelist.
    I know that that the tilelist is fed by an array. but i can't access that array from my test case.
    Can anyone tell me how I can get the number of elements in a tilelist on the application? which property of the tilelist can provide that number?

    try tileList.dataProvider.length;

  • I want to create an array that goes into a case structure where each element in the array is an individual case and gets done in order

    I want to create an array that goes into a case structure where each element in the array is an individual case and gets done in order. Any ideas, I've been playing with the idea but have had no luck, is this even possible?

    Hi,
    Please check it out the attached Vi.. Is this you need?
    Sasi.
    Certified LabVIEW Associate Developer
    If you can DREAM it, You can DO it - Walt Disney
    Attachments:
    Event.vi ‏11 KB

  • SQL Query - The number of columns specified in "SQL Query" does not match t

    I am creating new UDM for tablespace alert, below is my query,however its failing with error
    SQL Query - The number of columns specified in "SQL Query" does not match the value specified in "SQL Query Output"
    I selected Metric type is number
    SQL Query Format : Two columns
    Query:
    SELECT d.tablespace_name,round(((a.bytes - NVL(f.bytes,0))*100/a.maxbytes),2)
    used_pct FROM sys.dba_tablespaces d,(select tablespace_name, sum(bytes) bytes, sum(greatest(maxbytes,bytes)) maxbytes from sys.dba_data_files group by tablespace_name) a,(select tablespace_name, sum(bytes) bytes from sys.dba_free_space group by tablespace_name) f
    WHERE d.tablespace_name = a.tablespace_name(+) AND d.tablespace_name = f.tablespace_name(+)
    AND NOT (d.extent_management = 'LOCAL' AND d.contents = 'TEMPORARY');
    Any clues why i am getting error.

    SQL> SELECT d.tablespace_name,round(((a.bytes - NVL(f.bytes,0))*100/a.maxbytes),2) used_pct
    2 FROM sys.dba_tablespaces d,(select tablespace_name, sum(bytes) bytes, sum(greatest(maxbytes,bytes)) maxbytes from sys.dba_data_files group by tablespace_name) a,(select tablespace_name, sum(bytes) bytes from sys.dba_free_space group by tablespace_name) f
    3 WHERE d.tablespace_name = a.tablespace_name(+) AND d.tablespace_name = f.tablespace_name(+)
    4 AND NOT (d.extent_management = 'LOCAL' AND d.contents = 'TEMPORARY');
    TABLESPACE_NAME USED_PCT
    MGMT_TABLESPACE .82
    SYSAUX 1.52
    UNDOTBS1 .32
    RMAN .02
    CORRUPT_TS 10.63
    USERS 0
    SYSTEM 2.26
    MGMT_ECM_DEPOT_TS .04
    MGMT_AD4J_TS 0

  • Number of elements at logical level / odbc driver

    Hi everyone,
    I'm new in BI area and I cannot understand one basic thing.
    I study documentation about BI server, exactly chapter about "creating dimensions" and I'm confused about setting "number of elements at logical level"
    It looks for me that "number of elements at logical level" is static.
    What will be when someone update data in the table and number of elements will be different than number of elements in our logical level?
    example:
    current column with distinct values:
    channel_desc:
    direct sales
    tele sales
    catalog
    internet
    partners
    in this case I set number of elements at logical level 5.
    after a while some update data in the table and our column looks (see below)
    column after update with distinct values:
    channel_desc:
    direct sales
    tele sales
    catalog
    internet
    partners
    others (added value)
    Does it mean that I have to change it to current numbers of elements?
    I'm sure that this is misunderstanding in my case, but I don't know where?
    Second problem which I have:
    BI with oracle database is on linux
    client software on windows
    I can import data from database like sybase or flat files to the physical model, I can view data, but when I create whole model (physical, bussines model and mapping, presentation) and I try access data from "Answers" I have this error:
    "Data source name not found and no default driver specified"
    regards
    Bart

    Number of elements is just an indication used by the BI Server (e.g. when generating LOV's in Answers). It won't cause any problems when it doesn't hold the exact number of elements available in the dataset.

  • Number of elements - Dimensional Hierarchy

    Hi,
    In a *'Dimensional Hierarchy'*, while creating a new *'Parent level'*, a 'Logical Level' dialogue box prompts for entering *'Number of elements at this Level'*+. What is its significance ?
    What is achieved by+ *'Number of elements at this Level'* +?+
    Thanks in Advance & Regards,
    Deeba

    Hi deeba,
    Its not mandatory to specify the number of elements in hierarchy....if you wont mention also by default it takes the value of 1.....Above vino gave you the link for explanation.
    Hope it helps you...Award points and close the thread.
    By,
    KK

Maybe you are looking for