
June 19th, 2000, 10:55 AM
|
|
Contributing User
|
|
Join Date: Dec 2002
Posts: 14,575
  
Time spent in forums: < 1 sec
Reputation Power: 22
|
|
|
<i><b>Originally posted by : </b></i><br />The way you are doing it is to find a record where Review.Level_ID='level', which doesn't exist in the table, so you got nothing. To get the value of the query string, the right way is:<br /><br />WHERE Review.Subn='2000-0002' and DACO.Division_id='LSD' and Daco.Daco_ID=Review.Daco_ID and Review.Level_ID=' " &_<br />request.querystring("level") & "'" &_<br />"ORDER BY DACO.Daco_id"<br />SET rst = MyConn.Execute(sql) %><br /><br />Carol<br /><br />------------<br />K. St-Louis at 6/11/2000 12:18:15 AM<br /><br />I'm very new to asp....so bear with me.<br /><br />I have:<br />chemistry.asp<br /><% <br /><br /><br /> set MyConn = Server.CreateObject("adodb.connection") <br /> MyConn.Open "DSN=PMRA"<br /><br /> level=Request.QueryString("level") <br /> sql = "SELECT DISTINCT Review.*, DACO.* " &_<br /> "FROM Review, daco " &_<br /> "WHERE Review.Subn='2000-0002' and DACO.Division_id='LSD' and Daco.Daco_ID=Review.Daco_ID and Review.Level_ID='level' " &_<br /> "ORDER BY DACO.Daco_id"<br /> SET rst = MyConn.Execute(sql) %><br /><br />My problem is with the querystring that requests level... If I replace Review.Level_ID= with a correct value of 'C1', I get the<br />correct records that I require. If I pass the value ..<a href="chemistry.asp?level=C1">, I get nothing. <br />Am I doing something wrong?<br /><br />kstlouis<br /><br />
|