10
有一種簡單的方式來獲得一個executeQuery:SELECT * ...
的FMDB結果很容易變成一本字典?FMDB結果集到字典
FMResultSet *appointmentResults = [[DataClass getDB] executeQuery:@"SELECT * FROM Appointments WHERE date = ?",currDateString];
while ([appointmentResults next]) {
//Create dictionary
//Add dictionary to array for later use
}
我想知道是否有一種方法可以使字典鍵列名和值列值。最好不必在時間內的每一行做一個循環。
太棒了!你從哪裏得到這個?查看FMDB文檔resultDict不在那裏。 – Bot 2012-02-23 02:18:44
@jostster它在'FMResultSet.h'中。 – 2012-02-23 02:30:03
'-resultDict'已被棄用,請改用'-resultDictionary'。 – lucianf 2012-05-21 09:24:37