代码编织梦想

sqlzoo刷题记录-爱代码爱编程

列出1962年首影的電影, [顯示 id, title]。 SELECT id,title FROM movie WHERE yr=1962; 電影大國民 ‘Citizen Kane’ 的首影年份。 selec

sqlzoo刷题记录-爱代码爱编程

列出歐州每國家的人均GDP,當中人均GDP要高於英國’United Kingdom’的數值。 select name from world where GDP/population> (select G

sqlzoo练习笔记-爱代码爱编程

SQLZOO练习笔记-Select from World Tutorial 小白头一次在CSDN上发博客…这个系列主要是想记录一下自己的DQLZOO练习,也希望大家不吝赐教~哪里写错了或者有更好的方法还请多多指教啦。?

sqlzoo-爱代码爱编程

SELECT within SELECT 1.哪些國家的GDP比Europe歐洲的全部國家都要高呢? [只需列出 name 。] (有些國家的記錄中,GDP是NULL,沒有填入資料的。) select name from

sqlzoo练习笔记-爱代码爱编程

SELECT SUM(population) FROM world select distinct continent from world select sum(gdp) from

sqlzoo练习笔记-爱代码爱编程

SELECT yr, subject, winner FROM nobel WHERE yr = 1950 SELECT winner FROM nobel WHERE yr = 1962 AND

sqlzoo (7)-爱代码爱编程

SQLZOO (7) The JOIN operation 1.显示德国队打进的所有进球的比赛号和球员名称。 SELECT matchid,player FROM goal WHERE teamid = 'GE

sqlzoo练习题(6)-爱代码爱编程

SQLZOO练习题(6) 1.显示世界人口总数。 SELECT SUM(population) FROM world 2.列出所有大洲——每个大洲只列出一次。 select distinct(contine

sqlzoo练习题(5)-爱代码爱编程

Sqlzoo练习题(5) 1.列出每个人口比“俄罗斯”多的国家的名字。 SELECT name FROM world WHERE population > (SELECT population FR

SQLZOO_The JOIN operation(sql server)-爱代码爱编程

1、Modify it to show the matchid and player name for all goals scored by Germany. To identify German players, check for: teamid = ‘GER’ select matchid,player from goal where team

SQLZOO_SUM and COUNT(sql server)-爱代码爱编程

1、Show the total population of the world. select sum(population) from world 2、List all the continents - just once each. select distinct continent from world 3、Give the tota

sqlzoo-more join-爱代码爱编程

1-11题参考链接 10.列出演員夏里遜福 ‘Harrison Ford’ 曾演出的電影,但他不是第1主角。 SELECT title FROM casting a JOIN movie b ON(a.movieid=b.id) JOIN actor c ON(a.actorid=c.id)

SQLZOO刷题记录5——SUM and COUNT-爱代码爱编程

World Country Profile: Aggregate functions(世界国家概况:综合功能) 题目7:Counting big countries in each continent  For each continent show the continent and number of countries with popu

SQLZOO_Window LAG-爱代码爱编程

继上篇博客,关于窗口函数 1、Introducing the covid table Modify the query to show data from Spain SELECT name ,DAY(whn) ,confirmed ,deaths ,recovered FROM covid WHERE name = 'spain' AND MONT

SQLZOO_Window functions-爱代码爱编程

       感觉窗口函数是sqlzoo里比较难的一块,于是写下这篇文章,共同学习。 这块的题目不在sqlzoo主页的左侧栏目,而是在下方,我也是刷完左侧题目后面才发现的。由于sql代码很容易懂,就不做过多解释了,详见代码。 1、Warming up Show the lastName, party and votes for the con

SQLZOO刷题记录4——SELECT within SELECT Tutorial-爱代码爱编程

本章节主要训练SELECT语句的嵌套使用。 题目3:Neighbours of Argentina and Australia List the name and continent of countries in the continents containing either Argentina or Australia. Order by

SQLZOO刷题记录3——SELECT from Nobel Tutorial-爱代码爱编程

 This tutorial is concerned with a table of Nobel prize winners:(本节关注诺贝尔奖获奖者信息) nobel(yr, subject, winner)   题目12: Apostrophe Find all details of the prize won by EUGENE O'

SQLZOO刷题记录2——SELECT from WORLD Tutorial-爱代码爱编程

题目5:France, Germany, Italy Show the name and population for France, Germany, Italy 解题5: SELECT name, population FROM world WHERE name IN ('France', 'Germany', 'Italy')

SQLZOO刷题记录1——SELECT names-爱代码爱编程

SELECT names This tutorial uses the LIKE operator to check names. We will be using the SELECT command on the table world: (本节要求在上表world中,使用like操作符进行一些操作。) 题目13: Find the ca

SQLZOO-DAY5表连接3-爱代码爱编程

1. List the films where the yr is 1962 [Show id, title] SELECT id, title FROM movie WHERE yr=1962 2. Give year of 'Citizen Kane'. SELECT yr FROM movie WHERE title = 'Citi