When you call CreateUnique
to create the user-[:CURRENT]->work
relationship, it's not actually being appended to the query. What you need to change that line to is:
query = query.CreateUnique("user-[:CURRENT]->work");
Which is what is happening for all the fluent methods chained in the first query you write out. The easiest way to spot these things is stick a breakpoint on the query.ExecuteWithoutResults();
method and when VS breaks there, hover over query
and see if the text matches what you think it should.