{"id":53,"date":"2011-04-18T19:32:00","date_gmt":"2011-04-18T19:32:00","guid":{"rendered":"http:\/\/www.sapbpc.sapag.co.in\/?p=53"},"modified":"2011-04-18T19:32:00","modified_gmt":"2011-04-18T19:32:00","slug":"how-to-create-custom-ssis-package-for-unlocking-workstatus-of-selected-base-member-without-unlocking-other-workstatus-of-memebrs-in-sap-bpc-microsoft-platform","status":"publish","type":"post","link":"https:\/\/www.sapbpc.sapag.co.in\/?p=53","title":{"rendered":"How to create custom SSIS package for unlocking workstatus of selected base member without unlocking other workstatus of memebrs in SAP BPC (Microsoft Platform)"},"content":{"rendered":"<p>SAP BPC has Workstatus Function that user can or can\u2019t submit their data from client according to workstatus state value but some users complain below things.<\/p>\n<p>a.&#160;&#160;&#160;&#160; If one of the child entity wants to adjust value after all entity\u2019s workstatus set as \u2018locked\u2019,&#160; there is no way to allow submitting data from only that entity. Admin has to unlock all entity so Admin can\u2019t make sure others do not submit data during workstatus is unlocked.<\/p>\n<p>b.&#160;&#160;&#160;&#160; Even though there is TOPDOWN application parameter exists, it needs to unlock from top member to based member.<\/p>\n<p>c.&#160;&#160;&#160;&#160; In addition, if user wants to change status, it can\u2019t change it from \u2018Locked(Approved)\u2019 to \u2018Unlocked\u2019. It means if user has 4 states in their workstatus, they have to change 3 times using current UI.<\/p>\n<p>Tbl&lt;app&gt;Lock table has all workstatus information so user can solve above issues using Data Manager custom package. This blog article will help to create it.<\/p>\n<p><strong>Note: Create custom package should be done by customers and partners. This document is just helping to create package and doesn\u2019t guarantee its result. SAP strongly recommends testing custom package after it is created by users or partners. <\/strong><\/p>\n<p>Package will work based on the selected base members.<\/p>\n<p>For example, if user selects Actual, Budget and 2010.JAN, 2010.FEB, SalesUSNeast, SalesWest it will change below combinations.<\/p>\n<p>Actual, 2010.JAN, SalesUSNeast<\/p>\n<p>Actual, 2010.JAN, SalesWest<\/p>\n<p>Actual, 2010.FEB, SalesUSNeast<\/p>\n<p>Actual, 2010.FEB, SalesWest<\/p>\n<p>Budget, 2010.JAN, SalesUSNeast<\/p>\n<p>Budget, 2010.JAN, SalesWest<\/p>\n<p>Budget, 2010.FEB, SalesUSNeast<\/p>\n<p>Budget, 2010.FEB, SalesWest<\/p>\n<p>Here is detail design of SSIS package.<\/p>\n<p><strong>a. Package Screen shot<\/strong><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" border=\"0\" alt=\"image\" src=\"https:\/\/weblogs.sdn.sap.com\/weblogs\/images\/251844296\/SSISsample.JPG\" width=\"377\" height=\"474\" \/><\/p>\n<p>-. Package will create SQL statement in the script task<\/p>\n<p>-. ExecuteSQL task will execute that SQL statement<\/p>\n<p>-. ForeachLoopContainter will execute stored procedure as many as combination of selected members.<\/p>\n<p><strong>&#160;&#160; b. SQL statement for creating <u>all combination of selected base members<\/u><\/strong><\/p>\n<p>For example, if user selects below members, query and result set will be same as below. <\/p>\n<p>Category Dimension: &#8216;Actual&#8217;,&#8217;Budget&#8217;<\/p>\n<p>Time Dimension: &#8216;2007.JAN&#8217;,&#8217;2007.FEB&#8217;<\/p>\n<p>Entity Dimension: &#8216;SalesUSNeast&#8217;,&#8217;SalesSouth&#8217;<\/p>\n<p>&lt;Query&gt;   <br \/>select a.*, b.* , c.* from ( select &#8216;actual&#8217; as category union select &#8216;budget&#8217; ) as a, (select &#8216;2007.JAN&#8217; as [time]union select &#8216;2007.FEB&#8217; ) as b, (select &#8216;salesusNeast&#8217; as [entity]union select &#8216;salesSouth&#8217; ) as c order by category,[time],entity <\/p>\n<p>&lt;Resultset&gt; <\/p>\n<p>actual&#160;&#160; 2007.FEB&#160;&#160;&#160; salesSouth<\/p>\n<p>actual&#160;&#160; 2007.FEB&#160;&#160;&#160; salesusNeast&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; <\/p>\n<p>actual&#160;&#160; 2007.JAN&#160;&#160;&#160; salesSouth<\/p>\n<p>actual&#160;&#160; 2007.JAN&#160;&#160;&#160; salesusNeast<\/p>\n<p>budget&#160;&#160; 2007.FEB&#160;&#160;&#160; salesSouth<\/p>\n<p>budget&#160;&#160; 2007.FEB&#160;&#160;&#160; salesusNeast<\/p>\n<p>budget&#160;&#160; 2007.JAN&#160;&#160;&#160; salesSouth<\/p>\n<p>budget&#160;&#160; 2007.JAN&#160;&#160;&#160; salesusNeast<\/p>\n<p><strong>c.&#160; <u>Stored procedures that needs to be executed in the loop container<\/u><\/strong><\/p>\n<p>&lt;For ChangeBasememberWorkStatus&gt; <\/p>\n<p>EXEC up_SetWorkStatusFinance @StatusCode=2,@UpdateBy=N'&lt;Execution user&gt;,@Category=N&#8217;ACTUAL&#8217;,@Entity=N&#8217;Worldwide1&#8242;,@Time=N&#8217;2006.TOTAL&#8217;<\/p>\n<p> &lt;For ChangeWorkstatuswithChildren &gt; <\/p>\n<p>EXEC up_SetWorkStatusIncludeChildrenFinance @StatusCode=2,@UpdateBy=N'&lt;Execution User&#8217;,@Category=N&#8217;ACTUAL&#8217;,@Entity=N&#8217;Worldwide1&#8242;,@Time=N&#8217;2006.TOTAL&#8217;<\/p>\n<p><strong>d. <\/strong><u><strong>Data Manager Script for receiving selected dimension members<\/strong><\/u><\/p>\n<p>You can define Global variable and use this value for creating SQL statement in the First script task<\/p>\n<p>GLOBAL(A1,%CATEGORY_SET%)<\/p>\n<p><strong>&#160;&#160;&#160;&#160;&#160;&#160; Note: Global variable is case sensitive so please define it as UPPERCASE.<\/strong><\/p>\n<p>One of my customers created this package with SAP Partner based on this article and used it in the production environment now. Of course, this is not for usual case but might be useful for controlling complex workstaus without affecting workstatus of other entity.<\/p>\n<p><a href=\"http:\/\/sapbpctutorials.blogspot.com\/\" target=\"_blank\">SAP BPC Tutorials | SAP BPC Training | SAP BPC Interview Questions |SAP BPC Books<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>SAP BPC has Workstatus Function that user can or can\u2019t submit their data from client according to workstatus state value but some users complain below things. a.&#160;&#160;&#160;&#160; If one of the child entity wants to adjust value after all entity\u2019s &hellip; <a href=\"https:\/\/www.sapbpc.sapag.co.in\/?p=53\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-53","post","type-post","status-publish","format-standard","hentry","category-sap-bpc-tutorials"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=\/wp\/v2\/posts\/53","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=53"}],"version-history":[{"count":0,"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=\/wp\/v2\/posts\/53\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=53"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=53"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sapbpc.sapag.co.in\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=53"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}