ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old March 21st, 2011, 07:45 PM
Vertex21 Vertex21 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2011
Posts: 3 Vertex21 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 31 sec
Reputation Power: 0
Please Help! errorCode:80020009 Either BOF or EOF is true......

Hi all, and thank you in advance for all your help! I am not a good .asp programmer, but I have a project I'm trying to get finished and it involves an ASP website that a company uses for creating reservations. I built a new server for them and imported all of the information from the old server, set up IIS7 on the new server, MySQL 5.5 and upgraded to the MySQL ODBC driver version 5.1. Most everything went smooth, except for having to hunt down and update a bunch of connection strings, but I seem to be left with one issue. And I'm not exactly sure if it's something I set up wrong on the web hosting or mysql install, or if the old ASP code isn't compatible with the newer web and database software. Anyway, I'm getting a "either BOF or EOF is true, or the current recordset has been deleted" error, from a piece of javascript code that allows the users to update/change pieces of data in the database. It is a little popup window that has a few editable form fields, and when the user clicks "save" it is supposed to update the database and then automatically close the popup window. It is updating the database just fine, but instead of closing the popup window it just displays an internal 500 error and in my IIS7 error log it says it is error 80020009. here is the code, and I very much appreciate the help! thanks!

Code:
<%
Dim MM_db_STRING
MM_db_STRING = "Driver={MySQL ODBC 5.1 Driver}; Server=localhost; Database=suncityexpress; UID=sce_user; PWD=****; Option=3;"
Dim voucher
Dim voucher_cmd
Dim voucher_numRows

Set voucher_cmd = Server.CreateObject ("ADODB.Command")
voucher_cmd.ActiveConnection = MM_db_STRING
voucher_cmd.CommandText = "SELECT * FROM new_book WHERE id='"&Request.QueryString("trip")&"'" 
voucher_cmd.Prepared = true

Set voucher = voucher_cmd.Execute

If Request.Form("book") <> "" Then

theSql = "UPDATE new_book SET dropoff_at='"&Request.Form("doa")&"', customer_name='"&Replace(Request.Form("custName"), "'", "\'")&"', voucher='"&Request.Form("Ticket")&"', a_headcount='"&Request.Form("a_headcount")&"' WHERE id='"&Request.Form("book")&"'"

theOtherSql = "UPDATE new_book SET voucher='"&Request.Form("Ticket")&"', last_edit='"&Session("userFullName")&"' WHERE riders_id='"&Request.Form("r_id")&"'"

	'Response.Write(theSql)
	'Response.End()
    Dim MM_editCmd
    Set MM_editCmd = Server.CreateObject ("ADODB.Command")
    MM_editCmd.ActiveConnection = MM_db_STRING
    MM_editCmd.CommandText = theSql
    MM_editCmd.Prepared = true
    MM_editCmd.Execute
	MM_editCmd.CommandText = theOtherSql
    MM_editCmd.Prepared = true
    MM_editCmd.Execute
    MM_editCmd.ActiveConnection.Close
	Set MM_editCmd = Nothing
    Response.Write("<script>opener.location=""voucher.asp?id="&Request.Form("book")&"""; self.close();</script>")
End If
%>
<style type="text/css">
<!--
body,td,th {
	font-family: Trebuchet MS, Arial, Helvetica, sans-serif;
	font-size: 16px;
}
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
}
-->
</style><body bgcolor="#CAEEFF">
<center>
<b><u>Change Customer Information:</u></b><br />
<form name="setDriver" method="post" action="cAddress.asp">
<table cellpadding="3" cellspacing="0">
	<tr>
    	<td align="right"><strong>Customer Name:</strong></td>
        <td align="left"><input type="text" name="custName" value="<%=voucher("customer_name")%>"></td>
    </tr>
    <tr>
    	<td align="right"><strong>Airport:</strong></td>
        <td align="left"><input type="text" name="doa" value="<%=voucher("dropoff_at")%>"></td>
    </tr>
    <tr>
    	<td align="right"><strong>Ticket Voucher:</strong></td>
        <td align="left"><input type="text" name="Ticket" value="<%=voucher("voucher")%>"></td>
    </tr>
    <tr>
    	<td align="right"><strong>Headcount:</strong></td>
        <td align="left"><input type="text" name="a_headcount" value="<%=voucher("a_headcount")%>"></td>
    </tr>
</table>
<br />
<input type="hidden" name="r_id" value="<%=voucher("riders_id")%>">
<input type="hidden" name="book" value="<%= Request.QueryString("trip") %>">
<input type="hidden" name="way" value="<%=Request.QueryString("way")%>">
<input type="submit" value="Save" />
</form>
</center>
<%
voucher.Close()
Set voucher = Nothing
%>

Reply With Quote
  #2  
Old March 22nd, 2011, 12:52 AM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 19th Plane (14000 - 14499 posts)
 
Join Date: Jun 2003
Posts: 14,237 Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level) 
Time spent in forums: 1 Month 4 Weeks 14 h 43 m 55 sec
Reputation Power: 4445
The error message should identify the line of code that generated the error. Please identify the error code line. And in IE, turn off the 'show friendly http errors' setting and you should get a detailed error message in the browser instead of just a 500 error.
__________________
======
Doug G
======
It is a truism of American politics that no man who can win an election deserves to. --Trevanian, from the novel Shibumi

Reply With Quote
  #3  
Old March 22nd, 2011, 01:56 AM
Vertex21 Vertex21 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2011
Posts: 3 Vertex21 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 31 sec
Reputation Power: 0
Thank you for the quick response! in the error page (xml file that IIS creates) on the error line it says "line 0". I can't imagine that the first line of code is bad.. I did turn 'show friendly errors' off, but it doesn't give me any detailed information.. still shows the 500 error page. I printed a pdf of the error log and since I can't attach it here, I uploaded it to www . vertex21 . com /files/fr000148.pdf
Hopefully that'll help.. sorry for the messed up link, but it wouldn't allow me to post URLs.. Thanks so much!

Mike

Reply With Quote
  #4  
Old March 25th, 2011, 06:30 AM
andybuk99 andybuk99 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2011
Posts: 2 andybuk99 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 55 m 14 sec
Reputation Power: 0
Hi,
Are you sure that your SQL..
voucher_cmd.CommandText = "SELECT * FROM new_book WHERE id='"&Request.QueryString("trip")&"
Is returning a row? your using vouchers("field name") in the form but your not checking that it actually found a row.
Just a thought.

Reply With Quote
  #5  
Old March 25th, 2011, 10:37 PM
Vertex21 Vertex21 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2011
Posts: 3 Vertex21 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 31 sec
Reputation Power: 0
Thank you all for the replies, but I found the problem. It was as simple as me not having restored one of the tables. I added the table back in, and it worked great! thanks again though, and sorry for wasting any time..

Mike

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > Please Help! errorCode:80020009 Either BOF or EOF is true......

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap