是否可以使用内部连接将值插入两个表中..?表是用户,详细信息
用户表包含 user_id,name,passwrd
详细信息表包含 id、地址、电子邮件
我做了什么:
if(isset($_POST['submit'])=='SUBMIT')
{
$user_name = $_POST['user_name'];
$user_password = $_POST['user_password'];
$details_email = $_POST['details_email'];
$details_phn = $_POST['details_phn'];
$details_age = $_POST['details_age'];
$SQL_QUERY="INSERT INTO tbl_user(user_name,user_password)VALUES('$user_name','$user_password')";
$result=mysql_query($SQL_QUERY);
$SQL_QUERY1="INSERT INTO tbl_details(details_email,details_phn,details_age)VALUES('$details_email','$details_phn','$details_age')";
$result1=mysql_query($SQL_QUERY1);
}
我怎样才能用 innerjoin 重写...请有人帮助我..