diff options
author | Bibiko <bibiko@eva.mpg.de> | 2009-06-04 18:14:15 +0000 |
---|---|---|
committer | Bibiko <bibiko@eva.mpg.de> | 2009-06-04 18:14:15 +0000 |
commit | 57c25577a9c5ae66add3c30e1daf4e2bb5756a80 (patch) | |
tree | 9accfac6e4dcc3594b2e5e040f0d41cc89882a45 | |
parent | 65d479f8dc06cd41636c82479e28cf55346d490e (diff) | |
download | sequelpro-57c25577a9c5ae66add3c30e1daf4e2bb5756a80.tar.gz sequelpro-57c25577a9c5ae66add3c30e1daf4e2bb5756a80.tar.bz2 sequelpro-57c25577a9c5ae66add3c30e1daf4e2bb5756a80.zip |
• added the operator LIKE to numeric fields in the content browser
- this fixes issue 270
-rw-r--r-- | Source/TableContent.m | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/TableContent.m b/Source/TableContent.m index cc06902d..555b1a13 100644 --- a/Source/TableContent.m +++ b/Source/TableContent.m @@ -543,11 +543,16 @@ [argument setString:[[@"(" stringByAppendingString:argument] stringByAppendingString:@")"]]; break; case 7: + compareOperator = @"LIKE"; + doQuote = YES; + ignoreArgument = YES; + break; + case 8: compareOperator = @"IS NULL"; doQuote = NO; ignoreArgument = YES; break; - case 8: + case 9: compareOperator = @"IS NOT NULL"; doQuote = NO; ignoreArgument = YES; @@ -1124,7 +1129,7 @@ - (IBAction)setCompareTypes:(id)sender { NSArray *stringTypes = [NSArray arrayWithObjects:NSLocalizedString(@"is", @"popup menuitem for field IS value"), NSLocalizedString(@"is not", @"popup menuitem for field IS NOT value"), NSLocalizedString(@"contains", @"popup menuitem for field CONTAINS value"), NSLocalizedString(@"contains not", @"popup menuitem for field CONTAINS NOT value"), @"IN", nil]; - NSArray *numberTypes = [NSArray arrayWithObjects:@"=", @"≠", @">", @"<", @"≥", @"≤", @"IN", nil]; + NSArray *numberTypes = [NSArray arrayWithObjects:@"=", @"≠", @">", @"<", @"≥", @"≤", @"IN", @"LIKE", nil]; NSArray *dateTypes = [NSArray arrayWithObjects:NSLocalizedString(@"is", @"popup menuitem for field IS value"), NSLocalizedString(@"is not", @"popup menuitem for field IS NOT value"), NSLocalizedString(@"is after", @"popup menuitem for field AFTER DATE value"), NSLocalizedString(@"is before", @"popup menuitem for field BEFORE DATE value"), NSLocalizedString(@"is after or equal to", @"popup menuitem for field AFTER OR EQUAL TO value"), NSLocalizedString(@"is before or equal to", @"popup menuitem for field BEFORE OR EQUAL TO value"), nil]; NSString *fieldTypeGrouping = [NSString stringWithString:[[tableDataInstance columnWithName:[[fieldField selectedItem] title]] objectForKey:@"typegrouping"]]; |