Alter express code to include views and unions for top dim items

If a user selects a dimension item at the top most level, the explain plan shows that it does a full table scan of the fact table instead of using the materialized views. If we add the highlighted information(see below) to the osa generated sql, then the explain plan does what we want it to do.
Do you know if it is possible to alter the express code to include the views and unions for the dimension items that are at the top most level in the hierarchy? I think that I need to alter how the sq.query.drv program figures out what to include in the sql. But this is beyond my express comfort level.
The query below is generated by the osa cube and we want to include the highlighted information in the sql that is generated which will force it to use the correct query rewrite and return data in a reasonable time frame.
Is this possible and has anyone tried this before?
SELECT 'B4' || lt2.acct_lvl_4_id
, 'C2' || lt6.cust_grpng_id
, 'G1000'
, 'L1000'
, 'O190012880'
, 'P1000000000'
, 'R100001'
, 'T3' || lt25.mth_id
, 'E190'
, SUM (ft34.usd_curr_pl_amt)
FROM osa_fivcas_mth_ifct_gbl_992 ft34
, osa_fivcas_acct_992 lt2
, osa_fivcas_cal_mastr lt25
, osa_fivcas_cust_898_000 lt6
-- Extra Tables
, osa_fivcas_geo_942 lt20
, osa_fivcas_org_817 lt22
, osa_fivcas_prod_710 lt23
WHERE lt2.acct_lvl_9_skid = ft34.acct_lvl_9_skid
AND lt6.cust_lvl_10_skid = ft34.cust_lvl_10_skid
AND lt25.mth_skid = ft34.mth_skid
-- Extra Join Conditions
AND lt20.geo_lvl_8_skid = ft34.geo_lvl_8_skid
AND lt22.org_lvl_12_skid = ft34.org_lvl_12_skid
AND lt23.fpc_skid = ft34.fpc_skid
AND lt2.acct_lvl_4_id IN ('81013286')
AND lt6.cust_grpng_id IS NOT NULL
AND lt25.mth_id IN ('AUG08')
GROUP BY 'B4' || lt2.acct_lvl_4_id
, 'C2' || lt6.cust_grpng_id
, 'G1000'
, 'L1000'
, 'O190012880'
, 'P1000000000'
, 'R100001'
, 'T3' || lt25.mth_id
, 'E190';

David,
When u add a field to a header table. U can use the User data source to bind it. Even if u add the DBDatasource the Coulmn needs to be present in the DB at the time of setting the data source to the Field in the UI.
Actually if u add a header filed to the DB it pops up on the User-Fields Form i guess u can use it as no extra code is needed. To view the UDF form VIEW--User Defined Fields.
Hope it helps,
Vasu Natari.

