66 Commits

Author SHA1 Message Date
9b53c06018 Fix part 1 of bug #307 export to directory did not create files for each table if "Table structure" was unchecked. Instead the data was found in the header file afterwards. 2008-09-13 09:54:27 +00:00
5c9a096179 Use WideFormat() instead of Format(). 2008-09-02 15:07:25 +00:00
881da41fa0 * Export binary data to SQL without corruption.
* Add todo notes in GridTo[Xml,Csv,Html}.
* Whitespace adjustments.

Partly fixes issue #659.
2008-09-02 15:05:02 +00:00
807484ab6e Use Format() where appropriate. 2008-09-02 14:19:58 +00:00
5d877d7f18 Avoid overflowing the target compatibility box. 2008-09-02 07:21:23 +00:00
883cd1e7d8 Avoid mucking with other client applications character_set_connection: do not emit a SET CHARACTER SET into exported SQL files. Instead rely on the receiving application to correctly interpret files in Unicode format. 2008-09-02 07:14:33 +00:00
92f4ebc762 Bugfix: (regression) avoid using 4.x functions UUID() and IS_FREE_LOCK() during export. 2008-09-01 18:23:22 +00:00
020b620c47 Avoid destructive actions (DROP before CREATE) when user tried to do a 'recreate' action on two sessions connected to the same database. Fixes issue #703. 2008-09-01 17:51:25 +00:00
85075d5be7 * Fix inconsistent enable/disable of the other host database dropdown.
* Fix generating wrong SQL when non-enabled cbxDatabase was checked.
* Correct wording a few places.
2008-09-01 16:21:24 +00:00
9a52593dc2 Use Vista's Segeo font for all forms by using the SetVistaFonts() in mainform plus the new routine InheritFont() which simply overtakes fontname and size from the mainform to all other forms. 2008-08-29 18:20:14 +00:00
8367deb592 Fix bug #613 Target database not remembered in Export window 2008-08-26 19:38:49 +00:00
2cff5732fc Remove no longer needed routine for autocalculating row limit: GetCalculatedLimit. The Export SQL dialog now uses a constant number of 5000 rows fetched per step. Also removes the option in the preferences screen for limiting the data amount, which was misleading the user before and only used to limit the export stuff. 2008-08-26 09:09:41 +00:00
6daf4b3f76 Fix most remaining Unicode unsafe GUI controls. 2008-08-25 20:24:00 +00:00
87a804275a Fix bug #683, cli version exports escaped and quoted like ANSI exports. 2008-08-15 20:42:21 +00:00
a686c05cd8 Stop telling users ANSI SQL is some neutral target version which works for every dbms 2008-08-15 19:51:39 +00:00
aabd4bbf57 Add some more support for databases and tables with unicode characters. 2008-08-08 19:32:24 +00:00
70370dca8c Always export files in UTF-8. 2008-08-07 19:44:40 +00:00
614a6a813c "Fix" regression from one of the previous revisions. Rather a null reference than a random pointer. 2008-08-07 18:33:46 +00:00
e01567dcb6 Revert r1609. 2008-08-07 18:19:24 +00:00
1680561311 Fix Utf8 field contents displayed in datagrids and exported to SQL. 2008-08-04 20:48:44 +00:00
732fadd17a Try to fix bug #620 "Export utf-8 table content broken" by using WideStrings in all relevant places. Couldn't find a way to fix TZConnection.GetEscapeString, so this replaces that call by WideStringReplace which should do the job as well (although I remember that was a performance problem on large memos).
Todo: TField.AsWideString seems to be broken for ftMemo fields with utf8 collation.
2008-08-04 20:39:33 +00:00
04d314d5ea Autolimit optimizations:
- Do not uncheck the LIMIT checkbox if the value in EditLimitEnd is larger than the total row count. In such (very common) cases it doesn't matter if a LIMIT is applied or not, so we don't annoy the user now by not auto-unchecking it.
- EditLimitEnd's value was never increased, only decreased, as of r1521. This seems more annoying than it helps prioritizing what the user wants.
2008-07-16 23:07:09 +00:00
ffc58c022b Revert broken r1561. Worse than before - more AVs, even when pressing a speedbutton which has loaded its icon correctly. Weird. 2008-07-02 22:33:05 +00:00
94822c33fa Fix one critical AV, part of bug #580 . Loading a PNGImage from a TPNGImagelist onto a TSpeedbuttons seems buggy. Instead, assign icons at designtime. Ugly fix as we now have redundant icons, anyway, we should look after not using TPNGSpeedbutton in too many places. 2008-07-02 22:21:04 +00:00
5c7631796f Add specific modes supposed to include various brokenness in mysqldump. Hopefully we won't have to discuss whether to account for a specific brokenness in mysqldump ever again. I almost couldn't be happier if MySQL actually fixed their bugs ;-). Fixes issue #537. 2008-06-25 05:46:19 +00:00
5c1c61af8b Work around a bug in MySQL server; NO_BACKSLASH_ESCAPES is not included in ANSI mode, even though according to the manual:
"NO_BACKSLASH_ESCAPES enables an SQL standard compatibility mode, where backslash is 
not considered a special character."
2008-06-25 04:31:14 +00:00
41074d211e Convert database tree from TTreeView to TVirtualStringTree.
- Fixes bug #271 "F5 shortcut in database tree not working"
- Fullfills rfe #519 "Highlight selected item in tree view when focus is elsewhere"
- Fixes inconsistent expansion state of nodes after refreshing
- Fixes plus sign staying when a db node with 0 tables was selected
- Slightly enhances painting speed within the dbtree
- Removes temporary storage of a rightclicked node (DBRightClickSelectItem). VirtualTree handles its right clicked selection exactly like the left clicked one, which makes makes coding a bit cleaner as we can always use the selected item instead of hacking with the right and left clicked node. On the other side it removes a quite user friendly feature. Well, we can reimplement this feature later, though it's not user UNfriendly currently.
- Reasonably rename the StringList "OnlyDBs" to "DatabasesWanted" and "OnlyDBs2" to "Databases"
2008-06-13 23:05:51 +00:00
d0a0a22443 Display sizegrip in the lower right corners of all resizable forms which have no TStatusbar. (For copyright notices see code in helpers.pas) 2008-05-12 17:55:06 +00:00
c70bc467b1 Find a well working replacement for platform specific SelectDirectory function in StdActns unit. Fixes a corresponding compiler warning about using FileCtrl unit. 2008-03-29 17:09:51 +00:00
19f463b1d0 Code comments... 2008-03-29 16:13:31 +00:00
38caa4cd99 Make most "btnCancelClick" procedures superflous by assigning the correct ModalResult (mrCancel) to the relevant cancel buttons. 2008-03-09 20:27:12 +00:00
9618ac94b3 Fix directory selection in dialog "Export SQL": Root directory was set to previously selected directory which made it impossible to select parent directories of that one. 2008-03-09 20:04:13 +00:00
e53db0a9b7 PngIcons:
- Ban glyph data of all TSpeedButton's + TBitBtn's out of dfm files by converting them to TPngSpeedButtons and assign an image from PngImageListMain at runtime.
- Add "highlight" versions of "database" and "table" icons and use these on selected DBtree nodes.
- Remove no longer used BMP icons

