the default of attribute in coredata
I did versioning and I added a new attribute of type string
it will be empty at first I want to create a predicate to check for the empty attribute I tried
[fetchRequest setPredicate:[NSPredicate predicateWithFormat:
@"( SeriesStudyID == 开发者_JAVA技巧'""' )" ]];
but it doesn't work
what's the default of this attribute and how to detect the empty
SeriesStudyID is NSString
if ([SeriesStudyID length]<=0) {
NSLog(@"empty");
}
else {
NSLog(@"not empty");
}
精彩评论