Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| 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
  #1 (permalink)  
Old August 8th, 2006, 08:49 AM
Registered User
Points: 1,897, Level: 17
Points: 1,897, Level: 17 Points: 1,897, Level: 17 Points: 1,897, Level: 17
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2005
Location: Mumbai, Maharastra, India.
Posts: 352
Thanks: 14
Thanked 0 Times in 0 Posts
Send a message via Yahoo to rupen
Default Enable to run query in ASP...

Runs fine in MS Access directly ,..but if i execute it from ASP it gives error as

Error Type:
(0x80004005)
Unspecified error

SELECT tm.TeamName,wt.WTName,ts.Projid,ts.task,task.descn ,at.ActName,ts.workdate,ts.time_hr,ts.time_mi FROM timesheet ts,WorkType wt,ActivityMaster at,TeamMaster tm,timeestmaster task WHERE ts.teamid = tm.teamid and ts.wtid = wt.wtid and ts.actid = at.actid and ts.projid = task.proid and ts.task = task.task and ts.empid = 13979 and ts.workdate between #1-Aug-2006# and #7-Aug-2006#
I have heard if we use reserved words it will generate such error but here i can't see any such errors...any idea??

Rupen Anjaria.:)
------------------
We CAN'T avoid problems, but can solve it.
Reply With Quote
  #2 (permalink)  
Old August 8th, 2006, 09:04 AM
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

'at' is a reserved Keyword; also, that is not a very optimized query, i'd suggest using JOINS as opposed to just selecting from those tables.

"The one language all programmers understand is profanity."
Reply With Quote
  #3 (permalink)  
Old August 8th, 2006, 09:45 AM
Registered User
Points: 1,897, Level: 17
Points: 1,897, Level: 17 Points: 1,897, Level: 17 Points: 1,897, Level: 17
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2005
Location: Mumbai, Maharastra, India.
Posts: 352
Thanks: 14
Thanked 0 Times in 0 Posts
Send a message via Yahoo to rupen
Default

Thanks...it is working now...
further there r around 5 tables i have to join and i dont know how to do this by JOINS...can u suggest...Thanks in advance..


Rupen Anjaria.:)
------------------
We CAN'T avoid problems, but can solve it.
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
How can I run or not run Google AD in my ASP.NET w mycwcgr ASP.NET 2.0 Professional 0 November 5th, 2007 07:18 AM
Enable Update and Enable Delete check boxes don't mihabib ASP.NET 2.0 Basics 2 December 7th, 2006 11:44 AM
Will this query run perfectly??? ... rupen Access 2 August 1st, 2006 06:11 AM
CheckBox enable in asp 2.0 with javascript bbsdev Javascript How-To 0 July 18th, 2006 12:27 PM
run total in query stoneman Access 1 December 23rd, 2003 04:43 AM



All times are GMT -4. The time now is 04:49 AM.


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