Wrox Programmer Forums
|
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 software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 7th, 2007, 04:01 AM
Authorized User
 
Join Date: Jun 2007
Posts: 87
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to ivanlaw Send a message via Yahoo to ivanlaw
Default Urgent need help: ASP Code for database

Hi all Pro,

Please tell why I face this problem as below:
Error Type:
Microsoft JET Database Engine (0x80040E14)
Syntax error in FROM clause.
/web/CheckLogin.asp, line 10

Then my coding is as below:
Dim strEMail, strPassword
strEMail = Request("EMail")
strPassword = Request("Password")

Dim rsUsers
set rsUsers = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT * FROM User WHERE EMailAddress = '" & strEMail & "';"
rsUsers.Open strSQL, objConn
...

Please help me...this is very urgent to me.

 
Old August 7th, 2007, 07:06 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

User is a reserved Keyword; try this instead: SELECT * from [user]

================================================== =========
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
================================================== =========
Technical Editor for:
Professional Search Engine Optimization with ASP.NET

Professional IIS 7 and ASP.NET Integrated Programming

================================================== =========
 
Old August 9th, 2007, 01:51 AM
Authorized User
 
Join Date: Jun 2007
Posts: 87
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to ivanlaw Send a message via Yahoo to ivanlaw
Default

How to say it is a reserved keyword???And what does it using for???
I have see another program also write the coding like that,but it can run without error.Then it's reserved keyword is "Person".But I facing that kind of problems...why???

Thank you...
 
Old August 9th, 2007, 08:52 PM
Wrox Author
 
Join Date: Oct 2005
Posts: 4,104
Thanks: 1
Thanked 64 Times in 64 Posts
Send a message via AIM to dparsons
Default

Ok. In most database systems there are reserved keywords, just as there are in programming languages. (string, int, double, float, etc)

SQL is no different. In any event user, at least in SQL Server, is a reserved keyword so you can not directly reference your object. What I mean is that while you can name a table named 'user' you can not reference it such as:

SELECT * from user

because SQL thinks you are trying to do soemthing with the user type so, instead, you need to reference your table with [ ].

No, person is not a reserved keyword.

================================================== =========
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
================================================== =========
Technical Editor for:
Professional Search Engine Optimization with ASP.NET

Professional IIS 7 and ASP.NET Integrated Programming

================================================== =========
 
Old August 10th, 2007, 02:11 AM
Authorized User
 
Join Date: Jun 2007
Posts: 87
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to ivanlaw Send a message via Yahoo to ivanlaw
Default

Like that...
Ok, I understand.

Thank you very much






Similar Threads
Thread Thread Starter Forum Replies Last Post
Urgent :ASP code and Database ivanlaw Classic ASP Databases 14 September 21st, 2007 03:49 AM
Ms access database in asp-urgent plz netfresher Classic ASP Basics 1 June 30th, 2006 03:35 PM
asp errors with database recordset code dhx10000 Classic ASP Professional 0 June 27th, 2006 12:30 PM
asp.net code to insert image in to database madhusrp ASP.NET 1.0 and 1.1 Professional 2 March 16th, 2006 02:54 AM
Urgent: Pagination in ASP using arrays ,code reqd. jyoti_khera BOOK: Beginning ASP 3.0 1 October 19th, 2004 12:25 PM





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