Hi, Are there any sample appsheet apps that ...

(D. Robert Charlon) #1

Hi,

Are there any sample appsheet apps that use table partitioning? Specifically I would like to see one with partitioning across worksheets. The YouTube tutorial was helpful, but lacking in certain vital details.

Thanks, David

(Tony Fader) #2

@D_Robert_Charlon Hi, here’s an example of worksheet partitioning. https://www.appsheet.com/samples/worksheet-partitioning?appGuidString=40c9e4b7-42a3-4100-9a2e-cbf9d7845979

(D. Robert Charlon) #3

@tony Thanks for the response. That was deceptively simple. My situation is a bit more complicated it turns out. The partitions I’m trying to create are actually Google workbooks not single sheets (I misspoke). My app backend consists of several sheets/tabs referencing each other in various ways, in some cases going down 2-3 levels from a parent table. What I’m wanting to do is create partitions that preserve the entire app schema (all the relationships etc) over a set time interval. Is this possible? Do I need to partition every sheet? And will the app behave the same way, for instance if I create a new record in a partitioned parent table will it also create the related records in the partitioned child tables?

(Praveen Seshadri (AppSheet)) #4

You can partition at the level of sheets (within the same workbook) or at the level of different workbooks. Conceptually it is identical. Just try it out with two partitions. There’s documentation on this at help.appsheet.com

(D. Robert Charlon) #5

@praveen I didn’t expect to get a response on Sunday, thank you! I have read through the documentation and watched the videos. I guess what I’m not understanding is how one goes about partitioning an entire workbook file with many sheets/tables when the partition happens at the table level. I have a file with a main parent table (goals), a child table (benchmarks) and a grandchild table (trials), and a handful of lookup and query tables aggregating portions of the dataset. I was able to partition the parent table, but when I select the other partition and try to create a new record, only the row for that table is written to the selected partition. The other related records are written to the tables on the original partition. I definitely appreciate any guidance on this. I have managed to create a few complex apps that function well, but I still consider myself a novice at this.

(Praveen Seshadri (AppSheet)) #6

Hi @D_Robert_Charlon, you would need to partition all the tables (I guess don’t need to do the lookup tables if they are read-only, but the rest).

So in a simple case, let’s say you have two tables A and B, from two worksheets SheetA and SheetB in a workbook.

Let’s say you have two workbooks — WorkbookUSA and WorkbookCanada. Also, let’s say you ask the user to choose a country via the User Settings: USA or Canada. Based on the user’s choice, the appropriate partition is chosen. The partition function for tables A and B will look like this: UserSettings(“Country”)

and the options will be: “USA” : and “Canada”:

(D. Robert Charlon) #7

@praveen So the partition function would (in this case) be the same for all the tables. That makes sense. I’ll give it a try, thanks again!