<?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: Update Transparent Tables in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996583#M1343497</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello vikred, everybody, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you suggested I'm doing like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	data: wa_transptabl type z_transptabl, it_transptabl like standard table of wa_transptabl.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	select FLD1 FLD2 FLD3&lt;/P&gt;&lt;P&gt;	into table it_transptabl&lt;/P&gt;&lt;P&gt;	from R3TABLE&lt;/P&gt;&lt;P&gt;	where FLD1 ne ''.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	loop at it_interloc into wa_interloc.&lt;/P&gt;&lt;P&gt;	    wa_interloc-ZINTIND = '0007'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	****************************************************&lt;/P&gt;&lt;P&gt;	&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;I want to insert current field into "z_transptabl" transparent table &amp;lt;--- how?&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;	****************************************************&lt;/P&gt;&lt;P&gt;	endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Bernardo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 20 Aug 2009 20:54:21 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-08-20T20:54:21Z</dc:date>
    <item>
      <title>Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996576#M1343490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) I've created a transparent table&lt;/P&gt;&lt;P&gt;2) Transparent table is loaded by running a SELECT including tables (e.g.: R/3's VTTK, VTPA)&lt;/P&gt;&lt;P&gt;3) Updates must be done on transparent table data, so I need to loop at table, make field updates according some specific criteria&lt;/P&gt;&lt;P&gt;4) A CURSOR fetches data into another structure / CURSOR must be based on transparent table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would like to know how to complete step n°3), I mean, loop at transparent table, update fields record by record, etc.. Are used table types fine? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope you could help. Thanks!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bernardo&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 00:01:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996576#M1343490</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T00:01:58Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996577#M1343491</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can't loop through the transparent table data.&lt;/P&gt;&lt;P&gt;Data needs to be extracted into an internal table.&lt;/P&gt;&lt;P&gt;Then update the internal table.&lt;/P&gt;&lt;P&gt;Finally MODIFY or UPDATE the transparent table using internal table.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 00:54:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996577#M1343491</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T00:54:55Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996578#M1343492</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tampering with standard sap tables, &lt;/P&gt;&lt;P&gt;it not at all advisable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The data in this table comes from transactions,&lt;/P&gt;&lt;P&gt;and these transactions validate the data,&lt;/P&gt;&lt;P&gt;only after that it dumps the business data in such tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the reason why VTTK, VTPA table does not&lt;/P&gt;&lt;P&gt;have table maintenance, and sap has not&lt;/P&gt;&lt;P&gt;provided any maintenance for it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; For such requirements,&lt;/P&gt;&lt;P&gt;one way is to create a Z program,&lt;/P&gt;&lt;P&gt;which has a selection screen&lt;/P&gt;&lt;P&gt;asking for the primary key selection&lt;/P&gt;&lt;P&gt;(Inspection Lot Number in your case)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Then after that, using SQL, it updates&lt;/P&gt;&lt;P&gt;the field of that row.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Still such things are not advisable. &lt;/P&gt;&lt;P&gt;Its necessasry to have the confirmation&lt;/P&gt;&lt;P&gt;and signature of functional consultant,&lt;/P&gt;&lt;P&gt;which touching standard sap tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Thanks &amp;amp; Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Saurabh Goel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 03:49:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996578#M1343492</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T03:49:46Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996579#M1343493</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;we do not loop in transparent tables.&lt;/P&gt;&lt;P&gt;fetch them to a internal table. use &lt;STRONG&gt;select&lt;/STRONG&gt; for this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then loop at this internal table and modify the internal table as needed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;then modify the transparent table from this internal table.&lt;/P&gt;&lt;P&gt;MODIFY ztest FROM TABLE gt_test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;here ztest is transparent table and gt_test is internal table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 04:49:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996579#M1343493</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T04:49:24Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996580#M1343494</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you dont have to loop at the transperant table. Instead loop at the internal table. Just use the UPDATE and SET statement to update the database table with conditions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

" After the select statement and when  the internal table is filled

loop at itab.
UPDATE ZTABLE SET field1 = itab-field1 
where field2 = 'ABC'.                   " Any condition based on which the table has to be updated
endloop.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vik&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 04:50:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996580#M1343494</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T04:50:22Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996581#M1343495</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;how can u loop the sap transparent table?&lt;/P&gt;&lt;P&gt;u cant , u should fetch the dat afrom transaparent table to a internal table , then loop the internal table and then get the required data in the internal table and then modify the sap transapranet table from the internal table.&lt;/P&gt;&lt;P&gt;still modifying the trnsparent table is not advisable programatically,as it keeps the data from the transaction.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u decide what is the requirement exactly , and wht u want to do&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 05:36:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996581#M1343495</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T05:36:02Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996582#M1343496</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;how can u loop the sap transparent table?&lt;/P&gt;&lt;P&gt;u cant , u should fetch the dat afrom transaparent table to a internal table , then loop the internal table and then get the required data in the internal table and then modify the sap transapranet table from the internal table.&lt;/P&gt;&lt;P&gt;still modifying the trnsparent table is not advisable programatically,as it keeps the data from the transaction.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u decide what is the requirement exactly , and wht u want to do&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 05:39:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996582#M1343496</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T05:39:53Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996583#M1343497</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello vikred, everybody, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you suggested I'm doing like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	data: wa_transptabl type z_transptabl, it_transptabl like standard table of wa_transptabl.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	select FLD1 FLD2 FLD3&lt;/P&gt;&lt;P&gt;	into table it_transptabl&lt;/P&gt;&lt;P&gt;	from R3TABLE&lt;/P&gt;&lt;P&gt;	where FLD1 ne ''.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	loop at it_interloc into wa_interloc.&lt;/P&gt;&lt;P&gt;	    wa_interloc-ZINTIND = '0007'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	****************************************************&lt;/P&gt;&lt;P&gt;	&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;I want to insert current field into "z_transptabl" transparent table &amp;lt;--- how?&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;	****************************************************&lt;/P&gt;&lt;P&gt;	endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Bernardo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2009 20:54:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996583#M1343497</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-20T20:54:21Z</dc:date>
    </item>
    <item>
      <title>Re: Update Transparent Tables</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996584#M1343498</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bernardo,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Assuming FLD1, FLD2 &amp;amp; FLD3 are the keys of the transparent table z_transptabl, try it like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;loop at it_interloc into wa_interloc.
 wa_interloc-ZINTIND = '0007'.
 update z_transptabl 
      set ZINTIND = wa_interloc-ZINTIND
      where FLD1  = wa_interloc-FLD1
      and   FLD2  = wa_interloc-FLD2
      and   FLD3  = wa_interloc-FLD3.
 if sy-subrc ne 0.
* your error handling goes here...
 endif.
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Sougata.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2009 04:35:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-transparent-tables/m-p/5996584#M1343498</guid>
      <dc:creator>Sougata</dc:creator>
      <dc:date>2009-08-21T04:35:44Z</dc:date>
    </item>
  </channel>
</rss>

