Skip to content

Commit 833e355

Browse files
committed
remove images
1 parent 4f71d94 commit 833e355

File tree

9 files changed

+14
-77389
lines changed

9 files changed

+14
-77389
lines changed

docs/chdb/guides/jupysql.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ description: How to install chDB for Bun
66
keywords: [chdb, JupySQL]
77
---
88

9+
import PlayersPerRank from '@site/static/images/chdb/guides/players_per_rank.png';
10+
911
[JupySQL](https://jupysql.ploomber.io/en/latest/quick-start.html) is a Python library that lets you run SQL in Jupyter notebooks and the IPython shell.
1012
In this guide, we're going to learn how to query data using chDB and JupySQL.
1113

@@ -71,7 +73,7 @@ Next, let's import the `dbapi` module for chDB:
7173
from chdb import dbapi
7274
```
7375

74-
And we'll create a chDB connection.
76+
And we'll create a chDB connection.
7577
Any data that we persist will be saved to the `atp.chdb` directory:
7678

7779
```python
@@ -93,7 +95,7 @@ Next, we'll display the display limit so that results of queries won't be trunca
9395

9496
## Querying data in CSV files {#querying-data-in-csv-files}
9597

96-
We've downloaded a bunch of files with the `atp_rankings` prefix.
98+
We've downloaded a bunch of files with the `atp_rankings` prefix.
9799
Let's use the `DESCRIBE` clause to understand the schema:
98100

99101

@@ -273,7 +275,7 @@ We're going to write a query that finds the maximum points accumulate by each pl
273275

274276
```python
275277
%%sql
276-
SELECT name_first, name_last,
278+
SELECT name_first, name_last,
277279
max(points) as maxPoints,
278280
argMax(rank, points) as rank,
279281
argMax(ranking_date, points) as date
@@ -305,12 +307,12 @@ It's quite interesting that some of the players in this list accumulated a lot o
305307

306308
## Saving queries {#saving-queries}
307309

308-
We can save queries using the `--save` parameter on the same line as the `%%sql` magic.
310+
We can save queries using the `--save` parameter on the same line as the `%%sql` magic.
309311
The `--no-execute` parameter means that query execution will be skipped.
310312

311313
```python
312314
%%sql --save best_points --no-execute
313-
SELECT name_first, name_last,
315+
SELECT name_first, name_last,
314316
max(points) as maxPoints,
315317
argMax(rank, points) as rank,
316318
argMax(ranking_date, points) as date
@@ -357,7 +359,7 @@ Parameters are just normal variables:
357359
rank = 10
358360
```
359361

360-
And then we can use the `{{variable}}` syntax in our query.
362+
And then we can use the `{{variable}}` syntax in our query.
361363
The following query finds the players who had the least number of days between when they first had a ranking in the top 10 and last had a ranking in the top 10:
362364

363365
```python
@@ -422,4 +424,4 @@ plot = (
422424
)
423425
```
424426

425-
<img src={require('./images/players_per_rank.png').default} class="image" alt="Migrating Self-managed ClickHouse" style={{width: '90%', padding: '30px'}}/>
427+
<img src={PlayersPerRank} alt="Histogram of player rankings in ATP dataset" class="image" style={{width: '90%', padding: '30px'}} />

0 commit comments

Comments
 (0)