Some use cases require a large amount of data to be inserted into a database table. A typical example in Strategy is a data mart report, or a multi-statement SQL report where a temp table is created to store intermediate results. If the data of a temporary table is inserted using an 'insert into values' query, you can enable parameterized queries to turn on bulk insert and therefore improve performance.

Sample parameterized query SQL:
INSERT INTO DMTABLE (Customer_ID, Customer_Name) VALUES (?, ?)
Follow the solutions below to improve bulk insert performance after parameterized queries are enabled for the following gateways:
Bulk insert is supported in Hive ODBC and JDBC with the following settings in addition to enabling parameterized queries:
NATIVE QUERY: OFF

VLDB Syntax Change


"Insert Into Values Pattern"property. Change the value to
"insert into #0 values (##0)"and save the file.



Tuning Performance via PARAM_QUERY_ROWSET_SIZE
PARAM_QUERY_ROWSET_SIZEin the ODBCConfig.ini file and add a new section similar to the one shown in the image below.
PARAM_QUERY_ROWSET_SIZEparameter, add the lines shown below (adjusting for a number of rows to insert at a time) to the ODBCConfig.ini file located at:
<Installation Path>\Common Files\Strategy
<Installation Path>/MicroStrategy/install

Strategy's in-house test results for Hive:
Execution Time | Execution Time | Execution Time |
Execution Time | Execution Time | Execution Time |
Bulk insert is supported in Spark and Impala ODBC and JDBC with the following settings once parameterized queries are turned ON:
NATIVE QUERY: OFF
While creating the DSN, make sure Use Native Query is not selected.
Tuning Performance via PARAM_QUERY_ROWSET_SIZE
You can also test the performance for an ODBC driver by changing the batch size. Modify the batch size in the z:\bin\x64\ODBCConfig.ini file and add a new section similar to the one shown in the image below. You must enter the database ID, database name, and the batch size you want to test the driver with.

Strategy's in-house test results for Spark:
Execution Time | Execution Time | Execution Time |
Execution Time | Execution Time | Execution Time |
Execution Time | Execution Time | Execution Time |