본문 바로가기
인프라 7기/Oracle

PHP - Oracle 연동 2

by 킹버거 2023. 3. 3.

# 출력 프로그램 

student 테이블 출력 프로그램 파일 : st_vi.php

<?
	echo("<a href=./st_in.html>자료 입력하기</a><hr>");

	require('conn.php');

	$sql="select sno,sname,sex,major,syear,avr
	         from student order by sno";

	$result=oci_parse($conn, $sql);
	oci_execute($result);

	while ($row = oci_fetch_array($result, OCI_NUM)) {
		echo("$row[0]-$row[1]-$row[2]-$row[3]-$row[4]-$row[5] <br>");
	}

	oci_free_statement($result);
	oci_close($conn);
?>

 

# 실행 결과

'인프라 7기 > Oracle' 카테고리의 다른 글

Oracle : Redo Log File 관리  (0) 2023.03.06
Oracle : 관리자 패스워드 지정  (0) 2023.03.06
PHP - Oracle 연동  (0) 2023.03.03
PHP - DB 접속  (0) 2023.03.03
Oracle 자동 실행  (0) 2023.03.03