Method Community

 

Loop Through Table Does Not Return Values

Last post 06-18-2016 10:25 PM by Jack. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 06-10-2016 3:51 AM

    • Jack
    • Top 150 Contributor
    • Joined on 02-23-2016
    • OKC, OK
    • Posts 38

    Loop Through Table Does Not Return Values

    I have a Screen, Loop Issue, on the Reports app that demonstrates my issue. I have one button that performs a grid loop(on a grid that has no views/filters), which worked just fine, returning six values. I have it set to show a message each time for easy counting. Right next to it I have a button that performs loop through table (with no filter except Record ID is not empty). Unfortunately, this action does not return any values, but it does apprear to be going through each record as six sequential blank message dialogs pop up.

    Setting the loop through table qaction to place the Record ID into an action result does not appear to work either.

    However, there is a workaround, since it appears that Loop's Record ID (oRow.RecordID in message dialogs) populates with the correct value just fine, allowing me to assign it to an action result, use that action result in a Retreive Values From Table action and essentially acheive the same result, just with a few more steps.


    I figured I would see someone else post about this so am I missing something here or am I the only one trying to use a table loop?

    -Jack
  • 06-10-2016 10:15 AM In reply to

    Re: Loop Through Table Does Not Return Values

    Hi Jack,

    There are currently some issues we are aware of with the Loop through Table action not parsing values correctly without first assigning them to Action Results.

    We are working on overhauling how this process works so that we dont run into any troubles with it, but for now he Action Result assignment is the fastest workaround.

    If you run into any specific scenarios where this doesnt work for you in the meantime, let me know and we can work on a solution together Smile

    Sorry for the Inconvenience Jack!

    -Ben

    Ben Hargreaves
    Senior Support Specialist
    Method:CRM
    b.hargreaves@method.me
    Toll Free: 1.888.925.6238
    Local & Overseas: 416.847.0400
    Fax: 416.640.6027
  • 06-10-2016 12:11 PM In reply to

    • Jack
    • Top 150 Contributor
    • Joined on 02-23-2016
    • OKC, OK
    • Posts 38

    Re: Loop Through Table Does Not Return Values

    Ok, good to know that I am not doing something wrong.

    Just to clarify, the way I am doing it (use get RecordID from loop, use it to retreive values from table)is currently the best way to do so? I have a setup on the same screen I mentoned above that demonstrates how I am doing it.

    -Jack
  • 06-16-2016 2:30 PM In reply to

    • Jack
    • Top 150 Contributor
    • Joined on 02-23-2016
    • OKC, OK
    • Posts 38

    Re: Loop Through Table Does Not Return Values

    Hi Ben, I have found a specific scenario in which I am having an issue. It appears, as mahlonf has postefd about (https://www.method.me/cs/forums/t/9581.aspx), that the Loop through Table Action's Order By setting does not work at all. regardless of what is selected, the results return in RecordID order. This is problematic because I want to look at a range of records by date and get the first date value and then the last date value. 

    I have posted a workaround to this issue on the above-mentioned post by mahlonf.

    -Jack
  • 06-18-2016 10:25 PM In reply to

    • Jack
    • Top 150 Contributor
    • Joined on 02-23-2016
    • OKC, OK
    • Posts 38

    Re: Loop Through Table Does Not Return Values

    Hi Ben,

    I have a second issue. It appears that the workaround mentioned initially on this post that you confirmed was the only way to get a Table loop to work (run table loop, assign loop's recordID to AR, use AR in a Retrieve value from Table action) no longer appears to work. Instead, all the values I try to retreive from the table return blank, but apparently are not actually blank since they do not seem to register as empty when using a conditional statement that looks to see if they are empty or not. I have an action result that, before the lookup, have a value of 0 in it. The lookup is supposed to pass a value into the action result, and after the lookup, the action result is now blank. 

    This issue now prevents me from using a table loop entirely.

    Sample issue can be found on the screen "Retrieve from Table Issue" in the Quotes App. A chain of action will run on page focus, inclusing the one with the table loop issue.

    Any suggestions?

    -Jack
Page 1 of 1 (5 items)