Skip to main content
Completed

Exclude added_by/added_on from auto generated update handler

Related products:Software Factory
  • November 14, 2023
  • 9 replies
  • 176 views

Guido Bijl
Sidekick
Forum|alt.badge.img+2

It would be nice if the auto generated update handler would not include the added_by and added_on trace fields. Because they are automatically included in the update handler you have to set a value for them, even though technically those two fields should never be overwritten. There are workarounds ofcourse, but i’d rather use the auto generated update handler as is. Our project is in Dutch, so if langauge can also be considered when excluding the added trace fields, that would be nice, because we are using toegevoegd_op en toegevoegd_door as added_by/on.

9 replies

Mark Jongeling
Administrator
Forum|alt.badge.img+23
  • Software Architect
  • November 14, 2023
New→Open

Remco Kort
Administrator
Forum|alt.badge.img+2
  • Administrator
  • November 15, 2023

I like the general idea but I think it should be more generic. Like give a developer the option for a column to set whether this column is used in the automatically generated handlers or not.


Mark Jongeling
Administrator
Forum|alt.badge.img+23
  • Software Architect
  • November 15, 2023

I like the general idea but I think it should be more generic. Like give a developer the option for a column to set whether this column is used in the automatically generated handlers or not.

We could provide a Tag that developers then can attach to Columns to exclude them from the automatically generated handlers, but maybe we can think of another way 😄


Remco Kort
Administrator
Forum|alt.badge.img+2
  • Administrator
  • November 15, 2023

I like the general idea but I think it should be more generic. Like give a developer the option for a column to set whether this column is used in the automatically generated handlers or not.

We could provide a Tag that developers then can attach to Columns to exclude them from the automatically generated handlers, but maybe we can think of another way 😄

That would work but is also not a great user experience. Maybe you could add it as options in this screen, that seems a logical place: 

 


Robert Jan de Nie
Thinkwise blogger
Forum|alt.badge.img+7

Agree with Remco. It should be a formal property per column.

  • Include in insert handler (default = true)
  • Include in update handler (default = true)

Remco
Moderator
Forum|alt.badge.img+4
  • Moderator
  • November 28, 2023
Open→Working on it!

Remco
Moderator
Forum|alt.badge.img+4
  • Moderator
  • November 29, 2023

Hi all,

We have added in the upcoming release a way that you can exclude columns for the generated insert and update statement. These setting can be found via User Interface --> Subjects --> Columns --> tab: Performance

Image

There you can uncheck if you don't want that column to be used in the auto generated statement. There are some restrictions for the insert handler checkbox. This can not be unchecked if the column is:

  • Primary key
  • Mandatory without default value

Note that it may break your dynamic model if you use select * into #cols from col. Please verify your dynamic model code and add the new columns if needed.


Remco
Moderator
Forum|alt.badge.img+4
  • Moderator
  • November 29, 2023
Working on it!→Next release

Mark Jongeling
Administrator
Forum|alt.badge.img+23
  • Software Architect
  • January 19, 2024
Next release→Completed