{"id":3495,"date":"2024-08-27T14:44:26","date_gmt":"2024-08-27T12:44:26","guid":{"rendered":"https:\/\/www.clavis.biz\/?page_id=3495"},"modified":"2024-10-08T13:29:05","modified_gmt":"2024-10-08T11:29:05","slug":"left-outer-join-2","status":"publish","type":"page","link":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/","title":{"rendered":"Data Record in a DB table"},"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<h2 class=\"wp-block-heading has-text-align-left has-neve-text-color-color has-text-color\">Checking a data record in a DB table<\/h2>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-0435e4fc105cba251c08c16e1df99f17 wp-block-paragraph\">Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"alignleft size-full has-custom-border\"><img loading=\"lazy\" decoding=\"async\" width=\"440\" height=\"157\" src=\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/08\/abap_true.png\" alt=\"\" class=\"has-border-color has-neve-text-color-border-color wp-image-3500\" style=\"border-width:1px\" srcset=\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/08\/abap_true.png 440w, https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/08\/abap_true-300x107.png 300w\" sizes=\"auto, (max-width: 440px) 100vw, 440px\" \/><\/figure>\n<\/div>\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-fab9ff6db77b9887b7b1c980c958b6c4 wp-block-paragraph\">An inline declaration is used to create a variable which then contains the value &#8216;X&#8217; for abap_true or &#8216; &#8216; for abap false, i.e. whether a data record exists or not. The key or a secondary index of the table should be specified in the WHERE statement. <\/p>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-2dc9193f9c3235e26d73ae90230b31a0 wp-block-paragraph\">This variant avoids detours via a COUNT(*) and also requires no data transport or specification of columns from the table.<\/p>\n\n\n\n<p class=\"has-neve-text-color-color has-text-color has-link-color wp-elements-ac85fc85d062985686c0dd95f866bf94 wp-block-paragraph\">Source: <a href=\"https:\/\/help.sap.com\/doc\/abapdocu_750_index_htm\/7.50\/de-de\/abensql_expr_literal_abexa.htm\" target=\"_blank\" rel=\"noreferrer noopener\">https:\/\/help.sap.com\/doc\/abapdocu_750_index_htm\/7.50\/de-de\/abensql_expr_literal_abexa.htm<\/a><\/p>\n\n\n\n<div style=\"height:40px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n<\/div><\/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 wp-block-paragraph\">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-fe48e5de 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-3495","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>Checking a data record in a DB table<\/title>\n<meta name=\"description\" content=\"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:\" \/>\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-2\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Checking a data record in a DB table\" \/>\n<meta property=\"og:description\" content=\"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/\" \/>\n<meta property=\"og:site_name\" content=\"clavis berater soziet\u00e4t\" \/>\n<meta property=\"article:modified_time\" content=\"2024-10-08T11:29:05+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-2\/\",\"url\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/\",\"name\":\"Checking a data record in a DB table\",\"isPartOf\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg\",\"datePublished\":\"2024-08-27T12:44:26+00:00\",\"dateModified\":\"2024-10-08T11:29:05+00:00\",\"description\":\"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:\",\"breadcrumb\":{\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#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-2\/#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\":\"Data Record in a DB table\"}]},{\"@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":"Checking a data record in a DB table","description":"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:","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-2\/","og_locale":"en_US","og_type":"article","og_title":"Checking a data record in a DB table","og_description":"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:","og_url":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/","og_site_name":"clavis berater soziet\u00e4t","article_modified_time":"2024-10-08T11:29:05+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-2\/","url":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/","name":"Checking a data record in a DB table","isPartOf":{"@id":"https:\/\/www.clavis.biz\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#primaryimage"},"image":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#primaryimage"},"thumbnailUrl":"https:\/\/www.clavis.biz\/wp-content\/uploads\/2024\/06\/Hintergrund_TipsTricks_Pixabay_sparks-692122.jpg","datePublished":"2024-08-27T12:44:26+00:00","dateModified":"2024-10-08T11:29:05+00:00","description":"Since NetWeaver 7.40, the following command with @abap_true can be used to check whether a data record for a value exists in a table:","breadcrumb":{"@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.clavis.biz\/en\/sap-technologies\/sap-tipps-and-hints\/left-outer-join-2\/#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-2\/#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":"Data Record in a DB table"}]},{"@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\/3495","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=3495"}],"version-history":[{"count":10,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/3495\/revisions"}],"predecessor-version":[{"id":4452,"href":"https:\/\/www.clavis.biz\/en\/wp-json\/wp\/v2\/pages\/3495\/revisions\/4452"}],"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=3495"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}