{"id":1091,"date":"2018-11-28T10:33:46","date_gmt":"2018-11-28T03:33:46","guid":{"rendered":"http:\/\/www.todsapon.com\/story\/?p=1091"},"modified":"2020-06-02T11:20:05","modified_gmt":"2020-06-02T04:20:05","slug":"abap-code-how-to-delete-data-duplicates-of-query","status":"publish","type":"post","link":"https:\/\/www.todsapon.com\/story\/programmer\/abap-code-how-to-delete-data-duplicates-of-query","title":{"rendered":"ABAP Code:How to delete data duplicates of query"},"content":{"rendered":"<div id=\"attachment_985\" style=\"width: 680px\" class=\"wp-caption aligncenter\"><a href=\"http:\/\/www.todsapon.com\/story\/wp-content\/uploads\/2018\/11\/sap-abap.jpg\" data-rel=\"lightbox-image-0\" data-rl_title=\"\" data-rl_caption=\"\" title=\"\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-985\" class=\"size-full wp-image-985\" src=\"http:\/\/www.todsapon.com\/story\/wp-content\/uploads\/2018\/11\/sap-abap.jpg\" alt=\"ABAP Code How to delete data duplicates of query\" width=\"670\" height=\"320\" srcset=\"https:\/\/www.todsapon.com\/story\/wp-content\/uploads\/2018\/11\/sap-abap.jpg 670w, https:\/\/www.todsapon.com\/story\/wp-content\/uploads\/2018\/11\/sap-abap-300x143.jpg 300w\" sizes=\"auto, (max-width: 670px) 100vw, 670px\" \/><\/a><p id=\"caption-attachment-985\" class=\"wp-caption-text\">ABAP Code How to delete data duplicates of query<\/p><\/div>\n<p>\u0e1c\u0e21\u0e44\u0e14\u0e49\u0e25\u0e2d\u0e07\u0e17\u0e33 SAP&nbsp;query \u0e14\u0e39 \u0e41\u0e25\u0e49\u0e27\u0e40\u0e1c\u0e2d\u0e34\u0e0d\u0e40\u0e08\u0e2d\u0e1b\u0e31\u0e0d\u0e2b\u0e32 \u0e14\u0e36\u0e07\u0e02\u0e49\u0e2d\u0e21\u0e39\u0e25\u0e08\u0e32\u0e01&nbsp;query \u0e41\u0e25\u0e49\u0e27\u0e02\u0e49\u0e2d\u0e21\u0e39\u0e25\u0e2d\u0e2d\u0e01\u0e21\u0e32\u0e0b\u0e49\u0e33\u0e01\u0e31\u0e19 \u0e25\u0e2d\u0e07\u0e1b\u0e23\u0e31\u0e1a\u0e41\u0e01\u0e49\u0e44\u0e02 \u0e01\u0e32\u0e23 Join Table \u0e43\u0e19 TCODE SQ02 \u0e41\u0e25\u0e49\u0e27 \u0e01\u0e47\u0e22\u0e31\u0e07\u0e44\u0e21\u0e48\u0e44\u0e14\u0e49\u0e1c\u0e25 \u0e2a\u0e38\u0e14\u0e17\u0e49\u0e32\u0e22\u0e08\u0e1a\u0e1b\u0e31\u0e0d\u0e2b\u0e32\u0e14\u0e49\u0e27\u0e22\u0e01\u0e32\u0e23 \u0e40\u0e02\u0e35\u0e22\u0e19\u0e42\u0e04\u0e47\u0e14\u0e40\u0e02\u0e49\u0e32\u0e44\u0e1b\u0e40\u0e2d\u0e07\u0e43\u0e19&nbsp;query \u0e43\u0e19\u0e2a\u0e48\u0e27\u0e19 InfoSet \u0e0b\u0e36\u0e48\u0e07\u0e40\u0e02\u0e35\u0e22\u0e19\u0e40\u0e02\u0e49\u0e32\u0e44\u0e1b\u0e43\u0e19 2 \u0e2a\u0e48\u0e27\u0e19 \u0e04\u0e37\u0e2d<\/p>\n<p><!--more--><\/p>\n<p><strong>\u0e2a\u0e48\u0e27\u0e19\u0e17\u0e35\u0e48 1 : Code Section 1 DATA<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nconstants&amp;nbsp;:&amp;nbsp;lv_table(6)&amp;nbsp;VALUE&amp;nbsp;'%G00[]'.\nfield-symbols: &amp;lt;table&amp;gt; type any table.\n<\/pre>\n<p><strong>\u0e2a\u0e48\u0e27\u0e19\u0e17\u0e35\u0e48 2 : Code Section 12 INITIALIZATION<\/strong><\/p>\n<p>*END OF SELECTION<\/p>\n<p><strong>\u0e2a\u0e48\u0e27\u0e19\u0e17\u0e35\u0e48 3&nbsp;: Code Section 7&nbsp;END-OF-SELECTION (after List)<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nassign (lv_table) to &amp;lt;table&amp;gt;.\nif &amp;lt;table&amp;gt; is assigned.\nsort &amp;lt;table&amp;gt;.\ndelete adjacent duplicates from &amp;lt;table&amp;gt;.\nendif.\n<\/pre>\n<p>\u0e40\u0e1e\u0e35\u0e22\u0e07\u0e41\u0e04\u0e48\u0e19\u0e35\u0e49\u0e04\u0e23\u0e31\u0e1a \u0e1b\u0e31\u0e0d\u0e2b\u0e32\u0e2b\u0e32\u0e22\u0e40\u0e25\u0e22&nbsp;\u0e41\u0e15\u0e48\u0e16\u0e49\u0e32\u0e22\u0e31\u0e07\u0e44\u0e21\u0e48\u0e2b\u0e32\u0e22\u0e43\u0e2b\u0e49\u0e43\u0e2a\u0e48\u0e04\u0e35\u0e22\u0e4c\u0e02\u0e2d\u0e07\u0e02\u0e49\u0e2d\u0e21\u0e39\u0e25\u0e17\u0e35\u0e48\u0e15\u0e49\u0e2d\u0e07\u0e01\u0e32\u0e23\u0e44\u0e14\u0e49\u0e08\u0e23\u0e34\u0e07\u0e15\u0e32\u0e21\u0e02\u0e49\u0e32\u0e07\u0e25\u0e48\u0e32\u0e07\u0e19\u0e35\u0e49\u0e04\u0e23\u0e31\u0e1a<\/p>\n<p><strong>\u0e40\u0e1e\u0e34\u0e48\u0e21\u0e42\u0e04\u0e4a\u0e14\u0e43\u0e19\u0e2a\u0e48\u0e27\u0e19\u0e17\u0e35\u0e48 1 : Code Section 1 DATA<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nconstants : lv_field_01 TYPE fieldname VALUE 'VTTK-TKNUM',\nlv_field_02 TYPE fieldname VALUE 'LIPS-VBELN',\nlv_field_03 TYPE fieldname VALUE 'LIPS-POSNR',\nlv_field_04 TYPE fieldname VALUE 'LIPS-MATNR'.\n<\/pre>\n<p><strong><strong>\u0e41\u0e01\u0e49\u0e44\u0e02\u0e42\u0e04\u0e4a\u0e14\u0e43\u0e19<\/strong>\u0e2a\u0e48\u0e27\u0e19\u0e17\u0e35\u0e48 2&nbsp;: Code Section 5 Record Processing<\/strong><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nassign (lv_table) to &amp;lt;table&amp;gt;.\nif &amp;lt;table&amp;gt; is assigned.\nsort &amp;lt;table&amp;gt; DESCENDING.\n* delete adjacent duplicates from &amp;lt;table&amp;gt;.\ndelete adjacent duplicates from &amp;lt;table&amp;gt;;\nCOMPARING (lv_field_01) (lv_field_02) (lv_field_03) (lv_field_04).\nendif.\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u0e1c\u0e21\u0e44\u0e14\u0e49\u0e25\u0e2d\u0e07\u0e17\u0e33 SAP&nbsp;query \u0e14\u0e39 \u0e41\u0e25\u0e49\u0e27\u0e40\u0e1c\u0e2d\u0e34\u0e0d\u0e40\u0e08\u0e2d\u0e1b\u0e31\u0e0d\u0e2b\u0e32 \u0e14\u0e36\u0e07\u0e02\u0e49\u0e2d\u0e21\u0e39\u0e25\u0e08\u0e32\u0e01&nbsp;query \u0e41\u0e25\u0e49\u0e27\u0e02\u0e49\u0e2d\u0e21\u0e39\u0e25\u0e2d\u0e2d\u0e01\u0e21\u0e32\u0e0b\u0e49\u0e33\u0e01\u0e31\u0e19 \u0e25\u0e2d\u0e07\u0e1b\u0e23\u0e31\u0e1a\u0e41\u0e01\u0e49\u0e44\u0e02 \u0e01\u0e32\u0e23 Join Table \u0e43\u0e19 TCODE SQ02 \u0e41\u0e25\u0e49\u0e27 \u0e01\u0e47\u0e22\u0e31\u0e07\u0e44\u0e21\u0e48\u0e44\u0e14\u0e49\u0e1c\u0e25 \u0e2a\u0e38\u0e14\u0e17\u0e49\u0e32\u0e22\u0e08\u0e1a\u0e1b\u0e31\u0e0d\u0e2b\u0e32\u0e14\u0e49\u0e27\u0e22\u0e01\u0e32\u0e23 \u0e40\u0e02\u0e35\u0e22\u0e19\u0e42\u0e04\u0e47\u0e14\u0e40\u0e02\u0e49\u0e32\u0e44\u0e1b\u0e40\u0e2d\u0e07\u0e43\u0e19&nbsp;query \u0e43\u0e19\u0e2a\u0e48\u0e27\u0e19 InfoSet \u0e0b\u0e36\u0e48\u0e07\u0e40\u0e02\u0e35\u0e22\u0e19\u0e40\u0e02\u0e49\u0e32\u0e44\u0e1b\u0e43\u0e19 2 \u0e2a\u0e48\u0e27\u0e19 \u0e04\u0e37\u0e2d<\/p>\n","protected":false},"author":1,"featured_media":985,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"footnotes":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_options":[]},"categories":[250,384,251],"tags":[331,336,255,335],"class_list":["post-1091","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-programmer","category-archive-blog","category-sap-abap","tag-abap-code","tag-data-duplicates","tag-how-to","tag-query"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/www.todsapon.com\/story\/wp-content\/uploads\/2018\/11\/sap-abap.jpg","jetpack_shortlink":"https:\/\/wp.me\/p5sZE6-hB","amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/posts\/1091","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/comments?post=1091"}],"version-history":[{"count":5,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/posts\/1091\/revisions"}],"predecessor-version":[{"id":1572,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/posts\/1091\/revisions\/1572"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/media\/985"}],"wp:attachment":[{"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/media?parent=1091"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/categories?post=1091"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.todsapon.com\/story\/wp-json\/wp\/v2\/tags?post=1091"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}