Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
SQL_QUERIES__1_.pdf
Search
Manisha Rai
March 28, 2022
0
9
SQL_QUERIES__1_.pdf
Manisha Rai
March 28, 2022
Tweet
Share
More Decks by Manisha Rai
See All by Manisha Rai
MANISHA
manisha27
0
23
ANALYTICS_IN_TELECOM_INDUSTRY.pdf
manisha27
0
56
Featured
See All Featured
HDC tutorial
michielstock
1
290
What the history of the web can teach us about the future of AI
inesmontani
PRO
0
390
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.1k
Principles of Awesome APIs and How to Build Them.
keavy
127
17k
A Tale of Four Properties
chriscoyier
162
23k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
9
1k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
200
Typedesign – Prime Four
hannesfritz
42
2.9k
SERP Conf. Vienna - Web Accessibility: Optimizing for Inclusivity and SEO
sarafernandez
1
1.3k
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
80
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
0
120
Stop Working from a Prison Cell
hatefulcrawdad
273
21k
Transcript
SQL QUERIES 1)select top 10* from [DataDB].[dbo].['sample-csv-file-for-testing$'] ORDER BY[ Gross
Sales ] DESC 2) select top 3 *from [DataDB].[ dbo].['sample-csv-file-for-testing$'] 3) select top 5* from [DataDB].[dbo].['sample-csv-file-for-testing$']ORDER BY [ Profit ] DESC;
4) select Country, SUM([ Sales ]) TOTAL_Sales From [DataDB].[dbo].['sample-csv-file-for-testing$'] GROUP
BY Country
5) select Country, SUM([ Profit ]) TOTAL_Profit from [DataDB].[dbo].['sample-csv-file-for-testing$'] GROUP
BY Country
6) select Segment, SUM([ Sales ]) TOTAL_Sales from [DataDB].[dbo].['sample-csv-file-for-testing$'] GROUP
BY Segment ORDER BY TOTAL_Sales DESC; 7) select Segment, SUM([ Sales ]) TOTAL_Sales from [DataDB].[dbo].['sample-csv-file-for-testing$'] GROUP BY Segment having SUM([ Sales ])>2000000 ORDER BY TOTAL_Sales DESC;
8)select * from dbo.['Table 2$'] LEFT JOIN dbo.['Table 1$']on dbo.['Table
2$'].[ Sales ]=dbo.['Table 1$'].[ Sales ] 9) select*from dbo.['Table 2$']RIGHT JOIN dbo.['Table 1$']on dbo.['Table 2$'].Country=dbo.['Table 1$'].Country
10)select *from dbo.['Table 2$']FULL OUTER JOIN dbo.['Table 1$']on dbo.['Table 2$'].[Units
Sold]=dbo.['Table 1$'].[Units Sold]
None