Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
So I have table with [TimeStamp] in it and I have created a custom column with below formulae
=DateTimeZone.RemoveZone([TimeStamp])+#duration(0,3,0,0) ,
but this custom column was allowed in Import mode, when I do Direct Query I can't create one. How do I fix this in Direct query, which gives me same result as above code??
Solved! Go to Solution.
@PowerrrBrrr
Of course you can do that in dax, you may create the measure in Direct Query mode.
Best Regards
Paul
@PowerrrBrrr
Of course you can do that in dax, you may create the measure in Direct Query mode.
Best Regards
Paul
Please make sure the TimeStamp column in your datasource is already Datetime type before connecting to Power BI. Direct Query doesn't support changing Text type date column to datetime type.
Paul
The timestamp column in Power Bi do show the Datetime format in Modelling tab , though it does not show the calendar icon beside the field name as a normal datetime field will show in normal table in Power Bi but i believe that is direct query feature and direct query do not support hirearchy.
I am looking if someone can confirm that with direct query I can create a measure to add time to a timestamp column from a direct query table
yeah.. but this you cant create with direct query
@PowerrrBrrr
In this case you can just + 3 hours to the timestamp column. Direct Query just does not support the timezone function, which is not necessary.
=[TimeStamp]+#duration(0,3,0,0)
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
this is a measure what you have created ? I dont get the result when I create a measure.
I am afraid you can only switch the connect mode to import, this is a limitation of direct query. Is there any reason that you don't want to use import mode?
Use DirectQuery in Power BI Desktop - Power BI | Microsoft Docs
"To remedy the error, either delete the problematic step in Power Query Editor, or import the data instead of using DirectQuery."
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
its just we cant use import here, due to some limitation on data frequently changing. isnt there a way we can increase the hours in my timestamp field by 3 or 4 hours. thats all i need to change the time zone
User | Count |
---|---|
128 | |
108 | |
100 | |
64 | |
62 |
User | Count |
---|---|
136 | |
113 | |
102 | |
71 | |
60 |