Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
In Power Query Editor, the text string is: 123547126811
Why is the text string in SQL Server: 123547126811.0?
R Script:
library(RODBC)
conn <- odbcDriverConnect("driver={SQL Server}; server=localhost;Database=**;uid=uid;pwd=password")
odbcClearError(conn)
sql="Delete T From
(Select Row_Number() Over(Partition By cust_id order By cust_id) As RowNumber,* From tmp)T
Where T.RowNumber > 1"
sqlSave(conn, dataset, tablename="tmp",rownames=FALSE, safer=FALSE, append=TRUE,fast=TRUE)
sqlQuery(conn,sql) #delete duplicate data.
close(conn)
because The PowerQuery M code run twice,so run delete duplicate sql in R Script.
Solved! Go to Solution.
using format function is ok:
dataset$cust_id <- format(dataset$cust_id)
using format function is ok:
dataset$cust_id <- format(dataset$cust_id)
Hi @luojiandan_bi ,
Check whether the data type has been changed automatically in power query,if so,close it.
Check the reference below:
https://a4accounting.com.au/stop-power-query-from-automatically-setting-data-types/
Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
wait for helping online.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
16 | |
10 | |
10 | |
8 | |
7 |