How to Update a table row from a Wordpress page


Staff member
I'm trying to update a row from one table in Wp database, all this from a page in wordpress. I'm using a plugin that allows me to write php inside the page, and I'm writing this:

$ident = $_GET['id'];
echo $ident;

global $wpdb;
$table_name = $wpdb->prefix . ' wp_cf7dbplugin_submits';

$data = array(
 'field_name' => 'p'
$where = array( 'submit_time' => $ident );
$format = array( '%s', '%d' );
$where_format = array( '%d' );

$wpdb->update( $table_name, $data, $where, $format, $where_format );

Thanks a lot for the help.