CodeCharge Studio
search Register Login  

Visual PHP Web Development

Visually Create Internationalized Web Applications, Web Reports, Calendars, and more.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> ASP

 SQL Error in Code Charge not in SQL Server

Print topic Send  topic

Author Message
mljonzs

Posts: 124
Posted: 09/22/2006, 12:41 PM

Can someone tell me how to get rid of the following??:

When data not found I get

Error: Warning: Null value is eliminated by an aggregate or other SET operation. (Microsoft OLE DB Provider for SQL Server)

When I run the same SQL statement directly in SQL Server's Query Analyzer tool I do not get any errors so I'm struggling trying to figure out what to adjust in my CodeCharge file to get rid of the error message. The table in use here is a view that joins data from three tables so I'm wondering if that is part of the problem.

I've tried using the IsNull function in the Datasource for all values but that doesn't work either. Can someone offer some insight? I can provide more information if needed. Oddly enough too, this error doesn't come up EVERY time no records are found and I can't pinpoint any one thing that occurs when it does come up??

HELP!! :-/
_________________
What does not begin WITH God, will end in failure!
View profile  Send private message
mljonzs

Posts: 124
Posted: 09/22/2006, 1:55 PM

Hello - Once again, after I posted my problem, I found the solution.

In case anyone is interested in the future, the problem was an SQL Server issue after all. Due to the way my view is built, SQL Server may display the warning message when ANSI_WARNINGS is set to ON. The solution was to turn it off.

I didn't want to change our SQL Server settings so I did the following in my Code Charge application and the warning message has gone away.

In the BeforeBuildSelect of my grid, I added the following code:
SList.DataSource.SQL = "SET ANSI_WARNINGS OFF" & SList.DataSource.SQL

Then, in the BeforeExecuteSelect of my grid I added the following code:
SList.DataSource.SQL = SList.DataSource.SQL & " SET ANSI_WARNINGS ON"

Now my codecharge pages display normally whether the searches find data or not.
_________________
What does not begin WITH God, will end in failure!
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.