Commit Graph

1470 Commits

Author SHA1 Message Date
Ansgar Becker
44cedeed4e Try a 99% work around for binary contents of function results: Check if a field is a function result on servers below 5.0.46, if yes, detect it as text type rather than binary. If it's a real table column, leave detection logic as is (Field.charsetnr = COLLATION_BINARY). This surely returns evil text type for SELECT LEFT(binaryfield, 5), but that seems to be a rare situation so that's the compromise here. Fixes issue #725. 2009-12-05 18:12:47 +00:00
Ansgar Becker
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
Ansgar Becker
de45bdd24a Fix a follow up error of previous commit - need to call CharsetTable.First now. 2009-12-05 16:54:43 +00:00
Ansgar Becker
37f83b6af8 Fix offset in charset table, always set to 0. See http://www.heidisql.com/forum.php?t=4638 2009-12-05 16:03:07 +00:00
Ansgar Becker
4b01d83ed7 My IDE insists on camel case for this component class name. 2009-12-04 21:44:00 +00:00
Ansgar Becker
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
Ansgar Becker
c75df83cfc Work around internal Delphi problem, complaining about a "unsupported 16bit resource file" when loading this file. 2009-12-04 21:27:43 +00:00
Ansgar Becker
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
Ansgar Becker
f8d88f31d7 Right align text in size column, like it's in DBtree 2009-12-01 15:15:40 +00:00
Ansgar Becker
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
Ansgar Becker
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
Ansgar Becker
96f0478cb0 Increase length of displayed/loaded query in processlist by factor 10, so it's more helpful than 1 kb of SQL, but still low enough to avoid a huge memory load. Fixes issue #1498. 2009-12-01 10:45:35 +00:00
Ansgar Becker
a9ab1a1c6d Fix documentation 2009-12-01 00:32:49 +00:00
Ansgar Becker
1e0f6444b8 Enhance readability of sorted columns in high contrast mode (white text on black background). Check brightness and decide for a brighter or darker background color as needed. See issue #1366. 2009-12-01 00:17:21 +00:00
Ansgar Becker
7fed732f40 Tabs popup menu should only activate when clicked on the tabs area. Fixes issue #1456 2009-11-30 23:19:25 +00:00
Ansgar Becker
680bbcf0ac Automatically remove AUTO_INCREMENT=x clause from CREATE TABLE statement for SQL export. Fixes issue #1110. 2009-11-30 22:42:08 +00:00
Ansgar Becker
cc028cee30 Fix sporadic access violation when a new row was inserted and UPDATE or INSERT gets posted. Fixes issue #1496 2009-11-30 20:58:31 +00:00
Ansgar Becker
84f7663887 Make SQL help dialog modeless, so it can stay open while the user returns to its query or whatever. A later F1 pressing again searches the right help item. Fixes issue #971. 2009-11-30 00:52:02 +00:00
Ansgar Becker
278dbfa80d Same as previous commit, this time for the about dialog. 2009-11-29 21:22:04 +00:00
Ansgar Becker
f465ee6086 Fix wrong color in mainform's font property. Broken since r1 (!). Fixes issue #1366. 2009-11-29 21:19:36 +00:00
Ansgar Becker
115148fd23 Move a "continue" for deleted privs slightly lower, so these get deleted. Fixes issue #1454 2009-11-29 20:03:11 +00:00
Ansgar Becker
a80e9cb91d Fix point where last (successful connected) session name is saved to registry. The session manager is not the only place where Mainform.InitConnection is called. 2009-11-29 17:59:26 +00:00
Ansgar Becker
627b4690ec Minimize memory usage and optimize performance in process list tab when large (INSERT) queries are running, by fetching only the first KB of the "Info" column. Fixes issue #345. 2009-11-29 17:31:03 +00:00
Ansgar Becker
d8d82e3e72 Move caching of information_schema objects into database connection unit. Simplifies code when accessing them. 2009-11-29 15:50:51 +00:00
Ansgar Becker
1995e2e820 Try to fix sporadic access violation when destroying a non-results-query. Unlikely but probably fixes issue #1494 . 2009-11-29 11:51:29 +00:00
Ansgar Becker
1b1a2c2edc No need to center selected node vertically normally. Should make selecting the next node after deletions in datagrid nicer. See issue #1471. 2009-11-29 00:21:00 +00:00
Ansgar Becker
8ac6fbd15c There is no 64 bit unsigned integer type in Delphi, but MySQL has it: bigint unsigned. Handle these as strings in the table editor. Fixes issue #1489. 2009-11-29 00:18:20 +00:00
Ansgar Becker
59da2e193a Enhance visibility of size numbers in dbtree - use clWindow also for databases, and a darker grey for tables. Should fix issue #1492 2009-11-28 23:26:51 +00:00
Ansgar Becker
ef282ed7f0 Remove unused variable and silence compiler notice. 2009-11-28 23:17:50 +00:00
Ansgar Becker
1dc71c845d Set focus to next available node after deleting one or more rows in datagrid. Fixes issue #1471 2009-11-28 23:13:35 +00:00
Ansgar Becker
5f9a62de94 Use cached result of SHOW CHARSET in one more place. 2009-11-28 21:39:15 +00:00
Ansgar Becker
30b970c92b Implement bulk table editing in table tools dialog. Fixes issue #576 2009-11-28 19:51:57 +00:00
Ansgar Becker
a0fc5e2065 Readd code which I deleted in r2790 to achieve numbers without thousand separators in grids. A side effect was that FormatNumber(Float) still returned numbers with thousands. Avoid that, and let both int and float overloaded FormatNumber() functions pass their parameter to FormatNumber(string), and introduce a thousands parameter to be able to turn that off for grid numbers. 2009-11-25 23:17:08 +00:00
Ansgar Becker
312f9cb67f Fix too short SQL query timer, used in query tabs: Also count network time consumed by mysql_store_result(), display that time separately. 2009-11-25 21:36:06 +00:00
Ansgar Becker
e456764692 Fix forever staying message in status bar, for certain situations. 2009-11-25 21:05:06 +00:00
Ansgar Becker
4852f229e5 Allow multiple SQL files loaded via OpenFile dialog. Load file 0 in active query memo and file 1 to n in new tabs. 2009-11-25 20:52:37 +00:00
Ansgar Becker
9b9442f470 Fix mixed up logic in Mainform.OnCloseQuery: Save dialog popped up for only one modified query content, then the form was not closed. Plus: Wrong tab captions in such cases. 2009-11-25 20:39:39 +00:00
Ansgar Becker
c1855c84e7 Missing changes for r2789 2009-11-25 20:35:21 +00:00
Ansgar Becker
1c0af2316a Turn off adding regional thousand separators in grids again. 4 reports in one day tell me that users don't like that. Fixes issue #1484 2009-11-25 19:23:41 +00:00
Ansgar Becker
53c4accde2 Remove two buttons from main toolbar (execute selection + execute line) which are not that necessary to have them there, seems enough to have them in the context menu. 2009-11-24 23:10:14 +00:00
Ansgar Becker
6ebe40c929 Make INSERTs in user manager compatible with pre-4.1 servers by
* removing the ON DUPLICATE KEY clauses
* turning the INSERT into INSERT IGNORE
* and doing an UPDATE afterwards if RowsAffected is 0
Fixes issue #1229
2009-11-24 22:59:21 +00:00
Ansgar Becker
44c0cfbfe8 Overtake comment of original table in "Create table copy". Fixes issue #1141. 2009-11-24 19:43:47 +00:00
Ansgar Becker
0c83491ed5 Implement preference option to adjust tab width in SynMemos. Fixes issue #857. 2009-11-24 19:34:48 +00:00
Ansgar Becker
e5771ad084 Do not add thousand separators to zerofilled numbers 2009-11-24 18:36:57 +00:00
Ansgar Becker
3caf576eac Fix mixed up combo box item when generating LOAD DATA query. Fixes issue #1481 2009-11-24 18:11:43 +00:00
Ansgar Becker
6b5c692d3b Fix formatted, signed floats with a thousands separator after the minus sign, e.g. "-,123,456.789" 2009-11-23 21:57:34 +00:00
Ansgar Becker
cdb936b77d Consistently use FormatTimeNumber() also for formatting server uptime. Leave out the day portion if zero. 2009-11-23 21:24:25 +00:00
Ansgar Becker
db3fbd0df7 Move timer stuff for server uptime and connection from main unit into connection layer. Both are seconds since start now. 2009-11-23 21:12:26 +00:00
Ansgar Becker
79c5d04cfe Do not ping server in TMySQLConnection.GetActive, rather do that in a new Ping() function. TMySQLConnection.Active now returns true also in cases where the connection had timed out. Reconnection logic should work in such cases, only the connected timer gives the user a wrong info, which is cosmetic and unavoidable if we do not want to spam the server with keep-alive pings every second. 2009-11-23 20:27:27 +00:00
Ansgar Becker
a1d0d0c0ec Prefer local formatting over raw numbers in grids:
* This time, also support formatted integers, not only floats.
* Do not quote both types in grid updates/deletes/inserts.
* Do no internal conversion from string to float and back to string (FloatToStr did that) to avoid silent data corruption. Just use strings in all places.
* Replace FloatStr() function with UnformatNumber(), which is also able to handle integers
Should fix issue #1012
2009-11-23 20:11:13 +00:00