|
|
|
@ -1,5 +1,5 @@ |
|
|
|
/* |
|
|
|
/* |
|
|
|
* Copyright 2002-2018 the original author or authors. |
|
|
|
* Copyright 2002-2020 the original author or authors. |
|
|
|
* |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
@ -172,7 +172,7 @@ public class CallMetaDataContext { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* Secify the name of the schema. |
|
|
|
* Specify the name of the schema. |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
public void setSchemaName(@Nullable String schemaName) { |
|
|
|
public void setSchemaName(@Nullable String schemaName) { |
|
|
|
this.schemaName = schemaName; |
|
|
|
this.schemaName = schemaName; |
|
|
|
@ -354,7 +354,7 @@ public class CallMetaDataContext { |
|
|
|
logger.debug("Using declared out parameter '" + paramName + |
|
|
|
logger.debug("Using declared out parameter '" + paramName + |
|
|
|
"' for function return value"); |
|
|
|
"' for function return value"); |
|
|
|
} |
|
|
|
} |
|
|
|
setFunctionReturnName(paramName); |
|
|
|
this.actualFunctionReturnName = paramName; |
|
|
|
returnDeclared = true; |
|
|
|
returnDeclared = true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
@ -362,8 +362,7 @@ public class CallMetaDataContext { |
|
|
|
} |
|
|
|
} |
|
|
|
setOutParameterNames(outParamNames); |
|
|
|
setOutParameterNames(outParamNames); |
|
|
|
|
|
|
|
|
|
|
|
List<SqlParameter> workParams = new ArrayList<>(); |
|
|
|
List<SqlParameter> workParams = new ArrayList<>(declaredReturnParams); |
|
|
|
workParams.addAll(declaredReturnParams); |
|
|
|
|
|
|
|
if (!provider.isProcedureColumnMetaDataUsed()) { |
|
|
|
if (!provider.isProcedureColumnMetaDataUsed()) { |
|
|
|
workParams.addAll(declaredParams.values()); |
|
|
|
workParams.addAll(declaredParams.values()); |
|
|
|
return workParams; |
|
|
|
return workParams; |
|
|
|
@ -393,8 +392,8 @@ public class CallMetaDataContext { |
|
|
|
"Unable to locate declared parameter for function return value - " + |
|
|
|
"Unable to locate declared parameter for function return value - " + |
|
|
|
" add a SqlOutParameter with name '" + getFunctionReturnName() + "'"); |
|
|
|
" add a SqlOutParameter with name '" + getFunctionReturnName() + "'"); |
|
|
|
} |
|
|
|
} |
|
|
|
else if (paramName != null) { |
|
|
|
else { |
|
|
|
setFunctionReturnName(paramName); |
|
|
|
this.actualFunctionReturnName = param.getName(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
else { |
|
|
|
else { |
|
|
|
@ -422,7 +421,7 @@ public class CallMetaDataContext { |
|
|
|
(StringUtils.hasLength(paramNameToUse) ? paramNameToUse : getFunctionReturnName()); |
|
|
|
(StringUtils.hasLength(paramNameToUse) ? paramNameToUse : getFunctionReturnName()); |
|
|
|
workParams.add(provider.createDefaultOutParameter(returnNameToUse, meta)); |
|
|
|
workParams.add(provider.createDefaultOutParameter(returnNameToUse, meta)); |
|
|
|
if (isFunction()) { |
|
|
|
if (isFunction()) { |
|
|
|
setFunctionReturnName(returnNameToUse); |
|
|
|
this.actualFunctionReturnName = returnNameToUse; |
|
|
|
outParamNames.add(returnNameToUse); |
|
|
|
outParamNames.add(returnNameToUse); |
|
|
|
} |
|
|
|
} |
|
|
|
if (logger.isDebugEnabled()) { |
|
|
|
if (logger.isDebugEnabled()) { |
|
|
|
|