You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: solution/0100-0199/0175.Combine Two Tables/README_EN.md
+4-4
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@
14
14
| lastName | varchar |
15
15
| firstName | varchar |
16
16
+-------------+---------+
17
-
personId is the primary key column for this table.
17
+
personId is the primary key (column with unique values) for this table.
18
18
This table contains information about the ID of some persons and their first and last names.
19
19
</pre>
20
20
@@ -31,17 +31,17 @@ This table contains information about the ID of some persons and their first and
31
31
| city | varchar |
32
32
| state | varchar |
33
33
+-------------+---------+
34
-
addressId is the primary key column for this table.
34
+
addressId is the primary key (column with unique values) for this table.
35
35
Each row of this table contains information about the city and state of one person with ID = PersonId.
36
36
</pre>
37
37
38
38
<p> </p>
39
39
40
-
<p>Write an SQL query to report the first name, last name, city, and state of each person in the <code>Person</code> table. If the address of a <code>personId</code> is not present in the <code>Address</code> table, report <code>null</code> instead.</p>
40
+
<p>Write a solution to report the first name, last name, city, and state of each person in the <code>Person</code> table. If the address of a <code>personId</code> is not present in the <code>Address</code> table, report <code>null</code> instead.</p>
41
41
42
42
<p>Return the result table in <strong>any order</strong>.</p>
43
43
44
-
<p>The query result format is in the following example.</p>
44
+
<p>The result format is in the following example.</p>
Copy file name to clipboardexpand all lines: solution/0100-0199/0185.Department Top Three Salaries/README_EN.md
+5-5
Original file line number
Diff line number
Diff line change
@@ -15,8 +15,8 @@
15
15
| salary | int |
16
16
| departmentId | int |
17
17
+--------------+---------+
18
-
id is the primary key column for this table.
19
-
departmentId is a foreign key of the ID from the <code>Department </code>table.
18
+
id is the primary key (column with unique values) for this table.
19
+
departmentId is a foreign key (reference column) of the ID from the <code>Department </code>table.
20
20
Each row of this table indicates the ID, name, and salary of an employee. It also contains the ID of their department.
21
21
</pre>
22
22
@@ -31,19 +31,19 @@ Each row of this table indicates the ID, name, and salary of an employee. It als
31
31
| id | int |
32
32
| name | varchar |
33
33
+-------------+---------+
34
-
id is the primary key column for this table.
34
+
id is the primary key (column with unique values) for this table.
35
35
Each row of this table indicates the ID of a department and its name.
36
36
</pre>
37
37
38
38
<p> </p>
39
39
40
40
<p>A company's executives are interested in seeing who earns the most money in each of the company's departments. A <strong>high earner</strong> in a department is an employee who has a salary in the <strong>top three unique</strong> salaries for that department.</p>
41
41
42
-
<p>Write an SQL query to find the employees who are <strong>high earners</strong> in each of the departments.</p>
42
+
<p>Write a solution to find the employees who are <strong>high earners</strong> in each of the departments.</p>
43
43
44
44
<p>Return the result table <strong>in any order</strong>.</p>
45
45
46
-
<p>The query result format is in the following example.</p>
46
+
<p>The result format is in the following example.</p>
Copy file name to clipboardexpand all lines: solution/0200-0299/0262.Trips and Users/README_EN.md
+6-6
Original file line number
Diff line number
Diff line change
@@ -17,9 +17,9 @@
17
17
| status | enum |
18
18
| request_at | date |
19
19
+-------------+----------+
20
-
id is the primary key for this table.
20
+
id is the primary key (column with unique values) for this table.
21
21
The table holds all taxi trips. Each trip has a unique id, while client_id and driver_id are foreign keys to the users_id at the Users table.
22
-
Status is an ENUM type of ('completed', 'cancelled_by_driver', 'cancelled_by_client').
22
+
Status is an ENUM (category) type of ('completed', 'cancelled_by_driver', 'cancelled_by_client').
23
23
</pre>
24
24
25
25
<p> </p>
@@ -34,20 +34,20 @@ Status is an ENUM type of ('completed', 'cancelled_by_driver', &
34
34
| banned | enum |
35
35
| role | enum |
36
36
+-------------+----------+
37
-
users_id is the primary key for this table.
37
+
users_id is the primary key (column with unique values) for this table.
38
38
The table holds all users. Each user has a unique users_id, and role is an ENUM type of ('client', 'driver', 'partner').
39
-
banned is an ENUM type of ('Yes', 'No').
39
+
banned is an ENUM (category) type of ('Yes', 'No').
40
40
</pre>
41
41
42
42
<p> </p>
43
43
44
44
<p>The <strong>cancellation rate</strong> is computed by dividing the number of canceled (by client or driver) requests with unbanned users by the total number of requests with unbanned users on that day.</p>
45
45
46
-
<p>Write a SQL query to find the <strong>cancellation rate</strong> of requests with unbanned users (<strong>both client and driver must not be banned</strong>) each day between <code>"2013-10-01"</code> and <code>"2013-10-03"</code>. Round <code>Cancellation Rate</code> to <strong>two decimal</strong> points.</p>
46
+
<p>Write a solution to find the <strong>cancellation rate</strong> of requests with unbanned users (<strong>both client and driver must not be banned</strong>) each day between <code>"2013-10-01"</code> and <code>"2013-10-03"</code>. Round <code>Cancellation Rate</code> to <strong>two decimal</strong> points.</p>
47
47
48
48
<p>Return the result table in <strong>any order</strong>.</p>
49
49
50
-
<p>The query result format is in the following example.</p>
50
+
<p>The result format is in the following example.</p>
0 commit comments