This project has moved and is read-only. For the latest updates, please go here.


InnerJoin Method almost working


Hi thanks for the brill piece of software.
I'm working on Camlex.Client 2.2.

This is my query here

var caml =
            InnerJoin(x => x[CesaDocument.DocType_field].PrimaryList(CESAContext.Documents).ForeignList(CESAContext.DocumentType)).
            Where(x => (string)x[CesaDocument.RiOID_field] == id).
It compiles and that works find but the Join code is placed at the end of the query string like so..



This doesn't want to work in sharepoint 2010, which I'm working with.
If you put the <join></join> at the top then it works (in my tester).

Thanks for your help.
Closed Dec 3, 2016 at 8:49 AM by sadomovalex


rhousham wrote Nov 18, 2016 at 11:24 AM

Sorry I thought that was the issue, but still doesn't want to work.

The problem with Joins is that it doesn't want to work when you put them in the view field.
They have to be kinda on there own.

Right - ok 'lightbulb!' getting somewhere.

rhousham wrote Nov 21, 2016 at 10:40 AM

Fixed with this code.

var caml =
            .InnerJoin(x => x[CesaDocument.DocType_field].ForeignList(CESAContext.DocumentType))
            .Where(x => (string)x[CesaDocument.RiOID_field] == id)
This gives the right caml query.
No bug! Sorry ;)

sadomovalex wrote Dec 1, 2016 at 6:01 PM

sorry for late reply, somehow I missed your question in the inbox. Glad that it works)

rhousham wrote Dec 2, 2016 at 9:31 AM

Thanks, no worries.

FYI was working with it when I suddenly worrried about escaping characters!
Turned out that Camlex does it out the box!

Great software, a real asset.

sadomovalex wrote Dec 3, 2016 at 8:49 AM

Great to hear, thank you)