Solved

Instead of Trigger program object missing

  • 13 September 2022
  • 12 replies
  • 67 views

Userlevel 5
Badge +16
  • Thinkwise Local Partner Brasil
  • 383 replies

What can be the reason that I have a view, and I created an IoT for it but when I want to assign it, the program object of this view is nowhere to be found. Is there a setting that perhaps blocks this? 

Because normally every view will gets a TRIGGER_INSTEAD_OF_STATMENT correct?

icon

Best answer by Mark Jongeling 13 September 2022, 14:31

View original

This topic has been closed for comments

12 replies

Userlevel 7
Badge +23

Hi Freddy,

Is the program object still missing after Generating the code group? For every Table(/View), this object should be generated. 
Edit: As long as it is not a system versioned table

Userlevel 5
Badge +16

Hi Freddy,

Is the program object still missing after Generating the code group? For every Table(/View), this object should be generated. 
Edit: As long as it is not a system versioned table

Yeah, generated code groups, the whole project.. but it just doesn't show. 

Userlevel 7
Badge +23

Maybe some filtering has taken place causing the object to be out of selection. Could that be it?

Userlevel 5
Badge +16

Maybe some filtering has taken place causing the object to be out of selection. Could that be it?

NO, checked that as well. no filters active

Userlevel 7
Badge +23

Only thing I can think of is that you are using the TRIGGERS code group instead of the INSTEAD_OF_TRIGGERS code group; the second being also available to Views. Triggers are only generated for Tables.

Userlevel 5
Badge +16

Only thing I can think of is that you are using the TRIGGERS code group instead of the INSTEAD_OF_TRIGGERS code group; the second being also available to Views. Triggers are only generated for Tables.

Not the case… 

Userlevel 7
Badge +23

Have you copied another Control procedure and changed the Code group maybe? (I'm now more guessing as I haven't encountered this issue myself yet). 

Does making a new Control procedure with the Code group INSTEAD_OF_TRIGGERS solve the issue? Otherwise I think it's something vague that we would have to investigate using a model.dat

Userlevel 5
Badge +16

I only see that in the full model the view doesn't have the objects generated ..  I think here lies the problem. Only handlers are created, not the Instead of Triggers. 

 

Userlevel 7
Badge +23

Last few suggestions, does the Control procedure "sql_instead_of_triggers” exists in your work project? It is a generated Control procedure so the prefilter Hide generated has to be turned off to make it visible.

And, can you double check the Use system versioning checkbox via the Grid of the Tables screen to see if that happened to be check for this View? If this is checked, that indeed caused the program object to be not generated. To uncheck it, you can Edit the View in Tables, change its type to Table, uncheck the setting, then change it back to View.

Userlevel 5
Badge +16

Last few suggestions, does the Control procedure "sql_instead_of_triggers” exists in your work project? It is a generated Control procedure so the prefilter Hide generated has to be turned off to make it visible.

And, can you double check the Use system versioning checkbox via the Grid of the Tables screen to see if that happened to be check for this View? If this is checked, that indeed caused the program object to be not generated. To uncheck it, you can Edit the View in Tables, change its type to Table, uncheck the setting, then change it back to View.

  1. Yes that I checked already system versioning is not active in the checkbox. 

Strange part is I have views with IOT generated and I have a few where this is not the case. 

Userlevel 5
Badge +16

Last few suggestions, does the Control procedure "sql_instead_of_triggers” exists in your work project? It is a generated Control procedure so the prefilter Hide generated has to be turned off to make it visible.

And, can you double check the Use system versioning checkbox via the Grid of the Tables screen to see if that happened to be check for this View? If this is checked, that indeed caused the program object to be not generated. To uncheck it, you can Edit the View in Tables, change its type to Table, uncheck the setting, then change it back to View.

I found you cannot deselect system versioning and save it as a view a the same time..  so effectively it still had system versioning active..  perhaps a good fix for the SF to not set the system versioning at all when creating a view..  

Solution was to make it a table and SAVE it and subsequently edit it again and save it as a view again. 

Userlevel 7
Badge +23

I'll double check and solve it for 2023.1 😁