Making SQLITE/SQLITE3 executable scripts
发布时间:2020-12-12 20:36:57 所属栏目:百科 来源:网络整理
导读:Use "here document" statements to build complex script files with embedded SQL statements via the sqlite/sqlite3 utility. #! /usr/bin/env bash # execute some bash scripting commands here sqlite3 mydatabase SQL_ENTRY_TAG_1 SELECT * FROM myt
Use "here document" statements to build complex script files with embedded SQL statements via the sqlite/sqlite3 utility.
Note that being in a bash script means that you can expand $-variables inside the SQL code directly. This is,however,not advised unless you can be sure that only trusted,competent people will run your code. Otherwise you'll be facing SQL injection attacks. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |