aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPFieldMapperController.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/SPFieldMapperController.m')
-rw-r--r--Source/SPFieldMapperController.m5
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/SPFieldMapperController.m b/Source/SPFieldMapperController.m
index ac6f46e7..171155d7 100644
--- a/Source/SPFieldMapperController.m
+++ b/Source/SPFieldMapperController.m
@@ -819,7 +819,9 @@
[fieldMappingTableColumnNames removeAllObjects];
[fieldMappingTableDefaultValues removeAllObjects];
[fieldMappingTableTypes removeAllObjects];
+
BOOL serverGreaterThanVersion4 = ([mySQLConnection serverMajorVersion] >= 5) ? YES : NO;
+
if([importFieldNamesHeaderSwitch state] == NSOnState) {
for(id h in NSArrayObjectAtIndex(fieldMappingImportArray, 0)) {
[fieldMappingTableColumnNames addObject:h];
@@ -1010,6 +1012,7 @@
// Retrieve the server-supported encodings and add them to the menu
NSArray *encodings = [databaseDataInstance getDatabaseCharacterSetEncodings];
NSString *utf8MenuItemTitle = nil;
+
if ([encodings count] > 0
&& ([mySQLConnection serverMajorVersion] > 4
|| ([mySQLConnection serverMajorVersion] == 4 && [mySQLConnection serverMinorVersion] >= 1)))
@@ -1032,7 +1035,6 @@
}
[newTableInfoEncodingPopup selectItemWithTitle:[prefs objectForKey:SPLastImportIntoNewTableEncoding]];
-
}
[NSApp beginSheet:newTableInfoWindow
@@ -1047,7 +1049,6 @@
- (IBAction)addGlobalSourceVariable:(id)sender
{
-
addGlobalSheetIsOpen = YES;
[NSApp beginSheet:globalValuesSheet