사이트는 swj.co.kr 입니다
검색에 규격으로 검색하면 찾아내지못합니다
어떨때는 또 찾아내기도 합니다
아래 소스에 문제가 없을듯한데 어느 부분을 손을 데야 할지 .......도와주세요
..................상단생략.......................
<%
sel_sch = request("sel_sch")
sel_sch2 = request("sel_sch2")
sel_comp_code = request("comp_code")
'이전페이지 , 다음페이지....
'이 부분은 밑에 처리되었다...
'하이퍼링크로 이전페이지 다음페이지 한 부분에 가보면 있다...
session("CurrentPage") = 1
'이 부분은 페이지로 직접 접근하는 부분이다.
If Request.QueryString("GoTopage") <> "" then
session("CurrentPage") = Request.QueryString("GoTopage")
else
end If
If sel_sch2 = "" Then '검색어가 없다면
If sel_sch = "no1" Then '상품명으로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
else '규격코드로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
end if
else '정상적인 검색이라면
If sel_sch = "no1" Then '상품명으로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
else '규격코드로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
end if
end If
Set Grs = Server.CreateObject("ADODB.Recordset")
Grs.pagesize = 30
Grs.Open SQL,objconn,1
TotCount_search = Grs.RecordCount
if Grs.BOF or Grs.EOF Then
%>
<script language='javascript'>
alert('검색에 부합하는 상품이 없습니다.')
history.back();
</script>
<%
response.end
else
sql_f = "select comp_code,comp_name from company where comp_code = '" & Grs("pr_comp") & "'"
set rs_com_f = objConn.Execute (sql_f)
End if
%>
<tr>
<td width="689" align="left" valign="middle" height="31"> <p style='margin-left:30px; margin-right:5px;'> <font color="#495766"> <%=rs_com_f("comp_name")%> 회사에 대해 검색어 : <b><%=sel_sch2%></b>
(총 <%=TotCount_search%> 개의 항목을 검색했습니다)</font>
</p></td>
</tr>
<tr>
<td width="689" align="center" valign="top">
<table border="0" width="560" align=center cellspacing='0' cellpadding='0'>
<tr>
<td align='center' valign='top'>
<img src='/swshop/images/sub_05.gif' border='0' align='absmiddle'>
</tD>
</tR>
</table>
<!-- 탑 부분 인클루드 종료 -->
<table border="0" width="650" align=center cellspacing='0' cellpadding='0'>
<!-- 제품리스트 시작 -->
<tr>
<td width="689" align="center" valign="top">
<%
if Grs.BOF or Grs.EOF then
%>
<br><br>
검색된 상품이 없습니다.<br>
<br><br>
<%
response.End
else
Grs.absolutepage = session("CurrentPage")
session("pagecount")=Grs.pagecount
%>
.........하단생략...............
검색에 규격으로 검색하면 찾아내지못합니다
어떨때는 또 찾아내기도 합니다
아래 소스에 문제가 없을듯한데 어느 부분을 손을 데야 할지 .......도와주세요
..................상단생략.......................
<%
sel_sch = request("sel_sch")
sel_sch2 = request("sel_sch2")
sel_comp_code = request("comp_code")
'이전페이지 , 다음페이지....
'이 부분은 밑에 처리되었다...
'하이퍼링크로 이전페이지 다음페이지 한 부분에 가보면 있다...
session("CurrentPage") = 1
'이 부분은 페이지로 직접 접근하는 부분이다.
If Request.QueryString("GoTopage") <> "" then
session("CurrentPage") = Request.QueryString("GoTopage")
else
end If
If sel_sch2 = "" Then '검색어가 없다면
If sel_sch = "no1" Then '상품명으로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
else '규격코드로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
end if
else '정상적인 검색이라면
If sel_sch = "no1" Then '상품명으로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_vol like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
else '규격코드로 검색한거라면
If sel_comp_code = "" Then '회사코드가없으면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' order by pr_code"
else '회사코드도 포함이라면
SQL = "select * from product where pr_name like '%" & sel_sch2 & "%' and chulryuk='y' and pr_comp like '%" & sel_comp_code & "%' order by pr_code"
end if
end if
end If
Set Grs = Server.CreateObject("ADODB.Recordset")
Grs.pagesize = 30
Grs.Open SQL,objconn,1
TotCount_search = Grs.RecordCount
if Grs.BOF or Grs.EOF Then
%>
<script language='javascript'>
alert('검색에 부합하는 상품이 없습니다.')
history.back();
</script>
<%
response.end
else
sql_f = "select comp_code,comp_name from company where comp_code = '" & Grs("pr_comp") & "'"
set rs_com_f = objConn.Execute (sql_f)
End if
%>
<tr>
<td width="689" align="left" valign="middle" height="31"> <p style='margin-left:30px; margin-right:5px;'> <font color="#495766"> <%=rs_com_f("comp_name")%> 회사에 대해 검색어 : <b><%=sel_sch2%></b>
(총 <%=TotCount_search%> 개의 항목을 검색했습니다)</font>
</p></td>
</tr>
<tr>
<td width="689" align="center" valign="top">
<table border="0" width="560" align=center cellspacing='0' cellpadding='0'>
<tr>
<td align='center' valign='top'>
<img src='/swshop/images/sub_05.gif' border='0' align='absmiddle'>
</tD>
</tR>
</table>
<!-- 탑 부분 인클루드 종료 -->
<table border="0" width="650" align=center cellspacing='0' cellpadding='0'>
<!-- 제품리스트 시작 -->
<tr>
<td width="689" align="center" valign="top">
<%
if Grs.BOF or Grs.EOF then
%>
<br><br>
검색된 상품이 없습니다.<br>
<br><br>
<%
response.End
else
Grs.absolutepage = session("CurrentPage")
session("pagecount")=Grs.pagecount
%>
.........하단생략...............
댓글 1개
17년 전
직접 디비에 접속하셔서
query를 실행해 보세요.
query를 실행해 보세요.
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 7930 | 9년 전 | 399 | ||
| 7929 | 9년 전 | 319 | ||
| 7928 | 9년 전 | 410 | ||
| 7927 | 9년 전 | 328 | ||
| 7926 | 9년 전 | 658 | ||
| 7925 | 9년 전 | 342 | ||
| 7924 | 9년 전 | 330 | ||
| 7923 | 9년 전 | 336 | ||
| 7922 | 9년 전 | 369 | ||
| 7921 | 9년 전 | 395 | ||
| 7920 | 9년 전 | 315 | ||
| 7919 | 9년 전 | 330 | ||
| 7918 | 9년 전 | 486 | ||
| 7917 | 9년 전 | 323 | ||
| 7916 | 9년 전 | 399 | ||
| 7915 | 9년 전 | 399 | ||
| 7914 | 9년 전 | 407 | ||
| 7913 | 9년 전 | 564 | ||
| 7912 | 9년 전 | 410 | ||
| 7911 | 9년 전 | 357 | ||
| 7910 | 9년 전 | 401 | ||
| 7909 | 9년 전 | 499 | ||
| 7908 | 9년 전 | 415 | ||
| 7907 | 9년 전 | 359 | ||
| 7906 | 9년 전 | 381 | ||
| 7905 | 9년 전 | 357 | ||
| 7904 | 9년 전 | 346 | ||
| 7903 | 9년 전 | 341 | ||
| 7902 | 9년 전 | 550 | ||
| 7901 |
|
9년 전 | 726 | |
| 7900 | 9년 전 | 572 | ||
| 7899 | 9년 전 | 370 | ||
| 7898 | 9년 전 | 378 | ||
| 7897 | 9년 전 | 331 | ||
| 7896 | 9년 전 | 351 | ||
| 7895 | 9년 전 | 459 | ||
| 7894 | 9년 전 | 381 | ||
| 7893 | 9년 전 | 323 | ||
| 7892 | 9년 전 | 375 | ||
| 7891 | 9년 전 | 753 | ||
| 7890 | 9년 전 | 1188 | ||
| 7889 | 9년 전 | 741 | ||
| 7888 |
limsy1987
|
9년 전 | 541 | |
| 7887 | 9년 전 | 537 | ||
| 7886 | 9년 전 | 423 | ||
| 7885 | 9년 전 | 395 | ||
| 7884 | 9년 전 | 398 | ||
| 7883 | 9년 전 | 395 | ||
| 7882 | 9년 전 | 440 | ||
| 7881 | 9년 전 | 429 | ||
| 7880 | 9년 전 | 550 | ||
| 7879 | 9년 전 | 450 | ||
| 7878 | 9년 전 | 1207 | ||
| 7877 | 9년 전 | 743 | ||
| 7876 | 9년 전 | 472 | ||
| 7875 | 9년 전 | 551 | ||
| 7874 |
|
9년 전 | 800 | |
| 7873 | 9년 전 | 509 | ||
| 7872 | 9년 전 | 666 | ||
| 7871 | 9년 전 | 473 | ||
| 7870 | 9년 전 | 597 | ||
| 7869 | 9년 전 | 424 | ||
| 7868 | 9년 전 | 431 | ||
| 7867 | 9년 전 | 412 | ||
| 7866 | 9년 전 | 478 | ||
| 7865 | 9년 전 | 441 | ||
| 7864 | 9년 전 | 505 | ||
| 7863 | 9년 전 | 502 | ||
| 7862 | 9년 전 | 459 | ||
| 7861 | 9년 전 | 620 | ||
| 7860 | 9년 전 | 610 | ||
| 7859 | 9년 전 | 403 | ||
| 7858 | 9년 전 | 694 | ||
| 7857 | 9년 전 | 1063 | ||
| 7856 | 9년 전 | 511 | ||
| 7855 | 9년 전 | 737 | ||
| 7854 | 9년 전 | 723 | ||
| 7853 | 9년 전 | 571 | ||
| 7852 | 9년 전 | 500 | ||
| 7851 | 9년 전 | 495 | ||
| 7850 | 9년 전 | 578 | ||
| 7849 | 9년 전 | 353 | ||
| 7848 | 9년 전 | 403 | ||
| 7847 | 9년 전 | 643 | ||
| 7846 | 9년 전 | 446 | ||
| 7845 | 9년 전 | 406 | ||
| 7844 | 9년 전 | 386 | ||
| 7843 | 9년 전 | 404 | ||
| 7842 | 9년 전 | 390 | ||
| 7841 | 9년 전 | 375 | ||
| 7840 | 9년 전 | 391 | ||
| 7839 | 9년 전 | 426 | ||
| 7838 | 9년 전 | 509 | ||
| 7837 | 9년 전 | 346 | ||
| 7836 | 9년 전 | 393 | ||
| 7835 | 9년 전 | 463 | ||
| 7834 |
|
9년 전 | 1185 | |
| 7833 | 9년 전 | 416 | ||
| 7832 | 9년 전 | 405 | ||
| 7831 | 9년 전 | 552 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기