执行 SQLite 脚本 [英] Execute SQLite script

查看:17
本文介绍了执行 SQLite 脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用以下命令启动了 sqlite3 版本 3.7.7、unix 11.4.2:

I start up sqlite3 version 3.7.7, unix 11.4.2 using this command:

sqlite3 auction.db

auction.db 尚未创建.

where auction.db has not already been created.

sqlite> auction.db < create.sql;

给我这个错误:near "auction": syntax error

如何运行脚本?

推荐答案

有很多方法可以做到这一点,一种方法是:

There are many ways to do this, one way is:

sqlite3uction.db

关注:

sqlite>.read create.sql

总的来说,SQLite 项目有非常棒的文档!我知道我们经常在文档之前接触 Google,但在 SQLite 的情况下,文档确实是最好的技术写作.它干净、清晰、简洁.

In general, the SQLite project has really fantastic documentation! I know we often reach for Google before the docs, but in SQLite's case, the docs really are technical writing at its best. It's clean, clear, and concise.

这篇关于执行 SQLite 脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