Skip to content

Instantly share code, notes, and snippets.

@iluvcapra
iluvcapra / NSPredicate2SQL.mm
Last active October 3, 2020 23:08
Convert an NSPredicate to a SQL WHERE clause
static NSString *SQLNullValueString = [[NSString alloc] initWithString:@"NULL"];
/* Prototypes */
NSString *SQLWhereClauseForPredictate(NSPredicate *predicate);
NSString *SQLExpressionForNSExpression(NSExpression *expression);
/* Implementation */