title: (Shiny) Modify table filtered by the user and see it reflected in the main table
body: <p>I have relied on the following <a href="https://github.com/rstudio/DT/pull/480" rel="nofollow noreferrer">Code</a> so that the user can modify the shiny table.
  I have a large database, before the user modifies the table I would like him to be able to filter by &quot;material&quot; and then he can make the corresponding modifications, especially the column &quot;stockobj&quot;, then I would like to see the filtered table and the main table with the modifications that were made previously.
  As you can see in the picture: [App][https://i.stack.imgur.com/2ecpK.png]</p>
  <p>My code:</p>
  <pre><code>library(DT)
  
  df&lt;- tibble(material=c(12345,12345,12345,12345,12345, 67891,67891,67891,67891,67891),
              centro=c(&quot;H01&quot;, &quot;H02&quot;, &quot;H03&quot;, &quot;H04&quot;,&quot;H05&quot;,&quot;H01&quot;, &quot;H02&quot;, &quot;H03&quot;,  &quot;H04&quot;,&quot;H05&quot; ),
              rotaSem= c(0.66,0.55,0.43,0.45, 0.33, 0.34,0.78, 0.31,0.89,0.87),
              stockobj=c(1,2,1,1,3,1,1,1,2,1))
  
  
  shinyApp(
    ui = fluidPage(
      titlePanel(&quot;My app&quot;),
      selectInput(&quot;mate&quot;, &quot;Select material&quot;, choices = unique(df$material)),
      h3(&quot;Edit table&quot;),
      DTOutput('x1'),
      h3(&quot;Main table&quot;),
      DTOutput(&quot;x2&quot;)
    ),
    server = function(input, output, session) {
      x = df
  
    
      categ&lt;-reactive({
        x %&gt;% filter(material==input$mate)
      })
      
      output$x1 &lt;- renderDT(categ(), selection = 'none', rownames = F, editable = T)
      output$x2 &lt;- renderDT({
        x
      })
      
      
      proxy = dataTableProxy('x1')
      
      observeEvent(input$x1_cell_edit, {
        
        info = input$x1_cell_edit
        str(info)
        i = info$row
        j = info$col + 1  # column index offset by 1
        v = info$value
        x[i, j] &lt;&lt;- DT::coerceValue(v, x[i, j])
        replaceData(proxy, x, resetPaging = FALSE, rownames = FALSE)
      })
    }
  )```
  
  I have been looking for a solution for several days but I have not been able to. The problem is that to modify the table I have to modify the &quot;reactive&quot; and I don't think it is possible. Any ideas?
  
  
    [1]: https://i.stack.imgur.com/2ecpK.png
  </code></pre>