Reverse Engineer assigns wrong schema to table valued parameter from the database
See original GitHub issueSituation: I have a stored procedure that takes a table-valued parameter as input. The stored procedure and the table-valued parameter do not share the same schema. The EF Power Tool assigns the wrong schema to the table-valued in the XXContextProcedures class.
Here is a snippet of code from the XXContextProcedures class. The error is in the schema of the type:
var parameterCategoryIDs = new SqlParameter
{
ParameterName = "CategoryIDs",
Value = CategoryIDs ?? Convert.DBNull,
SqlDbType = System.Data.SqlDbType.Structured,
TypeName = "[supplies].[TVP_Id]",
};
The stored procedure’s schema is [supplies], but the schema of [TVP_Id] schema is [dbo] in the database. I have to do find and replace after each time I run a reverse engineer in order to replace [supplies].[TVP_Id] with [dbo].[TVP_Id].
Otherwise, I really love the tool!
If you are unable to verify the bug I will supply SQL code to reproduce the error.
Further technical details
EF Core Power Tools version: 2.5
Database engine: Azure SQL Database
Visual Studio version: 2019 Preview version 16.9.0 Preview 1.0
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (3 by maintainers)
Top GitHub Comments
Got it! Works now. Thanks for the hint!
Did you download the daily build? Link in release notes in the wiki…