Loading ...
Sorry, an error occurred while loading the content.

Re: [json] SQL for JSON?

Expand Messages
  • Matthew Morley
    JSON is a data-interchange format, so unless your talking about building something that does a search through the raw strings, I m pretty sure that doing a
    Message 1 of 11 , Feb 10, 2007
    • 0 Attachment
      JSON is a data-interchange format, so unless your talking about building
      something that does a search through the raw strings, I'm pretty sure that
      doing a search through the native language equivalent would be faster.

      If you are working in an environment where the JSON consumer is a web
      browser, let the server do the heavy lifting and pass you the matches. If
      you really need the local ability to search or are doing non-browser
      exchanges, I am sure there exists generic functions to search through sets
      of data and match criteria. The real question is which language you are
      doing it in, and is it worth the overhead and complication.

      --
      Matthew P. C. Morley
      MPCM Technologies Inc.


      [Non-text portions of this message have been removed]
    • george.jempty
      ... matches. If ... through sets ... Baloney. The real question is the OP s original question: Has anyone played with a way to find parts of a JSON structure
      Message 2 of 11 , Feb 10, 2007
      • 0 Attachment
        --- In json@yahoogroups.com, "Matthew Morley" <WickedLogic@...> wrote:
        > If you are working in an environment where the JSON consumer is a web
        > browser, let the server do the heavy lifting and pass you the
        matches. If
        > you really need the local ability to search or are doing non-browser
        > exchanges, I am sure there exists generic functions to search
        through sets
        > of data and match criteria. The real question is which language you are
        > doing it in, and is it worth the overhead and complication.

        Baloney. The real question is the OP's original question: "Has anyone
        played with a way to find parts of a JSON structure like SQL?" This
        is not an unreasonable question: in fact its been considered by
        renowned Python/XML expert Uche Ogbuji; see
        http://copia.ogbuji.net/blog/2006-12-23/Why_JSON_v
        where he imagines "XQuery for JSON". By the way, a link to this very
        same article can be found at the bottom of json.org.
      • Matthew Morley
        ... Agreed, mostly. But I am not sure the case is as strong for xquery for json as it is with xml, though I can definitely see a use for it. Selectively
        Message 3 of 11 , Feb 10, 2007
        • 0 Attachment
          On 2/10/07, george.jempty <george.jempty@...> wrote:
          > Baloney. The real question is the OP's original question: "Has anyone
          > played with a way to find parts of a JSON structure like SQL?" This
          > is not an unreasonable question: in fact its been considered by
          > renowned Python/XML expert Uche Ogbuji; see
          > http://copia.ogbuji.net/blog/2006-12-23/Why_JSON_v
          > where he imagines "XQuery for JSON". By the way, a link to this very
          > same article can be found at the bottom of json.org.

          Agreed, mostly.

          But I am not sure the case is as strong for xquery for json as it is
          with xml, though I can definitely see a use for it. Selectively
          plucking data from a stream that you do not control or do not want to
          control is very appealing and probably useful. But at that point why
          not just do the same methods on the native language translation?

          One way your search through strings, translate subsections, then
          provide those back as native objects. The other you translate it all,
          then search against native objects to return subset of native objects.

          --
          Matthew P. C. Morley
          MPCM Technologies Inc.
        • Alexey Luchkovsky
          ... you are ... JsonTools included solution for client lookup JSON data, you can find parts of a JSON structure, if you need concrete decision, send e-mail me.
          Message 4 of 11 , Feb 26, 2007
          • 0 Attachment
            --- In json@yahoogroups.com, "george.jempty" <george.jempty@...> wrote:
            >
            > --- In json@yahoogroups.com, "Matthew Morley" <WickedLogic@> wrote:
            > > If you are working in an environment where the JSON consumer is a web
            > > browser, let the server do the heavy lifting and pass you the
            > matches. If
            > > you really need the local ability to search or are doing non-browser
            > > exchanges, I am sure there exists generic functions to search
            > through sets
            > > of data and match criteria. The real question is which language
            you are
            > > doing it in, and is it worth the overhead and complication.
            >
            > Baloney. The real question is the OP's original question: "Has anyone
            > played with a way to find parts of a JSON structure like SQL?" This
            > is not an unreasonable question: in fact its been considered by
            > renowned Python/XML expert Uche Ogbuji; see
            > http://copia.ogbuji.net/blog/2006-12-23/Why_JSON_v
            > where he imagines "XQuery for JSON". By the way, a link to this very
            > same article can be found at the bottom of json.org.
            >

            JsonTools included solution for client lookup JSON data, you can find
            parts of a JSON structure, if you need concrete decision, send e-mail me.
          • Anand Sadasivam
            Hi, Check out this... http://trimpath.com/project/wiki/TrimQuery you can see the demo right here... http://trimpath.com/demos/test1/trimpath/query_demo.html .
            Message 5 of 11 , Feb 28, 2007
            • 0 Attachment
              Hi,

              Check out this...

              http://trimpath.com/project/wiki/TrimQuery

              you can see the demo right here...
              http://trimpath.com/demos/test1/trimpath/query_demo.html .


              Hope this helps.

              Regards,
              Anand.S


              On 2/26/07, Alexey Luchkovsky <luchkovsky@...> wrote:
              >
              > --- In json@yahoogroups.com <json%40yahoogroups.com>, "george.jempty" <
              > george.jempty@...> wrote:
              > >
              > > --- In json@yahoogroups.com <json%40yahoogroups.com>, "Matthew Morley"
              > <WickedLogic@> wrote:
              > > > If you are working in an environment where the JSON consumer is a web
              > > > browser, let the server do the heavy lifting and pass you the
              > > matches. If
              > > > you really need the local ability to search or are doing non-browser
              > > > exchanges, I am sure there exists generic functions to search
              > > through sets
              > > > of data and match criteria. The real question is which language
              > you are
              > > > doing it in, and is it worth the overhead and complication.
              > >
              > > Baloney. The real question is the OP's original question: "Has anyone
              > > played with a way to find parts of a JSON structure like SQL?" This
              > > is not an unreasonable question: in fact its been considered by
              > > renowned Python/XML expert Uche Ogbuji; see
              > > http://copia.ogbuji.net/blog/2006-12-23/Why_JSON_v
              > > where he imagines "XQuery for JSON". By the way, a link to this very
              > > same article can be found at the bottom of json.org.
              > >
              >
              > JsonTools included solution for client lookup JSON data, you can find
              > parts of a JSON structure, if you need concrete decision, send e-mail me.
              >
              >
              >
              >



              --
              Anand.S
              anand.sadasivam@...
              +91 99804 75305


              [Non-text portions of this message have been removed]
            • Alexey Luchkovsky
              TrimQuery solution is right pretty, but.... not for tree-based structures. Visitor pattern and XPATH on XML realy designed for tree. Before I decide on Visitor
              Message 6 of 11 , Mar 1, 2007
              • 0 Attachment
                TrimQuery solution is right pretty, but.... not for tree-based
                structures.

                Visitor pattern and XPATH on XML realy designed for tree.
                Before I decide on Visitor I have seen JavaScript XPATH library
                written by Steffen Meschkat <mesch@...>. It's realy titanic
                solution, but it's designed for XML.

                Enter Visitor:
                function visit(aTree, anAcceptor, aVisitProcessor)

                I proceed from the assumption:
                - 90% tasks are based on search by equals or like.
                - 10% tasks can be realized by custom "acceptor" and/or custom "visit
                processor"

                Moreover, Visitor allowed to modify tree so well as search from them.
                For example, I can design code, that removed from JSON data structure
                all persons whose birth day arrived on full Moon (20 lines of code).

                Java Visitor on Tree vs. Events named Digester
                http://jakarta.apache.org/commons/digester/

                Resume:
                Of course Visitor is not competed with SQL (especially on server with
                indexes, cache etc), Visitor is not a rival for XPATH on XML.

                TrimQuery solution is very good and very helpful, but for JSON
                JsonTools is preffered more...
                http://sourceforge.net/projects/jsontools.

                Regards, Alexey Luchkovsky

                --- In json@yahoogroups.com, "Anand Sadasivam" <anand.sadasivam@...>
                wrote:
                >
                > Hi,
                >
                > Check out this...
                >
                > http://trimpath.com/project/wiki/TrimQuery
                >
                > you can see the demo right here...
                > http://trimpath.com/demos/test1/trimpath/query_demo.html .
                >
                >
                > Hope this helps.
                >
                > Regards,
                > Anand.S
                >
                >
                > On 2/26/07, Alexey Luchkovsky <luchkovsky@...> wrote:
                > >
                > > --- In json@yahoogroups.com <json%40yahoogroups.com>,
                "george.jempty" <
                > > george.jempty@> wrote:
                > > >
                > > > --- In json@yahoogroups.com <json%40yahoogroups.com>, "Matthew
                Morley"
                > > <WickedLogic@> wrote:
                > > > > If you are working in an environment where the JSON consumer
                is a web
                > > > > browser, let the server do the heavy lifting and pass you the
                > > > matches. If
                > > > > you really need the local ability to search or are doing
                non-browser
                > > > > exchanges, I am sure there exists generic functions to search
                > > > through sets
                > > > > of data and match criteria. The real question is which language
                > > you are
                > > > > doing it in, and is it worth the overhead and complication.
                > > >
                > > > Baloney. The real question is the OP's original question: "Has
                anyone
                > > > played with a way to find parts of a JSON structure like SQL?" This
                > > > is not an unreasonable question: in fact its been considered by
                > > > renowned Python/XML expert Uche Ogbuji; see
                > > > http://copia.ogbuji.net/blog/2006-12-23/Why_JSON_v
                > > > where he imagines "XQuery for JSON". By the way, a link to this very
                > > > same article can be found at the bottom of json.org.
                > > >
                > >
                > > JsonTools included solution for client lookup JSON data, you can find
                > > parts of a JSON structure, if you need concrete decision, send
                e-mail me.
                > >
                > >
                > >
                > >
                >
                >
                >
                > --
                > Anand.S
                > anand.sadasivam@...
                > +91 99804 75305
                >
                >
                > [Non-text portions of this message have been removed]
                >
              Your message has been successfully submitted and would be delivered to recipients shortly.