{"id":10313,"date":"2017-05-23T12:50:02","date_gmt":"2017-05-23T12:50:02","guid":{"rendered":"http:\/\/www.greytrix.com\/blogs\/sagex3\/?p=10313"},"modified":"2017-05-23T12:50:02","modified_gmt":"2017-05-23T12:50:02","slug":"how-to-extract-a-left-sub-string-from-a-given-string-in-sage-enterprise-management","status":"publish","type":"post","link":"https:\/\/www.greytrix.com\/blogs\/sagex3\/2017\/05\/23\/how-to-extract-a-left-sub-string-from-a-given-string-in-sage-enterprise-management\/","title":{"rendered":"How to extract a left sub-string from a given string in Sage Enterprise Management?"},"content":{"rendered":"<p style=\"text-align: justify;\">In Sage X3, we may come across various scenarios where you need to get sub-string from an existing string. We can derive sub-string from both the ends i.e. From the Left and from the right or start from a particular position of a given string.<\/p>\n<p style=\"text-align: justify;\">This blog will help us to extract the leftmost sub-string from a given string i.e. We can derive a sub-string with particular number character from the left of the given string.<\/p>\n<p style=\"text-align: justify;\">Sage X3 provides the below special function to achieve the same:<strong><em>\u00a0<\/em><\/strong><\/p>\n<p><strong><em>left$ (string,nb_char)<\/em><\/strong><\/p>\n<p style=\"text-align: justify;\">This function is used to extract a substring starting from the left-hand side first letter of an original string to the letter ending with the specified number of characters.<\/p>\n<p>Where,<\/p>\n<p>string -&gt; Original string with the alphanumeric expression<\/p>\n<p>nb_char -&gt; Numerical integer expression for the length of a string to be extracted.<\/p>\n<p>Let&#8217;s consider following example for Extraction of sub-string with 4 letters from left to better understand the working of <strong><em>left$<\/em><\/strong> function.<\/p>\n<p><strong><em><u>Snippet:<\/u><\/em><\/strong><\/p>\n<p><em>Local Char YSTRING(50)<\/em><\/p>\n<p><em>YSTRING = &#8220;JACKFRUIT&#8221;<\/em><\/p>\n<p><em>Infbox left$(YSTRING, 4)<\/em><\/p>\n<p>The above snippet of code will give output as &#8220;<em>JACK<\/em>&#8220;.<\/p>\n<p><strong>Hope this helps!<\/strong><\/p>\n<p><span style=\"font-size: Medium;\"><strong>About Us<\/strong><\/span><br \/>\n<a href=\"http:\/\/www.greytrix.com\/\">Greytrix<\/a> is one stop solution provider for Sage ERP and Sage CRM needs. We provide complete end-to-end assistance for your technical consultations, product customizations, data migration, system integrations, third-party add-on development and implementation expertise.<\/p>\n<p><a href=\"http:\/\/www.greytrix.com\/\">Greytrix<\/a> has some unique solutions of Sage X3\u2019s integration with <a href=\"http:\/\/www.greytrix.com\/product\/sage-crm\/gumu-sage-x3-integration\">Sage CRM<\/a>, <a href=\"http:\/\/www.greytrix.com\/product\/sage-x3\/gumu-x3-salesforce-integration\">Salesforce.com,<\/a>\u00a0and <a href=\"http:\/\/www.greytrix.com\/product\/magento-sage-integrations\/sage-x3-magento\">Magento<\/a> eCommerce. It also offers best-in-class <a href=\"http:\/\/www.greytrix.com\/product\/erp-development\/sage-x3\">Sage X3 customization and development services <\/a>to Sage business partners, end users, and Sage PSG worldwide.<\/p>\n<p>For more information on Sage X3 Integration and Services, please contact us at <a href=\"mailto:x3@greytrix.com\">x3@greytrix.com<\/a>. We will be glad to assist you.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In Sage X3, we may come across various scenarios where you need to get sub-string from an existing string. We can derive sub-string from both the ends i.e. From the Left and from the right or start from a particular position of a given string. This blog will help us to extract the leftmost sub-string\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.greytrix.com\/blogs\/sagex3\/2017\/05\/23\/how-to-extract-a-left-sub-string-from-a-given-string-in-sage-enterprise-management\/\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[776,1147,1822,1839,1941],"class_list":["post-10313","post","type-post","status-publish","format-standard","hentry","category-sage-erp-x3","tag-extract-a-left-sub-string","tag-left-function","tag-sage-x3","tag-sage-x3-blogs","tag-sage-x3-technical"],"_links":{"self":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/posts\/10313","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/comments?post=10313"}],"version-history":[{"count":0,"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/posts\/10313\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/media?parent=10313"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/categories?post=10313"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.greytrix.com\/blogs\/sagex3\/wp-json\/wp\/v2\/tags?post=10313"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}