<?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: Unable to apply datetime transformations in the storage block in Data Movement &amp; Streaming</title>
    <link>https://community.qlik.com/t5/Data-Movement-Streaming/Unable-to-apply-datetime-transformations-in-the-storage-block/m-p/2037187#M760</link>
    <description>&lt;P&gt;Hi,&amp;nbsp; &amp;nbsp;In Qlik Cloud Data Integration it is important to understand WHERE the transformations are performed in each task you create in your pipeline.&amp;nbsp;&lt;BR /&gt;&lt;STRONG&gt;Landing&lt;/STRONG&gt; -&amp;nbsp; &amp;nbsp;When adding expressions in the Landing task, transformations are executed before the data is landed into your cloud data platform.&amp;nbsp; &amp;nbsp;These transformations / expressions are executed in the gateway and leverage SQLLITE based SQL.&amp;nbsp; &amp;nbsp; In general, these transformations should be designed as necessary for use cases like obfuscating data before it lands in the target.(eg. 256 bit hash a SSN, or only load the last 4 digits of a phone number).&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&lt;STRONG&gt;Storage, Transform, Data Mart&amp;nbsp;&lt;/STRONG&gt; - When adding expressions in the Storage / Transform / Data Mart task the transformations are executed in a ELT manner - in your target data platform.&amp;nbsp; &amp;nbsp;These expressions should be written using the SQL of your target platform.&amp;nbsp; (e.g&amp;nbsp; &amp;nbsp;SQL that would run in Snowflake / BigQuery / Databricks etc.).&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since there is a dialect difference between LANDING and the other tasks - this is likely why your transform is not working correctly. A good way to test is, on the DataSets screen - select your dataset, click the ... and you can see the generated code.&amp;nbsp; There you can pull out the full load SQL - and run the select to check the syntax / data in your target platform.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 13 Feb 2023 14:26:01 GMT</pubDate>
    <dc:creator>TimGarrod</dc:creator>
    <dc:date>2023-02-13T14:26:01Z</dc:date>
    <item>
      <title>Unable to apply datetime transformations in the storage block</title>
      <link>https://community.qlik.com/t5/Data-Movement-Streaming/Unable-to-apply-datetime-transformations-in-the-storage-block/m-p/2037093#M759</link>
      <description>&lt;P&gt;Hi All,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have 5 tables that I am moving from MySQL to Snowflake, and I am going through Landing-&amp;gt;Storage-&amp;gt;Transform-&amp;gt;DataMart process.&lt;/P&gt;
&lt;P&gt;In one of the tables, I have 2 columns namely ShipDate (DATETIME) and DueDate (DATETIME). Using these 2 fields I am trying to find the delay in shipment by finding the difference between these 2 fields by adding a new column called Shipment_status&amp;nbsp; (STRING(15)). Also, I am adding another column called Shipment_bucket (STRING(50)) to see in which buckets does the shipment status fall into.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Expression for Shipment_status:&amp;nbsp;$IFF(${ShipDate}-${DueDate} &amp;lt;=0, 'on-time', 'delayed')&lt;/P&gt;
&lt;P&gt;Expression for Shipment_bucket:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;$IFF(${ShipDate}-${DueDate} &amp;gt;0 AND ${ShipDate}-${DueDate}&amp;lt;=1, '1-day Delay',&lt;BR /&gt;$IFF(${ShipDate}-${DueDate} &amp;gt;1 AND ${ShipDate}-${DueDate}&amp;lt;=2, '2-day Delay', &lt;BR /&gt;$IFF(${ShipDate}-${DueDate} &amp;gt;2 AND ${ShipDate}-${DueDate}&amp;lt;=3, '3-day Delay', &lt;BR /&gt;$IFF(${ShipDate}-${DueDate}&amp;gt;3, ' &amp;gt; 3-day Delay','On-time'))))&lt;/P&gt;
&lt;P&gt;These two expressions are working when they are applied in the landing zone. But when I apply the same in the storage zone it gives me an error that UNKNOW Error: Numeric value cannot be handled.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried to convert both shipdate and duedate using date() and datetime() function.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, in the storage section any transformation involving number columns are working.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Kindly suggest if I am missing something.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 19 Mar 2025 23:06:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Data-Movement-Streaming/Unable-to-apply-datetime-transformations-in-the-storage-block/m-p/2037093#M759</guid>
      <dc:creator>akaradhya</dc:creator>
      <dc:date>2025-03-19T23:06:21Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to apply datetime transformations in the storage block</title>
      <link>https://community.qlik.com/t5/Data-Movement-Streaming/Unable-to-apply-datetime-transformations-in-the-storage-block/m-p/2037187#M760</link>
      <description>&lt;P&gt;Hi,&amp;nbsp; &amp;nbsp;In Qlik Cloud Data Integration it is important to understand WHERE the transformations are performed in each task you create in your pipeline.&amp;nbsp;&lt;BR /&gt;&lt;STRONG&gt;Landing&lt;/STRONG&gt; -&amp;nbsp; &amp;nbsp;When adding expressions in the Landing task, transformations are executed before the data is landed into your cloud data platform.&amp;nbsp; &amp;nbsp;These transformations / expressions are executed in the gateway and leverage SQLLITE based SQL.&amp;nbsp; &amp;nbsp; In general, these transformations should be designed as necessary for use cases like obfuscating data before it lands in the target.(eg. 256 bit hash a SSN, or only load the last 4 digits of a phone number).&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&lt;STRONG&gt;Storage, Transform, Data Mart&amp;nbsp;&lt;/STRONG&gt; - When adding expressions in the Storage / Transform / Data Mart task the transformations are executed in a ELT manner - in your target data platform.&amp;nbsp; &amp;nbsp;These expressions should be written using the SQL of your target platform.&amp;nbsp; (e.g&amp;nbsp; &amp;nbsp;SQL that would run in Snowflake / BigQuery / Databricks etc.).&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since there is a dialect difference between LANDING and the other tasks - this is likely why your transform is not working correctly. A good way to test is, on the DataSets screen - select your dataset, click the ... and you can see the generated code.&amp;nbsp; There you can pull out the full load SQL - and run the select to check the syntax / data in your target platform.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Feb 2023 14:26:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Data-Movement-Streaming/Unable-to-apply-datetime-transformations-in-the-storage-block/m-p/2037187#M760</guid>
      <dc:creator>TimGarrod</dc:creator>
      <dc:date>2023-02-13T14:26:01Z</dc:date>
    </item>
  </channel>
</rss>

