Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 SQL 2005/ASP Problems

Author  Topic 

jezza
Starting Member

12 Posts

Posted - 2007-05-14 : 05:15:28
Help!! I've got a really odd problem....

I'm developing a web application using classic ASP. The devlopment has been done using Win XP Pro and SQL 2005 Express. The website is working fine.

I have now moved the application to the test server - Windows Server 2003, SQL Server 2005.

Most of the application is working - except for pages where the data returned requires an SQL JOIN...

However, the same SQL query returns data when entered in SQL Server Managment Studio...

One of the queries is:
SELECT dbo.tblUsers.UserID, dbo.tblUsers.Email, dbo.tblUsers.Password, dbo.tblUsers.New_Password, dbo.tblUsers.Forename, dbo.tblUsers.Surname, dbo.tblUsers.JobTitle, dbo.tblUsers.BranchID, dbo.tblUsers.rAdmin, dbo.tblUsers.rDownloads, dbo.tblUsers.rVacancies, dbo.tblUsers.rVehicles, dbo.tblUsers.NoLogins, dbo.tblUsers.LastLogin, dbo.tblUsers.ConfirmKey
FROM dbo.tblUsers LEFT OUTER JOIN dbo.tblBranches ON dbo.tblUsers.BranchID = dbo.tblBranches.BranchID
ORDER BY dbo.tblUsers.Surname;

Does anyone have any ideas??

Thanks

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-05-14 : 05:27:21
It looks like a permission problem.


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

jezza
Starting Member

12 Posts

Posted - 2007-05-14 : 05:30:47
Peter

To try to eliminate this, I've tried using the 'sa' logon for the web pages. Same results....
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-05-14 : 05:46:00
The query is syntax correct.
What is the error you experience? Too many records? Too few records? No records at all?



Peter Larsson
Helsingborg, Sweden
Go to Top of Page

jezza
Starting Member

12 Posts

Posted - 2007-05-14 : 05:47:30
No records at all... but in SQL Server Managment Studio, I get the 2 expected records...
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-05-14 : 06:34:20
Are you connecting to the SAME database, from BOTH EM and ASP-application?
Have you changed the connection string for the ASP application? Have you put the NEW server in the connection string?


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

jezza
Starting Member

12 Posts

Posted - 2007-05-14 : 06:39:00
I'm definately connecting to the server (changing records is reflected in the application)...
Go to Top of Page

jezza
Starting Member

12 Posts

Posted - 2007-05-14 : 07:50:26
Peter - thanks for your assistance...

The problem was resolved when I used Microsoft Update to update SQL!!!

Go to Top of Page
   

- Advertisement -