This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hi all,
I need to update a database table using a table from Power Query. I know you can export the PowerQuery table as a csv using R, but I need to automate this process directly from power query.
I was able to create the R code to update the database from R Studio
con <- DBI::dbConnect(odbc::odbc(),
Driver = "SQL Server",
Server = "XXX\\SQLEXPRESS",
Database = "Test",
Trusted_Connection = "True")
dbWriteTable(con, "test_table", test_table)
dbDisconnect(con)
When I use this code in Power Query as an R script (using "dataset" as data), it gives me the following error:
DataSource.Error: ADO.NET: R script error.
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
namespace 'rlang' 0.2.0 is already loaded, but >= 0.4.5 is required
Calls: <Anonymous> ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted
Details:
DataSourceKind=R
DataSourcePath=R
Message=R script error.
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
namespace 'rlang' 0.2.0 is already loaded, but >= 0.4.5 is required
Calls: <Anonymous> ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted
ErrorCode=-2147467259
ExceptionType=Microsoft.PowerBI.Scripting.R.Exceptions.RScriptRuntimeException
Any help is appreciated! Thank you
Fix this issue:
namespace 'rlang' 0.2.0 is already loaded, but >= 0.4.5 is required
Small side comment: Neither R nor Power Query are replacements for SSIS...
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 4 | |
| 3 | |
| 3 | |
| 1 | |
| 1 |
| User | Count |
|---|---|
| 11 | |
| 10 | |
| 3 | |
| 3 | |
| 3 |