locked
How to left join or sub select? RRS feed

  • Question

  • Is it possible to use left join or sub-select at server-side ProcessQuery or Filter method not through navigation property?

    Tuesday, January 22, 2013 7:40 AM

Answers

  • It depends on what you want to do Ryan.

    If you want to use a joined table to assist in filtering the records in a query's PreProcessQuery method, then yes, the LINQ Join syntax will work just fine.

    If you're attempting to create an enhanced entity, the answer is no, unless you do it inside a RIA Service. You simply can't change the shape of a LightSwitch entity (whether it's application data, from an attached data source (including an entity supplied by a RIA service).

    Does that answer your question?


    Yann - LightSwitch Central - Click here for FREE Themes, Controls, Types and Commands
     
    Please click "Mark as Answer" if a reply answers your question. Please click "Vote as Helpful" , if you find a reply helpful.
     
    By doing this you'll help others to find answers faster.

    • Proposed as answer by babloo1436 Thursday, January 24, 2013 6:41 AM
    • Marked as answer by Angie Xu Tuesday, February 5, 2013 1:53 AM
    Thursday, January 24, 2013 2:37 AM
    Moderator

All replies

  • It depends on what you want to do Ryan.

    If you want to use a joined table to assist in filtering the records in a query's PreProcessQuery method, then yes, the LINQ Join syntax will work just fine.

    If you're attempting to create an enhanced entity, the answer is no, unless you do it inside a RIA Service. You simply can't change the shape of a LightSwitch entity (whether it's application data, from an attached data source (including an entity supplied by a RIA service).

    Does that answer your question?


    Yann - LightSwitch Central - Click here for FREE Themes, Controls, Types and Commands
     
    Please click "Mark as Answer" if a reply answers your question. Please click "Vote as Helpful" , if you find a reply helpful.
     
    By doing this you'll help others to find answers faster.

    • Proposed as answer by babloo1436 Thursday, January 24, 2013 6:41 AM
    • Marked as answer by Angie Xu Tuesday, February 5, 2013 1:53 AM
    Thursday, January 24, 2013 2:37 AM
    Moderator
  • Hi  ryan lin

    I will mark Yann's reply as answer, if the marked answer is not helpful to solve your problem, please unmark and give quick response.

    With kind regards


    Angie xu
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Tuesday, February 5, 2013 1:53 AM