aboutsummaryrefslogtreecommitdiffstats
path: root/Source/TableSource.m
Commit message (Collapse)AuthorAgeFilesLines
* Replace the main toolbar's #define'd identifier constants with extern's. ↵stuconnolly2009-12-121-3/+3
| | | | This completes the conversion of all constants in SPConstants to extern's.
* Implement the same logic as implemented in r1548 except for the removal of ↵stuconnolly2009-11-241-62/+119
| | | | indexes. As foreign keys have a dependency on the presence of indexes to prevent table scans, offer the user the ability to drop the relationship before the index, which would otherwise result in an error if not dropped first.
* When attempting to delete a field that is part of a foreign key ↵stuconnolly2009-11-181-5/+51
| | | | | | | | | relationship, remove the key before the field to prevent an error. Obviously warn the user that the key is being dropped as well. Fixes issue #462. This check also needs to be implemented when removing indexes as foreign keys depend on the presence of indexes to prevent table scans. Something to be discussed, the display of foreign keys that are made up of multiple fields in the relations table and link arrows in the content table.
* Implement query cancellation support within MCPKit, and add it to the task ↵rowanbeentje2009-11-151-2/+14
| | | | | | | | | | functionality: - MCPKit now supports cancelling the active query; for MySQL servers >= 5.0.0 a query kill is attempted from a new connection, and if that fails or for MySQL < 5 a reconnect is triggered. - TableDocument now supports enabling a cancel task button on the task interface, including an optional callback - Implement query cancellation for custom queries. This addresses Issue #86. - Implement query cancellation for table content loads, filters, and sorts.
* Updates to the 'use monospaced font' preference, making it a lot more ↵stuconnolly2009-11-141-76/+50
| | | | consistent across all table views. Also includes live updating when the preference is changed as well as its implementation in the query console, process list and variables table views.
* Set keyboard shortcut for Delete button in alert dialogs to command D.avenjamin2009-11-091-2/+4
| | | | Set keyboard shortcut for Truncate button in alert dialog to command T
* Switch buttons on delete index dialog.stuconnolly2009-11-091-3/+3
|
* When removing a field or index, use its name in the dialog message.stuconnolly2009-11-091-10/+11
|
* Don't run the add new index sheet modally, thus blocking the main thread. ↵stuconnolly2009-11-091-168/+194
| | | | Part of issue #357. Also some refactoring.
* When creating a new field of type BIT, allowing default values in BIT ↵stuconnolly2009-11-071-12/+14
| | | | notation. For example b'1'. Fixes #340.
* - Alter query start/stop notifications to apply to only the originating ↵rowanbeentje2009-11-051-4/+4
| | | | window, regardless of key state, by passing in and looking for the table document instance
* - Add task support to all the main interface viewsrowanbeentje2009-11-041-9/+6
| | | | | | | | - Improve task support on previously supported views - Use a threaded task load for all initial table loads - Support threaded task loads for table content loads, reloads, sorts, and filters - Improve upon previous threaded task loads by minimising view updates and supporting updates of the existing data arrays where valid
* Replace the multiple occurrences of hard coded toolbar identifiers for the ↵stuconnolly2009-10-281-2/+2
| | | | main toolbar with constants.
* Missing space when appending extra field info when creating a new field. ↵stuconnolly2009-10-271-0/+1
| | | | Fixes original problem reported in issue #445.
* Change the order of the cancel/remove buttons on the remove field dialog.stuconnolly2009-10-271-3/+3
|
* - Set up TableSource to respond to task notifications to prepare for ↵rowanbeentje2009-10-271-3/+75
| | | | | | | threaded queries - Alter task notifications to pass the TableDocument as the notification object so that only the current window responds to the notification, allowing other windows to be fully used while a window is performing a task
* Replace the use of hard coded preference keys with constants to prevent ↵stuconnolly2009-10-171-12/+13
| | | | issues such as the one fixed in revision 1419. All future preference usage should be done so using these constants.
* - When moving or editing table columns, preserve comments and any column ↵rowanbeentje2009-10-031-0/+29
| | | | | | | details which are currently unhandled (column formats, storage, references). This addresses the data loss part of Issue #180. - Parse out column comments in SPTableData to allow displaying or editing comments in future
* - Replaces uses of the deprecated selectRow:byExtendingSelection: with ↵rowanbeentje2009-09-021-7/+7
| | | | selectRowIndexes:byExtendingSelection:
* - The add, rename and copy table sheets should not block the main thread ↵stuconnolly2009-08-181-24/+44
| | | | | | | | (part of issue #357). - Improve the consistency of destructive confirmation dialogs by making the remove field and index dialogs default button 'Cancel' with a key equivalent of return. - Disable the remove field button when the currently selected table only has one field, removing the need for the extra check (and subsequent dialog) when the user attempts to remove a field.
* - Fix an errant NSLog in TableSourcerowanbeentje2009-08-011-2/+0
| | | | | | - Improve and make consistent state saving in TableContent; now saves filters and scroll position mor reliably on refresh/edit, and supports remembering and restoring which rows were selected - Significantly improve table history - only create entries for tables switches or filters, only remember 50 items, and save view/filters/scroll position/selections in table content view
* Put the table content filter in a split view so the field name drop down and ↵stuconnolly2009-08-011-19/+16
| | | | search field can be resized. Addresses issue #339.
* Improve TablesList significantly:rowanbeentje2009-07-281-1/+8
| | | | | | | | - If there are twenty or more tables, show a table quicksearch/filter at the top of the list, and update the rest of the code to match. This addresses issue #178. - Select tables and views alphabetically by user's current locale (instead of default MySQL "A B C a b c") - When adding or duplicating tables, insert them at the correct point - Fix a number of minor display bugs caused by incorrect interaction with the tables list caches
* Merge framework integration branch back to trunk. Summary of changes:stuconnolly2009-07-211-4/+3
| | | | | | | | | | | | | | | - Includes all custom code from subclasses CMMCPConnection and CMMCPResult, meaning they have subsequently been removed from the project. - All previous Sequel Pro specific code in the above subclasses has been removed in favour of the delegate (currently set to TableDocumet) informing the framework of such information. - All references to CMMCPConnection and CMMCPResult have subsequently been changed to MCPConnection and MCPResult. - Framework includes MySQL 5.1.36 client libraries and source headers. - Framework is now built as a 4-way (32/64 bit, i386/PPC arch) binary. - All import references to <MCPKit_bundled/MCPKit_bundled.h> have been changed to <MCPKit/MCPKit.h>. - New script 'build-mysql-client.sh' can be used to build the MySQL client libraries from the MySQL source. See the script's header for a list of available options or run it with no arguments to display it's usage. Note that there are still a few changes to be made to the framework with regard to removing Sequel Pro specific calls to the delegate. These however can be made later on as they have no effect on functionality and are merely design changes. Also, note that any future development done on the framework should be made to be as 'generic' as possible, with no Sequel Pro specific references. This should allow the framework to be integrated into another project without the need for SP specific code.
* - Make the DBView window the document window. This allows the document to ↵rowanbeentje2009-07-151-1/+2
| | | | | | | | | | be closed when the window is closed, freeing the document's memory - Update a number of dealloc methods to include more retained memory, and to avoid releasing non-retained memory - Remove notification observers and delegates where appropriate to avoid issues after document closing - Fix a couple of memory leaks - Support window cascading for all windows past the first, using the first window as the autosave window
* - Tweak tabbing in TableSource.m to behave correctly following r991 (see ↵rowanbeentje2009-07-071-3/+1
| | | | Issue #323 for notes)
* - Alter the "Allow Null" column in the source view to use a checkbox ↵rowanbeentje2009-07-071-15/+13
| | | | | | | | instead of an autocompleting combo cell. This addresses Issue #323. - Make the appearance of all checkbox columns consistent and disable automatic resizing with table - Correctly flush the CREATE TABLE and status caches on table structure changes to ensure the Extended Info tab is kept up to date with column changes
* small fix for add index sheet default behaviormtvee2009-07-021-1/+1
|
* Fix warnings caused by calls to validateMenuItem: being passed to NSObject ↵stuconnolly2009-07-021-1/+1
| | | | by returning YES by default.
* Add contextual menus to table structure and table index views. Part of issue ↵stuconnolly2009-07-021-0/+23
| | | | #139.
* - Make changes to the table structure flush the appropriate table data cachesrowanbeentje2009-06-241-8/+18
| | | | | | - SPTableData's columnWithName: now updates caches as necessary to avoid issues - Mark the extended table info view (particularly the CREATE TABLE syntax) as requiring update following table structure changes
* - We have always allowed setting "on update CURRENT_TIMESTAMP" for ↵rowanbeentje2009-06-241-0/+8
| | | | timestamp columns - parse out this information, and now also show if it's set in the structure view. Fixes the setting not appearing to work.
* - Fix default values behaviour - previously, default values weren't being ↵rowanbeentje2009-06-241-15/+15
| | | | saved. They are now.
* • fixed several problems for alerting an error sheet inside of a ↵Bibiko2009-06-231-3/+3
| | | | didEndSelector: of an other sheet
* • fixed issue while editing an field cell in Structure View select an ↵Bibiko2009-06-231-28/+36
| | | | | | | other table • fixed issue while moving a field description row in Structure View that "Extra" field content wasn't moved • fixed issue that "Extra" field content was appended without leading space in "addRowToDB"
* • fixed issue for showing an error alert sheet inside of a endSheet ↵Bibiko2009-06-231-6/+25
| | | | | | | | | selector of an other sheet: - introduced -(void)showErrorSheetWithTitle:(id)error -- error is an array of title and message - this can be called via [self performSelector:@selector(showErrorSheetWithTitle:) withObject: afterDelay:] - this avoids a crash of the current table window
* • some code cleaning and tiny performance enhancements for various ↵Bibiko2009-06-211-6/+9
| | | | for/while loops
* Fix for issue #285. Also tidy up the add/change row method including ↵stuconnolly2009-06-191-42/+83
| | | | friendlier error message dialogs.
* • in r801 the code for inserting a new field containing a PRIMARY KEY ↵Bibiko2009-06-171-9/+19
| | | | | | | after the selected one was commented out - it's fixed now - improved code to ensure that in this case AFTER ... will be only appended for a new field
* • fixed: "Duplicate field" will be disabled explicitly if selected table ↵Bibiko2009-06-161-4/+6
| | | | is not a BASE TABLE
* • changed the behaviour of the "Duplicate Field" button in TableSource:Bibiko2009-06-161-5/+12
| | | | - if no field definition is selected "Duplicate Field" copies the last field structure defined in the table
* • fixed: if the user tries to delete the last defined field in a given ↵Bibiko2009-06-161-0/+18
| | | | table show an alert saying that this isn't allowed
* Replace the change table type button with an edit button that switches the ↵stuconnolly2009-06-151-63/+4
| | | | current view to the table info pane.
* - Default the index type picker to INDEX if a primary key already exists on ↵rowanbeentje2009-06-131-1/+15
| | | | | | | the table (addresses #290) - Set the default focus correctly on the add index sheet
* • fixed issue that after changing the pref "Use monospaced fonts" the ↵Bibiko2009-06-101-1/+20
| | | | table structure view did not recognize the change after a reload
* - Replace TableSource use of a custom, flawed NSScanner-based parser with ↵rowanbeentje2009-06-101-29/+32
| | | | SPSQLParser usage - fixes errors like closing brackets (")") truncating ENUM/SET definitions
* - fixed bug with changing extra to auto_increment for a columnmtvee2009-06-031-1/+1
| | | | - small mem release issue in CMMCPConnection
* Redesigned table information pane.stuconnolly2009-05-271-2/+3
|
* • add AFTER clause only if the user added a new fieldBibiko2009-05-261-2/+2
| | | | - this should fix issue 280
* - Added ability to insert field/column in structure mode.avenjamin2009-05-201-5/+12
| | | | | - Inserts a field after the current selection or at the end if there is no field selected. - Resolves issue #30