How to do the RELATIONSHIP in the BP transaction....???

Hi all,
Actually, I am working with the Business Partner(BP) transaction.  I have loaded some of the contact data using the LSMW.  Now I need to create relationship between the customer contacts and the main customer masters..  There is a RELATIONSHIP TAB in the BP transaction which creates the relationship between the partners.... I did created some of the relations manually, but I have to do it for a large amount of data.... Can anyone give me a idea as to how will I be going forward, is there any method that I need to follow or do I need to write any program.... ??
If at all, I need to write a program, is it possible to give me a sample code????
I will really appreciate your answers in the form of points.
Thanks,
    -Warren....

Hi Warren,
1) Upload the so called large amount of data (Typically residing in a file) into Internal table.
2) Record the steps done in the Business partner transaction using SHDB transaction and generate a BDC program out of the transaction.
3) Change the logic of the population of the BDC table using the data in the internal tables.
3) Call the transaction using the statement
call transaction using <BDC_INternal_Table>.
In Short, what we are trying here is simulating the manual entry of data into the transaction using a BDC Program.
Program skeleton
g_file hold the file name and path.
  CALL FUNCTION 'GUI_UPLOAD'
    EXPORTING
      filename                      = g_file
    TABLES
      data_tab                      = i_dataf
    EXCEPTIONS
      file_open_error               = 1
      file_read_error               = 2
      no_batch                      = 3
      gui_refuse_filetransfer       = 4
      invalid_type                  = 5
      no_authority                  = 6
      unknown_error                 = 7
      bad_data_format               = 8
      header_not_allowed            = 9
      separator_not_allowed         = 10
      header_too_long               = 11
      unknown_dp_error              = 12
      access_denied                 = 13
      dp_out_of_memory              = 14
      disk_full                     = 15
      dp_timeout                    = 16
      OTHERS                        = 17
  IF sy-subrc <> 0.
    write: / Text-032.
    stop.
  ENDIF.
loop at i_dataf.
*bulid the bdc table
      perform bdc_dynpro      using <screen Program Name> <Screen number>.
             perform bdc_field       using <Field name> <Value>.
          call transaction <TRansaction Name> using t_bdcdata
                                   mode 'N'
                                 update 'S'
                               messages into t_messages.
endloop.
form bdc_dynpro using    p_program
                         p_dynpro.
  t_bdcdata-program  = p_program.
  t_bdcdata-dynpro   = p_dynpro.
  t_bdcdata-dynbegin = 'X'.
  append t_bdcdata.
  clear t_bdcdata.
endform.                    " bdc_dynpro
*&      Form  bdc_field
      text
form bdc_field using    p_fnam
                        p_fval.
  t_bdcdata-fnam = p_fnam.
  t_bdcdata-fval = p_fval.
  append t_bdcdata.
  clear t_bdcdata.
endform.                    " bdc_field
Regards,
Ravi
Message was edited by: Ravi Kanth Talagana

