Programme SAP RCUDIRECTCONDITION - Convert manually assigned conditions

Title
Change Assignment of Manually Assigned Variant Conditions

Purpose
If conditions are assigned manually to values in a variant simulation,the variant conditions are saved in table CDCND. This table uses theCLINT key for an active class.
The configurator only recognizes one condition for each combination ofmaterial, characteristic, and value.
Manual assignment of conditions using the CLINT key of a class cancause problems if a material is assigned to more than one class,because more than one key refers to a material. This means that thesystem only recognizes one condition for a value, even though there aremore.
This report program reads the material number for the variantconditions, so that all new assignments are assigned to the material,not the class.

Input Parameters
The report program has 2 input parameters:

  • Save changes

  • Display log

  • If you set the Save changes parameter, all possible combinationsof classes from table CDCND and materials arequeried, and data for all relevant materials is transported to tableMACOND, with the information on conditions found in table CDCND. Thechanges apply to all clients. In case of multiple classification, theconditions for the class with the lowest CLINT in table CDCND aretransferred to table MACOND with the counter 000 (see the exampleresult of this report). The classes with the next highest CLINT aretransferred with the next counter (n + 1). If assignments already existfor a material in table MACOND, the counter 000 from the configuratoris ignored, and the counter in table MACOND automatically jumps to 001.
    You can only set the Save changes parameter once. If you set itagain, it has no effect.
    If the report has not yet run with the Save changes parameter,the Display log parameter means that the new assignments areonly simulated. If changes have already been saved, and entries intable MACOND are duplicated (or more), you can use the Display log
    parameter to process the data records found.

    Features

    Example
    Before the report runs, table CDCND contains the following data:
    Example 1: Material with only one class
    Material 1

    • Class 1 with CLINT 4711

    • Characteristic 1, Value 1, and Condition 1

    • Material 2
      • Class 2 with CLINT 4712

      • Characteristic 1, Value 1, Condition 2

      • and
        • Class 2 with CLINT 4712

        • Characteristic 2, Value 2, Condition 3

        • Table CDCND contains the following data records:
          4711,,Characteristic 1,,Value 1,,Condition 1,,
          4712,,Characteristic 1,,Value 1,,Condition 2
          4712,,Characteristic 2,,Value 2,,Condition 3
          Multiple classification:
          Now material 1 is assigned to class 2.
          Material 1
          • Class 2 with CLINT 4712

          • Characteristic 1, Value 1, Condition 2

          • and
            • Class 2 with CLINT 4712

            • Characteristic 2, Value 2, Condition 3

            • Class 1 and class 2 have their information on variant conditions fromtable CDCND. This begs the question as to which of the 2 conditions(condition 1 or 2) is active in the configurator. Up to this point intime, the condition with the lowest CLINT is loaded for the class(condition 1).
              If you run this report, you activate table MACOND. This table containsthe material as a key, and the conditions are created per material, notper class. The table also has the key field ATZHL, an internal counter.This counter allows more than one condition to be assigned to acombination of material, characteristic, and value (1:n). Duringconfiguration, only conditions with the counter 000 are read.
              You can use this report program to process duplicate (or more) entriesfor a material, characteristic, value, and condition.
              Examples shown above, after running the report:
              1. Table MACOND contains the following entries:
              Material 1,,Characteristic 1,,Value 1,,Condition 1,,Counter = 000
              Material 2,,Characteristic 1,,Value 1,,Condition 2,,Counter = 000
              Material 2,,Characteristic 2,,Value 2,,Condition 3,,Counter = 000
              2. Material 1 is assigned to both classes. Table MACOND contains thefollowing entries:
              Material 1,,Characteristic 1,,Value 1,,Condition 1,,Counter = 000
              Material 1,,Characteristic 1,,Value 1,,Condition 2,,Counter = 001
              Material 1,,Characteristic 2,,Value 2,,Condition 3,,Counter = 001
              Material 2,,Characteristic 1,,Value 1,,Condition 2,,Counter = 000
              Here, you can delete the first 2 records and set the counter in thethird record to 000.