You are viewing limited content. For full access, please sign in.

Question

Question

Weird Calculation Error in Table on the Classic Designer

asked on July 25

Forms  Version 11.0.2311.50556 Classic Designer.

I have a table with a couple fields on it, including a field for "Member Number" (our version of an account number).  There is another field on the table (a hidden field) that determines the thousand number range of that member number.  For example:

  • 1234 calculates to 001000-001999
  • 12345 calcualtes to 012000-012999
  • 123456 calculates to 123000-123999

This is used when archiving to the repository at the end of the process, as our records are segmented by thousands like this.

This is the formula I'm using: 

=RIGHT("000000" & ROUNDDOWN(INDEX(member_list_table.member_number,ROW())/1000,0)*1000, 6) & "-" & RIGHT("000000" & SUM((ROUNDUP(INDEX(member_list_table.member_number,ROW())/1000,0)*1000),-1), 6)

Basically, it's taking the member number, dividing it by 1000, rounding up or down to get the top and bottom of the range, subtracting 1 from the top of the range, and then appending leading zeros as needed. 

This formula has been in place on this form for several years without issue, and I have not seen errors with it in that time.  But in the last month I've have two instances where users encountered it giving them errors.  In both cases, the issue was that row 1 of the table worked, but row 2 was trying to get the member number from row 3, and row 3 was trying to get the member number from row 4, etc.  Either INDEX or ROW seems to be having an issue in these cases.

I haven't updated Forms since about 5 or 6 months ago, so I don't think this was a recent change to Forms to cause this behavior - though it could be possible.

I haven't been able to replicate this error despite multiple attempts, and I can't determine anything I am doing differently than the users who encountered the error were doing.

Has anyone ever encountered an issue like this - where a formula using the INDEX and ROW functions are targeting the wrong row of a table?  I'm just kind of stumped on this one.

0 0

Replies

replied on July 28

Hi Matthew,

The formula looks all good at my side, I feel like it's because the row count was not calculated correctly under some conditions but I cannot try it out. And I just add some rows manually  and type in the number, is it the same as yours? Or maybe the numbers are appended by lookup rule? Anyway, I don't see enough evidence to prove it to be a bug right now.

0 0
replied on July 29 Show version history

No, that's right, just click the link to add a row and then add the member number.  And it's working in almost every case.

It's frustrating because I haven't been able to replicate the behavior no matter how I try, even though I have witnessed it happen twice (specifically the staff member reached out after it was happening, and I could see it happening, but I didn't actually see it start to happen).

The row count being miscalculated makes sense - but no idea how to identify if that happened and why that happened.

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.