$yesterday = array (
\'year\' => date(\'y\'),
\'month\' => date(\'m\'),
\'day\' => date(\'d\')-1
);
$rows = $wpdb->query($wpdb->prepare(*emphasized text*
"SELECT id, yymmdd
FROM plugin_data
WHERE yymmdd LIKE \'%d-%d-%d",
$yesterday[\'year\'], $yesterday[\'month\'], $yesterday[\'day\']
));
foreach ( $rows as $r ) {
$id_for_yesterday_rows[]= $r->id;
}
现在,您在一个数组中拥有了昨天提交的所有ID或行。