Todo: Fill PngImageListMain at runtime.
Note 1: TBitBtn's are not Windows-theme-aware, even with a manifest in place, so we should avoid using them anywhere.
Note 2: T(Png)SpeedButton lacks a TabOrder property, so some of the other TabOrder's are automatically changed here.
2008-03-09 19:56:52 +00:00
815eea1481 Rename childwin's "Description" property to "SessionName" which says more exactly what it really is. 2008-03-05 12:21:25 +00:00
4e23728aa2 - Move all hardcoded preferences names (registry) plus their default values to const.inc to fix inconsistencies like the one described here: http://www.heidisql.com/forum/viewtopic.php?p=1739
- Consequently use Mainform.GetRegValue() to read these values, an overloaded method with either Boolean, String or Integer result. These methods keep a global TRegistry object (regMain) open while the application runs, rather than creating a new one for each caller.
- Remove Mainform.SaveRegValue() which was used in one or two callers. Rather use a TRegistry object and do that by hand. There's no significant advantage in using a SaveRegValue method currently.
2008-02-06 00:00:52 +00:00
1671ea2c19 Move all code for adjusting CREATE TABLE statements to a specific version from exportsql.pas to fixSQL(). Using SynEdit's nice regular expression object. Fixes bug #1843890 "Exportfile: YPE=MyISAM; (missing T)" 2007-12-17 23:12:35 +00:00
e32bd641eb Fix a theoretical access violation for servers with 0 databases. Could potentially fix bug #1844815 . 2007-12-16 23:44:57 +00:00
bac6b5bff2 Fix bug #1844735 "Corrupt CREATE TABLE in dumps" 2007-12-16 23:01:27 +00:00
249610072e Minor followup to rev 1170:
- Wording: "table" should be more clear than "objects"
- Source: Add TODO for platform specific method call
- GUI: Add right hand anchor for new radiobutton to ensure it's not covering some borders of the parent box
2007-12-13 18:04:49 +00:00
4e731b7fe5 Follow up to rev 1169: Add a more eye catching and user friendly solution to export to a directory.
- Add a fourth radiobutton + edit + button labeled "Directory" below the "File" option
- Code just uses that new option just like the File option. Only differentiate in the InitFileStream method.
- The SelectDirectory() method expects the unit FileCtrl in the USES clause. Silence a relevant compiler warning about usage of platform specific units - we will never compile anything else than a Win32 app here.
2007-12-12 21:42:49 +00:00
4793d275cd Add feature #1843670 "Multi-table Automated File Exporting"
The output filename gets parsed and the eventually existing "<table>" pattern gets replaced by either "header", "table1", "table2", ..., or "footer". That means, the single SQL files won't be complete in the end, as the header and footer is missing in the table-files. Not 100% sure if this is a good strategy. For me it seemed like the best/fast/lame way of working around the fact that the header potentially contains a CREATE DATABASE statement.
2007-12-10 21:02:06 +00:00
8c0965166c Fix second part of issue #1839045: conditional around default charset winds on for too long, encapsulating "row_format" too. Lines 754-768 should probably be factored out into a general method for doing these conditionals. Hmm, and why are there different target MySQL versions when the export function generates multi-version SQL anyway? 2007-11-29 20:42:48 +00:00
92737fa072 When masking USING <indexing algorithm>, place the end of the conditional enclosing right after the name of the algorithm (at the first space. assuming the name is only one word), rather than after at the first comma or parenthesis. Fixes issue #1839045. 2007-11-29 20:36:49 +00:00
e7bcbdf293 * Bugfix: plug the most obvious memory leaks.
* Clear some unused code and wrong comments.
2007-11-09 09:51:31 +00:00
fcc066d3e0 Follow-up to r1103: Enable keys before unlocking the table, so things are done in reverse to the locking process. 2007-11-06 14:20:11 +00:00
6d326739c2 Bugfix: LOCK TABLES needs to be done before DISABLE KEYS. MySQL seemingly does not always enforce this correctly? Either way, it's the correct semantics, to prevent other writers leaving data in the table after keys has been disabled but before HeidiSQL locks it. 2007-11-06 13:07:39 +00:00
a42a84ff6e Fix bug #1819886 "export silently overwrites target files" by later prompting for overwriting the target file. 2007-10-28 13:01:02 +00:00
382af79afc Fix issue #1819883. 2007-10-25 13:32:24 +00:00
17d41b8494 Fix/avoid AV on servers with 0 databases 2007-10-03 12:38:52 +00:00
46fd6af6d3 Fullfill feature wish #1789651 "export tables as sql to another host" (preselect matching remote database) 2007-10-02 22:32:37 +00:00