0

Need help !!

let me := this;
    for s in select 'Control Deliverables' do
        let newR := (create 'News Forecast Dates');
        newR.(
            'Control Deliverables_>' := s;
            let p1 := me.'Plan 1';
            let p2 := me.'Plan 2';
            let p3 := me.'Plan 3';
            let p4 := me.'Plan 4';
            let p5 := me.'Plan 5';
            newR.('Old Plan 1' := p1);
            newR.('Old Plan 2' := p2);
            newR.('Old Plan 3' := p3);
            newR.('Old Plan 4' := p4);
            newR.('Old Plan 5' := p5)
        )
    end
end

 

 

' Contol Deliverables' is subtable Documents table.

'New Forecast Date" is. Subtable Documents table.

'Control Deliverables_>' is n:1 on 'New Forecast Date' to 'Contro Deliverables'

Can't transfer the dates  'Plan 1 to 5' to ' Old Plan 1 to 5'  , but yes transfer the name of the documents .

The 'Old Plan 1 to 5 transfer are the same on all documents.

Need help 

6 Antworten

null
    • Ninox-Professional
    • planoxpro
    • vor 5 Monaten
    • Gemeldet - anzeigen

    Hi Rafael, is this a Buton script? Which table is this running in? What ID is in “me”? Should all new data records in 'New Forecast Dates' actually have the same values?

      • Rafael_Sanchis
      • vor 5 Monaten
      • Gemeldet - anzeigen

       

      Sí está en el botón, ejecute en la tabla 'Control de entregables', el yo es 'Control de entregables',

      Cada documento tiene diferentes fechas de plan.

      the image is Contro Deliversbles 

      • Rafael_Sanchis
      • vor 5 Monaten
      • Gemeldet - anzeigen

       

      I send the DB the tables are, Documents, 'Control Deliverables' and 'News Forecast Dates'

      The button is in 'Control Deliverables' Update for Re-Planning

      • Ninox-Professional
      • planoxpro
      • vor 5 Monaten
      • Gemeldet - anzeigen

       

      Take out the let intermediate steps, they are unnecessary:

      newR.(
          'Control Deliverables_>' := s;
          'Old Plan 1' := me.'Plan 1';
          'Old Plan 2' := me.'Plan 2';
             ...
      );

      But as I said: The new data records are all filled with the same values from the one data record in which the script is started.

      If you want to transfer the values of the data records from 'Control Deliverables' to 'News Forecast Dates', you would have to take the ID from the loop variable "s" (instead of "me").
       

      • Ninox-Professional
      • planoxpro
      • vor 5 Monaten
      • Gemeldet - anzeigen

      I just saw that you completely changed your last comment.  But I don't want to rethink this now. See if my hint helps you.

      • Rafael_Sanchis
      • vor 5 Monaten
      • Gemeldet - anzeigen

       Thank planox work now 👍

Content aside

  • Status Answered
  • vor 5 MonatenZuletzt aktiv
  • 6Antworten
  • 31Ansichten
  • 2 Folge bereits