Similar Messages

  • What is the relationship between the SAP BC and XI?

    Hi Friends,
    What is the relationship between the SAP BC and XI?
    Regards
    Sam

    Hi Samuel Melvin ,
    The SAP BC is basically WebMethod's product supplied free of charge to SAP customers.
    SAP XI is a purchased product from SAP that can be used to integrate multiple systems, you would need to contact your SAP Account rep to discuss licensing issues. You cannot download it for free from sapnet.
    It is probably more relevant to discuss the comparison between these solutions based on a specific scenario, but here are some basic differences. Obviously, the foremost one being that the SAP Exchange Infrastructure (XI) belongs to the SAP Netweaver technology suite, whereas Business Connector although bundled by SAP is really a Integration tool provided by Web Methods.
    Being a Netweaver solution the SAP XI is central in design and configuration. The SAP XI is really integrated as a required solution for some of new mySAP solutions like SRM. For example, the mySAP SRM business scenario for Supplier Self Services in EBP requires the implementation of SAP XI, the Business connector cannot be utilized to replace this scenario. Although the SAP Business Connector can still be utilized with SRM for all XML based communication. Both mySAP SRM and XI runs natively on the SAP WebAS Server.
    The Business Connector is a point to point solution that provides messaging and routing. Currently a number of organizations using the Business Connector utilize it to communicate between its partners using XML based messaging. This can be achieved using SAP XI as well, but SAP's strategy is to utilize XI as a central hub for messaging, routing, and communication between all SAP, non-SAP systems as well as partners. As SAP XI is a relatively new solution, organizations that are looking for communicating with their partners to exchange XML based documents or other point-to-point scenarios can still utilize SAP Business connector.
    Initially, when SAP announced the SAP XI, there was a notion that SAP Business Connector would be phased out and SAP XI would be the solution utilized hereon. But SAP will continue to support the Business Connector, the SAP Exchange Infrastructure will remain as the SAP's strategic integration solution. All new and or updated SAP solutions will make use of the XI for all process-centric, message based integration. As upgrades are scheduled and new solutions deployed we'll see the mandated need for XI but currently the only solution that natively requires SAP XI is mySAP SRM 2.0.
    It will be interesting to see how organizations that already utilize SAP Business Connector warm up the SAP XI idea. But for the most part they will not have a choice really, as the new mySAP products are going to natively require the use of SAP XI for all process-centric integration between the different SAP solutions. But there is no reason why organizations cannot continue to utilize the SAP Business Connector for all point-to-point solutions already deployed with possibly document exchange and partner integration. Hope this helps.
    These web-sites may help u in understanding XI & BC
    Understanding SAP XI SEEBURGER
    http://www.seeburger.com/fileadmin/com/pdf/SAP_Exchange_Infrastructure_Integratio_Strategy.pdf
    http://www.t2b.ch/Flyers/t2b%20SAP%20Xi%20Flyer.pdf
    SAP Exchange Infrastructure (BC-XI)
    http://help.sap.com/saphelp_srm30/helpdata/en/0f/80243b4a66ae0ce10000000a11402f/content.htm
    webMethods for SAP
    http://www1.webmethods.com/PDF/webMethods_for_SAP-wp.pdf
    http://help.sap.com/saphelp_srm30/helpdata/en/72/0fe1385bed2815e10000000a114084/content.htm
    cheers!
    gyanaraj
    ****Reward points if u find this helpful

  • Re: What is the relationship between the JTA Server Timeout and

    Two things. The transaction timeout is set when the transaction starts. When are you setting the timeout, and where are you starting the transaction?
              There is a bug in 6.0 SP1. The EJB subsystem always sets the transaction timeout. If you don't specify anything in your descriptor. It sets the timeout to 30 seconds. However, if you
              change the JTA default to 60 seconds, the EJB container won't see this change. This is fixed in our next minor release.
              -- Rob
              Tom Gerber wrote:
              > What is the relationship between the JTA Server Timeout and an EJB's <transcation-timeout-seconds> parameter?
              >
              > Does the EJB's timeout have to be >= the servers to take effect?
              >
              > We tried setting the timeout in the XML file to 60 seconds but the transaction still timed out after 30 seconds or so which makes me believe the server timeout overrides the EJB's timeout.
              >
              > Is this correct behavior?
              >
              > We are on WL 6.0 sp1
              >
              > Thanks
              >
              > Tom
              

    Sorry, you cannot query for known bugs yet.
              Work is in progress :)
              Kumar
              Tom Gerber wrote:
              > Is there a place on the WebSupport site for WebLogic that I can query
              > for know issues for WL 6 sp1?
              >
              > I tried the Find Solutions but didn't find much.
              >
              > Thanks
              >
              > Rob Woollen wrote:
              >
              > > Two things. The transaction timeout is set when the transaction starts. When are you setting the timeout, and where are you starting the transaction?
              > >
              > > There is a bug in 6.0 SP1. The EJB subsystem always sets the transaction timeout. If you don't specify anything in your descriptor. It sets the timeout to 30 seconds. However, if you
              > > change the JTA default to 60 seconds, the EJB container won't see this change. This is fixed in our next minor release.
              > >
              > > -- Rob
              > >
              > > Tom Gerber wrote:
              > >
              > >> What is the relationship between the JTA Server Timeout and an EJB's <transcation-timeout-seconds> parameter?
              > >>
              > >> Does the EJB's timeout have to be >= the servers to take effect?
              > >>
              > >> We tried setting the timeout in the XML file to 60 seconds but the transaction still timed out after 30 seconds or so which makes me believe the server timeout overrides the EJB's timeout.
              > >>
              > >> Is this correct behavior?
              > >>
              > >> We are on WL 6.0 sp1
              > >>
              > >> Thanks
              > >>
              > >> Tom
              > >
              

  • How to create new relationships in the BP transaction

    Hi ,
    I am very much newto CRM.I have got one requirment to create the relationships in BP transaction.
    After entering the BP transaction ,I have to select the Organisation in the FIND field then i need to select the BP number.After displaying the BP number i need to select display in BP role As 'Client'.Then  in the indentification Tab i will get the value for inustry sector.I need to focus my cursor on industry sector the i will press relationships button.
    In relationship button i will get 4 tabs 1) Overview2)Has employee3)Has Managing Partner relationships4)Has senior relationship partner.
    Here in the relationship i need to add 3 more tabs with 1)sector leader2)sector manager3)cluster leader.
    So how i need to add new relationship tab eaither i need to do this with config or with program i need to handle.Please suggest me.
    Thanks.

    To create new relationship types goto transaction BUBA. There you can easily create your new 3 types with minimum customazing effort.
    Regards.

  • How to get the Relationships data from Opportunity Transaction in CRM

    Hi Friends,
    Could you please let me know the table / class to fetch the relationships data associated with a single(main) opportunity.
    There may be several object types like (activites, sub-opp's..etc) linked to a single  main(source) opportunity.
    I wanted the these fields information from Relationships tab From Opp transaction.
    Source Item No.
    Object Type
    Target Trans/Object
    Description
    Type of Linkage
    Could you please let me know.
    Regards
    Vijay

    Hi Vijay,
    Can you try function module CRM_DOC_FLOW_READ_DB?
    By giving opportunity GUID it will return associated information.
    Kind regards,
    Garcia

  • How to make a relationship with the portal Id with R/3 Id

    Hi Experts,
    We have developed a portal application and assigned the role to the User.
    In R/3 where we can integrate the details.If we maintainin IT 0105 communication,will it suufice the need.
    Please advice.
    Regards,
    Vikram.

    Hi Vikram,
    And I add by saying that:
    1. The user from the portal have the portal roles (access to portal applications)
    2. This same user have the roles, groups and profiles on the backend to permit or deny access to the authorization objects (which permit access to ITs on the HR and tables)
    3. The Pernr that you assign this user via IT0105 STy0001, is used on the org structure.
    Hope I contributed.
    Regards,
    Bentow.

  • Identify the relationship for the follwing fields

    Hi experts,
    I have to develop a report which is taking input as : -
    1.matnr (material number)
    2.werks (plant)
    3.stlan (BOM usage)
    4. stlal (alternative)
    And I need the output as : -
    AENNR (ECR : engg change request)
    I am unable to identify the relationships between these fields, plz suggest me the best ways to do this..
    Thanks in advance
    Gaurav
    Moderator message : Spec-dumping not allowed. Read forum rules before posting. Thread locked.
    Edited by: Vinod Kumar on Jul 5, 2011 2:11 PM

    after getting the records to internal table write the statement
    delete adjacent duplicate ................... before that write sort stament also......
    Deleting Adjacent Duplicate Entries
    To delete adjacent duplicate entries use the following statement:
    DELETE ADJACENT DUPLICATE ENTRIES FROM <itab>
                                      [COMPARING <f1> <f 2> ...
                                                 |ALL FIELDS].
    The system deletes all adjacent duplicate entries from the internal table <itab>. Entries are duplicate if they fulfill one of the following compare criteria:
    Without the COMPARING addition, the contents of the key fields of the table must be identical in both lines.
    If you use the addition COMPARING <f1> <f 2> ... the contents of the specified fields <f 1 > <f 2 > ... must be identical in both lines. You can also specify a field <f i > dynamically as the contents of a field <n i > in the form (<n i >). If <n i > is empty when the statement is executed, it is ignored. You can restrict the search to partial fields by specifying offset and length.
    If you use the addition COMPARING ALL FIELDS the contents of all fields of both lines must be identical.
    You can use this statement to delete all duplicate entries from an internal table if the table is sorted by the specified compare criterion.
    If at least one line is deleted, the system sets SY-SUBRC to 0, otherwise to 4.

  • I bought a new computer, and i have transfered everything using home share, file transfers, etc.. yet still when i go to sync, itunes tells me ipod can only be synced with one computer... is there a way to retire the relationship with the old computer?

    i bought a new computer.  the itunes app allows for home shareing, file transfers, etc.. but i want to discontinue the syncing with the old computer and sync my ipod touch now only on my new system... but i cant seem to disconnect that old relationship at all.. when i try to syncit says that my ipod is already synced with another computer, do i want to discontinue that and only use the new informationon this computer?  i dont want to do that yet because it doesnt seem like everything has come over, and i am afraid of losing songs that i downloaded from cds, etc..

    if you don't want to sync it because you don't think that everything has been transferred then i would check first if you can, before you commit to used only the data from your new computer.
    though, im not sure if this is true, but i think that when you sync your ipod to a new computer it will take the items from your ipod and put it on itunes, like when you purchase something on your ipod and it gets automatically transfered, but don't take my word for it.

  • How to find Job relationship using the Function Module  RH_STRUC_GET

    Hi Experts,
    I am getting O-S-P relation ship using for an org unit using the function module RH_STRUC_GET.
    Further If I want the job relation ship, how it can be found out.
    Thanks in Advance,
    Irfan

    Hello Irfan,
    Have a look at the table T778A for evaluation path you require and pass this to the function module.
    Regards,
    Manoj.

  • SQL Server 2012 Management Studio:In the Database, how to print out or export the old 3 dbo Tables that were created manually and they have a relationship for 1 Parent table and 2 Child tables?How to handle this relationship in creating a new XML Schema?

    Hi all,
    Long time ago, I manually created a Database (APGriMMRP) and 3 Tables (dbo.Table_1_XYcoordinates, dbo.Table_2_Soil, and dbo.Table_3_Water) in my SQL Server 2012 Management Studio (SSMS2012). The dbo.Table_1_XYcoordinates has the following columns: file_id,
    Pt_ID, X, Y, Z, sample_id, Boring. The dbo.Table_2_Soil has the following columns: Boring, sample_date, sample_id, Unit, Arsenic, Chromium, Lead. The dbo.Table_3_Water has the following columns: Boring, sample_date, sample_id, Unit, Benzene, Ethylbenzene,
    Pyrene. The dbo.Table_1_XYcoordinates is a Parent Table. The dbo.Table_2_Soil and the dbo.Table_3_Water are 2 Child Tables. The sample_id is key link for the relationship between the Parent Table and the Child Tables.
    Problem #1) How can I print out or export these 3 dbo Tables?
    Problem #2) If I right-click on the dbo Table, I see "Start PowerShell" and click on it. I get the following error messages: Warning: Failed to load the 'SQLAS' extension: An exception occurred in SMO while trying to manage a service. 
    --> Failed to retrieve data for this request. --> Invalid class.  Warning: Could not obtain SQL Server Service information. An attemp to connect to WMI on 'NAB-WK-02657306' failed with the following error: An exception occurred in SMO while trying
    to manage a service. --> Failed to retrieve data for this request. --> Invalid class.  .... PS SQLSERVER:\SQL\NAB-WK-02657306\SQLEXPRESS\Databases\APGriMMRP\Table_1_XYcoordinates>   What causes this set of error messages? How can
    I get this problem fixed in my PC that is an end user of the Windows 7 LAN System? Note: I don't have the regular version of Microsoft Visual Studio 2012 in my PC. I just have the Microsoft 2012 Shell (Integrated) program in my PC.
    Problem #3: I plan to create an XML Schema Collection in the "APGriMMRP" database for the Parent Table and the Child Tables. How can I handle the relationship between the Parent Table and the Child Table in the XML Schema Collection?
    Problem #4: I plan to extract some results/data from the Parent Table and the Child Table by using XQuery. What kind of JOIN (Left or Right JOIN) should I use in the XQuerying?
    Please kindly help, answer my questions, and advise me how to resolve these 4 problems.
    Thanks in advance,
    Scott Chang    

    In the future, I would recommend you to post your questions one by one, and to the appropriate forum. Of your questions it is really only #3 that fits into this forum. (And that is the one I will not answer, because I have worked very little with XSD.)
    1) Not sure what you mean with "print" or "export", but when you right-click a database, you can select Tasks from the context menu and in this submenu you find "Export data".
    2) I don't know why you get that error, but any particular reason you want to run PowerShell?
    4) If you have tables, you query them with SQL, not XQuery. XQuery is when you query XML documents, but left and right joins are SQL things. There are no joins in XQuery.
    As for left/right join, notice that these two are equivalent:
    SELECT ...
    FROM   a LEFT JOIN b ON a.col = b.col
    SELECT ...
    FROM   b RIGHT JOIN a ON a.col = b.col
    But please never use RIGHT JOIN - it gives me a headache!
    There is nothing that says that you should use any of the other. In fact, if you are returning rows from parent and child, I would expect an inner join, unless you want to cater for parents without children.
    Here is an example where you can study the different join types and how they behave:
    CREATE TABLE apple (a int         NOT NULL PRIMARY KEY,
                        b varchar(23) NOT NULL)
    INSERT apple(a, b)
       VALUES(1, 'Granny Smith'),
             (2, 'Gloster'),
             (4, 'Ingrid-Marie'),
             (5, 'Milenga')
    CREATE TABLE orange(c int        NOT NULL PRIMARY KEY,
                        d varchar(23) NOT NULL)
    INSERT orange(c, d)
       VALUES(1, 'Agent'),
             (3, 'Netherlands'),
             (4, 'Revolution')
    SELECT a, b, c, d
    FROM   apple
    CROSS  JOIN orange
    SELECT a, b, c, d
    FROM   apple
    INNER  JOIN orange ON apple.a = orange.c
    SELECT a, b, c, d
    FROM   apple
    LEFT   OUTER JOIN orange ON apple.a = orange.c
    SELECT a, b, c, d
    FROM   apple
    RIGHT  OUTER JOIN orange ON apple.a = orange.c
    SELECT a, b, c, d
    FROM   apple
    FULL OUTER JOIN orange ON apple.a = orange.c
    go
    DROP TABLE apple, orange
    Erland Sommarskog, SQL Server MVP, [email protected]

  • How can I see the relationship of tables in Microsoft SQL Server?

    How can I see the relationships of the tables? Exactly like what we see in Access. In Access if we select Database tool and then relationships, we can see how the tables are linked to each other. How can I find this option in SQL Server Management Studio?
    Thanks,
    GGGGGNNNNN
    GGGGGNNNNN

    Thanks,
    I could verify what you explained here. how can I overcome this message and resolve it when my database owner is not there:
    Message while starting with database diagrams of a attached/restored database
    If you have just attached/restored a database from another SQL Server instance. While accessing its database diagrams folder, you may get the following message
    It is an informational message and would prevent you from working on database diagrams. The message says that your database has no valid owner currently. Reason for this error is that database owner on a previous SQL Server instance does not exist here.
    To overcome this error just add the valid database owner through T-SQL or SSMS. Also verify the compatibility level of your database is correct for your SQL Server instance.
    I appreciate your help.
    GGGGGNNNNN
    GGGGGNNNNN

  • How to find the relationship between tables

    Hi All
    I am working in oracle apps R12 in OM and INV and i am new. Is there any document for getting the all key tables and the relationship of the tables.
    Thanks & Regards
    Srikkanth.M

    Hi;
    You need to check e-trm site to can see table explaniation,integrity,relations etc
    Check:
    etrm.oracle.com
    Regard
    Helios

  • How do I use a runbook Activity on an Incident and Runbook Initialize Data activity to sync and get the GUid from the Incident?

    I currently have a runbook running every hour to attach Incidents Templates to Problems. I would like to just add a runbook activity to the Incident Template to activate the runbook, and only link that Incident to the problem it needs to be attached to. 
    I don't know how to set-up my Initialize Data activity in my runbook to load the calling Incidents GUID though. 
    I'm very new to Orchestrator, so please be detailed in your directions.
    The way my runbook works now is, I make my incident templates have the PR # they are for in the Alt Contact Block. My runbook searched for that, and then loads the PR# it has there and creates the relationship between the two, and then deletes that PR# so
    it doesnt hit on the next search.
    I would like my activity that calls the runbook to pass the Incident GUID to the runbook, so my runbook only has to query the PR# included in the incident, and create the relationship that way.
    Thanks for any help you can provide.

    This might help:
    Working With Relationships in the SCSM Orchestrator Integration Pack
    Basically, you'll receive the ID of the runbook automation activity from Service Manager, which you can then use with the Get Object and Get Relationship to get the runbook activity object, then get the incident object related to it. I realize this is confusing,
    but there should be more info out there to search on as well. Hope that helps.
    Noah Stahl | Automys |
    Downloadable Microsoft automation examples and solutions

  • Automatic creation of BP relationship at the time of creation of BP

    When a user creates a new account using BP transaction we need to create a 'Has the responsible employee' relationship automatically. If we try to create the same on save ( Using function BUPR_RELATIONSHIP_CREATE in BAdI PARTNER_UPDATE ) it doesn't work as the account would not have got created at the time of save. Hence we took a different approach of trying to create the relationship when the user clicks on 'Relationship' button ( in portal it is 'Relationship' tab ). We couldn't find a suitable BAdI which would contain the details of the recently created account as its import parameter.  Is there any other approach we could use to solve this issue? Please let me know your ideas on the same.

    Hi,
    You can implement this functionality using the BDT.
    --> in the PAI event, update the relationships in memory using function BUB_BUPA_RELATIONS_MODIFY.
    For BDT use, take a look at the following thread:
    Re: How do I update custom fields in a partner when I save the record?
    Michael.

  • Relationship between the "Stage" and the "preLoader"

    Other than the "preLoader" loading the project what is the relationship between the 2 elements in the project. Is the "preLoader" on the stage? is there a "stage" for the preloader ?
    In css markup in my html file to I need to deal with them seperately if I want to move there loaction?
    I use...
    sym.$("#Stage").css({"margin": "auto"})
    in compReady to center my stage. I tried do this with the preloader but it doesn't work. The stage is centered but the preloader off to the left.  Is there some code I can add to the project so my preloader will allways center in the same location where my stage is placed?
    If I'm using html css markup to place my "stage" how do I address the preloader so it's goverened by the same markup ?
    Also maybe this should be a seperate post question, but how would i add a timer to report preload times to the console ?
    Thanks
    Joel H

    That doesn't work all the time and sometimes it works with stage but not the preloader, especialy if I want to center vertically also like
    <style>
    #Stage {
            width:350px;
            height:350px;
            position:absolute;
            left:50%;
            top:50%;
            margin:-175px 0 0 -175px;
    </style>
    this doesn't work. But if I apply the same markup to a wrapper div it does work. like
    <style>
    #StageWrapper {
            width:350px;
            height:350px;
            position:absolute;
            left:50%;
            top:50%;
            margin:-175px 0 0 -175px;
    </style>
    then in the <body>
    <div id="StageWrapper">
    <div="Stage"  class="EDGE-blah-blah">
    </div></div>
    this works great, you just can't open your html file in edge again cause it screws your project all up.
    I was just wondering why if I was centering my stage with js in the project file why the preloader wasn't doing the same thing or how to do the same thing with js in the project file
    thanks
    Joel H

Maybe you are looking for