Skip to content

Query: Disallow FromSql/TVF with TPT - #21725

Merged
1 commit merged into
masterfrom
smit/blocks
Jul 22, 2020
Merged

1 commit merged into
masterfrom
smit/blocks

Conversation

@smitpatel

Copy link
Copy Markdown
Contributor
  • Throw exception when using FromSql* methods
  • Throw if a TVF is mapped to TPT
  • Throw if construction of SelectExpression with custom TableExpression is done when TPT

Resolves #21508

@smitpatel
smitpatel requested a review from AndriySvyryd July 22, 2020 01:11
}

if (entityType.BaseType != null || entityType.GetDerivedTypes().Any()
&& entityType.GetDiscriminatorProperty() == null)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure that we support TPH, do we have any tests?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably not tests but it just works due to design.

Base automatically changed from smit/mappings to master July 22, 2020 02:26
- Throw exception when using FromSql* methods
- Throw if a TVF is mapped to TPT
- Throw if construction of SelectExpression with custom TableExpression is done when TPT

Resolves #21508
@ghost

ghost commented Jul 22, 2020

Copy link
Copy Markdown

Hello @smitpatel!

Because this pull request has the auto-merge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost
ghost merged commit b23e0ac into master Jul 22, 2020
@ghost
ghost deleted the smit/blocks branch July 22, 2020 05:11
This pull request was closed.
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

Successfully merging this pull request may close these issues.

Query: Disallow FromSql on TPT/TPC

2 participants