• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 161
  • Last Modified:

Page cannot be displayed when there is a record

Hi,

I have problem to retrieve the data when using the following SQL statement. I cannot figure out which part went wrong.

select distinct(b.USR_ACCT_NO) from docsadm.profile b where (b.USR_ACCT_NO is not NULL and b.USR_ACCT_NO<>'') and b.USR_CUST_STATUS='C' and b.USR_ACCT_NO not in (select a.accountcode from USR_EDMS_DOC_SCAN_STATUS a where a.accountcode=b.USR_ACCT_NO and a.status = 'C' and a.updateStatus = '0') and convert(varchar(10),b.CREATION_DATE,120)=(select convert(varchar(10),getDate(),120))

This statement been used in asp code. Please help.
0
ailin_dinsin
Asked:
ailin_dinsin
  • 4
  • 3
  • 2
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
does actually the SQL fail, or the code that displays the results?
0
 
bugs021997Commented:
as angelIII said you need to tell us if the SQL Query fails to retrieve data and if so what error it gives. If not then it must certainly throw certain error to get troubleshooting started...
0
 
ailin_dinsinAuthor Commented:
I placed my asp code in inetpub\wwwroot\<myfolder>. So, i test this code by run this URL http://<myServerName>/<myFolder>/aspCode. When there is no record then i won't see this "page cannot be displayed" problem. Else, i will see that problem. Under "The page cannot be displayed" heading, it read "There is a problem with the page you are trying to reach and it cannot be displayed". I supposed to get a record from database A and update a table in database B.  
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
bugs021997Commented:
Ok do one small favor....

If you are using INTERNET EXPLORER Then GOTO TOOLS(In top Menus) then go to INTERNET OPTIONS then ADVANCED(Tab) and then uncheck SHOW FRIENDSLY HTTP ERROR MESSAGES.

Now refresh the page and tell us the error.
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
so, you have an error somewhere in your code, which eventually ignores an error that could happen in some lines of the code.
do you know about ON ERROR RESUME NEXT in asp/vbscript? and displaying any error checking err.number and err.description?
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
also, call your code on the server for testing with localhost/myfolder/aspcode.asp
0
 
bugs021997Commented:
Also add this following line of code once you have done execution of the code using your recordset object

<%
If objRS.EOF Then

response.write "NO RECORD FOUND"

Else

response.write objRs(0)

End If

%>
0
 
ailin_dinsinAuthor Commented:
After applied solution ID: 19590202, below is the message returned:


Microsoft OLEDB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

/MyFolder/include/usr_integration.inc, line 132
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
that error message means that your connection string specifies a DSN name that is not present on the web server.
please check/fix that.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 4
  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now