Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Scenario is like this:
Name Sal
A 10;
B 20;
C 30;

Then Output should be
Name Sal
A 10;
B 20;
C 30;
Total 60;

Use SQL For this scenario

Answer Posted / situ

first create a table emp4 using the above data then execute the below query to find that output
select case when grouping(name)=1 then 'Total'else name end as name,sum(sal) as sal from emp4 group by rollup(name);

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Mention a few design and development best practices for informatica?

992


What is a grid in Informatica?

1064


How to load the data from a flat file into the target where the source flat file name changes daily?

1050


What are the restrictions of union transformation?

1037


What is the need of etl tools?

1112


Write the advantages of partitioning a session?

1270


i have a data in my source as a flat files what test i have to perform the next step can any body help to me

2116


What is update strategy transform?

1096


To import the flat file definition into the designer where should the flat file be placed?

1057


Differentiate between a database and data warehouse?

1141


what is the size of your data warehousing?

2091


How do you migrate data from one environment to another?

1091


i had a source containing business,sales,details column and i have to load it to a target but i have some bad records in it , but i have to load 70% of business records and 50% of sales and 95% of details records excluding bad records to achieve this what should be done and what all logic and tx should be used can anyone help? thanks in advance

2123


what kind of issue you will get in environment? (we ll call help desk to raise ticket rite?

2049


what is granularity,what type of granularity we will take in fact tables either lowlevel or highlevel,if two tables having same granularity that is posiable or not

2317