3 Replies Latest reply: May 25, 2017 8:27 AM by Thales Monteiro RSS

    Get all possible periods, repeating values.

    Thales Monteiro

      Good morning folks,

      I have a situation here that I'm not getting any soluction by my own...

      I have 3 main fields to do this:

      the product ID "CD_PRODUTO" to identify it

      the periods reference "PERIODO" formated like 'YYYYMM' that tell when some product was bought

      and the cost "CUSTO" that tell how much each unit cost by that purchase.

      The problems is that the most part of the products aren't purchased every month. I need to show every product, period and price, even if it hasn't been purchased by this period, and by reapeating the price of the last bought.

      There are a picture of the data table.