>> Edit article
이름
제목
패스워드
mysql에 netibank라는 데이타베이스를 생성하구 netibank데이타베이스 안에 user_info라는 테이블을 생성한 다음에 다음과 같이 코딩을 하구 실행시겼더니 다음과 같은 에러가 나더라구요 ------------------------------------------------------------------------------------------------- Warning: Supplied argument is not a valid MySQL-Link resource in /mydir/web/mssql.php on line 6 Warning: Supplied argument is not a valid MySQL-Link resource in /mydir/web/mssql.php on line 10 Warning: Supplied argument is not a valid MySQL-Link resource in /mydir/web/mssql.php on line 11 ------------------------------------------------------------------------------------------------- connection은 된건 같은데 netibank 라는 데이타베이스를 못찻는것 같습니다. 고수님들 제발 도와주세요..... (--)(__)(--) ================================= 소스 ====================================================== <? echo("Database Connection.....................................................!<br>"); $dbconn = mysql_connect("localhost","php","php99") || die("DB Server Connect Fail!"); $status = mysql_select_db("netibank",$dbconn); <--- 6 line if(!$status) { $errNO = mysql_errno($dbconn); <-------------- 10 line $errMSG = mysql_error($dbconn); <------------- 11 line echo("[Error Code] : $errNO : [Error Message] : $errMSG<br>"); echo("Server is netibank database connet fail!<br>"); exit; } else { echo("netibank Database connet success!<br>"); } $query = "select * from user_info"; $result = mysql_query($query,$dbconn); //->waring if(!$result) { $errNO = mysql_errno($dbconn); //->waring $errMSG = mysql_error($dbcon); //->waring echo("[Error Code] : $errNO [Error Msg] : $errMSG"); exit; } $fields = mysql_num_fields($result); echo("<table border=0 cellpaddin=10>"); echo("<tr>=n"); echo("<td width=100 bgcolor=pink align=center> FILD NAME</td>"); echo("<td width=100 bgcolor=pink align=center> FILD TYPE</td>"); echo("<td width=100 bgcolor=pink align=center> FILD SIZE</td>"); echo("<td width=100 bgcolor=pink align=center> FILD FLAGS</td>"); echo("<td width=100 bgcolor=pink align=center> TABLE NAME</td>"); echo("</tr>"); for($irow = 0; $irow<$fields; $i++) { echo("<tr>"); $field_name = mysql_field_name($result,$i); $field_type = mysql_field_name($result,$i); $field_len = mysql_field_name($result,$i); $field_flags = mysql_field_name($result,$i); $field_table = mysql_field_name($result,$i); echo("<td bgcolor=lightyellow align=center>$field_name</td>"); echo("<td bgcolor=lightyellow align=center>$field_type</td>"); echo("<td bgcolor=lightyellow align=center>$field_len</td>"); echo("<td bgcolor=lightyellow align=center>$field_flags</td>"); echo("<td bgcolor=lightyellow align=center>$field_table</td>"); echo("</table>"); } mssql_close($dbconn);
Copyleft
1999-2026 by
JSBoard Open Project
Theme Designed by
IDOO
All right reserved