aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPTableStructureDelegate.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/SPTableStructureDelegate.m')
-rw-r--r--Source/SPTableStructureDelegate.m3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/SPTableStructureDelegate.m b/Source/SPTableStructureDelegate.m
index d63064e2..17ad817d 100644
--- a/Source/SPTableStructureDelegate.m
+++ b/Source/SPTableStructureDelegate.m
@@ -116,9 +116,10 @@
isCurrentExtraAutoIncrement = [[[anObject stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] uppercaseString] isEqualToString:@"AUTO_INCREMENT"];
if(isCurrentExtraAutoIncrement) {
[currentRow setObject:[NSNumber numberWithInteger:0] forKey:@"null"];
+
// Asks the user to add an index to query if AUTO_INCREMENT is set and field isn't indexed
if ((![currentRow objectForKey:@"Key"] || [[currentRow objectForKey:@"Key"] isEqualToString:@""])) {
- [chooseKeyButton selectItemAtIndex:0];
+ [chooseKeyButton selectItemWithTag:SPPrimaryKeyMenuTag];
[NSApp beginSheet:keySheet
modalForWindow:[tableDocumentInstance parentWindow] modalDelegate:self