It turned out that on some platforms we still aim to support the stdlib
had not yet implemented std::regex. For this reason we want to avoid
using it for now.
In the particular use cases here it was also not the best solution. It
was faster to write using a regular expression instead of a hand coded
loop but clearly a simple loop should be more efficient here.
See issue #1873.
Respect the suggested order of the licences as provided by the dbhub.io
server instead of sorting them alphabetically by their internal key.
Also remove the hard-coded "Unspecified" licence option because the
dbhub.io server provided its own "No licence specified" option.
This adds a built-in, default certificate which enables read-only access
to dbhub.io. This should make it easier to try out the remote features.
When trying to open the Push Database dialog, a message with more
details and all required links is displayed.
We started to use Niels Lohmann's JSON library instead of the one
included in Qt for the Export JSON dialog a while ago because Qt's
implementation showed some problems. To avoid any similar issues and
because Niels' library has a much nicer API, this commit migrates all
our code to his library.
In the Browse Data tab updating a row after having updated its primary
key or part of it before was broken for multi-column primary keys. When
updating the value of a primary key column and then updating any part of
the row afterwards, we were still using the old value until the view was
refreshed. With this commit it is possible to immediately update the
row using the updated primary key values.
See issue #1834.
This improves the performance for loading row data with my setup by
about 10%. Incidentally, the conversion from Qt to STL containers
reduced the performance by about the same number.
This adds another primitive benchmark tool which in this case helps
measuring the time required to load all remaining rows from the selected
table. When activated using the LOAD_DATA_BENCHMARK define, it opens a
message box after loading of all rows using the fetch-all-data button in
the Plot Dock is clicked.
produced. Messages would take the form:
[SQLB root]/src/sql/sqlitetypes.cpp:465:79: warning: declaration of ‘fields’ shadows a member of ‘sqlb::Table’ [-Wshadow]
and reference
[SQLB root]/src/sql/sqlitetypes.h:310:17: note: shadowed declaration is here
FieldVector fields;
All incidents isolated to [SQLDB root]/src/sql/sqlitetypes.{h,cpp}.
Change renames local variables to silence warnings.
no errors after execution w/ gcc/clang builds on Linux.
When a PRAGMA query did not return any value (most notably the PRAGMA
foreign_key_check after editing a table using the Edit Table dialog), we
used to print an error message to the console. There were no further
side effects but the message could be irritating. This extra error
message is removed by this commit.
See issue #1868.
Add a new tab to the Edit Table dialog to show a list of all table
constraints. Before this, some of them were visible in the field list
but others were not shown at all. This new view is still rather basic
and currently read-only but will be improved over time.
Resolve warnings that occur when building w/ ALL_WARNINGS enabled. Source tree
examined to enusre prefetch size is handled as type std::size_t. Also, tree was
modified correcting handling of the chunkSize variable in sqlitetablemodel that
uses the prefetch preference setting.
Also, some minor editing of sources was taken to improve readability
as well as consistency.
- Empty condition means: apply format to any row.
- Rearranged dialog upper buttons so it resembles the Edit Table Dialog.
- Added Help button: link to wiki page.
- Added Reset button: clear all conditional formats in the dialog.
- Fixed some glitches in the move commands: open editors were sometimes
closed, using currentIndex and selectedItems caused inconsistencies.
- Select colour with a single click and show it in the tooltip.
- Remove the unneeded colour name in the colour cells.
See issue #1815
The new text detection check implemented in
e2443d685f was giving problems with some
short by combinations that could look like as a truncated valid UTF-8
sequence, so it is better to only do this text, when the string has been
truncated. In this way, short byte sequences should be correctly checked.
See issue #1846
The following changes set the project as modified in order to ask to save
changes in project file when closing DB or application:
The main database file and any attached database file.
* PRAGMA values
* Show Row Id option
* Encoding
* Unlock View Primary Key option
* Sort columns and sort directions
* Column widths
* Applied Filters
* Display Formats
* Hidden columns
See issue #1706
When the Ctrl+F was used in the Scintilla widgets of the SQL Log or Edit
Database Cell docks, the shortcut was ambiguous with the search find bar
action, which had window context. Now the later has widget context and a
new widget-context shortcut is explicitly connected to the action in the
editors of each new SQL tab.
See issue #1746
A new find dialog, bound to Ctrl+F, has been added to all the Scintilla
editors. The dialog is basically the Find/Replace dialog, whose replace
related controls have been set to invisible.
This shortcut and the new menu contextual entry are disabled for the
Execute SQL editors, since there the shortcut is already assigned to the
search bar and it would also be redundant.
See issue #1746
This adds a very basic implementation to watch for external
modifications in SQL files. Whenever another application modified a SQL
file which was opened from or saved to disk, a message box pops up to
notify the user of the changes.
See issue #1839.
Move the code for opening and saving SQL files in the Execute SQL tab
from the main window to the SqlExecutionAtra class.
Also fix some warnings in the code for opening new SQL tabs.
In the Table class we need to store whether this is a WITHOUT ROWID
table or now. Instead of just storing a boolean flag for that we were
storing a list of the rowid column(s). This is not just more complicated
to handle than a simple flag but also more error-prone because the list
must always be kept equal to the list of primary key columns. Failing to
keep them equal would result in an invalid SQL statement.
Now number of rows and columns is always showed, independent of the number
of cells threshold. Plural forms are used in translations (Spanish and
British English updated for testing).
Min and Max have also been added to the status bar message.
When a selection is made in the Data Browser, the status bar shows:
number of rows, number of columns, sum and average of numeric values (other
data types count as 0) in the selection.
For avoiding expensive computations when the selection is very big
(selecting all cells or an entire column) the threshold setting for the
completion is reused.
This was inspired by #1791, but does not implement the proposed feature.