|
- <?
- require "global.php";
- if ($pa_equipment_number || $pa_user_company || $pa_company_location || $level)
- {
- $DB = new DB_MYSQL;
- $DB->servername = $servername;
- $DB->dbname = $dbname;
- $DB->dbusername = $dbusername;
- $DB->dbpassword = $dbpassword;
- $DB->connect();
- $DB->selectdb();
- $result1 = mysql_query("insert into guanli1 set pa_equipment_number= '$pa_equipment_number'");
- $result2 = mysql_query("insert into guanli2 set pa_user_company= '$pa_user_company'");
- $result3 = mysql_query("insert into guanli3 set pa_company_location '$pa_company_location'");
- $result4 = mysql_query("insert into guanli4 set level= '$level'");
- }
- else
- {
- echo "input error";
- }
- if ($result1 || $result2 || $result3 || $result4)
- {
- echo "add ok";
- }
- else
- {
- echo "No data.";
- }
-
- 我是4个数据随便添加的,随便添一个或者都个都可以,都放在单独的表内,
- 但是每次我添加后,都出现空格
- 代码:
- +-----+-----------------+
- | id2 | pa_user_company |
- +-----+-----------------+
- | 1 | |
- | 2 | 上海 |
- | 3 | |
- | 4 | |
- | 5 | 22 |
- | 6 | |
- +-----+-----------------+
-
复制代码
出现这样的问题,是不是自增量的问题啊? |
|