<?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: Automatically update the ZTABLE in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581429#M2009304</link>
    <description>&lt;P&gt;Holding the same data in two tables indicates a design problem. Either use a view, CDS or otherwise, or have the program that reads from ZTABLE get the information directly from USR02.&lt;/P&gt;&lt;P&gt;I cannot think of a single reason why you'd need to do what you want to do. Often people say "I have this requirement", when they mean "this is my solution to my requirement, how can I do it".&lt;/P&gt;&lt;P&gt;What is your end goal? What are you trying to achieve overall? (And please don't reiterate your question - we understand that).&lt;/P&gt;</description>
    <pubDate>Fri, 01 Jul 2022 09:01:34 GMT</pubDate>
    <dc:creator>matt</dc:creator>
    <dc:date>2022-07-01T09:01:34Z</dc:date>
    <item>
      <title>Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581424#M2009299</link>
      <description>&lt;P&gt;I have created a z table which contains the users validity date.&lt;/P&gt;
  &lt;P&gt;my requirement is whenever i change this validity date in &lt;STRONG&gt;SU01 &lt;/STRONG&gt;transaction the value in the z table should also be changed automatically.&lt;/P&gt;
  &lt;P&gt;Thank you,&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 08:04:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581424#M2009299</guid>
      <dc:creator>former_member806481</dc:creator>
      <dc:date>2022-07-01T08:04:26Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581425#M2009300</link>
      <description>&lt;P&gt;So strange, you have the information, but you want the same information in another table .... &lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 08:09:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581425#M2009300</guid>
      <dc:creator>FredericGirod</dc:creator>
      <dc:date>2022-07-01T08:09:37Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581426#M2009301</link>
      <description>&lt;P&gt;yes but that z table has multiple different field from multiple different tables so ............&lt;/P&gt;&lt;P&gt;lets say the current validity date is &lt;STRONG&gt;01-01-2022&lt;/STRONG&gt; in the &lt;STRONG&gt;SU01 &lt;/STRONG&gt;and also in the ZTABLE&lt;/P&gt;&lt;P&gt;now if i go to &lt;STRONG&gt;SU01 &lt;/STRONG&gt;and change the date to &lt;STRONG&gt;01-01-2021&lt;/STRONG&gt;  then my z table should be automatiacally updated with the new value&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 08:15:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581426#M2009301</guid>
      <dc:creator>former_member806481</dc:creator>
      <dc:date>2022-07-01T08:15:15Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581427#M2009302</link>
      <description>&lt;P&gt;What about a CDS view melting all your different data ? &lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 08:17:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581427#M2009302</guid>
      <dc:creator>FredericGirod</dc:creator>
      <dc:date>2022-07-01T08:17:20Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581428#M2009303</link>
      <description>&lt;P&gt;no need for CDS &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 08:25:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581428#M2009303</guid>
      <dc:creator>former_member806481</dc:creator>
      <dc:date>2022-07-01T08:25:14Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581429#M2009304</link>
      <description>&lt;P&gt;Holding the same data in two tables indicates a design problem. Either use a view, CDS or otherwise, or have the program that reads from ZTABLE get the information directly from USR02.&lt;/P&gt;&lt;P&gt;I cannot think of a single reason why you'd need to do what you want to do. Often people say "I have this requirement", when they mean "this is my solution to my requirement, how can I do it".&lt;/P&gt;&lt;P&gt;What is your end goal? What are you trying to achieve overall? (And please don't reiterate your question - we understand that).&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 09:01:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581429#M2009304</guid>
      <dc:creator>matt</dc:creator>
      <dc:date>2022-07-01T09:01:34Z</dc:date>
    </item>
    <item>
      <title>Re: Automatically update the ZTABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581430#M2009305</link>
      <description>&lt;P&gt;Actually i figured it out my self &lt;/P&gt;&lt;P&gt;I created a report and exectued it as a background job for every 1 min (because i wanted to test it quickly).&lt;/P&gt;&lt;P&gt;Here is the code that i have written.&lt;/P&gt;&lt;P&gt;DATA : lt_appid TYPE TABLE OF ztptp_w01_cde_v.&lt;BR /&gt;DATA : lt_subappid TYPE TABLE OF ztptp_w01_cde_v.&lt;BR /&gt;DATA : ls_appid TYPE ztptp_w01_cde_v.&lt;BR /&gt;DATA : ls_subappid TYPE ztptp_w01_cde_v.&lt;BR /&gt;&lt;BR /&gt;*&amp;amp; Main Approver------------------------------------------------------*&lt;BR /&gt;SELECT * FROM ztptp_w01_cde_v INTO CORRESPONDING FIELDS OF TABLE @lt_appid.&lt;BR /&gt;LOOP AT lt_appid INTO ls_appid.&lt;BR /&gt;  SELECT SINGLE gltgv,&lt;BR /&gt;  gltgb&lt;BR /&gt;  FROM usr02&lt;BR /&gt;  INTO @DATA(ls_usr02)&lt;BR /&gt;  WHERE bname = @ls_appid-zappuid.&lt;BR /&gt;*&lt;BR /&gt;  IF ls_usr02-gltgv &amp;lt;&amp;gt; ls_appid-vsdate.&lt;BR /&gt;    CLEAR ls_appid-vsdate.&lt;BR /&gt;    ls_appid-vsdate = ls_usr02-gltgv.&lt;BR /&gt;    APPEND ls_appid TO lt_appid.&lt;BR /&gt;    MODIFY ztptp_w01_cde_v FROM TABLE lt_appid.&lt;BR /&gt;  ENDIF.&lt;BR /&gt;  IF ls_usr02-gltgb &amp;lt;&amp;gt; ls_appid-vedate.&lt;BR /&gt;    CLEAR ls_appid-vedate.&lt;BR /&gt;    ls_appid-vedate = ls_usr02-gltgb.&lt;BR /&gt;    APPEND ls_appid TO lt_appid.&lt;BR /&gt;    MODIFY ztptp_w01_cde_v FROM TABLE lt_appid.&lt;BR /&gt;  ENDIF.&lt;BR /&gt;&lt;BR /&gt;ENDLOOP.&lt;BR /&gt;*&amp;amp;---------------------------------------------------------------------*&lt;BR /&gt;&lt;BR /&gt;*&amp;amp; Substitute Approver-------------------------------------------------*&lt;BR /&gt;SELECT * FROM ztptp_w01_cde_v INTO CORRESPONDING FIELDS OF TABLE @lt_subappid.&lt;BR /&gt;LOOP AT lt_subappid INTO ls_subappid.&lt;BR /&gt;  SELECT SINGLE gltgv,&lt;BR /&gt;  gltgb&lt;BR /&gt;  FROM usr02&lt;BR /&gt;  INTO @DATA(ls_usr02_01)&lt;BR /&gt;  WHERE bname = @ls_subappid-zsubappid.&lt;BR /&gt;*&lt;BR /&gt;  IF ls_usr02_01-gltgv &amp;lt;&amp;gt; ls_subappid-zvsdate.&lt;BR /&gt;    CLEAR ls_subappid-zvsdate.&lt;BR /&gt;    ls_subappid-zvsdate = ls_usr02_01-gltgv.&lt;BR /&gt;    APPEND ls_subappid TO lt_subappid.&lt;BR /&gt;    UPDATE ztptp_w01_cde_v FROM TABLE lt_subappid.&lt;BR /&gt;  ENDIF.&lt;BR /&gt;  IF ls_usr02_01-gltgb &amp;lt;&amp;gt; ls_subappid-zvedate.&lt;BR /&gt;    CLEAR ls_subappid-zvedate.&lt;BR /&gt;    ls_subappid-zvedate = ls_usr02_01-gltgb.&lt;BR /&gt;    APPEND ls_subappid TO lt_subappid.&lt;BR /&gt;    UPDATE ztptp_w01_cde_v FROM TABLE lt_subappid.&lt;BR /&gt;  ENDIF.&lt;BR /&gt;ENDLOOP.&lt;BR /&gt;*&amp;amp;---------------------------------------------------------------------*&lt;/P&gt;&lt;P&gt;Following is the screenshot of the Ztable i have created &lt;/P&gt;&lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/2068514-image.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG class="migrated-image" src="https://community.sap.com/legacyfs/online/storage/attachments/storage/7/attachments/2068515-image.png" /&gt;&lt;/P&gt;&lt;P&gt;RESULT : Whenever someone will change my validity date in SU01 transaction that date will be reflected in my table and i will not need not change it manually.&lt;/P&gt;&lt;P&gt;Also thank you for responding to my questions taking your time out.&lt;/P&gt;</description>
      <pubDate>Fri, 01 Jul 2022 10:57:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/automatically-update-the-ztable/m-p/12581430#M2009305</guid>
      <dc:creator>former_member806481</dc:creator>
      <dc:date>2022-07-01T10:57:06Z</dc:date>
    </item>
  </channel>
</rss>

