0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

sqlite

Posted at
ターミナル1
 $python manage.py runserver $IP:$PORT
ターミナル2
 $ python
Python 3.6.5 (default, Apr 26 2018, 00:14:31) 
[GCC 4.8.5 20150623 (Red Hat 4.8.5-11)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import test                                                                                                                                                 
>>> test.write("ss","aa2");
ターミナル3
 $sqlite3 sample_db.sqlite 
SQLite version 3.7.17 2013-05-20 00:56:22
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> select * from aiueo;
1|abc|abc|abc
sqlite> select * from aiueo;
1|abc|abc|abc
1|abc|abc|abc
1|abjjj|abjjj|abjjj
sqlite> CREATE TABLE test(
   ...>   id INTEGER PRIMARY KEY AUTOINCREMENT,
   ...>   name VARCHAR(255) NOT NULL,
   ...>   comment TEXT,
   ...>   created_at TIMESTAMP DEFAULT (DATETIME('now','localtime'))
   ...> );
sqlite> select * from test;
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?