Interview Questions   Tutorials   Discussions   Programs   

Teradata - How to handle nulls in Teradata? How many columns can be there in a table? How to find average sale with out using average function?




688
views
asked mar September 20, 2014 06:38 AM  

How to handle nulls in Teradata? How many columns can be there in a table? How to find average sale with out using average function?


           

1 Answers



 
answered By vishnoiprem   0  
1. Use coalesce(column1,column2) or case when column1 is null..end or zeroifnull(column1) to handle nulls.
2. In TD 14.0 there can be 2048 columns per table.
3. Sum/count gives you the average of the field.
   select sum(sal)/count(sal) as avgsal from table_name
flag   
   add comment

Your answer

Join with account you already have

FF

Preview


Ready to start your tutorial with us? That's great! Send us an email and we will get back to you as soon as possible!

Alert