eliminar $wpdb
del nombre de la tabla. El código funcionará
de
$count = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->pincode_distro1 WHERE pincode = '$the_order->shipping_postcode'");
a
$count = $wpdb->get_var("SELECT COUNT(*) FROM pincode_distro1 WHERE pincode = '$the_order->shipping_postcode'");