Forum Discussion

vstopp's avatar
vstopp
Helper I
6 years ago
Solved

Create table based on an input

I have a table with a field length of stay (LOS).  I would like to have all patients with a LOS > X put into another table.  I believe I would use power query editor for this using the Table.selectedRows, but I don't know where to start.  

 

I would then like to use this table for another form to show data related to the users selected.

 

Thank you in advance.

 

Valerie

 

  • In DAX you could create a new Table and use this formula:

     

    New Table = FILTER('Old Table', [LOS] > X)

     

    In Power Query, create a new query as a reference of your existing query then just use the GUI to filter to LOS > X 

     

3 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Community Champion

    In DAX you could create a new Table and use this formula:

     

    New Table = FILTER('Old Table', [LOS] > X)

     

    In Power Query, create a new query as a reference of your existing query then just use the GUI to filter to LOS > X 

     

    • vstopp's avatar
      vstopp
      Helper I

      I did create the table (using the new table button).  Now how do I add an input box for X and incorporate it into the create table verbage?

       

      tableLOS = Filter (CostUtilization_LOS, [losNumberDays] >= 500)