language-extensions/R/src/RSession.cpp
//--------------------------------------------------------------------------------------------------
// Name: RSession::GetOutputParam
//
// Description:
//  Returns the data and size of the output parameter
//
:GetOutputParam
Description:
Returns the data and size of the output parameter
: GetOutputParam Description : Returns the data and size of the output parameter
void RSession::GetOutputParam(
	SQLUSMALLINT paramNumber,
	SQLPOINTER   *paramValue,
	SQLINTEGER   *strLen_or_Ind)
{
	LOG("Initializing output param #" + to_string(paramNumber));
	if (paramValue == nullptr || strLen_or_Ind == nullptr)
	{
		throw invalid_argument("Null arguments supplied to GetOutputParam().");
	}
	if (paramNumber < m_paramContainer.GetSize())
	{
		m_paramContainer.GetParamValueAndStrLenInd(paramNumber, paramValue, strLen_or_Ind);
	}
	else
	{
		throw invalid_argument("Invalid output parameter id supplied to GetOutputParam(): " +
			to_string(paramNumber));
	}
}
void RSession :: GetOutputParam ( SQLUSMALLINT paramNumber , SQLPOINTER * paramValue , SQLINTEGER * strLen_or_Ind ) { LOG ( " " + to_string ( paramNumber ) ) ; if ( paramValue == nullptr || strLen_or_Ind == nullptr ) { throw invalid_argument ( " " ) ; } if ( paramNumber < m_paramContainer . GetSize ( ) ) { m_paramContainer . GetParamValueAndStrLenInd ( paramNumber , paramValue , strLen_or_Ind ) ; } else { throw invalid_argument ( " " + to_string ( paramNumber ) ) ; } }
Name: RSession::GetOutputParam
Description:
Returns the data and size of the output parameter
Name : RSession :: GetOutputParam Description : Returns the data and size of the output parameter