Jump to content

Custom field queries


chrisnutt

Recommended Posts

Hi,

I have a few questions regarding custom fields that I can't find answers to on the wiki. Any help would be greatly appreciated!

Firstly, according to https://wiki.hornbill.com/index.php/Mapping_Fields_from_Customised_Forms I should have fields h_custom_31 to h_custom_40 available for use. However, in database direct they are not showing on the h_itsm_requests table. My custom fields seem to stop at h_custom_30. Why could this be? We are fully up to date with releases.

Secondly, I am trying to use Capture Task Fields in an activity. I assumed that I would be using the custom fields from the above link here. However, I used h_custom_30 in an activity and, using radio buttons, put the value of 1 in it. Or so I thought. In database direct, h_custom_30 is blank in h_itsm_requests when looking at the request. Am I missing something? Unfortunately, I cannot see anything to explain this in https://wiki.hornbill.com/index.php/Capture_Task_Fields except that I don't seem to have the option experimental.feature.bpm.allowcustomtaskfields in my instance. Is that normal?

Finally, while troubleshooting this, I stumbled across the setting guest.itsm.progressiveCapture.overwriteCustomFieldValue which was disabled. The description says "A Custom Field (e.g. h_custom_a) could be mapped to a Field in more than one Customised Form. When disabled, overwritten values will not be considered and hence the 1st value is assigned to the Request's Custom Field." Am I right in thinking that if this is off then I won't be able to amend the data in custom fields via the request details form once a request is logged? I.E. In the progressive capture I answer "Yes" but once it is logged, I want to change it to "No".

Any guidance on these questions is very welcome!

Thanks

Chris

Link to comment
Share on other sites

On 5/22/2020 at 12:57 PM, chrisnutt said:

Firstly, according to https://wiki.hornbill.com/index.php/Mapping_Fields_from_Customised_Forms I should have fields h_custom_31 to h_custom_40 available for use. However, in database direct they are not showing on the h_itsm_requests table. My custom fields seem to stop at h_custom_30. Why could this be? We are fully up to date with releases.

Hi,

Just to add to the above that all the change related fields like h_backout_plan are also missing.

Quote

Secondly, I am trying to use Capture Task Fields in an activity. I assumed that I would be using the custom fields from the above link here. However, I used h_custom_30 in an activity and, using radio buttons, put the value of 1 in it. Or so I thought. In database direct, h_custom_30 is blank in h_itsm_requests when looking at the request. Am I missing something? Unfortunately, I cannot see anything to explain this in https://wiki.hornbill.com/index.php/Capture_Task_Fields except that I don't seem to have the option experimental.feature.bpm.allowcustomtaskfields in my instance. Is that normal?

I have put in a workaround here to take the info from the activity and use an "Update Request -> Custom Fields" node to get the data in so I much less concerned about this.

My main worry is my first point. I have less than two weeks to get this finished, tested, documented and launched (hard deadline due to my leaving the organisation) so would really appreciate an update today if possible.

Many thanks

Chris

Link to comment
Share on other sites

On 5/22/2020 at 12:57 PM, chrisnutt said:

Firstly, according to https://wiki.hornbill.com/index.php/Mapping_Fields_from_Customised_Forms I should have fields h_custom_31 to h_custom_40 available for use. However, in database direct they are not showing on the h_itsm_requests table. My custom fields seem to stop at h_custom_30. Why could this be? We are fully up to date with releases.

 

5 hours ago, chrisnutt said:

ust to add to the above that all the change related fields like h_backout_plan are also missing.

@chrisnutt not all this data is held in the main requests table, some data is stored in the extended tables... custom 31 to 40 are stored in h_sm_requests_extended table while h_backout_plan (and other related change request specific fields) are stored in h_itsm_changerequests table.

Check if you get the data from your PCF in one of these extended tables.

On 5/22/2020 at 12:57 PM, chrisnutt said:

I don't seem to have the option experimental.feature.bpm.allowcustomtaskfields in my instance. Is that normal?

Yes. It is no longer an experimental feature, functionality has been made available in all instances, hence no need to a setting anymore. The wiki needs updating then...

On 5/22/2020 at 12:57 PM, chrisnutt said:

I am trying to use Capture Task Fields in an activity. I assumed that I would be using the custom fields from the above link here. However, I used h_custom_30 in an activity and, using radio buttons, put the value of 1 in it. Or so I thought. In database direct, h_custom_30 is blank in h_itsm_requests when looking at the request. Am I missing something?

