SQL Server Machine Learning Services: R
2h 12mAdvanced2024-08-13
Authors

Adam Wilbert
Data Visualization Expert
Course details
SQL Server now includes support for direct execution of R code. This integration allows complex data science analyses to be performed quickly in a secure environment, without having to export data sets first. In this course, database expert Adam Wilbert walks through the steps of enabling the required components—including Machine Learning Services for R—and writing basic R scripts. He also shows how to retrieve and work with data stored in SQL Server tables, create data visualizations with external R libraries, and package scripts as stored procedures. At the end of the course, traditional SQL Server users will be able to dive deeper into using R and traditional R developers will be able to take advantage of using SQL Server as the source of data to create higher-performing analyses.
Topics include:
Installing Machine Learning Services
Writing your first R script
Importing data
Querying data
Outputting data to a result set
Creating a data frame
Creating SQL stored procedures from R scripts
Producing graphs, plots, and charts
Creating an external data science client
Topics include:
Installing Machine Learning Services
Writing your first R script
Importing data
Querying data
Outputting data to a result set
Creating a data frame
Creating SQL stored procedures from R scripts
Producing graphs, plots, and charts
Creating an external data science client
Skills covered
SQL ServerRStatisticsDatabase AdministrationMachine LearningDatabase ManagementArtificial Intelligence (AI)Programming LanguagesData ScienceOpen SourceMicrosoftSoftware DevelopmentDeep Dive (X:Y)
Concepts
0. Introduction
- 01 - Analyze SQL Server data with R
- 02 - What you should know
- 03 - Make the most of the exercise files
1. Get Started with MLS
- 04 - What is Machine Learning Services (MLS)
- 05 - Install Machine Learning Services for R
- 06 - Enable script execution in SQL Server
- 07 - Write your first R script
- 08 - R data types
2. Write R Scripts for SQL Server
- 09 - Variables in R
- 10 - Import a data set from SQL Server
- 11 - Query data into an R data frame
- 12 - Output data to a result set
- 13 - Select values from a data frame
- 14 - Create a data frame from vectors
- 15 - Subset a data frame
- 16 - Challenge - Import data
- 17 - Solution - Import data
3. Create a SQL Stored Procedure
- 18 - Sample a data set
- 19 - Parameterize a stored procedure
- 20 - Challenge - Write a stored procedure
- 21 - Solution - Write a stored procedure
4. Output Graphics with R
- 22 - View installed packages
- 23 - Produce graphs and plots
- 24 - Create a bar plot
- 25 - Challenge - Create a pie chart
- 26 - Solution - Create a pie chart
5. Create an External Data Science Client
- 27 - Install MLS on a standalone server
- 28 - Add development tools to a client
- 29 - Install and configure RStudio
Conclusion
- 30 - Next steps
Related courses
- Complete Guide to Advanced SQL Server
- Microsoft Azure: Backup and Disaster Recovery
- SQL Server 2016: Provision a Database
- Learn System Center 2016: Operations Manager
- SQL Server Machine Learning Services: Python
- REST APIs, Vectors, and AI in SQL Server 2025
- Develop ML Models with Python and T-SQL
- Scala Essential Training for Data Science
Related learn paths
- Develop Your NoSQL Skills
- Prepare for the MTA: Software Development Fundamentals Exam (98-361)
- Networking and Administration Fundamentals
- Optimizing Enterprise Security and Productivity Using Microsoft 365
- Become a Programmer: Foundations
- Become an Ethical Hacker
- Getting Started as an ASP.NET Developer
- Introduction to Fundamental Skills for Data Work: Data Storage