-
Notifications
You must be signed in to change notification settings - Fork 871
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to get records without meta-information? Exclude: @type, @version, etc... #6913
Comments
help |
hi @rcdiaz, No is not possible to get out record without metadata, this are needed to reassociate the persistent data in case of update. Bye |
HI @tglman for which case I need this metadata on client side and whats in the case of temporary rids? You don't need them for anywhere. |
hi All, Temporary rids are used in many places to reassociate references and define an unique identifier for each item of result of a projection query, as today the data structures of a projection query are the same of a persistent result set. This cannot be changed right now. In any case we may evolve with new api that not require this in formation in case of projections, but nothing possible yet. |
Hi @tglman Would not it be possible to create this structure and retrieve "@type": "d", I am trying with the json function but I have the same problem: select value from prueba select value.toJson() from prueba |
hi @rcdiaz, The result set of a query in orient is a document, you cannot remove the metadata from it. Regards |
Quick update on this, in V 3.0 projections won't have record metadata anymore. See http://orientdb.com/docs/3.0.x/sql/SQL-Projections.html Thanks Luigi |
Can I get records without this parameters?
"@type": "d",
"@Rid": "#21:2",
"@Version": 1,
"@Class": "EHR",
notification": "Query executed in 0.066 sec. Returned 3 record(s)"
I have tried with:
select expand(@this.exclude('@type','@Rid','@Version','@Class')) from v
But only omits rid and class:
`select * from pueblo
{
"result": [
{
"@type": "d",
"@Rid": "#67:0",
"@Version": 1,
"@Class": "pueblo",
"name": "malagon"
},
{
"@type": "d",
"@Rid": "#68:0",
"@Version": 1,
"@Class": "pueblo",
"name": "pozuelo"
},
{
"@type": "d",
"@Rid": "#69:0",
"@Version": 1,
"@Class": "pueblo",
"name": "valenzuela"
}
],
"notification": "Query executed in 0.038 sec. Returned 3 record(s)"
}
select expand(@this.exclude('@type','@Rid','@Version','@Class')) from pueblo
{
"result": [
{
"@type": "d",
"@Version": 1,
"name": "malagon"
},
{
"@type": "d",
"@Version": 1,
"name": "pozuelo"
},
{
"@type": "d",
"@Version": 1,
"name": "valenzuela"
}
],
"notification": "Query executed in 0.039 sec. Returned 3 record(s)"
}`
The text was updated successfully, but these errors were encountered: