Run mdx query in batch

Hi,
I am using BW MDX Driver to report off SAP BW data. Sometimes the returned data may be too much according to user selection. My question is, is there any way to run the MDX query in batch, so that the data is not returned all at once?
For opensql or infoset driver, we can configure the query to run in batch by adding some system environment variables. But for MDX, I have no idea now.
Thanks,
Ray

Hi,
Are you including the parameter that you must have created in Crystal Reports in the Select Expert. You need to include the parameter within the record selection or group selection formula of the Select Expert, as may be applicable. Only then the values returned by the database would be in accordance to the input by the user.
For instance, let us assume that you have created the Country parameter in Crystal Reports. In order to return data as per input fed within the County parameter during Report Refresh, the formula in Select Expert would be somewhat like :
{Customer.Country} = {?Country}
Please do this preliminary check before thinking of using Open SQL or InfoSet driver instead of the MDX driver or feeding the environment variables through batch processing.
Regards,
Amogh.

Similar Messages

  • Running MDX Query in BEX

    I've a question regarding MDX Query .
    1.Can we run MDX Query in BEx.
    2.If yes , then can you please tell me how and where can we run MDX Query in BEx.
    Regards,
    -Neha

    Hello,
    BEx does not support MDX. You can use MDXTEST transaction to generate the MDX select statements against queries or infocubes but it cannot be used with BEx.
    Thanks,
    Michael

  • Running MDX query in oracle

    How do i run a mdx query in oracle. Do i need to install any extra component.
    I used the following query and i get an illegal symbol error...
    SELECT
    { [Measures].[sales] } on columns,
    {  [Date].[1998],[Date].[1999] } on rows
    From units_history_fact

    MDX is not supported by Oracle. If the given database uses Oracle OLAP then you can use the simba connector: http://www.simba.com/connectors/mdx-for-oracle-olap.

  • Continue run MDX Query

    I want to execute a query which can continue run till 2 minutes .
    For Example- If I run below query, that should be run for 2 minutes with completion or Fail
    SELECT [Date].[Calendar Year].FirstChild on 0
    FROM [Adventure Works];
    Please Help
    -Ashish

    Hi David,
    This query hardly takes 2 second to complete. But I want that this should be continued  until it completes 2 minutes. Means - session of this query continue till 2 minutes instead it gets complete.
    Hi Ashishsingh,
    As Olaf said, we can use SQL. However, based on my research it seems there is no such a functionally to workaround this in MDX currently. If you have any concern about this behavior, you can submit a feedback at
    http://connect.microsoft.com/SQLServer/Feedback and hope it is resolved in the next release of service pack or product. Your feedback enables Microsoft to make software and services the best that
    they can be, Microsoft might consider to add this feature in the following release after official confirmation.
    Thank you for your understanding.
    Regards,
    Charlie Liao
    TechNet Community Support

  • MS SQL database needs to run mdx query to analysis services to retrieve data from a BPC 10 Netweaver cube(view only)

    We are in the process of migrating from BPC7 SP12 Microsoft sql server to BPC10 netweaver on a sql server with BW7.4 and need to integrate our home grown data warehouse which is on a Microsoft sql server.  The data warehouse currently connects to BPC7 using integration services/analysis services and runs mdx queries to analysis services to retrieve data from the BPC7 cube (view only).  Please provide documentation on how to create this same integration with our data warehouse using BPC10 netweaver on a sql server.

    When you were setting up your ODBC data source for
    the Text driver, did you click on the "Options"
    button? There's a lot of options in there that I
    didn't understand at first glance.Yes I clicked on the options button, but the only thing there is dealing with file extensions. I left it set to the default.
    I have since tried closing my connection after I insert a record, I then try executeQuery, but still no luck. Seems strange that I can write to the file but not read from it. If any thing I'd expect the opposite problem.
    I have also tried using the class "JoltReport" from the sun tutorial instead of my own with the same result.
    Message was edited by:
    Hentay

  • Long running MDX-query

    Table [Summary Requests] (count: 102 131):
    Id Int primary key
    RequesterFullNameId Int
    Dimesion [Dm Requester Full Names] (count: 50 124):
    Id Int primary key
    Title VARCHAR(1000)
    Dimesion [Dm Date] (count: 1 306):
    FullDate DateTime первичный ключ
    Year Int
    1) Query execution lasts
    5 seconds. Is it normal or not?
    2) Аre there ways to reduce the query execution time?
    Query example:
    with
    member [Measures].[XtraPivotGrid 1505778211 Sort] as '[Dm Date].[Year].currentmember.member_value'
    member [Measures].[XtraPivotGrid 1025407302 Sort] as '[Measures].[Summary Requests Count]'
    select
    non empty { { [Dm Date].[Year].[All], { order({{[Dm Date].[Year].[Year].members}}, [Measures].[XtraPivotGrid 1505778211 Sort], asc)} }  * { [Measures].[Summary Requests Count]}} dimension properties MEMBER_UNIQUE_NAME,MEMBER_TYPE,MEMBER_VALUE  on
    columns,
    non empty { [Dm Requester Full Names].[Title].[All], { order({{[Dm Requester Full Names].[Title].[Title].members}}, [Measures].[XtraPivotGrid 1025407302 Sort], desc)} }
    dimension properties MEMBER_UNIQUE_NAME,MEMBER_TYPE,MEMBER_VALUE  on rows
    from [Elicense Reports]
    where
    ( [Is Deleted].[Title].&[Нет] )

    Hi Captainsir,
    According to your description, the query execution lasts  5 seconds before return the results, and you want to know if it is normal or not, right?
    In your query, you used CrossJoin function to join multiple dimensions which might cause the performance issue. If you cross-join medium-sized or large-sized sets (e.g., sets that contain more than 100 items each), you can end up with a result set that contains
    many thousands of items—enough to seriously impair performance. For the detail information, please see:
    http://sqlmag.com/data-access/cross-join-performance
    Here is a blog which describe ways of improving MDX performance and improvements with MDX, please see:
    http://blogs.msdn.com/b/azazr/archive/2008/05/01/ways-of-improving-mdx-performance-and-improvements-with-mdx-in-katmai-sql-2008.aspx
    Hope this helps.
    Regards,
    Charlie Liao
    TechNet Community Support

  • Run sql query through batch file

    how to create a batch file so that on running the batch file,
    I should get into the database using username and password and create the table and insert values inside that table

    kindly, if you are using windows you can create 2 files as following:
    a.bat
    b.sql
    put the files under spacific folder for example d:\bat folder
    -first file a.bat will contain the following:
    sqlplus apps/apps@yourdb @d:\bat\B.sql
    exit
    -second file b.sql will contain any sql statments you want as following:
    create table a (a1 number, a2 varchar2(100))
    insert into a (a1,a2) values(1,'Test')
    commit
    exit;
    hope this help you
    Regards ...
    Edited by: shedo76 on 28/04/2012 03:14 ص

  • MDX Query not retuern any data on my production server when i check service it is running

    Hi All,
    MDX Query not return any data  on my production server when i check service it is running. when i restart my service  i can able to run MDX Query and get data in my production server.

    Hi Mnishcal,
    According to your description, there is no data returned before restart Analysis Services, right?
    We haven't experiencing such issue before. And we cannot reproduce this issue. In your scenario, can you reproduce this issue? Here is a post which explains why you might not see the data you expect when browsing a SQL Server Analysis Services cube that
    processed successfully. Please refer to the link below.
    http://social.technet.microsoft.com/wiki/contents/articles/19744.ssas-troubleshooting-data-is-not-visible-when-browsing-a-cube.aspx
    Besides, are there any error on the log file? The msmdsrv.log file for the SSAS instance that can be found in \log folder of the instance. (C:\Program Files\Microsoft SQL Server\MSAS10.MSSQLSERVER\OLAP\Log)
    Regards,
    Charlie Liao
    TechNet Community Support

  • Controlling meta data returned by an MDX query

    Hello,
    I'm retrieving results from Analysis Services then processing them further in SQL via OpenQuery. So I have a query of the form "select * from OpenQuery(LinkedServer, '<mdx>')
    The query works fine, but because I have a dimension hierarchy with a seven levels on rows, the result set contains seven columns which I don't need, one column for each level in the hierarchy.
    I can ignore them using the syntax "WITH CTE ([1],[2]...) as (<query>) ...", so this doesn't interfere with functionality.
    However, I'm wondering if there is some syntax in MDX which will prevent those columns from being returned at all. I'm guessing that regardless of whether they are selected in SQL, that data still has to be processed. The performance impact of this isn't
    noticeable on any single query, but it seems like for many queries with many rows it would add up. Is it possible to control the meta data that an MDX result set contains?
    Thank you!

    Hi vercinegetorix,
    When we run MDX query by using OPENQUERY having hierarchy, we will get extra columns describing the values of each hierarchy level in different columns. This behavior is by design and we can't change that.
    In addition, we may concern the attribute unique name a little long. The easiest way to remove them is to use an alias. For detail information, please refer to the article below:
    MDX + T-SQL: Combining relational and multi-dimensional data into one query result set:
    http://sqlblogcasts.com/blogs/drjohn/archive/2008/09/27/mdx-and-sql-combining-relational-and-multi-dimensional-data-into-one-query-result-set.aspx
    If you have any feedback on our support, please click
    here.
    Elvis Long
    TechNet Community Support

  • Getting the MDX query select error when running a webi report on BI query

    Getting the following error when running a webi report on BI query :
    A database error occured. The database error text is: The MDX query SELECT  { [Measures].[D8JBFK099LLUVNLO7JY49FJKU] }  ON COLUMNS , NON EMPTY [ZCOMPCODE].[LEVEL01].MEMBERS ON ROWS FROM [ZTEST_CUB/REP_20100723200521]  failed to execute with the error Unknown error. (WIS 10901).
    I have gone through many threads related to this error. But not able find the steps to follow for resoultion.
    Please help in this regard.
    Thanks,
    Jeethender

    The Fix Pack is also for Client Tools--it is a separate download.  Please see the text below for ADAPT01255422
    ADAPT01255422
    Description:
    Web Intelligence generates an incorrect MDX statement when a characteristic and a prompt are used.
    The following database error happens: "The MDX query ... failed to execute with the error
    Unknown error (WIS 10901)."
    New Behavior:
    This problem is resolved.
    This information is also available in the Fixed Issues document for any Fix Pack greater than 2.2.

  • MDX query Running slow in SSRS than in SSMS

    Hi,
    I have a SSRS report which takes 37 secs to execute a single MDX query whereas the same query takes less than 1 sec in SSMS.
    I tried removing the parameters and hardcoding default values, still it takes same time. I also tried using OLE DB data source which also takes same time.
    Please help.

    Hi Purush,
    According to your description, the query execute time in SQL Server Management Studio (SSMS) takes less than that in SQL Server Reporting Services (SSRS) report, right? As per my understanding, this is normal phenomenon. Because when we run a query on the
    query designer of the report, first we need pass the query to database, then execute the query and then return the result to query designer. So this 1 second can the time that used to pass the query to database and return the result.
    Hope this helps.
    Regards,
    Charlie Liao
    TechNet Community Support

  • MDX query runs on SQL but does not populate 'Measures' in Powerpivot

    I ran MDX query on SQL 2012 for looking the products and their shipping status
    The code is given below:
    WITH 
    set Date1 AS 
         strtomember( "[Time].[2014].[Q4].[2014-Jun].[" +format(now()-2, "MM") + "/"+format(now()-2, "dd") + "/" +format(now()-2, "yyyy") + "]")
    set Item1 as
    { [Item].[ItemID].ALLMEMBERS}
    SELECT NON EMPTY { [Measures].[Shipped Qty], [Measures].[Shipped Amt], [Measures].[Ordered Qty], [Measures].[Ordered Amt] }
    ON COLUMNS, 
    Date1*[Item1] ON ROWS FROM [ABCD]
     WHERE ( 
                 [Channel].&[OL], 
                 [Geography].&[A.9])
    The query gives desired output when run in SQL. But when I run the same query in while pulling data in PowerPivot, Dimensions i.e. Date and Item are populated but measures were not populated. Can anyone please help me understand how to populated Measures
    in PowerPivot?
     

    Hi apoorv,
    It was hard to reproduce this issue on my test environment. I would suggest you try to use a simple MDX query to check if it will retrun the correct measures data. Please see the screenshot below:
    In addition, you can also create a SQL Server Analysis Services trace to capture some events for furhter investigation.
    Use SQL Server Profiler to Monitor Analysis Services:http://technet.microsoft.com/en-us/library/ms174946.aspx
    Hope this helps.
    Elvis Long
    TechNet Community Support

  • How MDX query will work while we run BOXIR3 query!

    Hi All,
    I am facing lots peformance issues in terms of reports while running.
    Can somebody can explain how the query runs at backend like when we hit Run query in Webi how it functioins.When the MDX Query will be generated and how the query hits the BI/Underlying database.
    I am basically looking out what happens behind the screen when we run a report in Back end etc.
    I am using BI7.0 and BOXIR3.. Thanks in advance for reply.

    ok Thanks for your reply.Here are the answers for your questions.
    I)how many items are in the BI query ?
    52 dimensions it has and 15 keyfigures(ckfs,Rkfs) and around 250 details objects
    but we are using only the dimension objects in reports,we are not using detail objects I mean to say hardly 3 detail objects we are using in each report.
    Since these objects are navigationla attributes they are automatically created in universe as detailed objecs.So if we remove the detail objects does the performance will increase considerably?
    CAN YOU PLEASE COMMENT ON THIS
    II)how many items are using in the Web Intelligence query panel for each report ?
    In webI Query Panel roughly for each report we are using 10 Dimensions and 5 Keyfigures(Including Ckf,Rkfs) with 6 Prompts
    III)Do the reports share characteristics ? If yes - how many ?
       Yes they share charactorstics .Maximum upto 7 Characterstics  which are shared among the reports like Country,Post code,Group,Tier

  • Filters not getting passed in MDX query while using SAP BW with OBIEE

    Hello,
    I've been working on OBIEE with SAP BW as back-end. I've created some reports & those are working fine when there is less amount of data. But when I try to run a report with 3 dimensions & 1 fact it throws an error saying "No more storage space available for extending an internal table". When I checked MDX query, I found that the filters that I had applied to request & also selected from prompts are not getting passed in that query. So, I tried running a simple request using a simple filter in Answers. Although this request returns results but I can't see filter conditions in query. MDX query always show crossjoin but I can't see filter conditions anywhere.
    Is it the normal OBIEE behaviour OR am I doing something wrong in there? Can you please help me out with this?
    Thanks,
    Rocky

    Hello Sainath,
    We tried those things. But it is still giving same error.
    State: HY00. Code: 10058. [NQODBC][SQL_STATE:HY000][nQSError: 10058] A general error has occurred. XML/A error returned from the server: Fault code: "XMLAnalysisError.0X80000005". Fault string: "The XML for Analysis provider encountered an error: MDX result contains too many cells (more than 1 million)". (HY000)
    The problem here, I think, is the filter parameters are not getting passed in the MDX query. Any idea why would that happen? Is there any setting to do so?
    Thanks in advance for help.
    Regards,
    Rocky

  • SSAS Tabular : MDX query goes OutOfMemory for a larger dataset

    Hello all,
    I am using SSAS 2012 Tabular to build the cube to support the organizational reporting requirements. Right now the server is Windows 2008 x64 with 16GB of Ram installed. I have the following MDX query. What this query does is get the member caption of the
    “OrderGroupNumber” non-key attribute as a measure where order group numbers pertain to a specific day and which occurs in specific seconds of a day. As I want to find in which second I have order group numbers, I cross the time dimension’s members with a specific
    day and filter the tuples using the transaction count. The transaction count is a non-zero value if an Order Group Number occurs within a specific second of a selected day.
    At present “TransactionsInflight].[OrderGroupNumber].[OrderGroupNumber]” has 170+ million members (Potentially this could grow rapidly) and time dimension has 86400 members.
    WITH
    MEMBER [Measures].[OrderGroupNumber]
    AS IIF([Measures].[Transaction Count] > 0, [TransactionsInflight].[OrderGroupNumber].CURRENTMEMBER.MEMBER_CAPTION,
    NULL)
    SELECT
    NON EMPTY{[TransactionsInflight].[OrderGroupNumber].[OrderGroupNumber].MEMBERS}
    ON COLUMNS,
    {FILTER(([Date].[Calendar Hierarchy].[Date].&[2012-07-05T00:00:00], [Time].[Time].[Time].MEMBERS),
    [Measures].[Transaction Count] > 0) } ON
    ROWS
    FROM [OrgDataCube]
    WHERE [Measures].[OrderGroupNumber]
    After I run this query it reaches to a dead-end and freezes the server (Sometimes SSAS server throws OutOfMemory exception but sometimes it does not). Even though I have 16GB of memory it uses all the memory and doing nothing. I have to do a hard-reset against
    the server to get the server online. Even I limit the time members using the “:” range operator still the machine freeze. I have run out of solutions to fine-tune the design. Could you guys provide me some guidelines to optimize this query? I am willing to
    do a design change if it is necessary.
    Thanks and best regards,
    Chandima

    Hi Greg,
    Finally I found the problem why the query goes out of memory in tabular mode. I guess this information will helpful for others and I am posting my findings.
    Some of the non-key attribute columns in the tabular model tables (mainly the tables which form dimensions) do not contain pretty names. So for the non-key attribute columns which I need to provide pretty names I renamed the columns to something else.
    For an example, in my date dimension there is a non-key attribute named “DateAltKey”. This is the date column which I am using. As this is not pretty to the client tools I renamed this column as “Date” inside the designer (Dimension
    design screen). I deployed the cube, processed the cube and no problem.
    Now here comes the fun part. For every table, inside the Tables node (Tabular SSAS Database > Tables) you can view the partition details. You have single partition per dimension table if you do not create extra partitions. I opened the partitions screen
    and clicked on the “Edit” icon and performed a Syntax Check. Surprisingly it failed. It complains about the renamed column. It complained “Date” cannot be found in source. So I realized that I cannot simply rename the columns like that.
    After that I created calculated columns (with a pretty name) for all the columns which complained and all the source columns to the calculated columns were hid from the client tools. I deployed the cube, processed the cube and performed a
    syntax check. No errors and everything were perfect.
    I ran the query which gave me trouble and guess what... it executed within 5 seconds. My problem is solved. I really do not know who did this improve the performance but the trick worked for me.
    Thanks a lot for your support.
    Chandima

