Data Viewer

All data are displayed here. Displayed data can be:

Changes in Data Viewer are handled in a separate transaction. So you have to click Commit or Rollback buttons to promote them into the database file.

Important

Transactions in the Data Viewer are separated from SQL Editor. You cannot commit your changes by COMMIT in the SQL Editor.

Data changes are available only for tables (invoked in Schema Browser). There is no way to edit the data returned by an SQL statement yet.

Data Viewer/Browser

Insert Row

This button is enabled only when viewing a table. It creates a new and empty row at the end of the table. Default values are prefilled. Commit action is required to make this permanent. If a field has a default of CURRENT_TIMESTAMP, CURRENT_DATE, or CURRENT_TIME, it will be prefilled with the date and/or time when the record is created, but if the field is not modified it will be overwritten when changes are committed with the date and/or time then. If no field has been edited, and the defaults for all fields of the record are CURRENT_TIMESTAMP, CURRENT_DATE, CURRENT_TIME, or expressions, it is not possible to commit the record: this is a problem with the underlying Qt SQL library. To insert a record in this case, execute the SQL statement

INSERT INTO table DEFAULT VALUES ;

Duplicate Row

This button is enabled only when viewing a table and a current row is selected. It creates a copy of the current row at the end of the table (this can be useful when creating rows which differ only in one field). Commit action is required to make this permanent.

Delete Row

This button is enabled only when viewing a table and a current row is selected. It deletes the selected row from the table. Commit action is required to make this permanent.

Commit

This button is enabled only when changes have been made in the DataViewer. It promotes the changes into the database.

Rollback

This button is eanbled only when changes have been made in the DataViewer. It rejects the changes and reloads the Data Viewer from the database.

Blob Preview

Enable or disable BLOB preview widget. The blob preview widget can only be enabled when a field containing a blob is selected, but it can be disabled whenever it is enabled. If the blob preview is enabled, it will appear whenever a field containing a blob is selected and it will attempt to display the blob as an image.

Data Export

Open the Data Export dialog. You can export currently selected data in various formats. See Data Export documentation.

Table Snapshot

Duplicate current result table into new read only window. You can compare data versions etc. with it.

Go to line number

This button pops up a dialog to select a row number. It will select the first field of that row and scroll the Data Viewer to make it visible.

Display Types

Full View

Display data as a table. It's the most common view on SQL results.

Item View

Clicking on the Item View tab will display the Item View for the currently selected row (the tab is disabled when there is no current row). Double-clicking on a row number in the Full View will open the Item View for that row.

The Item View displays only one row at a time, but with more space to edit each field. The navigation buttons at the right move to the first, previous, next, and last row respectively, and are disabled if you are already at that row. There are also buttons to overwrite the selected field with a NULL or to open the Advanced Editor. You can also use the go to line number button. This view is now fully editable and synchronised with the Full View. If you are using NULL higlighting, the NULL alias will disappear if you click on a NULL field, so that you can type something in there: this only happens with editable tables.

Script Output

Describe action results and Run As Script from SQL Editor results are listed in this tab. It is automatically selected if you run a script.

Data Editor

Basic data editing is handled directly in the table cell, invoked by double-click on the field or Ctrl+Space when a field is selected.

Important

Remember that Sqlite recognizes NULL and empty string as two independent values. So inserting an empty string does not mean you are inserting a NULL. Use NULL buttons to do it.

Simple Data Editor

Line edit.

Simple strings can be edited in this widget.

Set NULL Ctrl+Alt+N

Set the cell to the real NULL value.

Advanced Editor Ctrl+Alt+E

Open advanced editor (also known as Multiline Editor). This allows you to edit multi line texts, BLOBs and the other special data formats.

Advanced Editor

This dialog is designed because the Simple Editor cannot handle advanced features comfortably.

Advanced Data Editor

When you accept changes in this dialog with OK button, only the result of the active tab will be promoted to the Data Viewer. If the Insert NULL option is checked, only NULL is inserted. As usual the commit button then has to be used to promote the changes into the database.

Text tab

Full plain text editor. There is no rich text support.

Blob tab

Content of chosen file will be transferred into the cell as is. No data transformations are performed. Original value of the cell can be saved into local file with Save... button.

Date to String tab

A helper wizard for storing date and time in string values.

Important

Consult Sqlite manual for date and time issues.

The Date item in this form can be set with pop-up calendar.

The String Format should be set with date time transform mask. Consult Qt4 documentation to explain its codes.

Example 7.2. Date to String

dd.MM.yyyy hh:mm.ss will produce e.g. "24.12.2007 18:30:45"

Fetching the data

Sqliteman can use progressive (step-by-step) fetching of data in the result set. This means that you don't need to wait until all data are transferred from database file to this result table.

When you call a select statement from table with e.g. thousands of rows only the first part of rows is physically fetched. Remaining rows are available on demand - scrolling down in the result table will perform next fetch.

Message in the error log widget will inform you about this situation:

More rows can be fetched. Scroll the result set for more rows and/or read the documentation.

Alternatively you can set a preference to read all of a table when opening it: this can be more convenient on a fast computer with plenty of memory.

Incremental Search

If you select a column by clicking on the column name at the top, and then type characters, Sqliteman will do an incremental search on the data in the selected column. The view will be scrolled so that the first matching row is visible, at the top of the window unless there are not enough rows below it to fill the window. This works best with a sorted column, but Sqliteman will do the search anyway.