开发者

how to save json value in sqlite database in iphone

开发者 https://www.devze.com 2023-03-12 14:27 出处:网络
hi friend this is my JSON file apitest[18318:207] { ErrorCode = 900; ErrorMessage = \"\"; Result = ( { DeviceInfoId = 12; Email = \"rocky@itg.com\"; FirstName = Rocky; LastName = Yadav; ProfileImage =

hi friend this is my JSON file apitest[18318:207] { ErrorCode = 900; ErrorMessage = ""; Result = ( { DeviceInfoId = 12; Email = "rocky@itg.com"; FirstName = Rocky; LastName = Yadav; ProfileImage = "<null>"; ThumbnailImage = "<null>"; UserId = 153; } ); TokenID = 59nUniliob; isError = 0; }

Can you please explain me how to parse the above JSON file and save the values in sqlite database开发者_StackOverflow this


You can use the SBJson parser to get a dictionary/array out of a json (depending on your response). You can then get the individual values from the dictionary/array and save them into your database.

The git repo also has some examples on how to use the parser.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号