Maybe you are looking for

  • Emails can not be saved to drafts, emails can not copy to sent.

    Email will not save messages as they are typed to drafts. Emails when sent can't save messages to the send box. Are they still sent to the recipient? The alerts that come up say "message append failed" Disc quota exceeded and "alert" The size of the

  • File to RFC, and through RFC response i am trying to trigger the Mail adapt

    Hi All, Right now i am doing File to RFC, its working fine but now the requirement is when xi connect to ftp and picks the  file need to send one success mail after the file pickup and data sent to BW system again i need to send one mail and also err

  • HTML5 API - Heat Layer Points Not Working

    Hi everyone, Really weird issue this, and I am honestly at a loss to explain what's going on, so hopefully someone can spot my mistake! I want to overlay a density-based heat map over a map of Britain, based on longitude/latitude points stored in OBI

  • Very urgent Thanks in advance

    Hi sdn Experts, 1) hi everyone iam ABAPER i have problem in fico module i.e i want to modify the standard report RFITEMGL (Line Items general Ledger a/c), it is displaying individual accounts. but my requirement is, i want 2 add " Opening and Closing

  • Photoshop CS6 extended student &teacher edition.

    I have purchased photoshop CS6 extended student &teacher edition.  How do I prove my student status? and obtain a serial number? Thanks Robin