{"id":3707,"date":"2024-09-10T11:21:19","date_gmt":"2024-09-10T09:21:19","guid":{"rendered":"https:\/\/www.clavis.biz\/?page_id=3707"},"modified":"2024-09-10T14:31:59","modified_gmt":"2024-09-10T12:31:59","slug":"left-outer-join-6","status":"publish","type":"page","link":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/","title":{"rendered":"HANA DB: copying large tables with high performance"},"content":{"rendered":"\n<div class=\"wp-block-cover alignfull\" style=\"min-height:320px;aspect-ratio:unset;\"><span aria-hidden=\"true\" class=\"wp-block-cover__background has-nv-site-bg-background-color has-background-dim-100 has-background-dim\"><\/span><div class=\"wp-block-cover__inner-container is-layout-flow wp-block-cover-is-layout-flow\">\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-d9ef74f8d85613d1bb1b3399405e4c5d\">In a current customer project, there was a requirement to migrate a table with an extremely large number of entries to a new namespace. Since renaming SAP tables is not possible, the only option was copying. However, for a table with 1.8 billion entries, this is a real challenge in terms of both runtime and execution itself.  <\/p>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-aba054bca792f3aa05a048fc844ddf2a\">In the end, only the following approach worked:<\/p>\n<\/div><\/div>\n<\/div><\/div>\n\n<div class=\"wp-block-cover alignfull\" style=\"min-height:320px;aspect-ratio:unset;\"><span aria-hidden=\"true\" class=\"wp-block-cover__background has-nv-light-bg-background-color has-background-dim-100 has-background-dim\"><\/span><div class=\"wp-block-cover__inner-container is-layout-flow wp-block-cover-is-layout-flow\">\n<div style=\"height:40px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading has-neve-text-color-color has-text-color has-link-color wp-elements-e1232ed499b9a83d193a83aaea74b9ee\">Copy directly to the HANA DB<\/h2>\n\n\n\n<h3 class=\"wp-block-heading has-neve-text-color-color has-text-color has-link-color wp-elements-037a231e0231870fa5189e896003c3a8\">Free memory check<\/h3>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-flow wp-block-group-is-layout-flow\">\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-f2112fa212a3871d1ca98356ad08311f\">First, it is necessary to evaluate the size of the table to be copied (Transaction DBACOCKPIT -&gt; Diagnostics -&gt; Tables\/Views) and to determine the available free memory (Transaction DBACOCKPIT -&gt; Current Status -&gt; Overview).<\/p>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-ad3c9a3dedc073f1cf2e48210d74016a\">If enough memory is available, the following statement can now be used to copy the table, either via an SQL statement in Hana Studio or via &#8220;EXEC SQL&#8221; in ABAP:<\/p>\n<\/div><\/div>\n\n\n\n<h3 class=\"wp-block-heading has-neve-text-color-color has-text-color has-link-color wp-elements-7d21661821a33aef643423fb4f4c1a71\">Copy table<\/h3>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-73e4a29cdd0c1eab916ca53f2c5ad710\">Use the following statement to copy the table: CREATE (COLUMN) TABLE &#8220;\/<namensraum1>\/<tabellenname>&#8221; LIKE &#8220;\/<namensraum1>\/<tabellenname>&#8221; WITH DATA<\/tabellenname><\/namensraum1><\/tabellenname><\/namensraum1><\/p>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-d0495f3ae52f8bad8efb58185cec6a30\">A documentation you can find here <a href=\"https:\/\/help.sap.com\/viewer\/4fe29514fd584807ac9f2a04f6754767\/2.0.03\/en-US\/20d58a5f75191014b2fe92141b7df228.html#loio20d58a5f75191014b2fe92141b7df228__create_table_like_clause\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/help.sap.com\/viewer\/4fe29514fd584807ac9f2a04f6754767\/2.0.03\/en-US\/20d58a5f75191014b2fe92141b7df228.html#loio20d58a5f75191014b2fe92141b7df228__create_table_like_clause<\/a> (from: 12.10.2020)<\/p>\n\n\n\n<h3 class=\"wp-block-heading has-neve-text-color-color has-text-color has-link-color wp-elements-134c4b178ff4ea220f5f38a13a066c02\">Copy ABAP Dictionary<\/h3>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-130bb77fcbb9f556b53c3218760c263c\">Since the copied table now exists in the database but not in the ABAP Dictionary, the table must now still be copied (as usual) in SE11. Now the copied table is also visible in SAP (incl. data). Further processing (e.g. SE14) is not necessary.  <\/p>\n\n\n\n<h3 class=\"wp-block-heading has-neve-text-color-color has-text-color has-link-color wp-elements-1a45a944416facff2d21b494ee4971dd\">Runtime<\/h3>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-15e268ba4e225b1cc8872771637e7cae\">The copy of a table with 1.8 billion rows and a total column width of 781 characters took about 6h.<\/p>\n\n\n\n<div style=\"height:40px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n<\/div><\/div>\n\n<div class=\"wp-block-cover alignfull\" style=\"min-height:300px;aspect-ratio:unset;\"><span aria-hidden=\"true\" class=\"wp-block-cover__background has-nv-dark-bg-background-color has-background-dim-100 has-background-dim\"><\/span><div class=\"wp-block-cover__inner-container is-layout-flow wp-block-cover-is-layout-flow\">\n<div style=\"height:80px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n<div class=\"wp-block-image is-style-rounded\">\n<figure class=\"aligncenter size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"285\" height=\"285\" src=\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/cl_orange_Informationen.png\" alt=\"\" class=\"wp-image-765\" style=\"width:80px;height:80px\" srcset=\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/cl_orange_Informationen.png 285w, https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/cl_orange_Informationen-150x150.png 150w\" sizes=\"auto, (max-width: 285px) 100vw, 285px\" \/><\/figure>\n<\/div>\n\n\n<div style=\"height:24px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<p class=\"has-text-align-center has-nv-text-dark-bg-color has-text-color\">Do you have any questions?<br\/>Get in touch with us.<\/p>\n\n\n\n<div class=\"wp-block-buttons is-content-justification-center is-layout-flex wp-container-core-buttons-is-layout-16018d1d wp-block-buttons-is-layout-flex\">\n<div class=\"wp-block-button is-style-default\"><a class=\"wp-block-button__link wp-element-button\" href=\"https:\/\/www.clavis.biz\/en\/contact\/\">CONTACT<\/a><\/div>\n<\/div>\n\n\n\n<div style=\"height:80px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n<\/div><\/div>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":2,"featured_media":982,"parent":2866,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"neve_meta_sidebar":"default","neve_meta_container":"","neve_meta_enable_content_width":"on","neve_meta_content_width":100,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":"off","neve_meta_reading_time":"","_ti_tpc_template_sync":false,"_ti_tpc_template_id":"","footnotes":""},"class_list":["post-3707","page","type-page","status-publish","has-post-thumbnail","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>HANA DB: copying large tables with high performance<\/title>\n<meta name=\"description\" content=\"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"HANA DB: copying large tables with high performance\" \/>\n<meta property=\"og:description\" content=\"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/\" \/>\n<meta property=\"og:site_name\" content=\"clavis berater soziet\u00e4t\" \/>\n<meta property=\"article:modified_time\" content=\"2024-09-10T12:31:59+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1920\" \/>\n\t<meta property=\"og:image:height\" content=\"1270\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/\",\"url\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/\",\"name\":\"HANA DB: copying large tables with high performance\",\"isPartOf\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg\",\"datePublished\":\"2024-09-10T09:21:19+00:00\",\"dateModified\":\"2024-09-10T12:31:59+00:00\",\"description\":\"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage\",\"url\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg\",\"contentUrl\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg\",\"width\":1920,\"height\":1270,\"caption\":\"SAP-TippsTricks_Image\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Start\",\"item\":\"https:\/\/www.clavis.biz\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SAP Technologies\",\"item\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"SAP Tipps and Hints\",\"item\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"HANA DB: copying large tables with high performance\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.clavis.biz\/en\/#website\",\"url\":\"https:\/\/www.clavis.biz\/en\/\",\"name\":\"clavis berater soziet\u00e4t\",\"description\":\"Beratung f\u00fcr SAP, mobile Anwendungen und Web-Entwicklung\",\"publisher\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.clavis.biz\/en\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.clavis.biz\/en\/#organization\",\"name\":\"clavis berater soziet\u00e4t\",\"url\":\"https:\/\/www.clavis.biz\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.clavis.biz\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/clavis-Logo_M.png\",\"contentUrl\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/clavis-Logo_M.png\",\"width\":441,\"height\":200,\"caption\":\"clavis berater soziet\u00e4t\"},\"image\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"HANA DB: copying large tables with high performance","description":"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/","og_locale":"en_US","og_type":"article","og_title":"HANA DB: copying large tables with high performance","og_description":"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.","og_url":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/","og_site_name":"clavis berater soziet\u00e4t","article_modified_time":"2024-09-10T12:31:59+00:00","og_image":[{"width":1920,"height":1270,"url":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg","type":"image\/jpeg"}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/","url":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/","name":"HANA DB: copying large tables with high performance","isPartOf":{"@id":"https:\/\/www.clavis.biz\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage"},"image":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage"},"thumbnailUrl":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg","datePublished":"2024-09-10T09:21:19+00:00","dateModified":"2024-09-10T12:31:59+00:00","description":"As it is not possible to rename SAP tables, copying is often the only option. A real challenge for very large tables.","breadcrumb":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#primaryimage","url":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg","contentUrl":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg","width":1920,"height":1270,"caption":"SAP-TippsTricks_Image"},{"@type":"BreadcrumbList","@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-6\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Start","item":"https:\/\/www.clavis.biz\/en\/"},{"@type":"ListItem","position":2,"name":"SAP Technologies","item":"https:\/\/www.clavis.biz\/en\/sap-technologies\/"},{"@type":"ListItem","position":3,"name":"SAP Tipps and Hints","item":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/"},{"@type":"ListItem","position":4,"name":"HANA DB: copying large tables with high performance"}]},{"@type":"WebSite","@id":"https:\/\/www.clavis.biz\/en\/#website","url":"https:\/\/www.clavis.biz\/en\/","name":"clavis berater soziet\u00e4t","description":"Beratung f\u00fcr SAP, mobile Anwendungen und Web-Entwicklung","publisher":{"@id":"https:\/\/www.clavis.biz\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.clavis.biz\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.clavis.biz\/en\/#organization","name":"clavis berater soziet\u00e4t","url":"https:\/\/www.clavis.biz\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.clavis.biz\/en\/#\/schema\/logo\/image\/","url":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/clavis-Logo_M.png","contentUrl":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/05\/clavis-Logo_M.png","width":441,"height":200,"caption":"clavis berater soziet\u00e4t"},"image":{"@id":"https:\/\/www.clavis.biz\/en\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/3707","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/comments?post=3707"}],"version-history":[{"count":3,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/3707\/revisions"}],"predecessor-version":[{"id":3741,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/3707\/revisions\/3741"}],"up":[{"embeddable":true,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/2866"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/media\/982"}],"wp:attachment":[{"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/media?parent=3707"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}