Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7623633
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T04:45:20+00:00 2026-05-31T04:45:20+00:00

I was just trying to parse a JSON-Object which includes a 2-dimensional array. Example:

  • 0

I was just trying to parse a JSON-Object which includes a 2-dimensional array.

Example:

{
  "2dimarray": [
                 [{"key": "val"}, {"key": "val"}],
                 [{"key": "val"}, {"key": "val"}]
               ]
}

Assuming the contents of 2dimarray[x][y] are only of one type, I added the mapping:

[objectMapping mapKeyPath:@"2dimarray" toRelationship:@"2dimarray" withMapping: myMappingForIncludedObjects];

In the log RestKit tells me:

W restkit.object_mapping:RKObjectMappingOperation.m:438 WARNING: Detected a relationship mapping for a collection containing another collection. This is probably not what you want. Consider using a KVC collection operator (such as @unionOfArrays) to flatten your mappable collection.

But actually it is what I want. Basicly I assumed that the object mapper would fill my Objective-C property NSArray* 2dimarray with NSArray*s that include objects that are mapped with myMappingForIncludedObjects. Instead, each array is mapped (which fails, of course) with myMappingForIncludedObjects.

What am I doing wrong? Or better: What do I need to do to archive the behavior I expected?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T04:45:22+00:00Added an answer on May 31, 2026 at 4:45 am

    I believe that the issue you cite is Blake explaining the problem, not a solution. I don’t think RestKit is set up to handle the mapping that you describe (an array of arrays of objects). You can walk through an example of what he describes in the issue as well as looking at his commit, and you’ll see that the introduced logic was aimed at detecting the problem and logging it for debugging purposes.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to parse JSON string using Boost Spirit store JSON object into recursive
I am trying to retrieve data in a JSON object (which I have validated
I'm just trying to parse a simple JSON string in the following format: [X,Y,Z]
i'm trying to make a very simple YACC parser on Pascal language which just
I'm using wikitools package to parse the wikipedia. I just copy this example from
Possible Duplicate: Selecting a JSON object with a colon in the key I apologize
I'm trying to parse some JSON using the JSon.Net library. The documentation seems a
I am trying to parse the following JSON data, but it seems that it
I'm trying to parse a simple JSON file. I'm very new to javascript, JSON,
I'm trying to parse a simple JSON file. I'm very new to javascript, JSON,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.