Cannot delete Edge
ChenZhaobin opened this issue · comments
I tried two methods to delete an Edge between two vetexs,they all have no effect .but it's fine when using command line
1.
var command = "g.V().has('code', '1020').outE("subcompany").where(__.inV().has('code','" + input.ToCode + "')).drop();g.tx().commit()";
await client.SubmitWithSingleResultAsync<dynamic>(query);
- C# Version
g.V().Has("code","1020").OutE("subcompany").Where(__.InV().Has("code", input.ToCode)).Drop().Iterate();
And it is weried that command line can give me the right count while gremlin.net cannot using below command:
g.E().hasLabel('subindustry').and(__.outV().has('code','0'),__.inV().has('code','12346')).count()
commandline will give result 1,but c# client.SubmitWithSingleResultAsync will give me result 0.
It seems that when I search on .net client side,the data has already been deleted ,but in server console ,I can still retrieve this data, is there some cach mechanism there?
I finnally got it , when I want to get the latest data ,I should first run the command :
graph.tx().rollback()
otherwise ,it always return the origin data before modified!