455 Commits

Author SHA1 Message Date
684983b57b Remove "perspectives" feature, to make data browsing less annoying. Restore old behavior where just the last set filter/columns/sorting was remembered. Fixes issue #822. 2009-12-24 11:39:20 +00:00
42f14ae9fc Exit grid loading earlier if no table or database was selected, to have less code indentation. 2009-12-24 07:03:50 +00:00
92eeced113 Don't raise exception when user enters an invalid filter, rather do that with a normal error dialog. Fixes issue #1559. 2009-12-23 17:51:57 +00:00
b8abe2cc21 On a blank server with 0 databases, the dbtree stayed empty after creating a database. DBtree.ResetNode seems to solve this, better as DBtree.ReInitChildren. Unfortunately that also collapses expanded nodes. 2009-12-23 15:15:24 +00:00
c3d771eb5e Add object names of selected database to SynMemo highlighter. Broken in r2879. Fixes issue #1557 2009-12-23 13:42:46 +00:00
029ac13101 Fix wrong node reference 2009-12-23 00:16:49 +00:00
54b6f31fa9 Safety check to avoid AVs in special cases. 2009-12-23 00:11:49 +00:00
5152b38937 Implement a "Duplicate row" action for quicker grid editing. Fixes issue #533. 2009-12-23 00:03:48 +00:00
eb9915d5be Invalidate columns and keys of an edited table when pressing the "Save" button, to avoid SQL errors when switching to "Data" tab. Fixes issue #1556 2009-12-22 23:38:38 +00:00
e356cb7ed7 Sanitize all "uses" clauses from unneeded unit references. 2009-12-22 23:19:56 +00:00
9d722e2f07 Don't auto-call database editor when focusing a table in dbtree. Fixes issue #1550. 2009-12-22 14:01:02 +00:00
4501f070a9 Wrap Connection.Database in try..except blocks, so they don't throw access violations when the selected db was deleted from outside. Fixes issue #1445 2009-12-21 09:07:21 +00:00
495ed3a689 After refreshing the tree, select the upper host node as fall back, if previously selected database was deleted from outside. Ensures there is at least one focused node and the unavailable database does not remain selected internally. 2009-12-21 06:34:18 +00:00
d14d8e01f7 Database node was not removed after DROP DATABASE action. Fixes issue #1474. Described access violation unreproducible here any longer, probably fixed earlier. 2009-12-20 09:37:36 +00:00
7272ba3bc3 Remove handling of crashed tables - there is no difference to normal tables in the way we handle them. 2009-12-19 21:25:59 +00:00
35e8bbb304 Do not fetch database objects from information_schema, which has gotten extremely slow on servers with many databases and triggers, since we support triggers.
* Instead, use separate SHOW commands for tables, functions, procedures and triggers
* Catch this chance to move these methods from main unit to mysql_connection, so they're accessible in a more generic way
* Additionally, introduce new classes TDBObject and TDBObjectList which provide a more generic way than TMySQLQuery to access these database objects.
Fixes issue #1529
2009-12-19 11:40:28 +00:00
17e6438a70 Do not auto-size columns in data grid after editing. Not sure why that was done, can be annoying when you manually sized column(s). 2009-12-16 19:54:10 +00:00
a86052a91f Fix wrong data type logic for SET columns. Fixes issue #1538. 2009-12-16 07:10:01 +00:00
8b34098669 Fix a similar problem as in previous commit - db and table nodes were not properly removed on disconnect. Probably fixes issue #1491. 2009-12-16 01:00:12 +00:00
53c69a5f51 Add "cut" + "select all" menu items to query editor context menu. Fixes issue #1537. 2009-12-16 00:37:36 +00:00
e7bfd5d1ee Do not autofit "size" column in db tree while nodes get initialized. Implicitly calls OnGetText before text is available. Instead, resize that column only at OnChange time, without examining all possible widths. Just assume "1,023.0 KB" as the widest possible text. Should optimize performance for browsing in tree, and fixes issue #1503. 2009-12-16 00:30:47 +00:00
7b5e5e410a Add action and menu item for saving current query contents silently, without Save-As-dialog. Fixes issue #1419. 2009-12-15 23:28:20 +00:00
adad668c37 Indicate modified query contents by appending an asterisk to the tabsheet's caption. 2009-12-15 22:51:49 +00:00
59af5bf6ec Catch exception when user lacks privileges for SHOW VIEW or SHOW CREATE TABLE command. 2009-12-15 22:28:23 +00:00
6f0a1b289b Apply the right datatype index to columns in datagrid. Fixes issue #1534. Obviously broken by r2821. 2009-12-15 20:19:15 +00:00
39a072ebc8 Remove unused variable 2009-12-15 20:03:28 +00:00
ddf6cf908d Show column comments as hints on data grid header. Fixes issue #1535. 2009-12-15 20:02:09 +00:00
dd398bb101 * Factor more code out of each database object editors into parent TDBObjectEditor.
* Use this chance to add a confirmation dialog when leaving the editors, to ask the user if he wants to save modifications. Fixes issue #1524.
* Also, enhance Mainform.RefreshTreeDB in a way that it does not trigger the OnFocusChange event. Important for the editors when saving changes.
2009-12-14 23:55:36 +00:00
3aef5bb5e5 Unify Init() method of database object editors. 2009-12-13 07:32:46 +00:00
68a1ae0416 Selecting information_schema.TRIGGERS.DATABASE_COLLATION results in "Unknown column 'DATABASE_COLLATION' in field list" on 5.0.? servers. We don't make use of this column, so select NULL instead. Fixes issue #1526 2009-12-11 17:13:03 +00:00
e4914bf582 Disable action for creating new triggers on server versions below 5.0.2. 2009-12-11 16:11:44 +00:00
b4cca2ea1f Implement handling of triggers as separate database objects, on the same level as tables, routines and views. Means we have a trigger editor frame, a new icon and various code extensions. Fixes issue #806. 2009-12-11 16:07:59 +00:00
6b92c3b08c Activate relevant tab before asking if contents shall be saved. Fixes issue #1518. 2009-12-10 20:48:35 +00:00
1f1e771fa6 Make views show their data again in data tab. Fixes issue #1515. 2009-12-09 21:08:38 +00:00
eefdbec81c Render primary key columns in query results in bold font, like in data grid. 2009-12-09 20:03:46 +00:00
f03af60357 Throw away one regular expression logic for detecting table columns, we have a simpler way to do that since r2821 2009-12-09 19:26:35 +00:00
a24c2bb847 Fix Unicode issue on main tabs: databases and tables with international characters were broken on tab captions. This just converts the main TPageControl to a TTntPageControl, plus its TTabSheets to TTntTabSheets. 2009-12-09 00:13:55 +00:00
a3aae38d2e Do not add UTF-8 BOM headers to written files, they are not needed in most cases, and break other tools from reading them, e.g. mysqldump. See http://www.heidisql.com/forum.php?t=4622 2009-12-08 23:51:43 +00:00
3ca479dd39 Trigger auto completer on @@SESSION and @@GLOBAL to display variables. Fixes issue #1513. 2009-12-08 13:58:36 +00:00
0e29eda7ac Add preference option to use locale number format for CSV+XML+HTML exports. Mainly to work around an Excel bug, which expects float values to be formatted with locale decimal separator when pasting. Fixes issue #1459. 2009-12-08 09:14:42 +00:00
bd4dd71797 Remember state of "Stop on errors in batch mode" button/action. Fixes issue #1128. 2009-12-07 20:13:52 +00:00
a89977ab6a Try successive regular expression executions instead of only the first one on a "table clause" before giving up. Hacks around special case "INSERT INTO foo SELECT t. FROM foo f". Fixes issue #1311. 2009-12-06 17:44:51 +00:00
d3ff85b730 Fix detection of previous token in query memo's. SynCompletionProposal.OnExecute passes x + y coordinates of current caret position - these are pixel values, while we expected them to be character + line numbers. 2009-12-06 17:12:56 +00:00
0218e3b754 Fix empty enum pulldown in datagrid. Broken in r2821. 2009-12-05 21:46:25 +00:00
566ac4a581 Destroy AllDatabases list *after* collapsing database tree, when a session connect is in progress. Hopefully fixes issue #1491. 2009-12-05 19:57:44 +00:00
a4e8637bdc Implement snippet generator for INSERT, UPDATE and DELETE statement using selected table. Clickable via query helpers columns tab, which then only involves selected column names. Fixes issue #1288. 2009-12-05 17:46:40 +00:00
94df12fa1f Enable auto scrolling in data- and query grid(s) when mouse is used to select rows. Fixes issue #849. 2009-12-04 21:37:01 +00:00
43fe695bc1 Make SHOW KEYS FROM <selected-table> and SHOW COLUMNS FROM <selected-table> superfluous. To achieve that, move parser for SHOW CREATE TABLE string from table editor to helpers unit, where it can be called by everyone. For consistency reasons the index list in table editor is converted from a TWideStringList to a TObjectList, like both table and foreign key list. However, that results in a large diff here. 2009-12-04 21:20:06 +00:00
ffe782b157 Now that the table tools dialog also has a second tree column "size", it should get autofitted the same way as mainform.dbtree. Fixes issue #1500. 2009-12-01 15:12:28 +00:00
14ff384039 Avoid accessing grid data array elements over its bounds in Datagrid.OnBeforeCellPaint, while painting NULL cell background. Can happen as RootNodeCount is set asynchronously to scrolling. Fixes issue #1497 and friends. 2009-12-01 13:16:43 +00:00