<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to create a relationship between 2 GOS objects in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206611#M1204519</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. check table:    SGOSATTR   Entry:Name   SRELATIONS	if the GOS is allowed&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;2. by creating the GOS:   &lt;/P&gt;&lt;P&gt;coding snip&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;   CALL METHOD cl_binary_relation=&amp;gt;create_link
      EXPORTING
        is_object_a = lo_is_object_a
        is_object_b = lo_is_object_b
        ip_reltype  = 'ATTA'.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ATTA &amp;gt; attach to gos&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best reg robert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 27 Feb 2009 08:57:45 GMT</pubDate>
    <dc:creator>robert_altenstraer</dc:creator>
    <dc:date>2009-02-27T08:57:45Z</dc:date>
    <item>
      <title>How to create a relationship between 2 GOS objects</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206610#M1204518</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a small problem how to create a link between 2 GOS (businnes objects) .&lt;/P&gt;&lt;P&gt;I have 2 different business objects ( Z* type, for example class Z1 and Z2) defined using SWO1, and I want to create link between instances of 2 GOS objects.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I try to use FM 'BINARY_RELATION_CREATE' , &lt;/P&gt;&lt;P&gt;fill parameters OBJ_ROLEA , OBJ_ROLEB ,&lt;/P&gt;&lt;P&gt;but I know how to fill parameter RELATIONTYPE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the time I got a message RL 301 (Role type '&amp;amp;1' is not assigned object type '&amp;amp;2').&lt;/P&gt;&lt;P&gt;Should I make some customization (and how ) for roles of object Z1 and Z2 ? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or should I use any general relationtype ?&lt;/P&gt;&lt;P&gt;Can somebody helo me to explain, how to make customization , or any link, example ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Milan Dobias&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Feb 2009 05:28:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206610#M1204518</guid>
      <dc:creator>milan_dobias</dc:creator>
      <dc:date>2009-02-27T05:28:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a relationship between 2 GOS objects</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206611#M1204519</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. check table:    SGOSATTR   Entry:Name   SRELATIONS	if the GOS is allowed&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;2. by creating the GOS:   &lt;/P&gt;&lt;P&gt;coding snip&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;   CALL METHOD cl_binary_relation=&amp;gt;create_link
      EXPORTING
        is_object_a = lo_is_object_a
        is_object_b = lo_is_object_b
        ip_reltype  = 'ATTA'.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ATTA &amp;gt; attach to gos&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;best reg robert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Feb 2009 08:57:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206611#M1204519</guid>
      <dc:creator>robert_altenstraer</dc:creator>
      <dc:date>2009-02-27T08:57:45Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a relationship between 2 GOS objects</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206612#M1204520</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for Your answer, but main problem is what relation type use to create link between 2 common objects.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your solution (use class CL_BINARY_RELATION) returns the same error message, because this class is used in FM BINARY_RELATION_CREATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the end I found that solution is to use as relationtype (ORBRELTYP-RELTYPE  = 'ASGN').&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'BINARY_RELATION_CREATE'&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        obj_rolea      = obj_a&lt;/P&gt;&lt;P&gt;        obj_roleb      = obj_b&lt;/P&gt;&lt;P&gt;        relationtype   = 'ASGN'&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;        no_model       = 1&lt;/P&gt;&lt;P&gt;        internal_error = 2&lt;/P&gt;&lt;P&gt;        unknown        = 3&lt;/P&gt;&lt;P&gt;        OTHERS         = 4.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It seems to work and on both objects (A and B) I can see link (relation).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards, &lt;/P&gt;&lt;P&gt;MD&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Mar 2009 10:23:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206612#M1204520</guid>
      <dc:creator>milan_dobias</dc:creator>
      <dc:date>2009-03-06T10:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a relationship between 2 GOS objects</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206613#M1204521</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Milan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you tell me how to find out what should be the relation type for other type of objects? I also need this information &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Chandrakant Kulkarni&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Dec 2012 12:18:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/how-to-create-a-relationship-between-2-gos-objects/m-p/5206613#M1204521</guid>
      <dc:creator>former_member206281</dc:creator>
      <dc:date>2012-12-07T12:18:56Z</dc:date>
    </item>
  </channel>
</rss>

