Inventory App - Remove product from the view when there is a value in a column

I am looking to hide product that is already sold and only displays available items depending on if there is a value in a column.

This is the view of my app displaying all the products

screenshot-www.appsheet.com-2022.04.19-10_31_48.png

And here is the data source

screenshot-docs.google.com-2022.04.19-10_36_02.png

If there is a value in the "Job Name" column, I would like that row not to display in the previous screenshot.

I tried searching around before making this post but had no luck. I am sure the answer is somewhere around these parts, just need a friendly guide to point me in the right direction. 

Solved Solved
0 6 201
2 ACCEPTED SOLUTIONS

You got it, but I'm not sure I'm following on that last part.

The idea is to use the Ref_rows to create an inline view using the slice as a source in order to filter those rows, so that you can use this to substitute this inline view:

Rafael_ANEICPY_0-1650382767727.png

Let me know if that works for you.

For reference:

https://help.appsheet.com/en/articles/2357313-ref_rows

View solution in original post

The REF_ROWS syntax is REF_ROWS(from-dataset , ref-column )

So yours should be REF_ROWS("the name of your slice", "Models")

View solution in original post

6 REPLIES 6

Hello @nadim_dayoub, you can do that by creating a slice of your "Inventory" table that excludes rows that have a value in the "Job Name" column, then create a virtual column with a ref_row expression like this:

REF_ROWS("Inventory","Item REF")

That way you will have an inline view of the ref items to that product that satisfy your conditions, after you have that you can simply hide the one that you had before.

Thanks for the reply @Rafael_ANEIC-PY 

Let me see if I am following you correctly.

I made a slice for my "inventory" table with this expression: ISBLANK([Job Name])

and then from there, I am creating a new virtual column with REF_ROWS("Inventory","Job Name")

and then I am making an edit to the Inventory_inline with displaying the new virtual column under column order?

Am I understanding that correctly? 

 

You got it, but I'm not sure I'm following on that last part.

The idea is to use the Ref_rows to create an inline view using the slice as a source in order to filter those rows, so that you can use this to substitute this inline view:

Rafael_ANEICPY_0-1650382767727.png

Let me know if that works for you.

For reference:

https://help.appsheet.com/en/articles/2357313-ref_rows

@Rafael_ANEIC-PY  Thanks for the reply.

Hmm, I am not sure if this method is going to work, or if I am going about this the wrong way. I do not mind tipping you for your time either. So let me kind of go back from the start and paint the full picture.

Here is a small walkthrough of my app: https://www.loom.com/share/5a2018c576e045a4b8868e8f7e7ef5ae

Here is the source: https://docs.google.com/spreadsheets/d/1b-PdiwJEXh2r33Yx7HGAza45ChsiiXi9OiPWZfP_CAM/edit?usp=sharing

For the availability column I have it set up like this:

screenshot-www.appsheet.com-2022.04.19-12_16_19.png

So the goal is when something is sold, I would like to remove it from the inline view along with the inventory amount going down. I am not sure what would be the simplest method on doing so.

I thought maybe depending on if there was a value in the job name column, it could go off of that. But that does not need to be set in stone. I would work with any method that would be ideal. 

The REF_ROWS syntax is REF_ROWS(from-dataset , ref-column )

So yours should be REF_ROWS("the name of your slice", "Models")

Thank you! 

I was trying that yesterday, and it wouldn't work at all. So I thought I was doing something wrong. With your comment, it gave me the confidence I was doing it correctly, but this time I hit the save button, and everything all of a sudden worked.

For some reason, I thought it would sync in real-time like all the other changes I have been doing to the app.

Ty Ty!

Top Labels in this Space