Best Practice on Task Table fields
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-05-2015 04:58 PM
Hi ServiceNow Community Developers,
Would you please advise as to the best practice when it comes to using fields from the task table rather than creating your own. For instance I have a requirement to include the Opened by field in the procurement (proc_po) table. The procurement table does not extend the task table and as such it does not inherit the fields from the task table. The opened_by field is defined in the task table and if I want to use it from the task table all I have to do to is to make proc_po an extended table of task table. I also have another requirement to include work_notes on transfer order (alm_transfer_order) table which also does not extend the task table which means that I either define a custom work notes field or I make the transfer order table extends the task table so I can use the one from the task. My biggest concern is that I don't want to extend the task table for a few oob fields because I am not sure if there are performance implications for doing that however at the same I don't want to re-invent the wheel, if I can use the oob fields with no serious overheads I would rather do that. Please advise.
Thanks,
Johannes

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-05-2015 07:47 PM
Hi Johannes Mweli,
Modifications made to the task table will be applied to all child tables. Be sure that the changes being made should apply to all of the child tables. Adding fields is a low-impact change, because the field can be hidden on tables that do not need it; however, deleting fields may cause unwanted data loss if the field is being used across tables. Note, when adding choice list entries to a choice list on the Task table, ensure the entry value is unique.
Some parts of a field definition can be changed in such a way as to not apply to all child tables using Dictionary Overrides.
Dictionary Overrides - ServiceNow Wiki
Dictionary Overrides — ServiceNow ELITE.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-24-2015 07:15 AM
Hello Joannes,
Some advice on your 2 issues:
1. Providing "Opened By" on the procurement table. While I don't have the proc_po table in my instance, most (all?) tables have a field named sys_created_by. If this is found on your table, give it a look as you might be able to use that. If needed, add a label for it so it appears as "Opened By" to your users.
2. With respect to your need to provide work notes on the alm_transfer_order table, I know of no way to change it to extend the task table, so this may not be possible. Also, if I may express an opinion, I think it's a bad reason to extend a table if the sole reason for doing so is to use a field on that table. Why not just add a work notes field to the table itself?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-23-2015 02:59 AM
Hi Johannes,
If your instance is on Dublin on later, chances are that task table has been flattened.
Task Table Flattening - ServiceNow Wiki
If that's the case then adding these tables as extension to task would mean they will be physically included in task, so you will automatically have access to all columns from task. Over long term this might have more benefits for you, but you can read more about pro's and con's here:
Creating fields takes forever after upgrade to Dublin
On the other hand if it's really for only a few tables and not too many fields, you can just create them directly on those tables. There will no really overhead. Fields like "Opened by" even if present on task is just a reference to "User (sys_user)", so they just hold sys_ids.
Hope this helps.
Regards,
Sergiu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-13-2018 05:33 PM
Also, one thing to note:
once proc_po is created you cannot extend the table afterwards.