<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Is it possible to load a DateTime column into Power BI from OData v4? in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3924483#M52552</link>
    <description>&lt;P&gt;Hi there, thanks for trying to help.&lt;BR /&gt;&lt;BR /&gt;If I format the date as ISO 8601 "2024-05-30T12:00:00" format, I get the following error:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;DataSource.Error: OData: Cannot convert the literal '2024-05-01T00:00:00' to the expected type 'Edm.DateTimeOffset'.&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And yes, I can convert the column after loading the data into Power BI, &lt;STRONG&gt;but then I can't fold the query!&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CleanShot 2024-05-16 at 16.59.05@2x.png" style="width: 999px;"&gt;&lt;img src="https://community.fabric.microsoft.com/t5/image/serverpage/image-id/1099700i9916FD4106627D59/image-size/large?v=v2&amp;amp;px=999" role="button" title="CleanShot 2024-05-16 at 16.59.05@2x.png" alt="CleanShot 2024-05-16 at 16.59.05@2x.png" /&gt;&lt;/span&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 16 May 2024 14:59:53 GMT</pubDate>
    <dc:creator>alexbjorlig</dc:creator>
    <dc:date>2024-05-16T14:59:53Z</dc:date>
    <item>
      <title>Is it possible to load a DateTime column into Power BI from OData v4?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3922548#M52514</link>
      <description>&lt;P&gt;I'm a developer of an OData API, and also a Power BI maintainer.&lt;BR /&gt;&lt;BR /&gt;When I return a column like this in OData:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;&amp;lt;Property Name="Date" Type="Edm.DateTimeOffset"/&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Power BI always parses this as a "Date/Time/Zone".&lt;BR /&gt;&lt;BR /&gt;Is it possible to specify a type, or format of the date, so Power BI will parse the column as "Date/Time"?&lt;BR /&gt;&lt;BR /&gt;(If I could achieve this, it would be really great for query folding and incremental refresh).&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 16 May 2024 06:31:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3922548#M52514</guid>
      <dc:creator>alexbjorlig</dc:creator>
      <dc:date>2024-05-16T06:31:48Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to load a DateTime column into Power BI from OData v4?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3924356#M52545</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/204812"&gt;@alexbjorlig&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You can specify the date format in the OData API response so that Power BI resolves the column to "Date/Time" instead of "Date/Time/Region". However, this may depend on the capabilities of the OData server and the way it handles data types and formats. Here are some suggestions on how to accomplish this:&lt;BR /&gt;Set the date format in ISO 8601 format without time zone offset:&lt;BR /&gt;&amp;lt;Property Name="Date" Type="Edm.DateTimeOffset"/&amp;gt; Instead of returning the date in a format, you can format the date as a string in ISO 8601 format (without a timezone offset). For example, "2024-05-30T12:00:00" represents a date without a time zone offset. This format is widely recognized and should be resolved by Power BI as "date/time" regardless of time zone.&lt;/P&gt;&lt;P&gt;If the OData API does not directly control the format of the date in the response, you can use Power BI's Query Editor to transform the data. After loading the data into Power BI, you can use the query editor to parse the date string into the Date/Time data type using the DateTime.FromText() function and specify the appropriate format.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;hackcrr&lt;/P&gt;&lt;P&gt;If this post helps, then please consider&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;EM&gt;&lt;STRONG&gt;Accept it as the solution&lt;/STRONG&gt;&lt;/EM&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;to help the other members find it more quickly.&lt;/P&gt;</description>
      <pubDate>Thu, 16 May 2024 13:49:50 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3924356#M52545</guid>
      <dc:creator>hackcrr</dc:creator>
      <dc:date>2024-05-16T13:49:50Z</dc:date>
    </item>
    <item>
      <title>Re: Is it possible to load a DateTime column into Power BI from OData v4?</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3924483#M52552</link>
      <description>&lt;P&gt;Hi there, thanks for trying to help.&lt;BR /&gt;&lt;BR /&gt;If I format the date as ISO 8601 "2024-05-30T12:00:00" format, I get the following error:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;DataSource.Error: OData: Cannot convert the literal '2024-05-01T00:00:00' to the expected type 'Edm.DateTimeOffset'.&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And yes, I can convert the column after loading the data into Power BI, &lt;STRONG&gt;but then I can't fold the query!&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="CleanShot 2024-05-16 at 16.59.05@2x.png" style="width: 999px;"&gt;&lt;img src="https://community.fabric.microsoft.com/t5/image/serverpage/image-id/1099700i9916FD4106627D59/image-size/large?v=v2&amp;amp;px=999" role="button" title="CleanShot 2024-05-16 at 16.59.05@2x.png" alt="CleanShot 2024-05-16 at 16.59.05@2x.png" /&gt;&lt;/span&gt;&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 16 May 2024 14:59:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Is-it-possible-to-load-a-DateTime-column-into-Power-BI-from/m-p/3924483#M52552</guid>
      <dc:creator>alexbjorlig</dc:creator>
      <dc:date>2024-05-16T14:59:53Z</dc:date>
    </item>
  </channel>
</rss>

