![](http://media.charlesleifer.com/blog/photos/sqlite-web.png)
`sqlite-web` is a web-based SQLite database browser written in Python.
Project dependencies:
* [flask](http://flask.pocoo.org)
* [peewee](http://docs.peewee-orm.com)
* [pygments](http://pygments.org)
### Installation
```sh
$ pip install sqlite-web
```
### Usage
```sh
$ sqlite_web /path/to/database.db
```
### Features
![](http://media.charlesleifer.com/blog/photos/p1494359468.71.gif)
* Works with your existing SQLite databases, or can be used to create new databases.
* Add or drop:
* Tables
* Columns (yes, you can drop and rename columns!)
* Indexes
* Export data as JSON or CSV.
* Import JSON or CSV files.
* Browse table data.
### Screenshots
The index page shows some basic information about the database, including the number of tables and indexes, as well as its size on disk:
![](http://media.charlesleifer.com/blog/photos/s1415479324.32.png)
The `structure` tab displays information about the structure of the table, including columns, indexes, and foreign keys (if any exist). From this page you can also create, rename or drop columns and indexes.
![](http://media.charlesleifer.com/blog/photos/s1415479418.23.png)
The `content` tab displays all the table data. Links in the table header can be used to sort the data:
![](http://media.charlesleifer.com/blog/photos/s1415479502.61.png)
The `query` tab allows you to execute arbitrary SQL queries on a table. The query results are displayed in a table and can be exported to either JSON or CSV:
![](http://media.charlesleifer.com/blog/photos/s1415487149.3.png)
The `import` tab supports importing CSV and JSON files into a table. There is an option to automatically create columns for any unrecognized keys in the import file:
![](http://media.charlesleifer.com/blog/photos/s1415479625.44.png)
### Command-line options
The syntax for invoking sqlite-web is:
```console
$ sqlite_web [options] /path/to/database-file.db
```
The following options are available:
* ``-p``, ``--port``: default is 8080
* ``-H``, ``--host``: default is 127.0.0.1
* ``-d``, ``--debug``: default is false
* ``-x``, ``--no-browser``: do not open a web-browser when sqlite-web starts.
* ``-P``, ``--password``: prompt for password to access sqlite-web.
Alternatively, the password can be stored in the "SQLITE_WEB_PASSWORD"
environment variable, in which case the application will not prompt for a
password, but will use the value from the environment.
* ``-r``, ``--read-only``: open database in read-only mode.
* ``-u``, ``--url-prefix``: URL prefix for application, e.g. "/sqlite-web".
### Using docker
A Dockerfile is provided with sqlite-web. To use:
```console
$ cd docker/ # Change dirs to the dir containing Dockerfile
$ docker build -t coleifer/sqlite-web .
$ docker run -it --rm \
-p 8080:8080 \
-v /path/to/your-data:/data \
-e SQLITE_DATABASE=db_filename.db \
coleifer/sqlite-web
```
没有合适的资源?快使用搜索试试~ 我知道了~
Python-sqliteweb用Python编写的基于web的SQLite数据库浏览器
共50个文件
html:16个
png:15个
py:4个
需积分: 49 13 下载量 111 浏览量
2019-08-10
03:48:32
上传
评论 2
收藏 373KB ZIP 举报
温馨提示
sqlite-web - 用Python编写的基于web的SQLite数据库浏览器
资源推荐
资源详情
资源评论
收起资源包目录
Python-sqliteweb用Python编写的基于web的SQLite数据库浏览器.zip (50个子文件)
sqlite-web-master
MANIFEST.in 94B
docker
Dockerfile 309B
sqlite_web
sqlite_web.py 26KB
__init__.py 0B
__main__.py 69B
templates
index.html 1KB
table_structure.html 5KB
add_index.html 1KB
table_query.html 4KB
table_import.html 1KB
base_table.html 1KB
table_content.html 2KB
drop_table.html 558B
rename_column.html 1KB
drop_column.html 811B
login.html 465B
add_column.html 979B
base_tables.html 1KB
drop_trigger.html 796B
base.html 3KB
drop_index.html 777B
static
img
index-create.png 8KB
table-drop.png 3KB
view-drop.png 3KB
select-advanced.png 25KB
table-create.png 12KB
insert.png 20KB
expression.png 42KB
trigger-drop.png 4KB
index-drop.png 3KB
trigger-create.png 22KB
select.png 14KB
view-create.png 7KB
delete.png 8KB
table-alter.png 5KB
update.png 17KB
js
jquery-1.11.0.min.js 94KB
bootstrap.bundle.min.js 66KB
fonts
glyphicons-halflings-regular.ttf 40KB
glyphicons-halflings-regular.eot 20KB
glyphicons-halflings-regular.svg 61KB
glyphicons-halflings-regular.woff 23KB
css
bootstrap.min.css 150KB
sqlbrowse.css 169B
syntax-highlight.css 3KB
run-docker 334B
requirements.txt 70B
LICENSE 1KB
setup.py 1KB
README.md 3KB
共 50 条
- 1
资源评论
weixin_39840515
- 粉丝: 446
- 资源: 1万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 什么是移动应用开发-关于移动应用开发的相关介绍
- 第二组汇报 PPT.pptx
- 什么是大数据开发-相关介绍-关于大数据开发的相关介绍
- 什么是软件测试-相关介绍-关于软件测试的相关介绍
- 前端开发-什么是前端开发-关于前端开发的一些相关介绍
- Sora AI-关于文生视频的使用场景说明
- suno AI文生视频的相关教程和介绍使用
- 什么是后端开发-关于后端开发的一些小介绍分享
- Jurassic Pack Vol. II Dinosaurs 侏罗纪包卷恐龙二号Unity游戏模型资源unitypackage
- Jurassic Pack Vol. III Dinosaurs 侏罗纪包卷恐龙三号Unity游戏模型资源unitypackag
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功