Error 80040e10...

Last Post 12 Apr 2005 03:23 AM by mtmeru. 0 Replies.
AddThis - Bookmarking and Sharing Button Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
mtmeru
New Member
New Member

--
12 Apr 2005 03:23 AM
Hi , I'm getting the useful "I could not access your data for some reason.", error 80040e10.

I'm trying to access data using an ASP page and a stored procedure on our development site, but I cannot figure out why this error occurs. Especially as the live site works fine. And it seems specific to this one page. I've copied the sproc and the ASP page code below. I realise much of it won't be relevant, but if anyone has any ideas I'd really appreciate it!

The sproc is:

CREATE PROCEDURE spRegion_Search
@vRegion int,
@vLanguage varchar(50),
@vEndorsement varchar(50),
@vEndorsement2 varchar(50),
@vEndorsement3 varchar(50),
@vTopic varchar(50),
@vTopic2 varchar(50),
@vLocation varchar(50),
@vDriver varchar(3),
@vParentRegion int
AS

-- add guide_membership to the select statement - 23/12/04


IF @vRegion IS NULL SET @vRegion = '
IF @vLanguage IS NULL SET @vLanguage = '
IF @vEndorsement IS NULL SET @vEndorsement = '
IF @vEndorsement2 IS NULL SET @vEndorsement2 = '
IF @vEndorsement3 IS NULL SET @vEndorsement3 = '
IF @vTopic IS NULL SET @vTopic = '
IF @vTopic2 IS NULL SET @vTopic2 = '
IF @vLocation IS NULL SET @vLocation = '
IF @vParentRegion IS NULL SET @vParentRegion = '

IF @vDriver = 'YES'

BEGIN
SELECT UPPER(guide_surname) + ', ' + guide_forename AS Guide,
tbl_guides.guide_code AS Code,
RAND(guide_record * guide_code + DATEPART(ms, GETDATE())) AS RecID,
guide_membership AS MembershipCode

FROM tbl_guides
JOIN tbl_registrations ON tbl_guides.guide_code = tbl_registrations.registration_guide
JOIN codetbl_touristbrd ON tbl_registrations.registration_touristbrd = codetbl_touristbrd.code_touristbrd
LEFT JOIN tbl_languages
LEFT JOIN codetbl_language ON language_code = code_language ON guide_code = language_guide
LEFT JOIN tbl_endorsements
LEFT JOIN codetbl_endorsements ON endorsement_code = code_endorsement ON guide_code = endorsement_guide
LEFT JOIN tbl_speciality
LEFT JOIN codetbl_speciality ON speciality_code = code_speciality ON guide_code = speciality_guide
LEFT JOIN tbl_drivers ON driver_code = guide_code
LEFT JOIN tbl_endorsements a
LEFT JOIN codetbl_endorsements b ON a.endorsement_code = b.code_endorsement ON guide_code = a.endorsement_guide
LEFT JOIN tbl_endorsements c
LEFT JOIN codetbl_endorsements d ON c.endorsement_code = d.code_endorsement ON guide_code = c.endorsement_guide
LEFT JOIN tbl_speciality e
LEFT JOIN codetbl_speciality f ON e.speciality_code = f.code_speciality ON guide_code = e.speciality_guide
LEFT JOIN tbl_mf_location ON mf_location_guide = guide_code

WHERE (@vRegion = ' OR codetbl_touristbrd.code_touristbrd = @vRegion)
AND (@vLanguage = ' OR codetbl_language.code_description = @vLanguage)
AND (@vEndorsement = ' OR codetbl_endorsements.code_description = @vEndorsement)
AND (@vTopic = ' OR codetbl_speciality.code_description = @vTopic)
AND (@vLocation = ' OR tbl_mf_location.mf_location_desc = @vLocation)
AND (@vEndorsement2 = ' OR b.code_description = @vEndorsement2)
AND (@vEndorsement3 = ' OR d.code_description = @vEndorsement3)
AND (@vTopic2 = ' OR f.code_description = @vTopic2)
AND EXISTS (SELECT * FROM tbl_drivers WHERE driver_guide = guide_code)
AND (@vParentRegion = ' OR tbl_mf_location.mf_location_parent_region = @vParentRegion)
GROUP BY guide_code, guide_surname, guide_forename, guide_registered, guide_record,guide_membership
HAVING tbl_guides.guide_registered = 1

ORDER BY RecID

END

ELSE

BEGIN
SELECT UPPER(guide_surname) + ', ' + guide_forename AS Guide,
tbl_guides.guide_code AS Code,
RAND(guide_record * guide_code + DATEPART(ms, GETDATE())) AS RecID,
guide_membership AS MembershipCode

FROM tbl_guides
JOIN tbl_registrations ON tbl_guides.guide_code = tbl_registrations.registration_guide
JOIN codetbl
You are not authorized to post a reply.

Acceptable Use Policy