Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support XML reoccurring structures #593

Merged
merged 1 commit into from
Aug 23, 2018
Merged

Conversation

dadoonet
Copy link
Owner

When you have an xml structure like:

<dataset>
  <object>
    <id>1</id>
    <name>foo</name>
  </object>
  <object>
    <id>2</id>
    <name>bar</name>
  </object>
</dataset>

It should create a document like:

{
    "object": [{
        "id": 1,
        "name": "foo"
      },
      {
        "id": 2,
        "name": "bar"
      }
    ]
}

Before this patch, the created document was:

{
  "object" : {
    "id" : 2,
    "name" : "bar"
  }
}

So first items were totally overwritten.

Closes #592.

When you have an xml structure like:

```xml
<dataset>
  <object>
    <id>1</id>
    <name>foo</name>
  </object>
  <object>
    <id>2</id>
    <name>bar</name>
  </object>
</dataset>
```

It should create a document like:

```json
{
    "object": [{
        "id": 1,
        "name": "foo"
      },
      {
        "id": 2,
        "name": "bar"
      }
    ]
}
```

Before this patch, the created document was:

```json
{
  "object" : {
    "id" : 2,
    "name" : "bar"
  }
}
```

So first items were totally overwritten.

Closes #592.
@dadoonet dadoonet added the bug For confirmed bugs label Aug 23, 2018
@dadoonet dadoonet self-assigned this Aug 23, 2018
@dadoonet dadoonet added this to the 2.6 milestone Aug 23, 2018
@dadoonet dadoonet merged commit 922f46a into master Aug 23, 2018
@dadoonet dadoonet deleted the fix/592-xml-uncomplete branch August 23, 2018 16:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug For confirmed bugs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant