Don't query content table when not required

When only requesting the c_name field, limit the SQL query to the quick
table.
pull/201/head
Francis Lachapelle 2016-02-19 14:56:46 -05:00
parent 95d0a18c08
commit 7c00ad7110
1 changed files with 4 additions and 1 deletions

View File

@ -107,6 +107,7 @@ static GCSStringFormatter *stringFormatter = nil;
while ((field = [fields nextObject]))
{
fieldName = [field columnName];
if (![fieldName isEqualToString: @"c_name"])
[quickFieldNames addObject: fieldName];
}
@ -116,7 +117,9 @@ static GCSStringFormatter *stringFormatter = nil;
while ((field = [fields nextObject]))
{
fieldName = [field columnName];
[contentFieldNames addObject: fieldName];
if (![fieldName isEqualToString: @"c_name"])
[contentFieldNames addObject: fieldName];
}
folderId = [_folderId copy];