May I ask you what you mean with personID and postID? Well I now tried:
CREATE edge hasPost FROM person.id To post.id Because it's nearly the form of the LINK query. But that just gives me: java.lang.IllegalArgumentException: Argument 'person.id' is not a RecordId in form of string. Format must be: Here is a picture of the whole data: http://i.imgur.com/oELqp4i.png Ignore the LINK in the picture. So as you can see. I want to link (or let's say create an edge) from #14:1 to #13:1 to say that that Person has a post. Just ask if something is unclear =) Am Freitag, 22. August 2014 18:44:58 UTC+2 schrieb Alex Gann: > > Are you trying to run one CREATE statement that would create edges for > every pre-existing relationship between your person and post classes? > > If you're creating an edge I would think you need to know the specific > person(s) and post(s) you're trying to link ahead of time, and then use > something like: > > create edge hasAppIn from (select from person where id = personId) to (select > from post where id = postId > ) > > from: > http://www.orientechnologies.com/docs/1.7.8/orientdb.wiki/SQL-Create-Edge.html > > Hope that helps! > > > On Thursday, August 21, 2014 2:00:58 PM UTC-4, Curtis Mosters wrote: >> >> I just did it with: >> >> CREATE LINK out_hasAppln TYPE linkset FROM person.id To post.id >> CREATE LINK in_hasAppln TYPE linkset FROM post.id To person.id >> >> But for sure it's a link and not a edge. But maybe this could work. And >> now I search for those LINK and on every of them I create an EDGE. Wow this >> is very crappy but until it does not work it seems to be the best approach. >> ;) >> >> Am Donnerstag, 21. August 2014 15:36:07 UTC+2 schrieb Curtis Mosters: >>> >>> How is it possible to create an edge for creating a relationship between >>> *person >>> *and *post*. >>> >>> CREATE edge hasAppln FROM (select FROM person) TO (select FROM post) >>> >>> I already tried it with >>> >>> CREATE edge hasAppln FROM (select FROM person) TO (select FROM post) >>> where person.id = post.id >>> >>> but it just combines everything. Let's say I have in both table 2 >>> entries, so I get 4 edges. The Where is completely ignored somehow. Another >>> thing is that this query on 4 entries takes 0,2 seconds. So this is not >>> practicable. Is there another way to do that? >>> >> <http://i.imgur.com/oELqp4i.png> -- --- 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 [email protected]. For more options, visit https://groups.google.com/d/optout.