Similar Messages

  • BED, AED and SED for the excise item is zero,Message no. 4F122

    Hi,
    While doing GR system issuing msg "  BED,AED and SED for the excise item is zero.Message no. 4F122,
    Chapter ID,mat chapter ID Comb,Cenvat determ,Vendor excise ,excise tax rate Maitained properly and cross verified twise.
    We are using TAXINJ procedure. Tax code maintaied and % maintained for Tax code.
    Any bady point out what exaclty CIN config missed out? why PO tax value are not flowing in MIGO.
    After manully putting value in MIGO also excise invoice (Capture excise invoice ) is not getting created. i am not able to view in J1IEX.
    Regards,
    Anil

    Hi anil kumar,
    I think you have maintained the any of these Excise details.
    Maintain
    >Chapter ID
    >Material & Chater ID Combination
    >Assesable Value
    >Cenvat Determination
    >Vendor Excise Details ( Check the Excise Indicator) as 1
    >Check the tax code assigned
    Please maintain and let me know.
    Thanks,
    Swamy H P

  • BED, AED and SED for the excise item is zero

    Dear ALL,
    I am working on IMPORT MATERIAL  GOODS RECEIPT,  
    While  doing MIGO  in excise  item tab  BED, AED, SED   values  are  visible  and  material document is  generated, but while posting  PART1 ENTRIES  through J1IEX  System is throwing error" BED, AED and SED for the excise item is zero"  and the  excise values are not flowing in to PART1, 
    IN J1IEX PART1 Entries
    1.IN DUTY RATE TAB all the entries like BED, AED, SED are zero,
    2. IN DUTY VALUES TAB all entries are zero
    ERROR MESSAGE NO 4F122
    Please suggest
    ARABBAS

    Dear,
      Please check this,
      [Excise;
      [BED Value not defaulted in GR;
    Sandip

  • How to get the Equipements number and desciption for the contract item ?

    Hi Gurus,
            How to get the Equipements number and desciption for the contract item items? It would gr8 helpful to me...
    VBAP,,EQUI,,,,,,?
    Thanks
    Krisna

    Check with below tables :
    EQUI    Equipment master data
    EQKT   Equipment short text
    EQUZ   Equipment time segment
    Thanks
    Seshu

  • Same Code in ordinary view and Materialised View is performing differentl

    I am currently working on a Data Warehouse Project hooked off the back of an accounting system. It takes data from an old system and data from a new system and uses both for Corporate Reporting.
    For Historical and Legacy Reporting reasons it is necessary to keep the Transaction Codes in the system at three characters. so anything that occurs that is less than three characters is padded to the left with zero's.
    The line of code that does this is ...
    CAST(LPAD(TRIM(TransactionCode),3,0) AS VARCHAR2(3)) AS TransactionCode
    There are then 2 Views.
    The first is a Materialised View, this contains 21 days worth of data for short term reporting and manipulation. In here this code seems to work perfectly.
    The second is an ordinairy real time View that spans all data available, within here the Transaction Codes are not padded, but remain at their random 1 or 2 digit lengths.
    In both views the field is defined as a VARCHAR2(3)
    This is not a data issue, as the 21 days will fall within the ordinairy view and there are no examples in the ordinary view of this working.
    The only thing that I can think of is if the character that is used for padding in the LPAD statement needs to be in quotes, I will try this, but I dont get why this would work in a Materialised View and not a View.
    Can anyone shed any light on why this might occur ???
    Many Thanks in advance
    Regards
    Craig Golby
    Dignitas Ltd
    http://www.dignitas.ltd.uk

    I am currently working on a Data Warehouse Project hooked off the back of an accounting system. It takes data from an old system and data from a new system and uses both for Corporate Reporting.
    For Historical and Legacy Reporting reasons it is necessary to keep the Transaction Codes in the system at three characters. so anything that occurs that is less than three characters is padded to the left with zero's.
    The line of code that does this is ...
    CAST(LPAD(TRIM(TransactionCode),3,0) AS VARCHAR2(3)) AS TransactionCode
    There are then 2 Views.
    The first is a Materialised View, this contains 21 days worth of data for short term reporting and manipulation. In here this code seems to work perfectly.
    The second is an ordinairy real time View that spans all data available, within here the Transaction Codes are not padded, but remain at their random 1 or 2 digit lengths.
    In both views the field is defined as a VARCHAR2(3)
    This is not a data issue, as the 21 days will fall within the ordinairy view and there are no examples in the ordinary view of this working.
    The only thing that I can think of is if the character that is used for padding in the LPAD statement needs to be in quotes, I will try this, but I dont get why this would work in a Materialised View and not a View.
    Can anyone shed any light on why this might occur ???
    Many Thanks in advance
    Regards
    Craig Golby
    Dignitas Ltd
    http://www.dignitas.ltd.uk

  • Anyway to have source code html, design view and CSS open windows at the same time?

    Hi all,
    Is there anyway I can keep design view, source code AND css open on screen all at the same time?
    Constantly clicking between source and css is really becoming irritating, would be so much easier if they were both on screen at the same time.
    Any help would be great

    You have two choices.
    1 You can go to preferences>general and the very first item (in CS6) is "open document in tabs" if you deselct that then you can view your page in split view and also open up the CSS file and have it visible as well.
    2 If you use tabs you can view the page in split view and open the CSS file and then detach the css from the tab and it will be an idependent item. You detach it by highlighting the tab and then dragging it down.
    It helps to have a large screen, and better still to have more than one screen, you can put the css on the other screen.
    VL Branko

  • Mandatory Views and Fileds for Material Types

    Hi
    We require the below, Whr can i get this. If any one hv the below requ pls sedn to this srcn dot ram at hot mail dot com
    The requ is we need to know wat are all the mandatory views and mandatory fileds for all std material types provided by SAP.
    When we create a matl with respect to one matl type its ask so many fileds as mandatory and so many fileds as optionsal and display.
    I need to know.. whr can i ge this.. is thr any doc or link for that.
    Vijay

    Never post Mail ids in SAP Forums. what ever the Information you need ask here.
    You can Check in OMSR & OMS9.
    For more Similar threads use SDN search.

  • View Memo option for a work item

    Hello,
    I am trying to include the "View Memo" option for a couple of different work items in UWL under the "You can also" section.
    The View Memo shows up fine for one work item and doesn't show up for the other. However I have similar UWL configuration for both items.
    Can any one suggest what is needed to include the View Memo option. I thought that the following tag should do it:
    <Action reference="viewMemos"/>
    The View Memo does not work for the following item: (Does not show up):
    <ItemType name="uwl.task.webflow.decision.TS20000131.ECCCLNT200" connector="WebFlowConnector" defaultView="DefaultView" defaultAction="com.sap.pct.erp.mss.tra.action.DisplayExpenseForm" executionMode="default">
          <ItemTypeCriteria systemId="ECCCLNT200" externalType="TS20000131" connector="WebFlowConnector"/>
          <CustomAttributes>
            <CustomAttributeSource id="WEBFLOW_CONTAINER" objectIdHolder="externalId" objectType="WebflowContainer" cacheValidity="final">
              <Attribute name="TripNumber" type="string" displayName="Trip Number"/>
              <Attribute name="EmployeeNumber" type="string" displayName="Employee Number"/>
            </CustomAttributeSource>
          </CustomAttributes>
          <Actions>
            <Action reference="viewMemos"/>
           <Action reference="addMemo"/>
            <Action reference="com.sap.pct.erp.mss.tra.action.DisplayExpenseForm"/>
            <Action name="com.sap.pct.erp.mss.tra.action.approver.ApproveTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
              <Properties>
                <Property name="decisionKey" value="1"/>
              </Properties>
              <Descriptions default="Approve Trip"/>
            </Action>
            <Action name="com.sap.pct.erp.mss.tra.action.approver.SendBackTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
              <Properties>
                <Property name="UserDecisionNote" value="mandatory"/>
                <Property name="decisionKey" value="2"/>
              </Properties>
              <Descriptions default="Send Trip Back for Corrections"/>
            </Action>
            <Action name="com.sap.pct.erp.mss.tra.action.approver.RejectTrip" groupAction="yes" handler="UserDecisionHandler" returnToDetailViewAllowed="no" launchInNewWindow="no">
              <Properties>
                <Property name="UserDecisionNote" value="mandatory"/>
                <Property name="decisionKey" value="3"/>
              </Properties>
              <Descriptions default="Reject Trip"/>
            </Action>
          </Actions>
        </ItemType>
    The View Memo option works fine for the following UWL item: (shows up fine)
    <ItemType name="uwl.task.webflow.TS20000189.ECCCLNT200" connector="WebFlowConnector" defaultView="DefaultView" defaultAction="launchWebDynPro" executionMode="default">
          <ItemTypeCriteria systemId="ECCCLNT200" externalType="TS20000189" connector="WebFlowConnector"/>
          <CustomAttributes>
            <CustomAttributeSource id="WEBFLOW_CONTAINER" objectIdHolder="externalId" objectType="WebflowContainer" cacheValidity="final">
              <Attribute name="TripNumber" type="string" displayName="Trip Number"/>
            </CustomAttributeSource>
          </CustomAttributes>
          <Actions>
            <Action reference="viewMemos"/>
            <Action reference="addMemo"/>
            <Action name="launchWebDynPro" groupAction="" handler="SAPWebDynproABAPLauncher" returnToDetailViewAllowed="yes" launchInNewWindow="yes" launchNewWindowFeatures="resizable=yes,scrollbars=yes,status=yes,toolbar=yes,menubar=yes,location=no,directories=no">
              <Properties>
                <Property name="WebDynproApplication" value="FITE_EXPENSES"/>
                <Property name="newWindowFeatures" value="resizable=yes,scrollbars=yes,status=yes,toolbar=yes,menubar=yes,location=no,directories=no"/>
                <Property name="DynamicParameter" value="WI_ID=${item.externalId}"/>
                <Property name="openInNewWindow" value="yes"/>
                <Property name="SAP_FITV_TRIPNO" value="${item.TripNumber}"/>
                <Property name="SAP_FITV_ACTION" value="CHG"/>
                <Property name="System" value="SAP_ECC_HumanResources"/>
                <Property name="WebDynproNamespace" value="sap"/>
                <Property name="display_order_priority" value="5"/>
              </Properties>
              <Descriptions default="Correct Trip"/>
            </Action>
          </Actions>
        </ItemType>
    Can anyone suggest what is the difference between the above two tasks.
    Thank You,
    Jaya R

    Hi Jaya,
    The reason why you are seeing this with the first task is because you are using the action handler UserDecisionHandler, more specifically UserDecisionNote.  This is what defines the memo box.  You can see the other workitem is not of type decision and is not using the UserDecisionHandler, therefore you can't just add a memo box.  If you want to add a memo box to the other workitem, you will need to configure it like the first and check the decisions also in the backend system through the function module: SAP_WAPI_DECISION_READ or SWK_DECISION_READ.  You can find more information here:
    http://help.sap.com/saphelp_nw70/helpdata/en/7a/df014b037141ca9afc6433ed42b519/content.htm
    Best Regards,
    Beth Maben
    EP - Senior Support Consultant
    AGS Primary Support, Business Suite & Technology
    Please see the UWL Wiki @
    https://www.sdn.sap.com/irj/scn/wiki?path=/display/bpx/uwl+faq  ***

  • Version History for a Document Library - Can't view version history for only 1 item

    It is a Document Library with around 8 items. Each of the items have around 60-178 versions.
    I checked programmatically that this particular item had 63 versions.
    I am getting the foll. error when I try to view the version history for that 1 particular item.. it works for all other items in the same list.
    Unable to complete this operation.  Please contact your administrator.   at Microsoft.SharePoint.Library.SPRequestInternalClass.GetFileVersions(String bstrWebUrl, String bstrFileUrl, Object& pvarVersions, UInt32& pdwcVersions)
       at Microsoft.SharePoint.Library.SPRequest.GetFileVersions(String bstrWebUrl, String bstrFileUrl, Object& pvarVersions, UInt32& pdwcVersions)
    This is what I tried so far..
    I tried programmatically deleting few verisons for this item - no luck.
    I ended up deleting all the versions for this item - still I get the same error.
    I tried editing other items to see if their version history still works after new versions get added and it worked.
    This is despite the fact that other items that are working have number of versions  as 178, 130, 63 and so on.
    I appreciate any help.
    Thanks.

    Mike, 
     I don't think it is a programming question. It's a sharepoint browsing question.
    I have a document library with Versioning set to Create major versions.
    In that document library, I have around 8 documents, each of which has versions. Only for 1 particular document, when I try to see the versions by clicking 'Version History', I get the error as stated above.
    For all other documents, Version history works.
    My initial thought was that may be the document in question had too many versions and that's why it's failing but I was able to check that the document (in question) had 63 versions while there are still other documents in the same list which has 178 versions and 'Version History' is still working.
    I further explained all my efforts done so far in order to resolve this issue (none of which worked.)
    I deleted all versions (I couldn't delete it from IE since I can't even get to the page where it says 'Delete All Versions' - thus I wrote a small program to delete all versions for this document.)
    I also tried modifying other documents to see if a version history is being created for other documents and that is happening.
    Thanking you in anticipation..

  • Issue in finding  GR posting date and quanity for Purchase order item

    Hi All,
    I have a requirement to list all PO items with Goods receipt posting date and quantity.
    So for each po item I have fetched Goods receipt posting date and quantity from table EKBE for movement type 101.
    But in transaction ME23n   in PO history tab it is displaying 3 records.
    2 are movement type 101 and 1 is movement type 102 GR quantity with minus sign.
    How  to find out Goods receipt posting date and quantity.
    what are the movement types we  have to consider.
    Thanks,
    Jwala

    movement type 102 is for GR for PO reversal that is why the quantity is negative.

  • Difference in amount in sales order and billing for one line item

    Hi experts,
    User created one sales order with three line items say line item10, line item20
    Line item 30.Line item 10 value is 5024.26 EUR in sales order. He did delivery for three line item and invoiced. But the problem is that the line item 10 value is changed i.e. 5024.28 EUR in Billing and the remaining line item values are correct. All the line items having same item category.
    I asked the user to cancel the invoice and PGI. He did that. And again he created the PGI and Invoice. But the value of line item 10 become 5024.27 EUR and again he cancels the invoice and the PGI. and again he created the PGI and Invoice. Now the value of line item 10 is correct i.e. 5024.26EUR in invoice.
    Note: No changes are carried out from sales order to billing and even in material also.
              I checked copy control settings also all are correct.

    Is the Item Category of that item different from the rest. If yes for that item probably pricing is redetermined. However if its the same somebody might have changed it manually.
    If all the item have same category then it is possible that repricing is carried out for all the items however it found new condition record only for that perticular item.
    Rings a bell ?
    Regars

  • Amount Difference in sales order and billing for one line item

    Hi experts,
    User created one sales order with three line items say line item10, line item20
    Line item 30.Line item 10 value is 5024.26 EUR in sales order. He did delivery for three line item and invoiced. But the problem is that the line item 10 value is changed i.e. 5024.28 EUR in Billing and the remaining line item values are correct. All the line items having same item category.
    I asked the user to cancel the invoice and PGI. He did that. And again he created the PGI and Invoice. But the value of line item 10 become 5024.27 EUR and again he cancels the invoice and the PGI. and again he created the PGI and Invoice. Now the value of line item 10 is correct i.e. 5024.26EUR in invoice.
    Note: No changes are carried out from sales order to billing and even in material also.
              I checked copy control settings also all are correct.

    Hi
    I think this is standard SAP issue of rounding the condition records at item level. Can you please share the netvalue for all the three items and the header net value at sales order and invoice level.
    kind regards
    sandeep

  • Creating a Display View and passing back the selected items

    Hello All,
    I will like to create the below scenario and will like to seek feedbacks and suggestions on how to do so in the best way.
    <u><b>Scenario</b></u>
    1) User enters his lastname and press a submit button (this is done in the initial window which contains UI elements that needes to be populated with the search results),
    2) The submited name is passed to the backend for searching,
    3) Results is then thrown back to the user in <b>ANOTHER</b> window in the form of a selection table. Here, the window will display a list of all matching lastnames.(Even if there is only 1 search result)
    4) User is required to select his own last name from the table and his info will be populated in the respective UI elements in the view of the initial window.
      Feedbacks and suggestion will be greatly appreciated. Thnak you very much.
    from
    Kwok Wei

    Define 2 views, "Search" and "Result", define a custom controller (or use the component controller) with a context containing all relevant data (entered name, result list). Define a controller usage from both view controllers to the custom controller, map both view contexts to the custom controller context.
    This will allow both view controllers to access the data entered in "Search" and the results from the backend displayed in "Result".
    For the navigation between "Search" and "Result", use the navigation modeller to define plugs and navigation links. In the event handler of the "search" action, navigate to the "Result" view, in the event handler of the result selection (e.g. a handler for IWDTable.onLeadSelect), navigate back to the "Search" view.
    Armin

  • How to get Item-Code wise stock quantity and value for a previous date

    Dear Sir,
    As per the government legal requirement , we are required to furnish a list for items having stock as on a date ( date is not the current date but it is some past date)  and  in the list we need to provide material wise stock quantity and value .
    We can generate a list  for the current date , but do not know how to get it for a previous date .
    We request you to kindly guide us about such a list .
    With Thanks and Regards
    Sonia Agarwal

    hi,
    might be this reports will be help full for your requirement.
    MMBE
    MB53
    MB52
    MB5M
    MB5B
    MB5T
    MBLB
    MBBS
    MB54
    ME56
    Thanking you

  • How to get only the filename and extension for a text item?

    Suppose there is a non-database text item called :myfilename
    :myfilename := 'C:\SomeFolder\SomePath\myfile.doc';
    I would like to get the file name only without the full path,
    i.e. myfile.doc
    and the file extension, i.e. 'doc', 'bat', 'java', 'xhtml' etc., i.e. the last few chars from the right to the period.
    Any help is welcome.

    Thanks for the hints.
    I defined the non-database Text Item called FULLFILENAME and another two text items called FILE_NAME, FILE_EXTENSION. The following can extract the file extension,
    select substr(:FULLFILENAME,instr(:FULLFILENAME,'.')+1) into :FILE_EXTENSION from dual;
    e.g.
    :FULLFILENAME := 'C:\MyFolder\AnotherFolder\file.doc';
    FILE_EXTENSION becomes 'doc'
    but I would also like to extract only the filename without path into FILE_NAME,
    i.e. file.doc
    Please give more hints. Thanks.

Maybe you are looking for

  • Report with Default Value

    hi, in a report i want to display defualt value instead of null or blank. Actually in my report one column contains null values, on this column i put a link, if the value is null then on a report it display blank space without box. it doesn't look go

  • Lion is no longer available from the App Store, but I haven't gotten it yet.

    I purchased Lion from the App Store on October 27th, but then realized I could not download it yet due to bandwidth restrictions at school (though I did download it once, but the file corrupted and I went over the bandwidth limit, causing my Internet

  • Automated Resizing of Images in Photoshop Elements 9

    I recently upgraded my wife's Photoshop Elements from version 6 to version 9.  However, there is one feature from version 6 that seems to not work in version 9.  When she drags an image into a blank template (of any size), the image drags in to the t

  • Have I made a huge mistake ordering this??

    I'm hoping there are a whole host of people who have ordered and had installed Infinity and get something like the service that is promised.. yet all I seem to be able to find here are people complaining about things, and a lack of replies from BT of

  • Taken 2 has been deleted from my iTunes purchase history, has it for anyone else?

    Just went to watch it on my Apple TV and it's been deleted from my purchase history, has this happened to anyone else?