I don't think you can map a request custom field to a task custom field. Afaik, this "mapping" is only available in PCF.

On 5/22/2020 at 12:57 PM, chrisnutt said:

Am I right in thinking that if this is off then I won't be able to amend the data in custom fields via the request details form once a request is logged?

That's incorrect. Once the request is raised the data you store in the custom field can be amended. When guest.itsm.progressiveCapture.overwriteCustomFieldValue is turned off it will prevent a value to be overwritten in case you map the custom field more than once. This setting (enabled) becomes useful when you have conditional fields where you can have different questions mapped to the same custom field. These questions will be visible or not depending on the conditional field configuration (check "Displaying Conditional Fields" section on https://wiki.hornbill.com/index.php/Progressive_Capture_Designer).

Link to comment
Share on other sites

2 minutes ago, Victor said:

 

@chrisnutt not all this data is held in the main requests table, some data is stored in the extended tables... custom 31 to 40 are stored in h_sm_requests_extended table while h_backout_plan (and other related change request specific fields) are stored in h_itsm_changerequests table.

Thanks @Victor

Please can you arrange for https://wiki.hornbill.com/index.php/Mapping_Fields_from_Customised_Forms to be updated to reflect that as it currently states, quite clearly:

"The exercise of field mapping ensures the data is written to h_itsm_requests (the main request table) which means it is readily available."

4 minutes ago, Victor said:

I don't think you can map a request custom field to a task custom field. Afaik, this "mapping" is only available in PCF.

Can you check on this because in https://wiki.hornbill.com/index.php/Capture_Task_Fields it says "Field Properties - Provide a title for the field, add a custom field id or leave as standard and add placeholder text if needed" which to me clearly indicates a custom field could be used.

Thanks

Chris

Link to comment
Share on other sites

4 minutes ago, chrisnutt said:

The exercise of field mapping ensures the data is written to h_itsm_requests (the main request table) which means it is readily available.

Some of them are in the main request table, so the above is correct but incomplete. Will look into updating the wiki to explain the extended tables.

5 minutes ago, chrisnutt said:

"Field Properties - Provide a title for the field, add a custom field id or leave as standard and add placeholder text if needed" which to me clearly indicates a custom field could be used.

Right, then it means they can be used. I'll check with developers to see if there are any issue in this area.

Link to comment
Share on other sites

Ok, I have checked with development. I did remember correctly the mapping to request custom fields is available only during PCF. I'll look into having the wiki update here too.

To achieve what you need you can add a Hornbill Automation to update Request custom fields after task has been completed.

 

Link to comment
Share on other sites

Hi @Victor, I've just come to update my email templates after building my new process and I want to add the answer to the question "Proposed Start Time" asked in my progressive capture, to a template. On the progressive capture, I am using "h_proposed_start_time".Once again, based on https://wiki.hornbill.com/index.php/Mapping_Fields_from_Customised_Forms I thought it would be available for email templates because of this line:

"The way the data is stored in the table h_itsm_questions does not offer us much flexibility when it comes to reporting and also means is not accessible via the email template variable picker. The exercise of field mapping ensures the data is written to h_itsm_requests (the main request table) which means it is readily available."

This is the same line that I thought was misleading before. Has it misled me again because I cannot see "proposed start time" in the email template variable picker.

Chris

Link to comment
Share on other sites

@chrisnutt proposed start time is change request specific field, it won't be stored in the main requests table. Therefore it won't be available in the email template variable picker. I would say as a workaround to copy this value into a custom field on request and use that in the template.

Link to comment
Share on other sites

31 minutes ago, Victor said:

@chrisnutt proposed start time is change request specific field, it won't be stored in the main requests table. Therefore it won't be available in the email template variable picker. I would say as a workaround to copy this value into a custom field on request and use that in the template.

Hi @Victor, I understand, and I have done that workaround.

However my main issue, really, is that page is extremely misleading at best. I would actually say that it is wrong, because it does not mention any other tables for these values. Therefore I have continued with the complete wrong notion. Luckily, there is a workaround this time but it really worries me that the source of truth I go to is actually inaccurate.

Chris

Link to comment
Share on other sites

@chrisnutt - I'll update the wiki to specify the request type-specific tables (and fields) and how they (don't) work in relation to template variables. Thanks for highlighting these, it helps us improve our documentation and sorry for the trouble this has caused.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...