Join Sheeri Cabral for an in-depth discussion in this video Executing batch commands on a remote database, part of Understanding MariaDB for MySQL Users.
- View Offline
…The CONNECT storage engine works by passing through the SQL command to…the remote server.…This means that for each command you run, you're creating a connection.…If you want to send many queries and have less overhead.…You can combine statements in one connection by using…a special CONNECT TABLE.…This table looks like the CONNECT TABLEs we have been working with,…except there are two differences.…The first difference, is that we add in an option to the table to specify that…the table should be used to execute code and send it along in a batch.…
This option is called execsrc equals 1.…It is a table option that we will put at the end of our table.…The second difference is that there are special flags for each column.…A flag of 0 is the default.…And it indicates that this column contains the commands to be run.…A flag of 1 is the number of affected rows for a DML query, that is a right query.…If the query is a SELECT query, the column with a flag of one.…WIll return the number of columns in the result set.…
- Why use dynamic columns?
- Creating, updating, and querying dynamic columns
- Installing the CONNECT storage engine
- Connecting to remote data
- Connecting to CSV, INI, and XML files
- Using PIVOT tables
- Accessing database metadata
- Working with the Cassandra storage engine