Closed iahmed9312 closed 9 months ago
Hi. HasTrigger
was added to v3.8.1 and enhanced in v3.8.2.
See release v3.8.2 notes
Please show me the SQL to create the trigger for the table, and the SQL for the table so that I may test it.
I also wanted to check you have set Settings.TemplateType = TemplateType.EfCore7
in your .tt settings file.
Thank you for your reply.
The template is set to Settings.TemplateType = TemplateType.EfCore7
To replicate my situation please follow the steps:
If you run POCO in Database1 it will run correctly and it will add (HasTrigger to Table1)
To get to my issue please follow the steps:
Now if you run POCO on Database2 it will run correctly except it will not add (HasTrigger to Table1)
I hope it is clear.
Please note you have to change FilterSettings.IncludeSynonyms = true in your .tt settings file
Try the attached file. It only works on SQL Server currently. Let me know if it works for you. EF.Reverse.POCO.v3.zip
Thank you very much, it is working perfectly!
Released in v3.9.0
After updating to EFCore7 (HasTrigger) is now required before inserting to a table, and thankfully POCO is updated since v3.8.0 . However, I have added table (that has trigger) as synonymous from another database but (HasTrigger ) is not added by POCO.