473,387 Members | 1,463 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

How do I rename null values found in GROUP BY column?

jt
Here's a sample result from the following statement:

select dept, sum(cost)
from dept
group by dept;

dept sum(cost)
---- --------
null 1000
200 20
300 100

Is there a way I can rename the null value to some other value?
Jul 19 '05 #1
1 3810
look at nvl function

"jt" <ju**********@yahoo.com> wrote in message
news:6f**************************@posting.google.c om...
Here's a sample result from the following statement:

select dept, sum(cost)
from dept
group by dept;

dept sum(cost)
---- --------
null 1000
200 20
300 100

Is there a way I can rename the null value to some other value?

Jul 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Boefje | last post by:
Hello, I need to get all records from a table where a for a given playerid no field enddate exists with value NULL. table player_team: id, playerid, startdate, enddate 1, ...
26
by: Agoston Bejo | last post by:
I want to enforce such a constraint on a column that would ensure that the values be all unique, but this wouldn't apply to NULL values. (I.e. there may be more than one NULL value in the column.)...
3
by: iStrain | last post by:
Hiya. I'm _sure_ this is an FAQ, but Googling hasn't produced the answer in a way I can make sense out of. I know I should get this, but so far no way... I'm creating tables and doing queries in...
5
by: William Wisnieski | last post by:
Hello Everyone, I have a query by form with several list boxes. The user selects items from the list boxes and clicks a button that returns results in a datasheet subform. One of the list...
2
by: Stuart | last post by:
Hi there I have a stored procedure on my SQL database that retrieves a wide range of values from about 5 different tables. My end point is to calculate the cost against each line of retrieved...
3
by: deejayquai | last post by:
Hi I'm attempting to insert multiple records from one table into another based on rows selected in a multiple list box. This all seems to be working OK until I get to a field where the value is...
11
by: sqlservernewbie | last post by:
Hi Everyone, Here is a theoretical, and definition question for you. In databases, we have: Relation a table with columns and rows
2
by: andrey.vul | last post by:
code: #include <iostream> #include <vector> #include <stdexcept> #include <cstdio> #include <cstdlib> #include <cmath> #include <cstring>
1
by: jt | last post by:
Here's a sample result from the following statement: select dept, sum(cost) from dept group by dept; dept sum(cost) ---- -------- null 1000 200 20
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.