Comment: It is not related to c#.
CLR debugging in visual studio 2019
I have a sql/clr project I created and have maintained in visual studio 2008. I am attempting to update it to visual studio 2019, community edition but I seem to be missing 'something'. I am running visual studio 2019 as Administrator. my login has sysadmin security.
I went to SQL server Objects, right clicked on the database instance I am working with (sqlserver 17), and checked 'allow SQL/CLR debugging'.
Application debugging is also checked.
In project, I added a database reference to master database, set the database name to my development database, and checked 'suppress errors caused by unresolved references in the referenced project'
In project settings, I set the target platform. permission level is set to unsafe in sqlCLR properties target framework is 4.5 optimize code is not checked
In sqlclr build page. on the debug page, I set the debug database to one that exists(different from my development database) and connection test returns success.
I cleared all the deployment option check boxes. on the 'advanced' tabs, I cleared most of the check boxes on the general tab, all the boxes in the drop tab, left the 'ignore' tab alone.
If I build with the 'generate DDL' flag UNCHECKED on SQLCLR tab, then project builds, but it will not deploy. doing a build | deploy adds my assembly to the database assemblies list, but none of my stored procedures and triggers are added.
If I build with the 'generate DDL' flag CHECKED then the project does not build, it throws 'error SQL71501 : trigger [dbo].[triggername] has an unresolved reverence to object [dbo].[tablename that exists in the database].
so, any ideas about what I am missing?
I do not want the structures (tables / views) messed with in this project (they are part of another project), I do need the stored procedures/functions/triggers/etc to be maintained by this project, so I can debug them