> On Jun 1, 2015, at 12:29 PM, Michael Kay <[email protected]> wrote:
>
>>
>>
>> And BTW Michael, if SQL would be good for querying hierarchical data, why
>> in the world did we waste 16 years building XQuery !???
>
> It didn’t say it was good for the purpose. I said it was possible. The only
> reason I can think of for actually doing it is that there’s a fair bit of
> software out there that likes to access its data using SQL.
>>
The paper I wrote with Donald Kossmann in 1997 about mapping XML into relations
ALSO included the
SQL queries equivalent to the simplest XPath expressions.
Those SQL queries are HORRENDOUSLY complicated.
I don’t care how many tools use SQL.
Two things come to my mind:
1. Nobody will write such SQL queries (that result from the mapping JSON->
tables or XML -> tables) and
2. Even if you manage to write them somehow, the queries are SO complex, the
relational database engines are not capable
of dealing with them — not even Oracle.
(Jay here https://www.linkedin.com/profile/view?id=955015 wrote his PhD about
such SQL queries, and I think he wakes
up with nightmares even now…)
Tools will need to adapt to a new query language for JSON. Or we need new
tools. Or we abandon JSON.
That’s as simple as that.
Best regards
Dana
_______________________________________________
[email protected]
http://x-query.com/mailman/listinfo/talk