Maybe you could use user defined functions with this goal. Documentation available at this link: https://docs.arangodb.com/3.2/AQL/Extending/
Functions at ArangoDB are very limited, but I think this is a good situation that fits into the DB user functions features. Retrieved from ArangoDB website: To add missing functionality or to simplify queries, users may add their own functions to AQL in the selected database. These functions are written in JavaScript, and are deployed via an API; see Registering Functions <https://docs.arangodb.com/3.2/AQL/Extending/Functions.html>. Em quinta-feira, 21 de setembro de 2017 04:38:48 UTC-3, Amit S escreveu: > > I have 4 documents Alpha,Alpha1,Alpha2 and Alpha3. I have to fetch > details for key "MNO". is there any direct way to fetch the "MNO" Or I have > manually to traverse to each document like in below query > > For doc in collection > Return ("MNO Data": doc.Alpha.ABC.DEF['2017']['GHI JKL'].MNO) > > > "Alpha": > {"ABC": > {"DEF": > {"2017": > {"GHI JKL": > {"MNO": > ["ABCDEFGHIJKLMNOP"]}}, > {"TGY BUG": > {"MNO": > ["1234567891012456"]}}}}} > "Alpha1": > {"XYZ": > {"TUW": > {"2014": > {"QRS PQR": > {"MNO": > ["ZYXWUTSRQPONML"]}}}}} > "Alpha2": > {"KJM": > {"LKI": > {"2005": > {"MNO": > ["POLKIKJUMNHY"]}}} > > "Alpha3": > {"WWW": > {"CCC DDD": > {"2011": > {"MNO": > {"POLKIKJUMNHY":"value"}}}}} > > -- You received this message because you are subscribed to the Google Groups "ArangoDB" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
