language-extensions/R/test/src/RExtensionGetResultColumnTests.cpp
TEST_F(RExtensionApiTests, GetDoubleResultColumnsTest)
	{
		// Initialize with a default Session that prints Hello RExtension
		// and assigns InputDataSet to OutputDataSet
		//
		InitializeSession(
			(*m_doubleInfo).GetColumnsNumber(),
			m_scriptString);

		InitializeColumns<SQLDOUBLE, SQL_C_DOUBLE>(m_doubleInfo.get());

		Execute<SQLDOUBLE, Rcpp::NumericVector, SQL_C_DOUBLE>(
			ColumnInfo<SQLDOUBLE>::sm_rowsNumber,
			(*m_doubleInfo).m_dataSet.data(),
			(*m_doubleInfo).m_strLen_or_Ind.data(),
			(*m_doubleInfo).m_columnNames,
			false);  // validate

		GetResultColumn(0, // columnNumber
			SQL_C_DOUBLE,  // dataType
			m_DoubleSize,  // columnSize
			0,             // decimalDigits
			SQL_NO_NULLS); // nullable

		GetResultColumn(1, // columnNumber
			SQL_C_DOUBLE,  // dataType
			m_DoubleSize,  // columnSize
			0,             // decimalDigits
			SQL_NULLABLE); // nullable
	}
//----------------------------------------------------------------------------------------------
// Name: GetDoubleResultColumnsTest
//
// Description:
//  Tests GetResultColumn with default script using an OutputDataSet of Double columns.
//
GetDoubleResultColumnsTest
Description:
Tests GetResultColumn with default script using an OutputDataSet of Double columns.
GetDoubleResultColumnsTest Description : Tests GetResultColumn with default script using an OutputDataSet of Double columns .
TEST_F(RExtensionApiTests, GetDoubleResultColumnsTest)
	{
		InitializeSession(
			(*m_doubleInfo).GetColumnsNumber(),
			m_scriptString);
		InitializeColumns<SQLDOUBLE, SQL_C_DOUBLE>(m_doubleInfo.get());
		Execute<SQLDOUBLE, Rcpp::NumericVector, SQL_C_DOUBLE>(
			ColumnInfo<SQLDOUBLE>::sm_rowsNumber,
			(*m_doubleInfo).m_dataSet.data(),
			(*m_doubleInfo).m_strLen_or_Ind.data(),
			(*m_doubleInfo).m_columnNames,
			false);   validate
		GetResultColumn(0,  columnNumber
			SQL_C_DOUBLE,   dataType
			m_DoubleSize,   columnSize
			0,              decimalDigits
			SQL_NO_NULLS);  nullable
		GetResultColumn(1,  columnNumber
			SQL_C_DOUBLE,   dataType
			m_DoubleSize,   columnSize
			0,              decimalDigits
			SQL_NULLABLE);  nullable
	}
TEST_F ( RExtensionApiTests , GetDoubleResultColumnsTest ) { InitializeSession ( ( * m_doubleInfo ) . GetColumnsNumber ( ) , m_scriptString ) ; InitializeColumns < SQLDOUBLE , SQL_C_DOUBLE > ( m_doubleInfo . get ( ) ) ; Execute < SQLDOUBLE , Rcpp :: NumericVector , SQL_C_DOUBLE > ( ColumnInfo < SQLDOUBLE > :: sm_rowsNumber , ( * m_doubleInfo ) . m_dataSet . data ( ) , ( * m_doubleInfo ) . m_strLen_or_Ind . data ( ) , ( * m_doubleInfo ) . m_columnNames , false ) ; GetResultColumn ( 0 , SQL_C_DOUBLE , m_DoubleSize , 0 , SQL_NO_NULLS ) ; GetResultColumn ( 1 , SQL_C_DOUBLE , m_DoubleSize , 0 , SQL_NULLABLE ) ; }
Name: GetDoubleResultColumnsTest
Description:
Tests GetResultColumn with default script using an OutputDataSet of Double columns.
Name : GetDoubleResultColumnsTest Description : Tests GetResultColumn with default script using an OutputDataSet of Double columns .
// Initialize with a default Session that prints Hello RExtension // and assigns InputDataSet to OutputDataSet // // validate // columnNumber // dataType // columnSize // decimalDigits // nullable // columnNumber // dataType // columnSize // decimalDigits // nullable