AnsweredAssumed Answered

Insert Perform Find calculated results into table

Question asked by NetDude on Jan 3, 2013
Latest reply on Jan 3, 2013 by philmodjunk


Insert Perform Find calculated results into table




     Execute a script that will execute 2 Perform Finds. Calculate the results from the finds and enter results into a Results Table. Will also need to insert the id for the current record. I started doing the following however Im not sure how I perform the insert. My example below stores each peform find result into a variable, I also store the current record into a variable to be used in each perform find and eventually for using in the insert along with the calculated result. The Result table for this eaxample only stores two pieces of data into Results table:

  1.           ven_id
  3.           calculated percent  (calculation: variable $total_yes / $total_hie * 100) It would be nice to limit how many characters to the right of the decimal will go as apposed to my example below which carries them out 12 spaces

     Because Im using Perform Find, Iv'e noticed that if they do not find any records then the auto "No Records Found" displays prior to getting through the rest of the script. If this happens then no records should be inserted and the user will simply be alerted and then taken to the Orginal Layour as apposed to being allowed to enter new search parameters. One other issue Ive seen with just this example is that it doesn't clear out previous finds within each variable. Im wndering if I need to flush them prior to running the script to avoid using the same record ven_id