Monday 15 June 2015

orientdb - Renaming existing edge relationships? -



orientdb - Renaming existing edge relationships? -

is there simple way update name of of type of existing border relationships?

alter class edge_name name new_edge_name

updates name of base of operations border class, doesn't impact existing relationships.

ie:

create class person extends v create class auto extends v create class owns extends e create vertex person set name="bob" create vertex auto set name="jeep" create border owns (select person name="bob") (select auto name="jeep") alter class owns name drives

does nil delete old border type , create new border type, leaving existing relationship unaffected (bob still owns jeep, yet owns doesn't exist)

what supposed if thousands of these relationships exist?

you should rename attributes next commands re-create new name , drop previous ones both in , out directions:

update v set out_drives = out_owns out_owns not null update v set in_drives = in_owns in_owns not null update v remove out_owns out_owns not null update v remove in_owns in_owns not null

orientdb

No comments:

Post a Comment