[ 
https://issues.apache.org/jira/browse/VXQUERY-222?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Christina Pavlopoulou updated VXQUERY-222:
------------------------------------------
    Description: 
I tried to run the following query:
let $collection := "vxquery-xtest/src/test/resources/TestSources/ghcnd"
for $r in collection($collection)/dataCollection/data
return {
                        "date": data($r/date),
                        "datatype": data($r/dataType),
                        "station": data($r/station),
                        "attributes": ",,",
                        "value": data($r/value)
                }

The result I got was not serialized correctly since the values of the object 
were without quotes.

This is the result I get:
{noformat}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
{noformat}


  was:
I tried to run the following query:
let $collection := "vxquery-xtest/src/test/resources/TestSources/ghcnd"
for $r in collection($collection)/dataCollection/data
return {
                        "date": data($r/date),
                        "datatype": data($r/dataType),
                        "station": data($r/station),
                        "attributes": ",,",
                        "value": data($r/value)
                }

The result I got was not serialized correctly since the values of the object 
were without quotes.


> Json Serialization
> ------------------
>
>                 Key: VXQUERY-222
>                 URL: https://issues.apache.org/jira/browse/VXQUERY-222
>             Project: VXQuery
>          Issue Type: Bug
>            Reporter: Christina Pavlopoulou
>            Assignee: Riyafa Abdul Hameed
>
> I tried to run the following query:
> let $collection := "vxquery-xtest/src/test/resources/TestSources/ghcnd"
> for $r in collection($collection)/dataCollection/data
> return {
>                       "date": data($r/date),
>                       "datatype": data($r/dataType),
>                       "station": data($r/station),
>                       "attributes": ",,",
>                       "value": data($r/value)
>               }
> The result I got was not serialized correctly since the values of the object 
> were without quotes.
> This is the result I get:
> {noformat}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {"date":2004-04-04T00:00:00.000,"datatype":PRCP,"station":GHCND:US000000004,"attributes":",,","value":40}
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to