I am trying to build a public safety dispatch table that will update with changes in the status of a call. For every call, the following time/date entries are made by the dispatcher in order track calls and to later generate statistical data on calls for service:
TIME_RECEIVED
TIME_DISPATCHED
TIME_ARRIVED
TIME_FINISHED
Depending on what state the given call is in, the CALL_STATUS will be:
RECEIVED (call received but not yet dispatched to an officer)
EN_ROUTE (officer on the way)
ON_SCENE (officer on scene)
FINISHED (officer mitigated issue)
I am trying to get the CALL_STATUS field to show the appropriate status for the state of the call based on the following logical expression:
if (isnotblank("Call_received") .and. isblank("Dispatched") .and. isblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="Received","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="En Route","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isnotblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="On Scene","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isnotblank("Arrived") .and. isnotblank("Finished") .and. isblank("Completed"),"Call_status"="Finished","Call_status"="")
On submission I keep receiving an error relating that the expression (while recognized as valid), does not return a character value. I have tried this with the target field CALL_STATUS as both a character and as a logical field type. No success either way.
Can anyone help with another approach, or does anyone see the flaw in my string above?
Sincerely,
Matt Carroll
Vice President
Paladin Private Security
TIME_RECEIVED
TIME_DISPATCHED
TIME_ARRIVED
TIME_FINISHED
Depending on what state the given call is in, the CALL_STATUS will be:
RECEIVED (call received but not yet dispatched to an officer)
EN_ROUTE (officer on the way)
ON_SCENE (officer on scene)
FINISHED (officer mitigated issue)
I am trying to get the CALL_STATUS field to show the appropriate status for the state of the call based on the following logical expression:
if (isnotblank("Call_received") .and. isblank("Dispatched") .and. isblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="Received","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="En Route","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isnotblank("Arrived") .and. isblank("Finished") .and. isblank("Completed"),"Call_status"="On Scene","Call_status"="") .and. if (isnotblank("Call_received") .and. isnotblank("Dispatched") .and. isnotblank("Arrived") .and. isnotblank("Finished") .and. isblank("Completed"),"Call_status"="Finished","Call_status"="")
On submission I keep receiving an error relating that the expression (while recognized as valid), does not return a character value. I have tried this with the target field CALL_STATUS as both a character and as a logical field type. No success either way.
Can anyone help with another approach, or does anyone see the flaw in my string above?
Sincerely,
Matt Carroll
Vice President
Paladin Private Security
Comment