Expression logic for qualified tables

Hello Experts.
I am searching for an expression that can manage the following requirements:
Different records of a qualified table belong to one record of the main table. One value that belongs to a certain combination in the qualified table should be automatically transferred to a field in the main table. For example there is one main table (MAIN) and a qualified table (QT) with at least two fields.
Main table (MAIN) with some fields
Qualified table (QT) with Field 1 and Field 2
I tried following expression: IF(QT.Field 1 = ‘NAME’, QT.Field 2). But the expression doesn't’t work.
How can an expression work with a certain combination of a qualified table? Has anybody an idea how to solve such a mystery?
Thank you in advanced,

Hi Anita.
I have the answer: You need an additional field in qualified table. This field is filled during import with the concatenation of all field values of the QT record.
Qualified table with field 1 and field 2 look then like this
Field 1: Name
Field 2: Anita
Field Conca:Name.Anita
Now it is possible to build expression that can evaluate the string of the concatenation field.
Thanks for your help,

Similar Messages

  • Case statement logic for External Tables

    Hi All,
    Is there anyway I can perform a CASE logic in External table creation script?
    I have a column which is supposed to receive only Numbers. But if i inadvertently receive a String, i want to insert NULL for that instance.
    My table has the following creation syntax: ( I have to make a check for the NumValue column - althought I am using VARCHAR2(50) I have the transformation stage where the NumValue column has a CASE logic ; my entire file is getting rejected just because a single row in the input dat file is coming as a String)
         LineNumber NUMBER(20),
         NumValue VARCHAR2(50 BYTE)
    OPTIONALLY ENCLOSED BY '#$' and '$#'
    ( 'FILE1.dat'
    Thank you,

    Chaitanya wrote:
    So here, in the CASE logic, can i perform a check for validating if the value received for NumValue is only number and not some Varchar2 value (which I am currently receiving for some rows)Assuming "is only number" means NumValue column can containg digits only:
      into TableABC(
      select  linenumber,
        from  TABLEXYZ
        where regexp_like(NumValue,'^\d+$')
    P.S. If NULL column NumValue is allowed, add OR NumValue IS NULL

  • Unique key for Qualified tables

    Hello Experts,
    We are currently facing an issue with qualified tables. We need to retain existing system keys as below:
    Item (Main table)
    Item_Id, Item_Number
    Item_Price (Qualified Table)
    Item_Price_Id, Item_Id, Price_Type_Id, Price
    1, Pencil
    2, Pen
    3, Notepad
    1, 1, Retail_Price, $10
    2, 1, Wholesale_Price, $5
    3, 2, Retail_Price, $15
    4, 2, Wholesale_Price, $10
    We need to migrate the existing ids (Item_Price_Id) in MDM qualified table and need to maintain the same as max(Item_Price_Id) + 1 for all future records.
    Is there a way we can achieve this?
    Your help is greatly appreciated.
    Thanks in advance,

    Hi Karol,
    The Interface Iprinciple has this function as it:
    Gets the unique identifier which unambiguously identifies the object's <b>principal type and principal's data record</b>(s) in the data store (e.g. a relational database).
    <b>Note: the unique ID is a case sensitive string</b>
    Use this identifier to keep and persist references to principals. As this identifier contains internal information and is usually not readable, it should not be displayed in user interfaces.
    UME implementation guarantees to return Strings which are not longer than 255 characters.
    a non-null String identifying this principal
    I hope this helps you.

  • XML for Qualified tables (SP05)

    Hi all
    I have a xml file like this
    <?xml version="1.0" encoding="UTF-8"?>
    <od:schema xmlns:od="" xmlns:xsd="">
    <od:element name="Test">
              <od:element name="Material_Number_R3"/>
              <od:element name="ST_Code"/>
              <od:element name="Family"/>
              <od:element name="Line"/>
              <od:element name="Category"/>
              <od:element name="Ginco_R3_Code"/>
              <od:element name="Material_Type"/>
              <od:element name="Material_Group"/>
              <od:element name="Division"/>
    And when i load it in the syndicator manager i can do the mapping, but i want to add some field of a qualified table: what should i change in my xml?

    Hi Jose,
    when you look at the delivered xsd-structures for the material master, you can see, taht Q-Lookup tables are already mirrored in these strcutres. so this could be used as a template.
    You simply would define a complex type structure for the Q-lookup-table fields (I call it MFGDATA). This complex type would then be referred to in your main strucutre (I call it MFGInfo).
    It would have the following for :
    <?xml version="1.0" encoding="UTF-8"?>
    <od:schema xmlns:od="" xmlns:xsd="">
    <od:element name="Test">
    <od:element name="Material_Number_R3"/>
    <od:element name="ST_Code"/>
    <od:element name="Family"/>
    <od:element name="Line"/>
    <od:element name="Category"/>
    <od:element name="Ginco_R3_Code"/>
    <od:element name="Material_Type"/>
    <od:element name="Material_Group"/>
    <od:element name="Division"/>
    <xsd:element name="MFGInfo" type="MFGDATA" maxOccurs="unbounded" />
    <xsd:complexType name="MFGDATA">
    ######here you define all the fields of the Q-lookup tabel #####
    Regards Klaus

  • Need a logic for Internal table processing

    I have a internal table contains three fields material no, bin no, and Quantity
    Mat. No    |         Bin No        |              Quantity
    a              |              x1         |                   10
    a              |              x1         |                   10
    a              |              x2         |                   20
    b              |              x3         |                   10 
    c              |              x3         |                   20
    c              |              x4         |                   30
    c              |              x4         |                   40
    In this I need to append the records to new internal table say itab1 where multiple entries exist for some material no like mat no 'a' and 'c'  and
    if the material no. exist only once in the table, it has to be moved to another new internal table say itab2.
    Pls suggest some logic that does not have performance issues.
    Thanks in advance

    Hi there,
    a solution in brief...
    data: wa_itab1_a like itab1,
             wa_itab2_b like itab1,
             lv_tabix       type sytabix.
    sort itab1 by matnr.
    loop at itab1.
      wa_itab1_a = itab1.
      at new matnr.
        lv_tabix = sy-tabix + 1.
        clear wa_itab2_b.
        READ TABLE itab1 into wa_itab2_b
                            INDEX lv_tabix.
        if wa_itab2_b-matnr ne wa_itab1_a-matnr.
          append wa_itab1_a to itab2.
          delete itab1 where matnr = wa_itab1_a-matnr.
    George Zervas
    Edited by: gzervas on Oct 20, 2010 12:08 PM

  • Logic for internal table

    I have an internal table with the following structure.
    PO Number     PO Line Number     Quantity     ETA
    PO_1     001     10     10 Aug 2009
    PO_1     002     12     11 Aug 2009
    PO_2     001     5     10 Aug 2009
    PO_1     001     13     10 Aug 2009
    PO_1     001     7     11 Aug 2009
    Now I want to sum up quantity based on ETA dates so that the structure will look like as below:
    PO Number     PO Line Number     Quantity     ETA
    PO_1     001     23     10 Aug 2009
    PO_1     001     7     11 Aug 2009
    PO_1     002     12     11 Aug 2009
    PO_2     001     5     10 Aug 2009
    Collect statement will not work as the checking is on date but not  on po no and line item.

    Use SUM statement for adding the quantity fields.
    Sample code :
    WA_N = WA_T

  • Logic for MVER table update

    Hi Experts,
    Can anyone let me know how this table MVER updates. What are all the mvt type it will consider for updation. Your fast reply is appreciated.

    Hi Suresh,
    The following are the various mvmt types that are used for consumption.
    These values are updated in the MVER table. For eg. V06, V08 fields of MVER are updated with 261 and 201 Mvmt types.
    Reward if cleared and close the thread.

  • Mass Update of date in Qualified  table

    I having problem in updating End availability date in Partner Specific Data (which is a qualified table). How can do a mass update of selected records. I have written an assignment expression which has no error but it is not doing the update.

    Hi Marcel
    Assignment and validation does not work well for qualified table. It will work for only first qualified linked record and not all.
    for mass update you can use import manager map the date qualifier field and select replcae action for qualified update in the destination item.
    best regards

  • How to add record in Qualified table using MDM Java API

    Hi experts,
    I am trying to add a record into a Table.
    but I am facing the problem in setFieldValue method.
    //Getting Field-ID to pass in setFieldValue() method.
    FieldId[] fields = new FieldId[6];
              fields[0] = repSchema.getFieldId("GTINs", "Description");
              fields[1] = repSchema.getFieldId("GTINs", "Unit_Descriptor");
              fields[2] = repSchema.getFieldId("GTINs", "GTIN");
              fields[3] = repSchema.getFieldId("GTINs", "Alternate_Item_Classifications");
              fields[4] = repSchema.getFieldId("GTINs", "Country_Of_Origin");
              fields[5] = repSchema.getFieldId("GTINs", "Bar_Coded");
    Record rec = RecordFactory.createEmptyRecord(mainTableId);
    rec.setFieldValue(fields, );
    but I am not getting how to assign the value to these fields using MDMvalue Interface.
    Can anyone provide me the code sample or Code flow so that I can do this.
    Plz help me it'll be great help for me.
    Edited by: Tarun Sharma on Feb 4, 2008 11:39 AM
    Hi Gurus
    I found the way to add the MDMValue in setFieldValue Method.
    we can set like this:
    setFieldValue(<fieldId object like fieldId[], <MdmValue like this> new StringValue("ABC"));
    Now I am facing problem in adding value to lookup flat table.
    According to the setFieldValue method we can assign the loookup like this:
    setFieldValue(<fieldId[0]>, new LookpValue(<here we have to pass the recordID of lookup table>);
    so I want to know how I can pass the recordId of lookup table here.
    Please suggest.
    Tarun Sharma
    Edited by: Tarun Sharma on Feb 4, 2008 3:15 PM
    Edited by: Tarun Sharma on Feb 4, 2008 3:25 PM
    Edited by: Tarun Sharma on Feb 8, 2008 6:58 PM

    Hi Andrea,
    I tried your suggestion but now i am getting Type Mismatch Error.
    Please suggest me what I can do?
    //TableId for Lookup[Flat].
    TableId lookupTableId = repSchema.getTableId("Return_Goods_Policies");
    FieldId[] ReturnGoodsPolicyTableIdFields = new FieldId[1];
    ReturnGoodsPolicyTableIdFields[0] = repSchema.getFieldId("Return_Goods_Policies", "Name");               
    Record recLookup = RecordFactory.createEmptyRecord(lookupTableId);
    recLookup.setFieldValue(ReturnGoodsPolicyTableIdFields[0], new StringValue("New_Brand"));
    }catch(Exception ex){
    //Creating Record in Qualified Table - Request Details
    CreateRecordCommand createLookupcommand = new CreateRecordCommand(simpleConnection);
    //Getting the recordId of Lookup record.
    RecordId lookupRecordId = createLookupcommand.getRecord().getId();
    //Table Id for Qualified table.
    TableId  qualifiedTableId = repSchema.getTableId("Ext_Hardlines");
    FieldId[] ExtHardlinesFields = new FieldId[3];
    ExtHardlinesFields[0] = repSchema.getFieldId("Ext_Hardlines", "Name");//Text
    ExtHardlinesFields[1] = repSchema.getFieldId("Ext_Hardlines", "Pieces_Per_Trade_item");//Integer
    ExtHardlinesFields[2] = repSchema.getFieldId("Ext_Hardlines","Return_Goods_Policy");
    Record recQualified = RecordFactory.createEmptyRecord(qualifiedTableId);
    recQualified.setFieldValue(ExtHardlinesFields[0], new StringValue("Qualified Value"));
    recQualified.setFieldValue(ExtHardlinesFields[1], new StringValue("Qualified Description"));
    recQualified.setFieldValue(ExtHardlinesFields[2], new LookupValue(lookupRecordId));
    }catch(Exception ex){
    //Creating Record in Qualified Table - Request Details
    CreateRecordCommand createQualifiedCommand = new CreateRecordCommand(simpleConnection);
    createQualifiedCommand.execute(); I am getting this Type match here, but i m not getting what mistake i did.     
    RecordId qualifiedRecordId = createQualifiedCommand.getRecord().getId();
    //Adding to Main Table
    TableId  mainTableId = repSchema.getTableId("GTINs");
    FieldId[] gtinsFields = new FieldId[1];
    gtinsFields[0] = repSchema.getFieldId("GTINs","Ext_Hardlines");
    Record recMain = RecordFactory.createEmptyRecord(mainTableId);
    //Adding the new record to Qualifed Lookup value and setting the Yes Qualifiers
    QualifiedLookupValue qualifiedLookupValue = new QualifiedLookupValue();
    recMain.setFieldValue(gtinsFields[0], new QualifiedLookupValue(qualifiedLookupValue));
    }catch(Exception ex){
    CreateRecordCommand createCmd = new CreateRecordCommand(simpleConnection);
    Could you help me out?

  • Issue creating qualified tables in MDM 5.5 SP04 Console

    Try the following:
    1) Make sure you are using SP04 Patch 1 (Build
    2) Unarchieve one of the supplied business content repositories (Eg. Customer, Material, etc).
    3) Create a flat lookup table
    4) Create a qualified table with only one field: Field type lookup flat referencing the flat lookup table created in step 3, non-qualifier, display field.
    5) Create a new field in main table, type qualified multi-value, referencing the qualified table created in step 4.
    6) Load the repository
    7) Login to repository with data manager
    8) Create 1 entry in lookup table created in step 3
    9) Create 1 entry in main table, also creating 1 sub-entry in qualified table, save the record with SHIFT-ENTER
    10) Make sure the record was saved, including qualified table entry
    11) Close data manager
    12) Open data manager again
    13) Select your record and try to go in to the qualified sub-entry
    In my case this produces data manager to crash.
    This does not happen for qualified tables created in SP03 and updated to SP04, only for tables created directly in the SP04 console.
    Please let me know if everybody is having the same problem.

    Hi, Jorge,
    I have MDM5.5 SP4 P1 HF1 and followed your steps (except in step 4 (THANK YOU for numbering them), I have more than one field.) At step 13, I selected my record and to my amazement the record was there but my qualified table data was gone. And I then performed your step 14, and opened the qualified lookup table, and again to my amazement the console crashed.
    This definitely appears to be a bug and you should report it. I will also see if I can ask around for other solutions.

  • Loading main tables or Qualified tables first recommended??

    Hi All,
    Is the loading data for  Qualified tables first recommended before we load the main table data??
    Could I find any SAP recommeded quotes regarding this??

    Hi Arvind,
    First Qualified Table data is uploaded and the Main Table data .
    Reward if Useful.
    Vinay Yadav

  • Qualified Tables - Loop with Expression

    Hi Experts,
    Is there any way to setup a validation to loop over qualified links and check if a specific field has a value (not being NULL)?
    For example I have the following qualified links of qualified table Location Data for a Main Table Record (Material), with two fields Plant and Purchasing Group. Plant is Non-Qualifier and Purchasing Group is Qualifier and a lookup field into the table Purchasing Group.
    Plant: 3100
    Purchasing Group: NULL
    Plant: 2100
    Purchasing Group: 12
    I want to set up a validation to loop over all qualified links and check wether Purchasing Group is set. If one of them is not set I want to display a warning on record save.
    Anybody know if this is supported?

    Hi Ingo,
    I am assuming the following requirement:
    You want to throw a validation error when your qualifier(Purchasing Group) is NULL.
    If this the case then we can have a validation as described below for the qualified link.
    Step1. In Data Manager select Main Table as  Current table and go to Validations Tab.
    Step2. Create a validation expression by Using Function IS_NOT_NULL() and then Go to Fields drop down and select the Qualified Table --> Qualifier (Purchasing Group).
    Suppose if your Qualified table is "Test" and Qualifier is "Purchasing Group" then the expression will look like IS_NOT_NULL(Test.Purchasing Group).
    The other properties like "Error Message", "Automatic Execution" will vary as per your requirement
    Try this out and let me know.
    Thanks and Regards,
    Sagar Sonje
    Mark Helpful Answers

  • Expression with qualified table fields

    Hi all!
    I have 2 doubts concerning the free-form search and expressions using qualified table.
    We're implementing SRM-MDM Catalog. Here is the scenario
    The search is done in the Main Table (Products). The qualified table (Contract) has the following fields:
    Contract ID: Non-Qualifier
    Contract Item: Non-Qualifier
    Contract Category: Non-Qualifier
    Lower Bound: Non-Qualifier
    Amount: Qualifier
    Currency: Qualifier
    Obsolete: Qualifier
    There are 2 records in the Contract table assigned to the Product in main table:
    1st doubt:
    Using the free-form search, if I set the field Contract-Amount to be less than 150, only the record 123-1-Normal-1-100-BRL is listed in the result, which is ok. But if I enter in the expression option the formula Contract.AMOUNT<150, both records are listed:
    456-1-Normal-1-250-BRL ???
    Is this formula wrong?
    2nd doubt:
    The Contract info isn't a mandatory information. It's ok to have a product in the main table without a contract assigned to it. This can happen for example if all contracts for a product are obsolete. In the named search, if I select all products where obsolete equals to 'FALSE', only the records of the main table that have at least one valid contract are listed. As the contract info isn't mandatory, I was expecting a different behavior. Also the records that don't have a valid contract should be listed, but the contract information should be blank. Is there a way to do that?

    check out these tables,
    VBAK Header Data
    VBAP Item Data
    VBAG Release Data by Schedule Line in Sch.Agrmt.
    VBUK Header Status and Administrative Data
    VBUP Item Status
    VBRL SD Document: Invoice List
    VBPA Partner
    VBKD Business Data
    VBKA Sales activities
    VBEP Schedule Line Data
    VBRK Billing: Header Data (invoice)
    VBRP Billing: Item Data (invoice)
    VBFA Sales Document Flow
    VTTP Shipment item

  • Need Logic for Inserting data into table from another table

    Could you please give me some logic on below:
    TABLE_A has columns A,B,C,D
    What i did
    Created new table
    TABLE_1_A with columns A1,A2,B1,B2,B3
    I should populate columns A1,A2 (table TABLE_1_A) with the data from column A (table TABLE_A)
    & simillarly populate columns B1,B2 with the data from B.
    the data is huge in the table_a.
    Database: 10g

    Here's one way:
    INSERT INTO  table_1_a
            (a1, a2, b1, b2)
    SELECT      a,  a,  b,  b
    FROM      table_a
    I hope this answers your question.
    If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all tables involved, and also post the results you want from that data.
    If you're asking about a DML statement, such as INSERT, the sample data will be the contents of the table before the DML, and the results will be state of the changed table(s) when everything is finished.
    Explain, using specific examples, how you get those results from that data.
    See the forum FAQ {message:id=9360002}

  • Incorrectly defined logical table source (for fact table X

    Imagine the following Physical Diagram:
    - Dim A
    - Dim B
    - Fact A
    - Fact B
    - Dim A is parent of Dim B
    - Fact B has a FK to Dim B
    - Fact A has a FK to Dim A
    Business Layer:
    - Logical Table Dim A
    - Logical Table Dim B
    - Logical Table Fact A
    - Logical Table Fact B
    - same joins (not FK Joins) that Physical Layer
    When we build a report that only has one column of Dim A and one column of Dim B (A is parent of B), the following error appears:
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 15018] Incorrectly defined logical table source (for fact table "Fact A") does not contain mapping for [Dim A.col1, Dim B.col1]. (HY000)
    What is wrong?

    The joins of dimensions go via a fact table. In your case there is no common fact table.
    You can solve this by drag/drop a field from the physical table Dim B on the displayed logical table source of the logical table Dim A.
    Now the BI Server knows that Dim A and B have a physical relationship.

