![]() The master table holds the key information about your database tables and it is called sqlite_master. The above setting will produce the output in the following format. You can use the following sequence of dot commands to format your output. Make sure there is no space in between sqlite> prompt and dot command, otherwise it will not work. show command to see default setting for your SQLite command prompt. Try opening locked tables for MS milliseconds List names of tables matching a LIKE pattern ![]() Show the current values for various settings If TABLE specified, only show tables matching LIKE pattern TABLEĬhange separator used by output mode and. If TABLE specified, only show indices for tables matching LIKE pattern TABLE Turn output mode suitable for EXPLAIN on or off. If TABLE specified, only dump tables matching LIKE pattern TABLE List names and files of attached databasesĭump the database in an SQL text format. The above command will display a list of various important SQLite dot commands, which are listed in the following table. sqlite> CREATE VIEW COMPANYVIEW AS SELECT ID, NAME, AGE FROM COMPANY You can now query COMPANYVIEW in a similar way as you query an actual table. This view will be used to have only a few columns from COMPANY table. Let's start with typing a simple sqlite3 command at command prompt which will provide you with SQLite command prompt where you will issue various SQLite commands.įor a listing of the available dot commands, you can enter ".help" any time. Following is an example to create a view from COMPANY table. These commands are called SQLite dot commands and exception with these commands is that they should not be terminated by a semi-colon ( ). This chapter will take you through simple and useful commands used by SQLite programmers.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |