Title: Run SQL upon button click in table row
Last modified: November 10, 2021

---

# Run SQL upon button click in table row

 *  Resolved [gareth94](https://wordpress.org/support/users/atebol/)
 * (@atebol)
 * [4 years, 6 months ago](https://wordpress.org/support/topic/run-sql-upon-button-click-in-table-row/)
 * Hello. I’d like to add a button to each row in a specific table. When the user
   clicks on that button, I’d like the data associated with that row to be moved
   to another table. I was wondering if anyone could help me achieve this please?
   I believe I could use an `INSERT INTO` sql command to insert the data into another
   table but I’m not sure how I’d initiate this or to ensure that only the relevant
   row gets moved/copied over?
    Thank you in advance

Viewing 1 replies (of 1 total)

 *  Plugin Author [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * (@wpdatatables)
 * [4 years, 6 months ago](https://wordpress.org/support/topic/run-sql-upon-button-click-in-table-row/#post-15061108)
 * Hi atebol,
 * Thank you for your interest in wpDataTables.
 * Unfortunately this is not possible with built in features of plugin.
 * You can take a look in our documentation about [Front-end callbacks](https://wpdatatables.com/documentation/information-for-developers/front-end-callbacks/)
   and also about [Actions](https://wpdatatables.com/documentation/information-for-developers/hooks/)
   and [Filters](https://wpdatatables.com/documentation/information-for-developers/filters/)
   which are defined in wpDataTables plugin for customization’s by developers.
 * Thank you for understanding.
 * Best regards.

Viewing 1 replies (of 1 total)

The topic ‘Run SQL upon button click in table row’ is closed to new replies.

 * ![](https://ps.w.org/wpdatatables/assets/icon-128x128.gif?rev=3010404)
 * [wpDataTables - WordPress Data Table, Dynamic Tables & Table Charts Plugin](https://wordpress.org/plugins/wpdatatables/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wpdatatables/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wpdatatables/)
 * [Active Topics](https://wordpress.org/support/plugin/wpdatatables/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wpdatatables/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wpdatatables/reviews/)

## Tags

 * [html](https://wordpress.org/support/topic-tag/html/)
 * [scripting](https://wordpress.org/support/topic-tag/scripting/)
 * [sql](https://wordpress.org/support/topic-tag/sql/)
 * [wpdatatable](https://wordpress.org/support/topic-tag/wpdatatable/)

 * 1 reply
 * 2 participants
 * Last reply from: [wpDataTables](https://wordpress.org/support/users/wpdatatables/)
 * Last activity: [4 years, 6 months ago](https://wordpress.org/support/topic/run-sql-upon-button-click-in-table-row/#post-15061108)
 * Status: resolved