public void readExternal( ObjectInput in )
throws IOException, ClassNotFoundException
{
super.readExternal(in);
specificName = (String) in.readObject();
dynamicResultSets = in.readInt();
parameterCount =
in.readInt();
parameterStyle = in.readShort();
sqlAllowed = in.readShort();
returnType = (TypeDescriptor) in.readObject();
calledOnNullInput = in.readBoolean();
//Following will be 0 from
pre-10.2 db, 1 for 10.2 db
//Can be bumped for future releases which require a change
//in RoutineAliasInfo.
int readMoreFromDisk = in.readInt();
if (parameterCount != 0) {
parameterNames = new String[parameterCount];
parameterTypes = new TypeDescriptor[parameterCount];
ArrayUtil.readArrayItems(in, parameterNames);
ArrayUtil.readArrayItems(in, parameterTypes);
parameterModes = ArrayUtil.readIntArray(in);
} else {
parameterNames = null;
parameterTypes = null;
parameterModes = null;
}
if (readMoreFromDisk > 1 || readMoreFromDisk < 0) {
if (SanityManager.DEBUG)
SanityManager.THROWASSERT
("Invalid value " + readMoreFromDisk + " read from the disk.");
} else if(readMoreFromDisk == 1)
//If true, that means we are dealing with 10.2 db and hence
//we should read external security info from the disk
executeUsingPermissionsOfRoutineInvoker = in.readBoolean();
else
//We are dealing with pre-10.2 db, which doesn't have external
//security feature on routines and hence no information about
//external security will be found on the disk. Hence, initialize
//external security information to definer's permissions as per
//SQL standards.
executeUsingPermissionsOfRoutineInvoker = false;
}
Mamta Satoor wrote:
> Hi,
>
> I ran following query in a 10.2 db
> select alias,systemalias from sys.sysaliases;
>
I don't think systemalias column in sys.sysaliases is being used in
Derby currently. It was probably used in Cloudscape product, from which
Derby originally came from. All routines in system schemas have this
flag set to 'false'. May be documentation should say this column is
'Reserved'?
What information do you need?
Satheesh
> I was expecting to see true for systemalias column for Derby supplied
> routines like SYSCS_COMPRESS_TABLE, SYSCS_EXPORT_TABLE etc. But all
> the rows returned by the query above have systemalias set to false.
> According to the docs on SYSALIASES table, the column systemalias will
> be set to true for system supplief/built-in aliases. Is the doc
> incorrect, system table incorrect or I am missing something?
>
> thanks,
> Mamta
