The user.phone variable doesn't work

Document ID : KB000117317
Last Modified Date : 30/10/2018
Show Technical Document Details
Issue:
I'm trying to specify the variable $(_.user.phone) as a field value as per the documentation. Even though my user has a phone number this does not fill in the field. In addition if my field is "required" this seems to remove the asterisk denoting this.
This is documented here:
https://docops.ca.com/ca-service-management/17-1/en/using/service-catalog-management/manage-forms/customize-a-predefined-form

We have also seen instanced where use of this variable as shown above causes failure to submit a request with errors in the view.log similar to:

ERROR [SimpleAlarmMgr-Init] [DBSource] Error while saving object:{task_id=rm_reservation_status_task, name=Reservations Status Updater, comment=null, day_of_month=-1, day_of_week=-1, hour=-1, minute=-1, month=-1, status=1, task_to_exec=com.ca.usm.integration.reservationmgr.RMStatusUpdateTask, type=Minutely, year=-1, start_date=2018/09/10 11:12:19, end_date=null, requestor=general, runtime_component_id=Scheduler, action_type=0, data1=, data2=, data4=, data5=, interval=10, description=Updates reservation status when it is past it's end date, action_description=null, created_date=2018/09/10 11:12:19, last_exec_date=1752/12/31 18:18:00, missed_action=0, user_id=spadmin, modified_date=2018/10/11 13:56:46, guinode_id=, tenant_id=WiproDCS, time_zone_code=GMT-06:00 America/Chicago, comments=null, data3=} 2018/10/12 00.26.24.609 ERROR [SimpleAlarmMgr-Init] [Task] Error creating ictask object. com.microsoft.sqlserver.jdbc.SQLServerException: The conversion of a datetime2 data type to a datetime data type resulted in an out-of-range value.....
Resolution:
This is being corrected in the documentation but now that the user fields contain multiple phone numbers this variable should be specified as:
$(_.user.phone[0])
or if you want to remove whitespace:
$(_.user.phone[0].trim())
As long as you have a valid variable in "value" the asterisk denoting a required field is preserved as well.