取得するデータの個数を制限して、データベースがクラッシュするのを防ぎましょう。
デフォルトは1000でした。
1 2 3 4 5 6 |
#(9)取得する数に制限を与える limit句 select * from products limit 10; select * from products limit 0,10; select * from products limit 10,20; select * from users where last_name like '中%' limit 0,1000; select id,last_name,gender from users where gender=1 limit 10; |
次回はcsvとして保存する方法をやっていきましょう。
The following two tabs change content below.
Keita N
こんにちは すうがく を こよなくあいする
”二代目 圧倒的 かず まなぶ (´・ω・`)” です
心が豊かになる方法について 引き続き考えていきたいです。
最新記事 by Keita N (全て見る)
- python MNIST問題 - 2020年12月19日
- python バフェット流 バリュー投資判断 - 2020年12月19日
- Python:webカメラとOpenCVで動体検知してLine Notifyで画像を通知する - 2020年12月19日