Skip to content

testing: adding catalog api and large table fetch benchmark testcase#1561

Draft
Anshu6250 wants to merge 4 commits into
mainfrom
catalog-api-benchmarks
Draft

testing: adding catalog api and large table fetch benchmark testcase#1561
Anshu6250 wants to merge 4 commits into
mainfrom
catalog-api-benchmarks

Conversation

@Anshu6250

Copy link
Copy Markdown
Collaborator

No description provided.

@Anshu6250 Anshu6250 changed the title testing: adding catalop api benchmark testcase testing: adding catalog api benchmark testcase Jun 15, 2026
ASSERT_EQ(Connect(connection_string, conn), SQL_SUCCESS) << "Failed to connect to the database.";

// Generate 90 Lakh (9,000,000) rows by cross-joining two arrays of 3,000
std::string query = R"(

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't do this, utilise the existing tables like kirltest tables for huge data and all_data_types I think exists for all data types

@Anshu6250 Anshu6250 force-pushed the catalog-api-benchmarks branch 3 times, most recently from 9417f45 to 15288a7 Compare June 16, 2026 10:50
@Anshu6250 Anshu6250 force-pushed the catalog-api-benchmarks branch from 15288a7 to f36e919 Compare June 16, 2026 10:52
@Anshu6250 Anshu6250 changed the title testing: adding catalog api benchmark testcase testing: adding catalog api and large table fetch benchmark testcase Jun 16, 2026
case SQL_FLOAT:
case SQL_DOUBLE: col_ptr->data_type = SQL_C_DOUBLE; break;
case SQL_BIT: col_ptr->data_type = SQL_C_BIT; break;
default: col_ptr->data_type = SQL_C_CHAR; break;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have cases for other data types as well like date, time, numeric, range

DescribeCol(conn, col_ptr, i);

switch (col_ptr->data_type) {
case SQL_BIGINT:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here have cases for other data types as well like date, time, numeric, range

TEST(DataFetchPerformance, Benchmark_PowerBI_Mimic_NewTimestampTable) {
auto conn = std::make_shared<ODBCHandles>();

std::string connection_string = kDefaultConnectionString + ";AllowHtapiForLargeResults=1;HTAPI_ActivationThreshold=0;";

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make all test cases parametrized and run with htapi and without

DescribeCol(conn, col_ptr, i);

switch (col_ptr->data_type) {
case SQL_BIGINT:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of doing this , use SqlToCdataTypes(col_ptr) instead , as here we are not doing conversion simply returning as string, maybe can have a separate test case to bind with SQL_C_CHAR only

@Anshu6250 Anshu6250 force-pushed the catalog-api-benchmarks branch from c2a572d to a21251d Compare June 17, 2026 09:09
@Anshu6250 Anshu6250 force-pushed the catalog-api-benchmarks branch from a21251d to c73f564 Compare June 17, 2026 09:21
@sachinpro

Copy link
Copy Markdown
Collaborator
  1. There should be a separate cmake target.
  2. The benchmark CI pipeline should not build the driver, only that target.
  3. After building the installer, windows-cmake CI pipeline should trigger another one for benchmarks. The installer should be uploaded to bq-dev-tools-testing-drivers/odbc-perf/ and a text file with the results will be uploaded by the 2nd pipeline.

@sachinpro

Copy link
Copy Markdown
Collaborator

@Anshu6250 In this PR, create the cmake target only. We can make the CI changes in the next one.

break;
case SQL_VARCHAR:
case SQL_CHAR:
case SQL_NUMERIC:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why are we returning SQL_NUMERIC and SQL_DECIMAL as SQL_C_CHAR ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants