Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Databases
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #21 (permalink)  
Old February 2nd, 2007, 02:34 PM
Authorized User
 
Join Date: Jan 2007
Location: , , .
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Add a space after FROM
now:
strSQL = "SELECT * FROM" & tablename

change to:
strSQL = "SELECT * FROM " & tablename



Reply With Quote
  #22 (permalink)  
Old February 2nd, 2007, 02:34 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Its not. Your syntax is incorrect. FROMbigcardtable isnt a SQL command, FROM bigcardtable is.

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Reply With Quote
  #23 (permalink)  
Old February 2nd, 2007, 02:37 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

OK. Now I get this error:

Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

/test.asp, line 19

I think this means that somewhere I need to define what rsgameused is. You see, it should "link" to a query called gameusedquery in my Access database. I see nothing in my code that does this. Is that the problem?

Now is the only thing that's real.
Reply With Quote
  #24 (permalink)  
Old February 2nd, 2007, 02:40 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

If I may, it's interesting to note that we are now stuck on the same line of code for this "test" file as with my real website. That,in theory, should mean the problem is with this line. But what is it?

Now is the only thing that's real.
Reply With Quote
  #25 (permalink)  
Old February 2nd, 2007, 02:44 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Holy ************************!!
I was fooling around with the gameused.asp file.
It works!! Sort of....
It will finally display my page, but not the items I want. I only want it to show items with the Category being GameUsed.
Do I just have to add that on to my SELECT * FROM string?????

Now is the only thing that's real.
Reply With Quote
  #26 (permalink)  
Old February 2nd, 2007, 02:49 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Your error was probably because you didnt add a Server.MapPath() in the second connection string that I supplied above.

SELECT * from table where category = 'GameUsed'

will return your used games.

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Reply With Quote
  #27 (permalink)  
Old February 2nd, 2007, 02:49 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Wow! I seem to have fixed the SELECT * FROM. I just added a WHERE and it seems to work. However,... I might as well go for broke.
How can I have it sort Alphabetically????

Now is the only thing that's real.
Reply With Quote
  #28 (permalink)  
Old February 2nd, 2007, 02:52 PM
Wrox Author
Points: 13,255, Level: 49
Points: 13,255, Level: 49 Points: 13,255, Level: 49 Points: 13,255, Level: 49
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2005
Location: Ohio, USA
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

SELECT name FROM table where Category = 'GameUsed' Order By name ASC

================================================== =========
I will only tell you how to do it, not do it for you.
Unless, of course, you want to hire me to do work for you.
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Reply With Quote
  #29 (permalink)  
Old February 2nd, 2007, 02:55 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

OK, now one step back. Remeber how I said it worked? Well...
I am trying to view on the net and as a preview in Dreamweaver, but all I get is a loading screen. It's been 3 or 4 minutes. Why might this be happening all of a sudden?

Now is the only thing that's real.
Reply With Quote
  #30 (permalink)  
Old February 2nd, 2007, 02:58 PM
Authorized User
 
Join Date: Feb 2007
Location: Winnipeg, Manitoba, Canada.
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Let's try this again. the unending load is gone, replaced by another error. I think I know the cause. I want to only display item in the GameUsed Category, but sorted alphabetically by PlayerName. How would that work?

Now is the only thing that's real.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Javascript Access Database Query panuvin Javascript How-To 28 May 9th, 2008 01:53 PM
Displaying query from three tables slims07 .NET Framework 2.0 8 April 2nd, 2008 10:47 AM
Displaying data from access database tusharpat@gmail.com Classic ASP Basics 1 January 24th, 2006 06:35 PM
displaying the query lanita PHP How-To 6 August 23rd, 2004 11:11 PM
Database access from java, INSERT query problem nitusincog BOOK: Beginning Java 2 1 July 21st, 2003 10:26 AM



All times are GMT -4. The time now is 02:04 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.