I have a mySQL database, called clients it has a single table called client
with 2325 records in it. It was originally an Access database but I have
exported it to mySQL.
I have created a system DSN that connects fine. the following code works a
treat. I get Connection Successful printed to my browser.
<%
on error resume next
dim adoConn
set adoConn = Server.CreateOb ject("ADODB.Con nection")
adoConn.Open "DSN=ClientsDat abase"
if adoConn.errors. count = 0 then
response.write "Connection Successful!"
else
response.write "ERROR: Couldn't connect to database"
end if
%>
However when I rty to access any data in the database it takes forever and
when I say forever I mean I've been sitting here for 10 mins with nothing. I
have hte blue progress bar in IE about half way but nothing is being
displayed. Here is my code
<%
on error resume next
dim adoConn
dim adoRS
dim counter
set adoConn = Server.CreateOb ject("ADODB.Con nection")
set adoRS = Server.CreateOb ject("ADODB.Rec ordset")
adoConn.Open "DSN=ClientsDat abase"
adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn
adoRS.MoveFirst
do until adoRS.EOF
response.write adoRS.fields(0) .value & "<br>"
adoRS.MoveNext
loop
adoRS.close
adoConn.close
%>
What am I doing wrong, surely 2325 records is not a lot!
Thanks
Stu
--
Don: I didn't know you had a cousin Penelope, Bill! Was she
pretty?
W. C.: Well, her face was so wrinkled it looked like seven miles of
bad road. She had so many gold teeth, Don, she use to have to
sleep with her head in a safe. She died in Bolivia.
Don: Oh Bill, it must be hard to lose a relative.
W. C.: It's almost impossible.
-- W. C. Fields, from "The Further Adventures of Larson
E. Whipsnade and other Tarradiddles" 5 2102
Stuart,
if you run the query on the server its fast?
i cant understand though why you want to display so many records? have you
thought any on how large the rendered html file is? a couple of Mb's?
/Lasse
"Stuart Mueller" <I.*********@em ail.address> wrote in message
news:Ob******** *****@tk2msftng p13.phx.gbl... I have a mySQL database, called clients it has a single table called
client with 2325 records in it. It was originally an Access database but I have exported it to mySQL. I have created a system DSN that connects fine. the following code works a treat. I get Connection Successful printed to my browser.
<% on error resume next dim adoConn set adoConn = Server.CreateOb ject("ADODB.Con nection") adoConn.Open "DSN=ClientsDat abase" if adoConn.errors. count = 0 then response.write "Connection Successful!" else response.write "ERROR: Couldn't connect to database" end if %>
However when I rty to access any data in the database it takes forever and when I say forever I mean I've been sitting here for 10 mins with nothing.
I have hte blue progress bar in IE about half way but nothing is being displayed. Here is my code
<% on error resume next dim adoConn dim adoRS dim counter set adoConn = Server.CreateOb ject("ADODB.Con nection") set adoRS = Server.CreateOb ject("ADODB.Rec ordset") adoConn.Open "DSN=ClientsDat abase" adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn adoRS.MoveFirst do until adoRS.EOF response.write adoRS.fields(0) .value & "<br>" adoRS.MoveNext loop adoRS.close adoConn.close %>
What am I doing wrong, surely 2325 records is not a lot!
Thanks
Stu
-- Don: I didn't know you had a cousin Penelope, Bill! Was she pretty? W. C.: Well, her face was so wrinkled it looked like seven miles of bad road. She had so many gold teeth, Don, she use to have to sleep with her head in a safe. She died in Bolivia. Don: Oh Bill, it must be hard to lose a relative. W. C.: It's almost impossible. -- W. C. Fields, from "The Further Adventures of Larson E. Whipsnade and other Tarradiddles"
one more thing:
<html>
<body>
<%
dim adoConn
dim adoRS
dim counter
set adoConn = Server.CreateOb ject("ADODB.Con nection")
set adoRS = Server.CreateOb ject("ADODB.Rec ordset")
adoConn.Open "DSN=ClientsDat abase"
adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn
do until adoRS.EOF
%>
<%=adoRS.fields (0).value%><br>
<%
adoRS.MoveNext
loop
adoRS.close
adoConn.close
%>
</body>
</html>
and get rid of that on error resume next thing!!
use OleDB provider connecting to database, fastest way
"Stuart Mueller" <I.*********@em ail.address> wrote in message
news:Ob******** *****@tk2msftng p13.phx.gbl... I have a mySQL database, called clients it has a single table called
client with 2325 records in it. It was originally an Access database but I have exported it to mySQL. I have created a system DSN that connects fine. the following code works a treat. I get Connection Successful printed to my browser.
<% on error resume next dim adoConn set adoConn = Server.CreateOb ject("ADODB.Con nection") adoConn.Open "DSN=ClientsDat abase" if adoConn.errors. count = 0 then response.write "Connection Successful!" else response.write "ERROR: Couldn't connect to database" end if %>
However when I rty to access any data in the database it takes forever and when I say forever I mean I've been sitting here for 10 mins with nothing.
I have hte blue progress bar in IE about half way but nothing is being displayed. Here is my code
<% on error resume next dim adoConn dim adoRS dim counter set adoConn = Server.CreateOb ject("ADODB.Con nection") set adoRS = Server.CreateOb ject("ADODB.Rec ordset") adoConn.Open "DSN=ClientsDat abase" adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn adoRS.MoveFirst do until adoRS.EOF response.write adoRS.fields(0) .value & "<br>" adoRS.MoveNext loop adoRS.close adoConn.close %>
What am I doing wrong, surely 2325 records is not a lot!
Thanks
Stu
-- Don: I didn't know you had a cousin Penelope, Bill! Was she pretty? W. C.: Well, her face was so wrinkled it looked like seven miles of bad road. She had so many gold teeth, Don, she use to have to sleep with her head in a safe. She died in Bolivia. Don: Oh Bill, it must be hard to lose a relative. W. C.: It's almost impossible. -- W. C. Fields, from "The Further Adventures of Larson E. Whipsnade and other Tarradiddles"
I have not worked with mySQL but is working when you quote the table name in
the from clause?
adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn
^ ^
Regards
/Hans
Yes, it is correct to quote the table. It is not necessay but it is correct.
This is most probably because mysql allows spaces in table names.
--
Fadi El-Eter, itoctopus - http://www.itoctopus.com
"Hans" <ha***@sorry.no spam.com> wrote in message
news:uO******** ******@TK2MSFTN GP11.phx.gbl... I have not worked with mySQL but is working when you quote the table name
in the from clause?
adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn ^ ^ Regards /Hans
you should download the MySQL ODBC 3.51 for MySQL from there website.
my mysql connection string looks more like.
"driver={My SQL ODBC 3.51
Driver};server= myserver;databa se=mydatabase;u id=myusername;p wd=myuserpass"
but i would say this has more to do with the fact that your pulling 2325
records at once. that is a hell of allot.
"Stuart Mueller" <I.*********@em ail.address> wrote in message
news:Ob******** *****@tk2msftng p13.phx.gbl... I have a mySQL database, called clients it has a single table called
client with 2325 records in it. It was originally an Access database but I have exported it to mySQL. I have created a system DSN that connects fine. the following code works a treat. I get Connection Successful printed to my browser.
<% on error resume next dim adoConn set adoConn = Server.CreateOb ject("ADODB.Con nection") adoConn.Open "DSN=ClientsDat abase" if adoConn.errors. count = 0 then response.write "Connection Successful!" else response.write "ERROR: Couldn't connect to database" end if %>
However when I rty to access any data in the database it takes forever and when I say forever I mean I've been sitting here for 10 mins with nothing.
I have hte blue progress bar in IE about half way but nothing is being displayed. Here is my code
<% on error resume next dim adoConn dim adoRS dim counter set adoConn = Server.CreateOb ject("ADODB.Con nection") set adoRS = Server.CreateOb ject("ADODB.Rec ordset") adoConn.Open "DSN=ClientsDat abase" adoRS.Open "SELECT agent FROM 'client' WHERE agent='Intercar s'", conn adoRS.MoveFirst do until adoRS.EOF response.write adoRS.fields(0) .value & "<br>" adoRS.MoveNext loop adoRS.close adoConn.close %>
What am I doing wrong, surely 2325 records is not a lot!
Thanks
Stu
-- Don: I didn't know you had a cousin Penelope, Bill! Was she pretty? W. C.: Well, her face was so wrinkled it looked like seven miles of bad road. She had so many gold teeth, Don, she use to have to sleep with her head in a safe. She died in Bolivia. Don: Oh Bill, it must be hard to lose a relative. W. C.: It's almost impossible. -- W. C. Fields, from "The Further Adventures of Larson E. Whipsnade and other Tarradiddles"
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Tim Fountain |
last post by:
We've recently enabled slow query logging on a server and it's proving
interesting seeing which queries are bogging things down. This one is
puzzling me a little:
SELECT articleid, type, authorid, authorname, text, posted FROM
comments WHERE status = 'normal' ORDER BY posted DESC LIMIT 5;
The purpose of this query is to list the five most recent
(non-deleted) comments. Here is the table structure:
|
by: Jesse Sheidlower |
last post by:
I'm struggling with speed issues on some queries that
I would have expected to be relatively fast. Perhaps
even more frustratingly, when I've tried to break
these down into their components, they still execute
very slowly. I've looked over all the relevant suggestions
for optimization and so forth, and there's nothing I can
tell that I'm missing.
An example of a query is to get all the words (the cg.cw
field) in a particular...
|
by: Scott |
last post by:
Hi,
I'm having a problem with a new machine running Mysql version 4.0.18
on the AMD64 version of Mandrake 10.0. The new machine has got 64bit
AMD processor and 2GB of RAM.
Nearly all queries(updates are especially slow) are running 20/30 or
more times slower than on an inferior(32 bit processor, 1.5GB RAM)
machine runnning Mysql 3.23.56 on mandrake 9.0.
|
by: DJJ |
last post by:
I am using the MySQL ODBC 3.51 driver to link three relatively small MySQL
tables to a Microsoft Access 2003 database. I am finding that the data from
the MySQL tables takes a hell of a long time to load making any kind linkage
with my Access data virtually useless.
I have the MySQL driver setup in as a USER DSN. The MySQL data is sitting
out on a server and the Access database is running locally. The network
connection is very...
|
by: D. Dante Lorenso |
last post by:
Trying to use the 'search' in the docs section of PostgreSQL.org
is extremely SLOW. Considering this is a website for a database
and databases are supposed to be good for indexing content, I'd
expect a much faster performance.
I submitted my search over two minutes ago. I just finished this
email to the list. The results have still not come back. I only
searched for:
SECURITY INVOKER
| |
by: Pratchaya |
last post by:
In my.cnf
i add these lines
#######
log-bin
log-slow-queries = /var/log/mysqld-slow.log
long_query_time=1
#######
|
by: grace |
last post by:
i am wondering why my database retrieval becomes too slow...we set up
a new server (ubuntu, breezy badger) machine where we transferred all
our files from the old server.. Our new server uses Asus p5pe-vm
motherboard and an Intel Pentium D 3.0Ghz processor, compared to the
old one where we uses asrock motherboard and AMD Duron. Both has the
same version of mysql installed...
To summarized, both machine has the same configuration except...
|
by: Derrick Shields |
last post by:
I'm working with a database that has over 11 million rows. The .SQL
drop file is about 2.5gigs. Doing a simple query:
select * from people where last_name like '%smith%'
A query like this can take up to two minutes. I've spent hours reading
these forums and other sites on the internet, and I've figured that I
need to do a couple things:
create some indexes -and- possibly create some partitions
|
by: mezise |
last post by:
Posted by Pratchaya:
------------------------------------------------------
MySQL Slow Log ERROR
In my.cnf
i add these lines
#######
log-bin
log-slow-queries = /var/log/mysqld-slow.log
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |