Hi again, I created a server-side javascript function to go over a set of "relationships", check for inconsistencies and create the required cleanup SQL commands for making the graph consistent again. It will work for both materialized and lightweight edges.
It's available as a gist if anyone wants to reuse it: https://gist.github.com/davide/8161038 Cheers, Davide On Friday, December 27, 2013 8:28:00 AM UTC, Andrey Lomakin wrote: > > Hi, > All these fields you listed are Set instances, so you can go through > records, try to load records pointed by links and remove links if they > point to deleted vertexes. > > > On Fri, Dec 27, 2013 at 6:15 AM, Davide Marquês <[email protected]<javascript:> > > wrote: > >> Hi all, >> >> Is there any built-in script to clean up lightweight edges that are >> pointing to deleted vertexes? >> I caught a few NullPointerExceptions that were caused when trying to load >> those old vertexes. >> >> So far the only way I found to [gradually] place the database into a >> coherent state is removing the vertex entries one by one (as the NPE pop >> up) with the SQL command: >> >> update Account remove addresses = <deleted_vertex_rid> >> >> Is there any way to select the deleted vertexes from the various >> out_REL1, in_REL1, out_REL2, in_REL2 fields and remove them in one go? >> >> Welcoming any thoughts or tips on how to proceed (I promise not to use >> the document API to mess around with graph databases again!). :) >> >> Thanks in advance! >> Davide >> >> -- >> >> --- >> 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] <javascript:>. >> For more options, visit https://groups.google.com/groups/opt_out. >> > > > > -- > 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 [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
