Can't Return A Value Of Type Hash (Doc ID 408120.1)

Last updated on JULY 28, 2017

Applies to:

Oracle Communications Billing and Revenue Management - Version 6.5.0.1.1 and later
Information in this document applies to any platform.
Checked for relevance on 18-Aug-2008.

Symptoms

Is it is possible to return a Hash as the result of an iScript function. E.g.:

function String testHash (String defaultValue)
{
  String result{}; 
  result{"a"} = "a";
  result{"b"} = "b";
  return result ;
 }



If try to compile the above example, IntegRate complains that a 'String' is expected as result, not a 'Hash'.  But if change the first line of the function to:

function Hash testHash (String defaultValue)

It seems that iScript thinks that Hash is the function name. Also tried something like "String {}" as return type, but without success. 

In the iScript documentation "Hash" and "Array" are used for types of function parameters, but never as return value. Is it possible in iScript to use a hash (with String, Bool, Long, Date, Decimal or File as base value) as return value of a function?

Changes

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms