baxtalo
asked on
Teradata error on Virtual Machine
I moved my web site to a different server. The code attached worked fine on the old server, but on the new one it gives me an error, in spite of the fact that all necessary software is installed on the new server (ODBC Driver for Teradata, etc.)
With this code I capture the login ID, then display the info of the logged in person.
Can anyone please let me know why it's not working?
Thank you very much.
With this code I capture the login ID, then display the info of the logged in person.
Can anyone please let me know why it's not working?
Thank you very much.
<%
If Request.ServerVariables("LOGON_USER") = "" Then
Response.Status = "401 Access Denied"
Response.End
End If
%>
<%
set conn = Server.CreateObject("ADODB.Connection")
conn.Open "DSN=Teradata;DRIVER={Teradata};UID=MyUID;PWD=MyPWD;Persist Security Info=True;"
set rs = Server.CreateObject("ADODB.recordset")
Dim UserID
UserID = Request.ServerVariables("LOGON_USER")
'if always 3 character User ID with '\'
UserID = Mid(UserID, 5)
rs.Open "SELECT Emp_Id, Last_Name, First_Name, Pref_First_Name FROM EmpDirectory WHERE Emp_Id = '" & UserID & "'", conn
do until rs.EOF
Emp_Id = rs("Emp_Id")
First_Name = rs("First_Name")
Last_Name = rs("Last_Name")
Pref_First_Name = rs("Pref_First_Name")
rs.MoveNext
loop
rs.close
conn.close
%>
Line error and error message?
ASKER
This is all I get, how can I make the browser display the actual line number? I was trying everything, I'm clueless.
The website cannot display the page
HTTP 500
Most likely causes:
• The website is under maintenance.
• The website has a programming error.
What you can try:
Refresh the page.
Go back to the previous page.
More information
This error (HTTP 500 Internal Server Error) means that the website you are visiting had a server problem which prevented the webpage from displaying.
For more information about HTTP errors, see Help.
The website cannot display the page
HTTP 500
Most likely causes:
• The website is under maintenance.
• The website has a programming error.
What you can try:
Refresh the page.
Go back to the previous page.
More information
This error (HTTP 500 Internal Server Error) means that the website you are visiting had a server problem which prevented the webpage from displaying.
For more information about HTTP errors, see Help.
If you're using IE try disabling 'show frioendly http errors' from Internet Options / Advanced
Also maybe you can try with Firefox to see if you get the same message
Also maybe you can try with Firefox to see if you get the same message
ASKER
Thanks, it worked. Now it's showing the line number and the error message is this:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/index.asp, line 9
But I know for sure the ODBC driver is installed. They even sent me a screenshot as a proof.
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/index.asp, line 9
But I know for sure the ODBC driver is installed. They even sent me a screenshot as a proof.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
I don't have access to the control panel on the server, but I'll ask the administrator. Do I need to give them any specific information about my page? Do they need to see its source code?
Thank you very much for your help.
Thank you very much for your help.
ASKER
Thank you very much.
you're welcome