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...

What is unpivot?

Answer Posted / Chandrakant Bharti

UNPIVOT is a SQL operator used to transpose rows into columns. It allows you to convert rows with multiple columns into a single row with multiple identical column names, which can be useful for analyzing data from various dimensions. For example, the following query uses UNPIVOT to transform a table with two columns (Product and Q1-2020, Q2-2020) containing sales data for each quarter:nn SELECT * FROM SalesDatan UNPIVOT(n SalesAmount FOR Quarter IN (Q1-2020 AS Q1,n Q2-2020 AS Q2)n )

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a scheduled job or what is a scheduled task?

1031


You have a stored procedure, which execute a lengthy batch job. This stored procedure is called from a trigger you do not want to slow the data entry process you do not want trigger to wait for this batch job to finish before it completes itself what you can do to speed up the process?

1207


What are different types of constraints?

995


When should you use an instead of trigger?

1042


How can I check that whether automatic statistic update is enabled or not?

1108


How to enter binary string literals in ms sql server?

1235


Why we use the openxml clause?

1069


How do I start sql server 2017?

1011


Can one drop a column from a table?

1081


What are wait types?

1239


Can sql servers link to other servers like oracle?

910


What is the primary use of the model database?

1144


How can we solve concurrency problems?

1120


what is spatial nonclustered index

1054


Why and when do stored procedure recompile?

1052