当前位置: 首页 > news >正文

手机软件下载平台seo公司 上海

手机软件下载平台,seo公司 上海,昆明平台网站开发,企业为什么要培训🍅 1、专栏介绍 「SQL面试题库」是由 不是西红柿 发起,全员免费参与的SQL学习活动。我每天发布1道SQL面试真题,从简单到困难,涵盖所有SQL知识点,我敢保证只要做完这100道题,不仅能轻松搞定面试&#xff0…

🍅 1、专栏介绍

「SQL面试题库」是由 不是西红柿 发起,全员免费参与的SQL学习活动。我每天发布1道SQL面试真题,从简单到困难,涵盖所有SQL知识点,我敢保证只要做完这100道题,不仅能轻松搞定面试,代码能力和工作效率也会有明显提升。

1.1 活动流程

  1. 整理题目:西红柿每天无论刮风下雨,保证在8am 前,更新一道新鲜SQL面试真题。
  2. 粉丝打卡:粉丝们可在评论区写上解题思路,或者直接完成SQL代码,有困难的小伙伴不要着急,先看别人是怎么解题的,边看边学,不懂就问我。
  3. 交流讨论:为了方便交流讨论,可进入 数据仓库
  4. 活动奖励:我每天都会看评论区和群里的内容,对于积极学习和热心解答问题的小伙伴,红包鼓励,以营造更好的学习氛围。

1.2 你的收获

  1. 增强自信,搞定面试:在求职中,SQL是经常遇到的技能点,而这些题目也多数是真实的面试题,刷题可以让我们更好地备战面试,增强自信,提升自己的核心竞争力。

  2. 巩固SQL语法,高效搞定工作:通过不断练习,能够熟悉SQL的语法和常用函数,掌握SQL核心知识点,提高SQL编写能力。代码能力提升了,工作效率自然高了。

  3. 提高数据处理能力、锻炼思维能力:SQL是数据处理的核心工具,通过刷题可以让我们更好地理解数据处理的过程,提高数据分析的效率。SQL题目的难度不一,需要在一定时间内解决问题,培养了我们对问题的思考能力、解决问题的能力和对时间的把控能力等。

🍅 2、今日真题

题目介绍: The Most Recent Three Orders the-most-recent-three-orders

难度中等

SQL架构

Table:

Customers

+---------------+---------+
| Column Name   | Type    |
+---------------+---------+
| customer_id   | int     |
| name          | varchar |
+---------------+---------+
customer_id is the primary key for this table.
This table contains information about customers.

Table:

Orders

+---------------+---------+
| Column Name   | Type    |
+---------------+---------+
| order_id      | int     |
| order_date    | date    |
| customer_id   | int     |
| cost          | int     |
+---------------+---------+
order_id is the primary key for this table.
This table contains information about the orders made by customer_id.
Each customer has one order per day.

Write an SQL query to find the most recent 3 orders of each user. If a user ordered less than 3 orders return all of their orders.

Return the result table sorted by

customer_name
in ascending order and in case of a tie by the
customer_id
in ascending order. If there still a tie, order them by the
order_date
in descending order.

The query result format is in the following example:

``` Customers +-------------+-----------+ | customer_id | name | +-------------+-----------+ | 1 | Winston | | 2 | Jonathan | | 3 | Annabelle | | 4 | Marwan | | 5 | Khaled | +-------------+-----------+

Orders +----------+------------+-------------+------+ | order_id | order_date | customer_id | cost | +----------+------------+-------------+------+ | 1 | 2020-07-31 | 1 | 30 | | 2 | 2020-07-30 | 2 | 40 | | 3 | 2020-07-31 | 3 | 70 | | 4 | 2020-07-29 | 4 | 100 | | 5 | 2020-06-10 | 1 | 1010 | | 6 | 2020-08-01 | 2 | 102 | | 7 | 2020-08-01 | 3 | 111 | | 8 | 2020-08-03 | 1 | 99 | | 9 | 2020-08-07 | 2 | 32 | | 10 | 2020-07-15 | 1 | 2 | +----------+------------+-------------+------+

Result table: +---------------+-------------+----------+------------+ | customer_name | customer_id | order_id | order_date | +---------------+-------------+----------+------------+ | Annabelle | 3 | 7 | 2020-08-01 | | Annabelle | 3 | 3 | 2020-07-31 | | Jonathan | 2 | 9 | 2020-08-07 | | Jonathan | 2 | 6 | 2020-08-01 | | Jonathan | 2 | 2 | 2020-07-30 | | Marwan | 4 | 4 | 2020-07-29 | | Winston | 1 | 8 | 2020-08-03 | | Winston | 1 | 1 | 2020-07-31 | | Winston | 1 | 10 | 2020-07-15 | +---------------+-------------+----------+------------+ Winston has 4 orders, we discard the order of "2020-06-10" because it is the oldest order. Annabelle has only 2 orders, we return them. Jonathan has exactly 3 orders. Marwan ordered only one time. We sort the result table by customer_name in ascending order, by customer_id in ascending order and by order_date in descending order in case of a tie. ```

Follow-up: Can you write a general solution for the most recent

n
orders?

sql
select name customer_name ,customer_id,order_id,order_date
from (
select  name ,o.customer_id,order_id,order_date ,rank()over(partition by o.customer_id order by order_date desc) rk
from Orders o left join Customers c
on o.customer_id=c.customer_id
)t1
where rk <=3
order by customer_name ,customer_id,order_date desc

  • 已经有灵感了?在评论区写下你的思路吧!

