Ersin Sevinc
2018-03-03 18:57:50 UTC
Hi there, m new at orient db trying to figure out something about relations
,
In this code Line => create edge owns from (select from Person where name =
'Matt') to (select from Car where model = 'Ferrari')
We have edge between record to record. Its fine for few records. But what
will happen if i ve millions of data ? Should i create edge from backend
for every new record?
Or can i just link the Property Fields like => create edge owns from
Person.Name to Car.model ??
I want to know that is there any possible way for relation database like
MSSQL , you know in ms sql , we can create PK and FK between Fields , with
that way we do not need to create relations for every new record.
Here another question -> select car.model person.name from car, person
Where .............................. I think i can not use 2 different
class after FROM m i right ?
,
In this code Line => create edge owns from (select from Person where name =
'Matt') to (select from Car where model = 'Ferrari')
We have edge between record to record. Its fine for few records. But what
will happen if i ve millions of data ? Should i create edge from backend
for every new record?
Or can i just link the Property Fields like => create edge owns from
Person.Name to Car.model ??
I want to know that is there any possible way for relation database like
MSSQL , you know in ms sql , we can create PK and FK between Fields , with
that way we do not need to create relations for every new record.
Here another question -> select car.model person.name from car, person
Where .............................. I think i can not use 2 different
class after FROM m i right ?
Hi,
Could you try
select name from Person where gender = 'M' and out('owns')[0].model =
"Ferrari" and out('likes')[0].mov_name = "Need For Speed"
Best regards,
Andrey Lomakin.
Orient Technologies
the Company behind OrientDB
Could you try
select name from Person where gender = 'M' and out('owns')[0].model =
"Ferrari" and out('likes')[0].mov_name = "Need For Speed"
Hi group,
I have below schema with three classes
orientdb {demo1}> select from Person
----+-----+-----+------+--------+---------
----+-----+-----+------+--------+---------
0 |#11:0|Matt |M |#12:0 |#13:0
1 |#11:1|Helen|F |#12:1 |#13:1
----+-----+-----+------+--------+---------
orientdb {demo1}> select from Car
----+-----+-------+-------
----+-----+-------+-------
0 |#12:0|Ferrari|#11:0
1 |#12:1|BMW |#11:1
----+-----+-------+-------
orientdb {demo1}> select from Movie
----+-----+--------------+--------
----+-----+--------------+--------
0 |#13:0|Need For Speed|#11:0
1 |#13:1|Matrix |#11:1
----+-----+--------------+--------
Person(name,gender)
Car(model)
Movie(mov_name)
Person > owns > Car
Person > likes > Movie
I'm looking at a query which matches values across three classes across
the edges
Find Person.name where Person.gender='M' and who owns Car.model='Ferrari'
and who likes Movie.mov_name='Need For Speed'
One way to achieve the same with gremlin is
For Speed').select(["x"])
I'm using OrientDB 1.7-rc2-SNAPSHOT..
Please help me with some pointers towards equivalent orientdb sql.
Thanks,
Mathew
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
--I have below schema with three classes
orientdb {demo1}> select from Person
----+-----+-----+------+--------+---------
----+-----+-----+------+--------+---------
0 |#11:0|Matt |M |#12:0 |#13:0
1 |#11:1|Helen|F |#12:1 |#13:1
----+-----+-----+------+--------+---------
orientdb {demo1}> select from Car
----+-----+-------+-------
----+-----+-------+-------
0 |#12:0|Ferrari|#11:0
1 |#12:1|BMW |#11:1
----+-----+-------+-------
orientdb {demo1}> select from Movie
----+-----+--------------+--------
----+-----+--------------+--------
0 |#13:0|Need For Speed|#11:0
1 |#13:1|Matrix |#11:1
----+-----+--------------+--------
Person(name,gender)
Car(model)
Movie(mov_name)
Person > owns > Car
Person > likes > Movie
I'm looking at a query which matches values across three classes across
the edges
Find Person.name where Person.gender='M' and who owns Car.model='Ferrari'
and who likes Movie.mov_name='Need For Speed'
One way to achieve the same with gremlin is
For Speed').select(["x"])
I'm using OrientDB 1.7-rc2-SNAPSHOT..
Please help me with some pointers towards equivalent orientdb sql.
Thanks,
Mathew
--
---
You received this message because you are subscribed to the Google Groups
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an
For more options, visit https://groups.google.com/d/optout.
Best regards,
Andrey Lomakin.
Orient Technologies
the Company behind OrientDB
--
---
You received this message because you are subscribed to the Google Groups "OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orient-database+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
---
You received this message because you are subscribed to the Google Groups "OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to orient-database+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.