Uploaded image for project: 'HPCC'
  1. HPCC
  2. HPCC-12850

Roxie service drops empty columns when returning data from an index

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Not specified
    • Resolution: Duplicate
    • Affects Version/s: 5.0.2
    • Fix Version/s: None
    • Component/s: ESP
    • Labels:
      None

      Description

      When I return data from an index via a roxie service, if all the data in a column in the filtered dataset being returned is empty, that column is dropped from the json/xml returned from roxie.

      If even one record has a value in this column, all columns are returned.

      My service consumer is expecting all index fields to exist, with empty fields being empty, in the json being returned.

      Example service soap call:
      <?xml version="1.0" encoding="utf-8"?>
      <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
      <soap:Body>
      <drealeed_testcleanpersonnameprefix.ins002_serviceRequest xmlns="urn:hpccsystems:ecl:drealeed_testcleanpersonnameprefix.ins002_service">
      <roxieserviceurl/>
      <refresh>1</refresh>
      <home_clean_fname_changed>0</home_clean_fname_changed>
      <home_clean_fname/>
      </drealeed_testcleanpersonnameprefix.ins002_serviceRequest>
      </soap:Body>
      </soap:Envelope>

      In the result, VIew_FnameDetails should have a home_clean_fname field, but because all the records returned with the above query have the row empty, it's not in the xml. (It does show up in the esp form for this Roxie query.

      <Dataset xmlns="urn:hpccsystems:ecl:drealeed_testcleanpersonnameprefix.ins002_service:result:view_fnamedetails" name="View_FnameDetails">
      <Row>
      <home_clean_lname>BENNETT</home_clean_lname>
      <home_cnt>1</home_cnt>
      </Row>
      <Row>
      <home_clean_lname>DE VALOIS</home_clean_lname>
      <home_cnt>1</home_cnt>
      </Row>

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                afishbeck Anthony Fishbeck
                Reporter:
                drealeed Drea Leed
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: