navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
FrontPage Alternative
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

ASP problems

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> ASP problems
Page: [1]
 
Topic Starter

 

Posts: 49
From: Canada, eh?
Status: offline

 
ASP problems - 3/30/2001 20:00:00   
I'm having some problems with what I thought was my server, but now it may be how FP connects to the database. I'm just wondering if anyone else has had this problem. For instance on some clients' sites they have admin screens that for example allow them to enter in a new Fishing Tournament into the event database. Once this is completed, if you go back to the event listings, the browser has to be refreshed in order to show the new event. Sometimes the header disappears and the page looks like a mess, and sometimes I have to delete my temp files and then refresh, its getting to be a real problem. I posted a message on a newsgroup, and thought I would bring my problem to you. Here is the response I got, sorry this message will be so long....

Hi,

It sounds to me that it is a ASP/Database issue, and nothing to do with the servers, refreshing, cookies or HTTP configs. When you say the user has to close the browser and re-open - this starts a new server session, therefore data will be written to the database, and the user will see it.

We had this problem - inserting, or deleting data from a database, then go to another page to view the result - and get the old data. The problem was down to our connection to the database.


For example ....


Dim objConn
Dim objRst
Dim strSQL

Set objConn = Server.CreateObject("ADODB.Connection")
Set objRst = Server.CreateObject("ADODB.Recordset")

objConn.Open "DBQ=" & Server.Mappath("../../../databases/PCM.mdb") & ";Driver={Microsoft Access Driver (*.mdb)};"

'
strSQL = "YOUR SQL STATEMENT HERE"

objRst.Open strSQL, objConn , 1, 3 <####
objRST.CacheSize = 1


The line that I've marked above "objRst.Open strSQL, objConn , 1, 3 " it the line that opens the recordset, sets the cursor, and connection type.

To me, it sounds like you've set your cursor wrong. The above line sets the Cursor to 3, meaning dynamic. That way I can go up and down the recordset, and view changes to the DB in real time.

It's all to do with how you connect to the database

Spooky

 

Posts: 26606
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: ASP problems - 3/30/2001 21:00:00   
I always use asp caching like so :

<%
Response.ExpiresAbsolute = Now() - 1
Response.AddHeader "Cache-Control", "must-revalidate"
Response.AddHeader "Cache-Control", "no-cache"
%>

It seems to work OK for me, perhaps you have a server cache issue?


(in reply to Topic Starter)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> ASP problems
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts