첨

카테고리를 클릭했는데 에러가 뜹니다..

2010-02-24 12 30 35.jpg

카테고리를 클릭했는데 에러가 뜹니다..
서버환경은  UTF-8 이구요

select distinct wr_parent from g4_write_B29 where ca_name = '토목' and (wr_num between '-13' and '9987') order by a.bn_id desc limit 0, 10

1054 : Unknown column 'a.bn_id' in 'order clause'

error file : /bbs/board.php

첨부파일

댓글 3개

a.bn_id 이 부분이 문제 같네요.

list.php 에서 a.bn_id 를 찾아서 bn_id 로 수정하시면 됩니다.

그런데 그누보드 게시판은 bn_id 라는 필드를 사용하지 않고

bn_id 라는 필드는 yc4_banner(영카트 배너테이블) 에서 사용하는 필드인데요.

bn_id 필드가 없어서 나는 오류일수도 있습니다.
해당 코드가 아래와같은데 어떻게 수정해야하나요???

<style type='text/css'>
/*-- 카테고리명 --*/
.cate {font-family:Tahoma,굴림,arial; color:#666666; font-size:12px;}
a.cate:link, a.b_ca:visited, a.b_ca:active {font-family:Tahoma,굴림,arial; color:#666666; font-size:12px;}
a.cate:hover {font-family:Tahoma,굴림, arial; color:#FF6600; font-size:12px; text-decoration:underline;}
</style>

<? $cnt_bo_1 = 6; // 한줄당 분류 갯수 ?>

<? if (!$wr_id) { ?>
<!-- 분류 셀렉트 박스 시작 -->
<?
$cnt = 1;
$sql = " SELECT bo_category_list FROM $g4[board_table] WHERE bo_table = '$bo_table' ";
$row = sql_fetch($sql);
$arr = explode("|", $row[bo_category_list]); // 구분자가 , 로 되어 있음
$str = "";
$str .= "<tr>";
for ($i=0; $i<count($arr); $i++)
if (trim($arr[$i])) {
$sql1 = " SELECT count(*) as cCount FROM $write_table WHERE ca_name = '$arr[$i]' and wr_comment >= 0 ";
$row1 = sql_fetch($sql1);
$str .= "<td height=24><img src='{$board_skin_path}/img/ico_folder.gif' width='13' height='11'> <a class='cate' href='./board.php?bo_table=$bo_table&sca=$arr[$i]&sop=&sst=wr_1&sod=desc&sfl=&stx=&page=1'>$arr[$i] ($row1[cCount])</a></td>";
if ($cnt == $cnt_bo_1) { $cnt = 0; $str .= "</tr><tr>"; }
$cnt++;
}

$sql2 = " SELECT count(*) as cCount FROM $write_table WHERE wr_comment >= 0 ";
$row2 = sql_fetch($sql2);
$Total_Cat = $row2[cCount]
?>

<table width=100% cellspacing=1 cellpadding=4 border=0 style=table-layout:fixed>
<col width=80></col>
<col width=20></col>
<col width=></col>

<tr bgcolor=white>
<td width='' align='center'>
<img src='<?=$board_skin_path?>/img/ico_folder.gif' width='13' height='11'> <a class='cate' href='./board.php?bo_table=<?=$bo_table?>&sca=<?=$arr[$i]?>&sop=&sst=wr_1&sod=desc&sfl=&stx=&page=1'><b>전체목록</b></a>
</td>
<td nowrap> </td>
<td width='' style='word-break:break-all;'>
<table border=0 cellspacing=0 cellpadding=0 width=100%>
<span class="cate"><?=$str?></span>
</table>
</td>
</tr>
</table>
<table border=0 cellspacing=0 cellpadding=0 width=100%><tr><td height=1 class=line1 style=height:1px><img src=<?=$board_skin_path?>/img/tab.gif border=0 height=1></td></tr></table>
<!-- 분류 셀렉트 박스 끝 -->
<? } ?>
위에 소스는 스킨 부분이고

select distinct wr_parent from g4_write_B29 where ca_name = '토목' and (wr_num between '-13' and '9987') order by a.bn_id desc limit 0, 10

실제 이 소스가 있는 부분은 /bbs/list.php

부분일겁니다.
댓글을 작성하시려면 로그인이 필요합니다.

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기 기존 게시물은 열람만 가능합니다.

+
제목 글쓴이 날짜 조회
10-02-24 조회 1,615
10-02-24 조회 1,421
10-02-24 조회 1,820
10-02-24 조회 3,355
10-02-24 조회 1,000
10-02-24 조회 1,042
10-02-24 조회 1,042
10-02-24 조회 1,195
10-02-24 조회 1,057
10-02-24 조회 1,615
10-02-24 조회 2,378
10-02-24 조회 1,603
10-02-24 조회 1,090
10-02-24 조회 1,085
10-02-24 조회 1,648
10-02-24 조회 1,425
10-02-24 조회 1,666
10-02-24 조회 1,660
10-02-24 조회 1,058
10-02-24 조회 1,394