Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago

calculate columns from two tables

Hello everybody,

I have a problem, can you help me?

I have 2 tables; an information and a data table.

I want to calculate a new column like in the example. Is that possible?

Example:

 

articelarticel_statsitic
100
110
101010
101111

 

articelordersales
1005
1104
1010150
10112014

 

solution:

articelordersalesorder_New
100515
110410
1010150-15
10112014-20

5 Replies

  • camargos88's avatar
    camargos88
    Community Champion

    Anonymous ,

     

    Sorry, I didn't get the logic for that. Can you explain more ?

  • Anonymous's avatar
    Anonymous
    Not applicable

    camargos88  i´m sorry for that 😉 

     

    Sorry.


    I try something else:

    If the articel has deposited a statistical articel, then the orders should be booked to the statistical articel.

    Table 1 states: Article 1010, Article 10 as a statistical article.

    That's why I have to add up all the values ​​of article 1010 to article 10

    • camargos88's avatar
      camargos88
      Community Champion

      Anonymous ,

       

      So the relations are always 1 to 1 ?

      And the values that's giving should be multiplied to -1 ?

      • Anonymous's avatar
        Anonymous
        Not applicable

        No, unfortunately not. There are many articles with the same stored statistical articles.

         
         

  • dax's avatar
    dax
    Community Support

    Hi Anonymous , 

    I am not clear about your requirement, could you please explain the logic of [order_new] column? If possible could you please inform me more detailed information(such as your expected output and your sample data)? Then I will help you more correctly.

    Please do mask sensitive data before uploading.

    Thanks for your understanding and support.
    Best Regards,
    Zoe Zhi

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.