<?php
require zb_system/function/c_system_base.php;
$zbp->Load();
$sql = $zbp->db->sql->get()->select(ships)
->min(array(cid=>min))
->where(array(=, a ,0))
->query;
$min=(int)$sql[0][min];
while($min>0)
{
if($min){
$array = $zbp->db->sql->get()
->select(typecho_relationships)
->where(array(=, cid, $min))
->where(array(=, a, 0))
->query;
$aa=;
foreach ($array as $cc) {
$ac={.$cc[mid].};
$aa=$aa.$ac;
}
$sql = $zbp->db->sql->get()->update($zbp->table[Post])
->where(=, log_ID, $min)
->data(array(log_Tag => $aa))
->query;
$sql = $zbp->db->sql->get()->delete(typecho_relationships)
->where(=, cid, $min)
->query;
}
$sql = $zbp->db->sql->get()->select(typecho_relationships)
->min(array(cid=>min))
->where(array(=, a ,0))
->query;
$min=(int)$sql[0][min];
}
评论列表