Requirements for AI Analyses
To execute AI-based Analyses in dab Nexus, a SQL Server with support for R-based Machine Learning Services is required. This article describes the necessary prerequisites and how to prepare the SQL Server environment.
Supported SQL Server Environments
dab Nexus supports the following environments for AI Analyses:
- SQL Server 2019 (Standard / Enterprise)
- SQL Server 2022
- SQL Server on Windows Server inside an Azure Virtual Machine
- Machine Learning Services installed and configured
Not supported
- Azure SQL Database
- Azure SQL Managed Instance
- SQL Server Express
- SQL Server on Linux
1. SQL Server Preparation
A SQL Server instance is required for executing R scripts used by AI Analyses. Choose one of the supported deployment options below.
1.1 SQL Server On-Premises Installation
During installation of SQL Server, ensure the following components are selected:
- Machine Learning Services
Microsoft documentation:
1.2 SQL Server on Azure Virtual Machine
If you operate dab Nexus inside Azure as a Managed Application, you may deploy SQL Server as an Azure Virtual Machine.
Recommended Marketplace Image
- SQL Server 2019 / 2022 on Windows Server
- SQL Server 2025 images are currently not supported
- We recommend to not use Marketplace images with “pre-configured” options
Required configuration during VM deployment
- R Services (Advanced Analytics) Enabled
If Machine Learning Services were not selected during deployment, they must be installed afterwards (see Step 2).
Microsoft documentation:
1.3 Adding Machine Learning Services to an existing SQL Server Instance
This process is documented for the following supported SQL Server Versions. Only follow the steps till the end of the step "Run setup". The R configuration is done later in step 2.
2. Enable Machine Learning Services
AI Analyses require R-based Machine Learning Services to be active and operational on the SQL Server.
2.1 Enable external script execution
Run the following command on the SQL instance:
sp_configure 'external scripts enabled', 1;
RECONFIGURE;
Restart the following service afterwards: SQL Server Launchpad
2.2 Verification
Execute the following on the SQL Server instance:
EXEC sp_execute_external_script @language = N'R', @script = N'print("OK")';
Expected output: OK
Troubleshooting: Known Issues for SQL Server Machine Learning Services
Verification
EXEC sp_execute_external_script @language = N'R', @script = N'str(installed.packages( [,c("Package","Version")])';
3. Installing the R Runtime
To execute AI Analyses, a functional R runtime must be available on the SQL Server. You can either use our prepackaged R runtime provided by dab, or create your own R installation manually, however the first one is heavily recommended.
3.1 Using a prepackaged R runtime (recommended)
We provide a ready-to-use R runtime that contains all required libraries for AI Analyses. This is the recommended option if you do not want to install or maintain an R environment yourself.
-
Download the R Runtime from Portal
- Go to dab Portal
- Navigate to: Portal → Products
- Download: dab AnalyticSuite R Runtime
-
Copy the runtime to the SQL Server Options:
- RDP copy/paste
- Azure Storage Explorer (recommended for Azure VMs)
- Windows file share
- SFTP or internal transfer tools
NoteEnsure that the runtime folder is placed on a local drive accessible by the SQL Server service account.
-
Create the installation folder manually Create the folder where the R runtime will be installed. Example: C:\Program Files\R\R-4.x.x>
Replace R-4.x.x with the version number from the ZIP file.
ImportantThis folder must be located in a directory accessible by the SQL Server service account (e.g., NT Service\MSSQLSERVER). Do not use user profile folders (Desktop, Downloads, Documents) or temporary folders.
-
Extract the R runtime into the installation folder Extract all files from the ZIP into the folder created in the previous step. The folder should now contain the full R runtime structure (bin, library, etc.).
-
Open Command Prompt as Administrator and navigate to the installation folder Open a Command Prompt with administrative privileges. Then change the current directory to the folder where you extracted the R runtime. Example: cd "C:\Program Files\R\R-4.x.x"
-
Register the R runtime with SQL Server Run the registration command:
RegisterRext.exe /configure /rhome:"C:\Program Files\R\R-4.x.x" /instance:"MSSQLSERVER"
Replace R-4.x.x and MSSQLSERVER if your installation uses different paths or an alternative instance name.
-
Restart the SQL Server Launchpad service Ensure the service named SQL Server Launchpad is running and set to Automatic. Restart the service if necessary.
-
Verify that the R runtime is working Execute a simple R test script on the SQL Server:
EXEC sp_execute_external_script @language = N'R', @script = N'print("Runtime OK")';The output "Runtime OK" confirms that SQL Server can execute R scripts.
3.2 Installation (On-Premises)
3.3 Installation on Azure SQL Server Virtual Machine (optional)
-
Connect to the VM Azure Portal → Connect → Download RDP File Login using the administrator account.
-
Transfer the R-Package
- RDP copy
- Azure Storage Explorer
- File share
-
Install the R-Package Run Command Prompt as Administrator:
.\RegisterRext.exe /configure .\RegisterRext.exe /configure /rhome:"C:\Program Files\R\R-4.5.0.12" /instance:"MYSQLSERVER"Check instance name:
SELECT @@SERVICENAME; -
Verify R
EXEC sp_execute_external_script @language = N'R', @script = N'print("AI Ready")'; -
List installed packages
EXEC sp_execute_external_script @language = N'R', @script = N'print(installed.packages())';
Troubleshooting
| Issue | Cause | Solution |
|---|---|---|
| R scripts do not execute | external scripts enabled disabled | Enable the setting + restart Launchpad |
| Launchpad does not start | Service misconfigured | Check Windows Services |
| R missing | ML Services not installed | Install ML Services |
| Nexus cannot connect | SQL Auth disabled / firewall | Enable SQL Auth, open port 1433 |
| Azure VM blocked | NSG rules | Allow traffic from Nexus subnet |