bggann
Active Member
Not even sure how to describe this.
Working on a tracking form where there is a main group "daily_log" and several repeated groups "xxx_flight leg"
Initially we were going to high/show the groups based on a choice in daily_log. Thanks to Hugh for updating the system to hid/show the tabs.
For a variety of reasons, we decided to restructure this to avoid conditional coding - validation on hidden values, etc. As we got further into it we understood the scope better and it became obvious that a more segregated approach would make sense.
So - we restructured.
Group daily_log became 3 groups (non-repeated), mma_daily_log, heli_daily_log, seat_daily_log.
The repeated groups were already separate (mma_flight_leg, etc.).
The underlying tables are the same (list mma_daily_log and heli_daily_log and seat_daily_log) all point at a db table daily_log.
The repeated groups point at different tables - such as daily_log_12_repeat___mma_flight log.
Many of the elements in the groups are identical - so they are parent-child pairs. Only where they must be different are the elements separated.
It the process of doing this - we have broken something.....
Became evident doing a calc field in a repeated group. The calc would work if the 3 fields involved (2 inputs, one output) were in the main group, but not in the repeated group.
Adding dumps in the calc it appears we have somehow broken the linkage. The element names in the $data array are not complete.
In the dump of $data it will say, for instance,
___Hobbs_Start_Time.
The element is
daily_log_12_repeat___Hobbs_Start_Time
Notice the "daily_log_12_repeat" is missing from the $data rendition
Thus the calcs don't work.
Attached is a screen capture of the dump output and a portion of the element list to illustrate. Notice how the full name is not in the data dump.
Obviously, we broke something when we split the groups. What is the best way to recover? It is to start over, or is there some database repair we can do.
Note - the tables (in php) are "close" to right.
The site is the aviation one in my sites.
Working on a tracking form where there is a main group "daily_log" and several repeated groups "xxx_flight leg"
Initially we were going to high/show the groups based on a choice in daily_log. Thanks to Hugh for updating the system to hid/show the tabs.
For a variety of reasons, we decided to restructure this to avoid conditional coding - validation on hidden values, etc. As we got further into it we understood the scope better and it became obvious that a more segregated approach would make sense.
So - we restructured.
Group daily_log became 3 groups (non-repeated), mma_daily_log, heli_daily_log, seat_daily_log.
The repeated groups were already separate (mma_flight_leg, etc.).
The underlying tables are the same (list mma_daily_log and heli_daily_log and seat_daily_log) all point at a db table daily_log.
The repeated groups point at different tables - such as daily_log_12_repeat___mma_flight log.
Many of the elements in the groups are identical - so they are parent-child pairs. Only where they must be different are the elements separated.
It the process of doing this - we have broken something.....
Became evident doing a calc field in a repeated group. The calc would work if the 3 fields involved (2 inputs, one output) were in the main group, but not in the repeated group.
Adding dumps in the calc it appears we have somehow broken the linkage. The element names in the $data array are not complete.
In the dump of $data it will say, for instance,
___Hobbs_Start_Time.
The element is
daily_log_12_repeat___Hobbs_Start_Time
Notice the "daily_log_12_repeat" is missing from the $data rendition
Thus the calcs don't work.
Attached is a screen capture of the dump output and a portion of the element list to illustrate. Notice how the full name is not in the data dump.
Obviously, we broke something when we split the groups. What is the best way to recover? It is to start over, or is there some database repair we can do.
Note - the tables (in php) are "close" to right.
The site is the aviation one in my sites.