Adding the variable editor to custom tables that are NOT task based
When creating a custom table that is not task based, the variable editor has to be created on the table form. When it is created, it will not initially be editable nor reportable. Below are the steps required to add the editor to the form and ensure that it’s fully usable.
Create a Variable Editor
Navigate to System UI > Formatters
Click Create New
Fill at the form as below and submit
Name: Variable Editor
Formatter: com_glideapp_questionset_default_question_editor
Table: Select your custom table
Active: true
Type: Formatter
Finally, navigate back to the form for your custom table, and add your new Variable Editor to it by personalizing the layout.
Ensure new Variable Editor is reportable and editable
Once created, the new editor is not really actionable. It’s view only. There is a simple fix, though, as described in KB0538897.*
Navigate to System Definition > Tables
Select your table
Create a new column on the table as follows:
Type: Variables
Column Label: variables
Column name: variables (this must be exact, you cannot have a u_ in the column name value)
Active: true
Navigate to the form view of your table, personalize it, and removed the new Variables field
* ServiceNow Support recommends that this be completed by them by putting in a Support Case. The Variables type is not a visible Field class for selection when creating a field. While you can make the field class visible, I would recommend you request this from ServiceNow Support.