0

YQL showing results from multiple sources

select * from people

    <root>
    <row>
      <name>a</name>
      <address>address1</address>
      <loc_id>1</loc_id>
    </row>
    <row>
      <name>b</name>
      <address>address2</address>
      <loc_id>2</loc_id>
    </row>
    </root>

select * from locations

    <root>
    <row>
      <id>1</id>
      <name>location1</name>
      <details>locationdetails1</details>
    </row>
    <row>
      <id>2</id>
      <name>location2</name>
      <details>locationdetails2</details>
    </row>
    </root>

Is there anyway in YQL where we can join both these data sources on people.loc_id<->location.id and return a result that includes all the values together. I know there is a possibility of naming conflicts but anyway of resolving that too? So basically any yql query that might help return results like below or something similar.

    <root>
    <row>
      <name>a</name>
      <address>address1</address>
      <loc_id>1</loc_id>
      <location.id>1</location.id>
      <location.name>location1</location.name>
      <location.details>locationdetails1</location.details>
    </row>
    <row>
      <name>b</name>
      <address>address2</address>
      <loc_id>2</loc_id>
      <location.id>2</location.id>
      <location.name>location2</location.name>
      <location.details>locationdetails2</location.details>
    </row>
    </root>

Cross-posted at stackoverflow

by
0 Replies

Recent Posts

in YQL