Brilliant Database Software - Home
Database software - Online Help System

Online Help System

Back to Brilliant Database Web-Site | Write to Support | Help Index

External DB SQL Query

table border="0" width="100%" cellspacing="0" cellpadding="4" bgcolor="#00000077">
External DB SQL Query

Parameters: SQL Query, Records Separator, Fields Separator

This action sends a unique query (multiple queries are not supported) to the opened external database. Before using this action an external database (e.g. MySQL, Access, MS SQL, etc) must be opened using the "Connect to External DB" action.

"SQL Query" is a text formula so you can use any field or variable values to pass to external database

SELECT * FROM users WHERE id=[user_id] ([user_id] will be replaced with the value of the "User_ID" field of the current record in Brilliant Database)
UPDATE users SET name="Tom" Where ID=[user_id]
DELETE FROM users WHERE name="[$name_to_del]"

In case of "SELECT" query this action will return one big string with all the query result rows in one big text. To specify custom separators for rows and columns use the "Records separator" and "Fields separator" parameters. E.g. with default separators the result of "SELECT" query can look like:
id, name, age
1, Tom, 34
2, Bill, 39
3, Mary, 25

It is better to use the special "For each record from SQL query (External DB)" cycle to work with the "SELECT" query results.

All topics in the "Import/Export/Send Operations" section: