게시판 전체 게시글 수 구하려고 하는데요~ 채택완료
fear
9년 전
조회 4,085
</p><p>function board_count($bo_table){</p><p>$allrow = sql_fetch(" select bo_count_write from g5_board where bo_table = '".$bo_table."' ");</p><p>return $allrow['bo_count_write'];</p><p>}</p><p>
랑
</p><p>function board_count($bo_table){</p><p>$allrow = sql_fetch(" select count(*) as total from g5_write_notice ");</p><p>//return $allrow['bo_count_write'];</p><p>echo $allrow[total];</p><p>}</p><p>
중에서 어떤게 더 효율적인가요?
게시글이 많을 때, 서버 자원 덜 먹고 빠른 쿼리문을 찾고 있어요. :'(
댓글을 작성하려면 로그인이 필요합니다.
답변 1개
답변을 작성하려면 로그인이 필요합니다.
로그인