首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > ASP >

ASP查询,帮忙,该如何解决

2012-02-24 
ASP查询,帮忙sql select*fromlarchiveswherechatroomyessql selectuser_id,name,sex,education,brit

ASP查询,帮忙
sql= "select   *   from   larchives   where   chatroom=yes   "  
sql= "select       user_id,name,sex,education,britherday,click,company,home,date,photo   from   larchives "

if   search_txt <> " "   then
sql1=sql   &   "   where   name   like   '% "   &   search_txt   &   "% ' "    
sql1=sql   &   "   or   sex   like   '% "   &   search_txt   &   "% ' "  
sql1=sql   &   "   or   education   like   '% "   &   search_txt   &   "% ' "
sql1=sql   &   "   or   britherday   like   '% "   &   search_txt   &   "% ' "
sql1=sql   &   "   or   click   like   '% "   &   search_txt   &   "% ' "
sql1=sql   &   "   or   cstr(company)   like   ' "   &   search_txt   &   " ' "
sql1=sql   &   "   or   date   like   '% "   &   search_txt   &   "% ' "
'sql=sql   &   "   or   chatroom   like   '% "   &   yes   &   "% ' "
end   if


我想把chatroom=yes   和查询结合起来,就是只查询表中chatroom=yes的内容,怎么写呀,高手帮忙,实在没分了,感谢感谢。

[解决办法]
sql= "select * from larchives where chatroom=yes "
sql= "select user_id,name,sex,education,britherday,click,company,home,date,photo from larchives "

热点排行