Quantcast
Viewing latest article 4
Browse Latest Browse All 44

wpdb get_row database query inquiry

Is this the right way to use get_row with a select *?

$_crds = $wpdb->get_row($wpdb->prepare(" SELECT * FROM `mailers` WHERE `id` = %d", $_GET['caId'] ));

$_zipcodes = $_crds->zipcodes;
$_maildate = $_crds->maildate;

Is that the right way to pull the values from the database?
I have a lot of records in that table I need to pull, so wanted to do it in one db pull…

but my code appears to not be working.

-Rich


Viewing latest article 4
Browse Latest Browse All 44

Trending Articles