Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-7209

/update/json/docs carry forward fields from previous records

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.1, 6.0
    • Component/s: None
    • Labels:
      None

      Description

      example

      curl -H 'Content-type:application/json' 'http://localhost:8983/solr/foo/update/json/docs?split=/exams&echo=true&f=/**&indent=true&omitHeader=true' -d '
      {
      'first': 'John',
      'exams': [
      {'subject': 'Maths', 'test'   : 'term1', 'marks':90},
      {'subject': 'Biology', 'test'   : 'term1', 'marks':86}
      ]
      }
      {
      'first': 'Bob',
      'exams': [
      {'subject': 'Maths', 'test': 'term1', 'marks': 95
      }
      ,
      {
      'subject': 'Biology', 'test'   : 'term1', 'marks': 92}
      ]
      }'
      

      produces the following set of docs

      {
            "first":"John",
            "subject":"Maths",
            "test":"term1",
            "marks":90},
          {
            "first":"John",
            "subject":"Biology",
            "test":"term1",
            "marks":86},
          {
            "first":["John",
              "Bob"],
            "subject":"Maths",
            "test":"term1",
            "marks":95},
          {
            "first":["John",
              "Bob"],
            "subject":"Biology",
            "test":"term1",
            "marks":92}
      

        Attachments

          Activity

            People

            • Assignee:
              noble.paul Noble Paul
              Reporter:
              noble.paul Noble Paul
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: