Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make a selected column from a leftJoined table option with Some #71

Open
JordanMarr opened this issue Nov 10, 2023 · 0 comments
Open

Make a selected column from a leftJoined table option with Some #71

JordanMarr opened this issue Nov 10, 2023 · 0 comments

Comments

@JordanMarr
Copy link
Owner

Should be able to make a selected column from a leftJoined table optional by wrapping it with Some.

For example:

    let! results = 
        selectTask HydraReader.Read (Create openContext)  {
            for o in Sales.SalesOrderHeader do
            leftJoin sr in Sales.SalesOrderHeaderSalesReason on (o.SalesOrderID = sr.Value.SalesOrderID)
            leftJoin r in Sales.SalesReason on (sr.Value.SalesReasonID = r.Value.SalesReasonID)
            where (isNullValue r.Value.Name)
            select (o.SalesOrderID, Some r.Value.ReasonType, Some r.Value.Name)
            take 10
        }

In the example above, the SalesReason table is optional because it is left joined.
We should be able to wrap these individually selected columns with Some so that they are of option types.

Currently, v2.2.0 where expression parser fails when wrapping selected columns with Some.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant