Request a license file from Ninox for your Private Cloud or On-Premises that is granted full access
for one of these Enterprise features: mssqlConnections
or pgConnections
.
Install the license file on your Private Cloud or On-Premises.
Get the following environment variables from your SQL Server:
Server name: MSSQL_SERVER
, e.g., mssqltest1.database.windows.net
Database name: DB_NAME
, e.g., mssql-test.ninoxdb.de
Server admin: MSSQL_SA
, e.g., nx-testsqlserver-admin
Password: MSSQL_SA_PASSWORD
Once you install the appropriate license file, the tab SQL Connections becomes visible in the Server Administration section in your Private Cloud or On-Premises.
Log in to your Private Cloud or On-Premises.
Click the SQL Connections tab, then click Create New Connection.
Under SQL Connection, paste the configuration details from #prerequisites into the fields below:
Name: enter a new name for this connection
Connection Type: select MS SQL Server from the dropdown menu
Active: tick the checkbox to set to true
Server: see Server name in #prerequisites
Database: e.g., mssql-test.ninoxdb.de
User: see Server admin in #prerequisites
Password: see Password in #prerequisites
Encrypted: tick the checkbox to set to true
Click the Save and Restart button.
Since we are using our own Ninox Private Cloud and SQL Server data in the validation steps, your results may look different than the ones below.
To validate the SQL connection, we are using a sample database that contains 1 table, 1 sub-table, and 3 fields:
SQL Connections
: a table
Connection name
: a text field to enter the name of the SQL connection
SQL Tests
: a sub-table
SQL Query or Command
: a text field to enter an SQL query or command
Result or Error
: a multiline text field to receive the result of the SQL query or command
sendCommand
Add a button, then add the following script that is triggered on click:
In the sub-table SQL Tests
, add a new record to run the following command in the SQL Query or Command field (1):
Click the sendCommand button (2). The following result appears in the Result or Error field (3):
{"result":{"recordsets":[[{"":1}]],"recordset":[{"":1}],"output":{},"rowsAffected":[1]}}
queryConnection
Add a button, then add the following script that is triggered on click:
In the sub-table SQL Tests
, add a new record to run the following command in the SQL Query or Command field (1):
Click the queryConnection button (2) to return actual record data. The following result appears in the Result or Error field (3):
{"result":[{"":1}]}
SQL Server Connector configuration is an Enterprise feature available on request that requires a valid license purchased from Ninox or a certified partner.
SQL Server Connector configuration is going to be released in 3.7.0 for Private Cloud starting September 20, 2022.
Some Ninox functions may change in future versions.
Current Ninox functions for SQL only work on the server side.
SQL commands with large data transfers may fail.
Data streaming is currently not available in Ninox.
We recommend implementing security options on the SQL Server side.
Any user can run any SQL command in Ninox.
We recommend setting up the login on the SQL Server side.
A dedicated log for SQL Server Connectors is currently not available in Ninox.
SQL Server Connectors are particularly helpful in cases such as:
You manage your production data in an SQL database and your CRM data in Ninox. For some reports you need to fetch a fitting, complex product ID from the production database.
You manage your CRM data with Microsoft Dynamics Navision (which is based on an SQL database). You need specific data for your Ninox application. Instead of manually exporting .csv
files and importing them to Ninox, you'd like transfer these files automatically.
In Ninox, click the gear icon to access the global settings, then select Server Administration from the dropdown menu.
SQL Server Connectors allow you to query and create tables in an external SQL Server database. In relation to Ninox, SQL Server Connectors help you connect your Private Cloud or On-Premises to an external relational database management system. Refer to SQL Server Connectors (external help page) for more info.