日期:2014-05-16 浏览次数:20479 次
/* 注入基本信息,A_I自动生成meta_id */
$query1 = "INSERT INTO libr_metacode (meta_isbn, meta_cip) VALUES ('$isbn', '$cip')";
$result1 = mysqli_query($dbc,$query1)
or die('无法写入基本编码,错误信息:' . mysqli_error($dbc));
/* 获取meta_id进行后续写入 */
$query = "SELECT * FROM libr_metacode WHERE meta_isbn='$isbn'";
$result = mysqli_query($dbc, $query);
$row = mysqli_fetch_array($result);
$ida = $row['meta_id'];
echo '获得本书藏书库系统元编码' . $ida . '<br />';
/* 题名 */
$query2 = "INSERT INTO libr_title (meta_id, title, subtitle, series) VALUES ('$ida', '$title', '$subtitle', '$series')";
$result2 = mysqli_query($dbc,$query2)
or die('无法写入题名信息,错误:' . mysqli_error($dbc));
/* 获取meta_id进行后续写入 */
$query = "SELECT * FROM '$ui_b' WHERE '$ui_c'='$ui_a'";
$result = mysqli_query($dbc, $query);
$row = mysqli_fetch_array($result);
$ida = $row['meta_id'];