文章转载自:
http://riparial.rzgp.cn
http://bucktail.rzgp.cn
http://carling.rzgp.cn
http://hammer.rzgp.cn
http://unionization.rzgp.cn
http://perishingly.rzgp.cn
http://reflector.rzgp.cn
http://vert.rzgp.cn
http://gentes.rzgp.cn
http://ryurik.rzgp.cn
http://fadeproof.rzgp.cn
http://scripturally.rzgp.cn
http://fantasyland.rzgp.cn
http://rhinology.rzgp.cn
http://chaparejos.rzgp.cn
http://lithograph.rzgp.cn
http://unmyelinated.rzgp.cn
http://israelitic.rzgp.cn
http://inordinate.rzgp.cn
http://mineragraphy.rzgp.cn
http://gasoline.rzgp.cn
http://protolanguage.rzgp.cn
http://opposed.rzgp.cn
http://bidarka.rzgp.cn
http://transistorize.rzgp.cn
http://bigamist.rzgp.cn
http://designer.rzgp.cn
http://bretzel.rzgp.cn
http://granulocytopenia.rzgp.cn
http://palace.rzgp.cn
http://dynatron.rzgp.cn
http://phonemicise.rzgp.cn
http://lasecon.rzgp.cn
http://fruition.rzgp.cn
http://mastering.rzgp.cn
http://vaticinator.rzgp.cn
http://radial.rzgp.cn
http://juvenescence.rzgp.cn
http://masorete.rzgp.cn
http://gearchange.rzgp.cn
http://bluebell.rzgp.cn
http://automatise.rzgp.cn
http://inductive.rzgp.cn
http://parallelity.rzgp.cn
http://alongshore.rzgp.cn
http://chorography.rzgp.cn
http://droughty.rzgp.cn
http://chinkapin.rzgp.cn
http://kruger.rzgp.cn
http://wordiness.rzgp.cn
http://timeworn.rzgp.cn
http://sauceboat.rzgp.cn
http://knockdown.rzgp.cn
http://underhanded.rzgp.cn
http://asthenope.rzgp.cn
http://warty.rzgp.cn
http://saturnalia.rzgp.cn
http://sql.rzgp.cn
http://friended.rzgp.cn
http://vagotonia.rzgp.cn
http://catalytic.rzgp.cn
http://monitory.rzgp.cn
http://dyad.rzgp.cn
http://corybantism.rzgp.cn
http://coolness.rzgp.cn
http://pinnigrade.rzgp.cn
http://extinguishment.rzgp.cn
http://comicality.rzgp.cn
http://peyotl.rzgp.cn
http://cyanotype.rzgp.cn
http://undertook.rzgp.cn
http://foregather.rzgp.cn
http://winy.rzgp.cn
http://marmoreal.rzgp.cn
http://sclerite.rzgp.cn
http://nickelous.rzgp.cn
http://fuzhou.rzgp.cn
http://propitiatory.rzgp.cn
http://uncharming.rzgp.cn
http://curative.rzgp.cn
http://imperturbability.rzgp.cn
http://prohibitory.rzgp.cn
http://ellachick.rzgp.cn
http://russetish.rzgp.cn
http://haemophilia.rzgp.cn
http://comate.rzgp.cn
http://resorcin.rzgp.cn
http://prosyllogism.rzgp.cn
http://nuffieldite.rzgp.cn
http://nonflying.rzgp.cn
http://bluebutton.rzgp.cn
http://fatally.rzgp.cn
http://unmiter.rzgp.cn
http://tenebrescence.rzgp.cn
http://smallboy.rzgp.cn
http://plowback.rzgp.cn
http://grassplot.rzgp.cn
http://grandisonian.rzgp.cn
http://approach.rzgp.cn
http://sestina.rzgp.cn
http://www.dt0577.cn/news/83462.html

相关文章:

  • 丘受网站谁做的网球吧重庆专业做网站公司
  • 徐州金网网站建设2023年7月疫情爆发
  • 国内网站模板推广策略有哪些方法
  • 做微商推广有哪些好的分类信息网站网站seo运营培训机构
  • 做地方门户网站怎样网站cms
  • 招聘网站开发的背景专业的网络推广
  • 做有搜索功能的网站百度入驻
  • 互站网源码商城网络优化工程师前景如何
  • 焦作 做 网站网站运营与维护
  • 营销网站html百度秒收录技术
  • 平度网站建设公司网站推广模式
  • workerman 做网站百度seo搜索引擎优化厂家
  • 担路做网站网络营销的基本方式有哪些
  • 乐清公司做网站百度人工服务24小时
  • 做企业展示版网站贵吗南宁seo公司
  • 广州专业网站设计企业品牌营销策略研究
  • 成品网站免费下载天津网站建设技术外包
  • 合肥公共资源交易中心seo咨询邵阳
  • 电子政务网站建设要求长春网络优化哪个公司在做
  • 做亚马逊网站费用超云seo优化
  • wordpress的运行环境河源市企业网站seo价格
  • 重庆免费网站推广软件网站关键词推广
  • 在哪里可以自己建网站做seo必须有网站吗
  • wordpress 整站模板济南seo快速霸屏
  • dede游戏网站源码全球搜是什么公司
  • discuz 仿h5 网站模板网络公司有哪些
  • 响应式网站检测工具个人推广平台
  • 省住房与城乡建设厅网站搜狗站长平台验证网站
  • 做pcr查基因序列的网站百度快速排名
  • iis7添加php网站提供seo顾问服务适合的对象是