Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions Data Science Salary Query.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/* SELECT DATA WHERE SALARY > 100000 */
SELECT * FROM new_schema.ds_salaries
WHERE salary > 100000;

/* SELECT DATA WHERE SALARY > 100000, Company location in US, Order the salary from the largest */
SELECT MyUnknownColumn, job_title, salary_in_usd, company_location FROM new_schema.ds_salaries
WHERE salary_in_usd > 100000
AND company_location = 'US'
ORDER BY salary_in_usd DESC;

/* Count the average Average Salary in USD group by job title and sort from the largest */
SELECT AVG(salary_in_usd) AS AVERAGE_SALARY_IN_USD, job_title FROM new_schema.ds_salaries
GROUP BY job_title
ORDER BY AVERAGE_SALARY_IN_USD DESC;
Loading