Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-17872

TAP returns incorrect column type when SELECT contains math

    XMLWordPrintable

Details

    • Story
    • Status: To Do
    • Resolution: Unresolved
    • None
    • dax
    • None

    Description

      When I submit the query 

      SELECT ra, decl, w1mag, w1mag - w2mag FROM wise_00.allwise_p3as_psd
      WHERE qserv_areaspec_circle(283.831250,-30.545278,0.20)=1

      through pyvo, the values in the result column "w1mag - w2mag" are all strings instead of floats. Manipulating the results with pandas seems to kind of work anyways, but it becomes excruciatingly slow.

      I can check what the XML looks like with:

      query_string = ("SELECT ra, decl, w1mag, w1mag - w2mag FROM wise_00.allwise_p3as_psd "
      {{ "WHERE qserv_areaspec_circle(283.831250,-30.545278,0.20)=1 ")}}
      query = pyvo.dal.TAPQuery(query=query_string, baseurl='http://lsst-lsp-stable.ncsa.illinois.edu/api/tap')
      res = query.execute_stream()
      res_str = res.read()
      res_str[:1500]

      and I see: 

      <FIELD name="w1mag - w2mag" datatype="char" arraysize="*" />

       

       

      Attachments

        Issue Links

          Activity

            People

              cbanek Christine Banek
              ctslater Colin Slater
              Frossie Economou
              Christine Banek, Colin Slater, Fritz Mueller, Frossie Economou, Gregory Dubois-Felsmann
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:

                Jenkins

                  No builds found.