Maybe you are looking for

  • How can I convert a project from LabWindows/CVI 2010 to a Visual Studio 2011 project?

    I have a good sized project, 12 source files, 14 headers, 1 uir, that I want to be able to edit and compile in MS Visual Studio 2011, MSVC++. I remember being told that LabWindows dropped support for C++ in 2008 and no longer had a wizard for convert

  • Rapidly decreasing hard-drive space after upgrading to snow leopard

    So... recently upgraded to SL on my just over 1 year old MBP. No problems at first, but now acting really... odd... When I first upgraded I had moved a bunch of files over to an external drive to have enough hard drive space. Had 11GB open when I upg

  • Using iMac as a wireless base station.

    Is it possible to have my iMac broadcast a wireless connection through airport to allow computers to join AND to get online, basically using the iMac as a wireless router. The iMac is currently connected through a LAN line.

  • 48F@01000003 Error on Storage Spaces

    Hi! I have the following configuration: 2-node cluster Spaces and Sofs (CIB) - SMB storage running on SuperStorage 2026T-DE2R24L And a Hyper-v 2-node cluster accessing the vm´s over 10G ethernet SMB OS Windows 2012R2 We have got a file corruption on

  • Optimize for ad hoc workloads.

    Hello all,    I was refering BOL documentation on 'optimize for adhoc workloads' option and when this is enabled the first run of the adhoc query gets 'compiled plan stub'(plan is not cached) and upon on second run,it gets 'compiled plan' (plan is ca