First open the folder where sqlite3.exe is located, as shown in Figure 1
figure 1
Change the path to cmd in the folder path, as shown in Figure 2
figure 2
Input the information in the pop-up cmd window as shown in Figure 3.
image 3
sqlite3 tichiceliang.db
Where tichiceliang is the database name. Then press enter and enter .table in cmd. You can see that a new file is created in the folder directory, as shown in Figure 4. The last file in the picture is the database file created.
Figure 4
Create a table in the database. The table name is celiang. The fields in the table include a-k, as shown in Figure 5 (note that ";" is added at the end during runtime).
Figure 5
Enter the .tables query, as shown in Figure 6, celiang appears, indicating that the table is successfully created (.tables indicates that all tables in the current database are displayed)
Figure 6
Enter select * from celiang; query the contents of the table. Input insert into celiang(a,b,c,d,e,f,g,h,i,j,k) values(1,2,3,4,5,6,7,8,9,10,11 );Write content into the table, as shown in Figure 7
Figure 7
Then use select * from celiang to query the table contents. The results are shown in Figure 8.
Figure 8
Reference video:Video