The ajExecuteSQL function executes a SQL Statement and then returns the result. We can use this in Excel to allow users to execute SQL statements that were not possible previously.
Some common SQL statements like
SELECT - extracts data from a database
UPDATE - updates data in a database
DELETE - deletes data from a database
INSERT INTO - inserts new data into a database
CREATE DATABASE - creates a new database
ALTER DATABASE - modifies a database
CREATE TABLE - creates a new table
ALTER TABLE - modifies a table
DROP TABLE - deletes a table
CREATE INDEX - creates an index (search key)
DROP INDEX - deletes an index
All the above can be easily run in Excel just like a normal function.
Below is one of the samples on how you can run it with AlchemyJ
Let me know what you think on the comments below.