If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > Return data type of aggregate functions

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-22-10, 12:45
MikeBigg MikeBigg is offline
Registered User
 
Join Date: Jan 2010
Posts: 2
Return data type of aggregate functions

Hi!

I'm working on converting a Windows application so it can be used with SQL-Server and Informix.

In SQL-Server the return data type of the SUM() function is the same as the data type of the column being summed. So, if I sum an integer field I get an integer data type.

It appears, in Informix, that no matter what I SUM(), I get a float data type.

This matters in my application as the data type must be know ahead of time.

My questions are:

1) Am I right about the returned data types?
2) Is there a setting that could change this?
3) What other aggregate functions does this apply to?

Thank you in advance for your help.

Kind regards,

Mike
Reply With Quote
  #2 (permalink)  
Old 01-27-10, 08:18
MikeBigg MikeBigg is offline
Registered User
 
Join Date: Jan 2010
Posts: 2
Anyone know anything about this?

Thanks,

Mike
Reply With Quote
Reply

Tags
aggreagte sum data_type

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On