Also problems in automatic generation of business partner no.

Hello,
I've studied all the entries in the forum concerning automatic BP no. generation, but I am getting
the internal error 8180 with the follwoing script:
if $[ocrd.cardtype] ='S'
begin
select CAST ((MAX (CAST (T0.CardCode AS Numeric)) + 1 ) AS VARCHAR) from [dbo].[ocrd] T0 where T0.cardtype = 'S'
end
else
begin
select CAST ((MAX (CAST (T0.CardCode AS Numeric)) + 1 ) AS VARCHAR) from [dbo].[ocrd] T0 where T0.cardtype != 'S'
end
Our GP Code starts with 2701000000 for customer and leads and 2702000000 for suppliers. Related companies have external numbers like 0009000100 with leading zeros.
Can anyone help ?
Thanks in advance.
Michael

Hello,
finally I've asked a B1 consultant and got the followiong query as solution:
SELECT CAST((MAX(CAST(T0.CardCode as numeric)) + 1) AS varchar) FROM [dbo].[OCRD] T0 WHERE  T0.CardType IN  ((SELECT CASE WHEN $[OCRD.CardType] <> 'S' THEN 'C' ELSE 'S' END)  UNION  (SELECT CASE WHEN $[OCRD.CardType] <> 'S' THEN 'L' ELSE 'S' END))  AND T0.CardCode <> 'a'
Michael Benner

Similar Messages

  • Automatic creation of Business Partner

    Is it possible to create business partner master data automatically in SAP FSCD when the claim payment is generated from Non-SAP claim system, if yes then how do we set this up.

    Hi Jon,
    Appreciate your feedback on this.
    My idea is not to provide specific function modules but to give an approach in solving a problem or satisfying a requirement.
    Here I have cited some examples of FMs to help out. There may be many more depending on the version and release level.
    for e.g
    taking the example of finding relevant BAPIs to create BPs. We can proceed to SE37 and typing BUPA* and on hitting F4 will bring up a list of create BAPIs which are many in number and it is up to the SAP consultants to choose the relevant ones depending upon the requirement or issue faced.
    The more methodical way is to navigate to transaction BAPI-> Cross Application Objects, another way is to proceed to SW01 -> BUS1006 -> Methods.
    As you can see there are even various ways to proceed and find BAPIs... in the same way there are various FMs to satisfy a requirement or resolve an issue.
    Anyways I hope that the BAPIs which you have recommended works out in the best possible manner
    Thanks,
    Sagar

  • Problem with BP. Assignment: Business partner person to user not unique

    I have a problem with a user. They have no BP assigned in PPOSA_BBP. We have found a BP in transaction BP.
    When we try the BBP_BP_OM_INTEGRATE the message BBP_UM_UI048 appear" Assignment: Business partner person to user not unique" .
    Any idea about how solve this??
    Best regards
    Jorge

    Hi
    Which SAP version are you using ?
    The user needs to be attached to the Org Plan. (PPOMA_BBP)
    Have you maintained the Contact person for this USer in the Org Plan. (PPOMA_BBP) ?
    Please check the consitency of this BP as well.
    Have you read the documenattion of the Transaction -> BBP_BP_OM_INTEGRATE ?
    If no, here it is..
    Transaction -> BBP_BP_OM_INTEGRATE
    Short text
    Object Synchronization and Repair
    Purpose
    This report enables you to run a consistency check for the integration of HR Master Data and Business Partner data. If not all data exists for the business partner, you can first synchronize data. When synchronization is run for organizational units, the basic data (name, description) and the address data is included; when synchronization is run for central persons, bank information is included in addition to the basic data and address data.
    Prerequisites
    To be able to run this report, integration between Organizational Management and SAP Business Partner must be active.
    Features
    This section contains information about the functions you can use to select and output data.
    Selection
    The following options enable you to restrict the selection of objects:
    Central Person
    In addition to selecting central persons created during integration between HR Master Data and Business Partner data, you can also select central persons who have been created locally. However, central persons created locally are not checked for consistency.
    Employee (object type P)
    This selection option is only available in HR systems. The corresponding central person is displayed together with the person. Both objects are kept consistent in the Basic Data, Address, and Bank Data columns.
    Positions
    Business Partners (Employee role)
    Users
    Organizational Unit(s)
    You can specify specific organizational units for the selection.
    Business Partner (Organizational Unit role)
    Note:
    The selection objects Position, Business Partner (Employee role), User, and Business Partner (Organizational Unit role) are only available if an implementation of BAdI HRALX_HRALXSYNC_BADI exists.
    Branch as of Organizational Unit
    This option enables you to select all objects in the structure for one or more organizational units. You can also restrict selection according to one of the following object types:
    Central Persons Only
    Employees Only
    Positions Only
    Business Partners Only (Employee role)
    Users Only
    Organizational Units Only
    Business Partners Only (Organizational Unit role)
    Include All Object Types
    Changes Since
    All organizational units and central persons for which changes have been made since the last time all objects were synchronized are read. When all objects have been synchronized successfully, a new change date is set.
    Note:
    If a selection has been made but the relevant input field remains blank, all objects of a particular object type are read from the database. This condition can lead to a long runtime, therefore, SAP recommends you also enter a restriction.
    Output
    The organizational units and central persons that have been found are displayed in a list that includes status data.
    To facilitate navigation, a hierarchical tree structure is displayed on the left-hand side of the object list. The branches are sorted according to the type of action that is to be executed.
    If an implementation of BAdI HRALX_HRALXSYNC_BADI exists, checks from this BAdI are executed in the External Checks branch.
    If you double-click on the folder icon in the navigation tree, all objects are displayed in the list.
    Note:
    Meaning of status display for data in the Basic Data, Address, and Bank Data columns:
    Icon Message Text Meaning
    Green traffic light Business partner does not need to be synchronized with HR object data All business partner data is consistent with HR object data.
    Yellow traffic light Business partner does need to be synchronized with HR object data Business partner exists. The business partner data is not consistent with the HR object data.
    Red traffic light Object data is new and must first be created for the business partner The business partner does not yet exist or the the business partner data is incomplete.
    No traffic light Object type does not include this type of data Check type is not relevant for this object.
    Activities
    To integrate business partners or to repair selected objects, you must select the relevant lines in the object list and choose Execute. Any errors that occur are displayed after synchronization.
    Hope this will help.
    Please reward suitable points, incase it suits your requirements.
    Regards
    - Atul

  • Code generation for business partner

    Hi, all
    In our scenario we need to assign a unique code to business partner record as soon as it is approved by data manager (in MDM workdlow). This assignment should be automatic. Next incremental number would suffice, but AutoID field can't be used for this purpose since it automatically assigns numbers even to new, still not approved records.
    Some kind of this pseudocode in assignment would be great:
    CODE = MAX(CODE)+1
    Where MAX(FIELD) is a function returning maximal value in FIELD field in current table.
    But I couldn't find such function in data manager standard functions list.
    Can anyone suggest a solution?
    Vadim

    hi thanks for your valuable replies...
    i changed the codes...pls check its right or wrong
    declare @temp as char(20)
    IF $[OCRD.GroupCode] = 104  and $[OCRD.cardtype] = 'c'
    BEGIN
    set @temp=(select isnull(max(right(cardCode,7)),0) + 1 from Ocrd where (groupcode= 104) and (len(cardCode)=7))
    set @temp='TRA'isnull(replicate(0,7-len(@temp)),'')@temp
    select cast(@temp as char(20))
    END
    ELSE IF $[OCRD.cardtype] = 'C'
    BEGIN
    set @temp=(select isnull(max(right(cardCode,7)),0) + 1 from Ocrd where   (len(cardCode)=7))
    set @temp='C'isnull(replicate(0,7-len(@temp)),'')@temp
    select cast(@temp as char(20))
    END
    ELSE IF $[OCRD.cardtype] = 'S'
    BEGIN
    set @temp=(select isnull(max(right(cardCode,7)),0) + 1 from Ocrd where   (len(cardCode)=7))
    set @temp='S'isnull(replicate(0,7-len(@temp)),'')@temp
    select cast(@temp as char(20))
    END
    Thanks & Regards
    B.Lakshmi Narayanan

  • Send an automatic email to business partner when i create a new service call

    HI,
    I NEED TO SEND AN EMAIL TO BUSINESS PARTNER AN AUTOMATIC WHEN I CREATE A NEW SERVICE CALL
    I USE SAP BUSINESS ONE 8.82 PL 15
    THANKS..

    Ivan te adjunto mi código del SP me emite el msg de error:
    " Msg 14607, Level 16, State 1, Procedure sysmail_verify_profile_sp, Line 42
    profile name is not valid
    (1 row(s) affected)"
    Me arroja un valor 0.
    Adjunto mi codigo del SP:
    USE ["MiBase de Datos"]
    GO
    /****** Object:  StoredProcedure [dbo].[Emails_send]    Script Date: 04/14/2015 13:35:59 ******/
    SET ANSI_NULLS ON
    GO
    SET QUOTED_IDENTIFIER ON
    GO
    ALTER PROCEDURE [dbo].[Emails_send]
    AS BEGIN
    EXEC msdb.dbo.sp_send_dbmail
    @profile_name ='MyMailAccount', (Asi se llama el perfil en donde esta config mi mail)
    @recipients ='[email protected]',
    @subject ='Orden de Servicio',
    @body ='Llamada de Servicio',
    @query ='SELECT T0.[ItemCode], T0.[ItemName], T0.[FrgnName]FROM OITM T0 WHERE T0.[ItemCode]= ZF122SM02IDQ',
    @attach_query_result_as_file = 1, @query_result_separator =';',
    @query_result_no_padding = 1, @exclude_query_output = 1,
    @query_result_header = 1,@query_attachment_filename ='LlamadaServicio.pdf'
    END

  • No automatic Confirm of Business Partner requirde

    Hi,
    I have generated a Call-List for Organizations with and without Contact Person`s.
    Using next Call the System confirms the selected Business Partner from the Call-List (without or with the Conatct Person) automatically.
    Where can I set the Customizing so that I have first the Possibilty to select a Contact Person for the Organization manualy and then confirm it.
    Thanks and regards,
    Andreas

    Under call list profile , uncheck the 'Auto prepare' flag
    spro-> crm-> interaction center webclient -> additional function -> call list -> Define call list profiles

  • Problem with External List Management; Business Partner Type

    Hello experts;
    I created a mapping format for importing a simple notepad file. In the ELM i see all my fields populated correctly. Once i start the importing process it goes smoothly with no mistakes at all (green lights). The bp is actually imported and i can see it in the BP transaction with most of the fields correctly imported BUT the business partner type (PERS_PERS_BPKIND in ELM). For this field i have a Constant Assignment which is always HH and because of that i don't have it in my notepad file but i pass the value directly from ELM constant assignement=HH. Unfortunately this value is not copied. Any idea? Am i doing something wrong or i'm loosing some steps in between?
    Thank you very much

    Hello,
    the issue is most probably related to missing authorizations. As you know the processing in external list management happens in the background using WF-BATCH user.
    Please check the following notes:
    708557 - 'ELM: Troubleshooting' point 1.
    https://service.sap.com/sap/support/notes/708557
    1912414 - ELM upload: Error in the map data-step
    https://service.sap.com/sap/support/notes/1912414
    1664498 - External List will not execute
    https://service.sap.com/sap/support/notes/1664498
    The information provided in the notes should help to solve the issue.
    best regards,
    Johannes

  • BP change documents ( linking problem between Object id and Business Partner)

    Hi,
    We need to create a report for documents changed for a Business partner.
    This will be done in sap bw.
    on source side I have created the datasource with function module changedocument_read and I am getting most of the information
    which I want. Only missing part is Business Partner number.
    Can somebody suggest , how I would be able to link Object Id to business partner.
    I need to pull everything that is changed at BP level and the Object class selection around 30 in number.
    So I am looking for any standard function module which can provide me the link between Object id and Business partner.
    If I establish the rules to determine the Business partner from Object id , its getting bit difficult.
    Can somebody please help/suggest.
    I have gone through many documents and scn posts but unable to find anything on this.
    Thanks !

    Hi, looking at the change history header table CDHDR it seems that object ID simple equals the internal format of the business partner number.

  • Problem while enter address for business partner-tcode BPC1

    Dear Experts,
    I have already enter address for business partner completely in BPC1, but after saving, the data has been entered always gone and message appears: "Enter address for business partner".
    Please somebody advice me about this issue.
    Thank you in advance.

    Please check this thered follow the steps.
    [BDT|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/6173fb9e-0701-0010-6083-a0001827a6ff]
    Create  a field group--> attch fields over there.
    Create a view > attach a field group over there.->If you double click the view , you have to create one screen and attach function modules for PBO and PAI.
    create a section --> Attach your view.
    Create a screen ---> Attach your section.
    Regards,
    Siva

  • Problem in adding a new business partner

    hi all
               iam getting an error like "Bank account is missing",when i add a new business partner..i think iam missing any mandatory field..can anybody help me..i have posted my add BP coding in the last...
    <?xml version="1.0" encoding="utf-8" ?>
    - <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope">
    - <env:Body>
    - <env:Fault>
    - <env:Code>
      <env:Value>env:Receiver</env:Value>
    - <env:Subcode>
      <env:Value>-5002</env:Value>
      </env:Subcode>
      </env:Code>
    - <env:Reason>
      <env:Text xml:lang="en">Bank account is missing</env:Text>
      </env:Reason>
    - <env:Detail>
      <Object>2</Object>
      <ObjectIndex>1</ObjectIndex>
      <Command>AddObject</Command>
      <SessionID>EE10Cu91-F252-CB47-58A6-9929L682316F</SessionID>
      </env:Detail>
      </env:Fault>
      </env:Body>
      </env:Envelope>
    the coding for adding a new business partner is,,
    <WebMethod()> Public Function QueryBP(ByVal SessionID As String, ByVal CardCode As String, ByVal CardName As String) As Xml.XmlDocument
            Dim DISnode As SBODI_Server.Node
            Dim strSOAPans, scmd As String
            Dim xmlDoc As Xml.XmlDocument
            xmlDoc = New Xml.XmlDocument
            DISnode = New SBODI_Server.Node
            sCmd = "<?xml version=""1.0"" encoding=""UTF-16""?> "
            sCmd += "<env:Envelope xmlns:env=""http://schemas.xmlsoap.org/soap/envelope/""> "
            sCmd += " <env:Header> "
            sCmd += "<SessionID>" & CStr(SessionID) & "</SessionID>"
            sCmd += " </env:Header> "
            sCmd += " <env:Body> "
            sCmd += "<dis:AddObject xmlns:dis=""http://www.sap.com/SBO/DIS"" > "
            sCmd += "<BOM>"
            sCmd += "<BO>"
            sCmd += "<AdmInfo>"
            scmd += "<Object>oBusinessPartners</Object> "
            scmd += "</AdmInfo> "
            scmd += "<QueryParams>"
            scmd += "<CardCode>" & CStr(CardCode) & "</CardCode>"
            scmd += "</QueryParams>"
            scmd += "<BusinessPartners>"
            scmd += "<row>"
            scmd += "<CardCode>" & CStr(CardCode) & "</CardCode>"
            scmd += "<CardName>" & CStr(CardName) & "</CardName>"
            scmd += "</row>"
            scmd += "</BusinessPartners>"
            sCmd += "</BO> "
            sCmd += "</BOM> "
            sCmd += "</dis:AddObject> "
            sCmd += " </env:Body> "
            sCmd += "</env:Envelope> "
            strSOAPans = DISnode.Interact(scmd)
            xmlDoc.LoadXml(strSOAPans)
            Return (RemoveEnv(xmlDoc))
        End Function

    Hi michael,
                       Even if i declare like below it's showing the bank account is missing..
    scmd += "<BusinessPartners>"
            scmd += "<row>"
            scmd += "<CardCode>" & CStr(CardCode) & "</CardCode>"
            scmd += "<CardName>" & CStr(CardName) & "</CardName>"
            scmd += "<BankCountry> </BankCountry>"
            scmd += "</row>"
            scmd += "</BusinessPartners>"

  • Automatic Identification of Business Partner in Web IC

    Hi,
    We have a new external software vendor(CTI) who is providing IVR for our SAP enviorment. Our goal is to find the BP automatically in the Web IC. How ever it is searching the based on Caller Phone Number.
    The external Vendor(CTI) is sending the Phone Call Changed event , it is hitting 3 times in the SAP & after that in the Web IC environment , it is going . There we have the class CL_CRMCMP_B_CUCOBUPA_IMPL. & trying find the BP based on Caller phone number, because it is thinking there is no Internal & External CAD data.
    We are getting BP GUID in the phonecall_changed event, but still Web IC is searching through Caller Telephone number.& says " No Account Information Found".
    We are not sure where is the issue is. Is the external CTI vendor should take care of this? OR we have to change this in SAP.I do not agree with the second option, because with the same settings(code & config) it is working with previous CTI vendor.
    We have a live system by other CTI vendor, which is working fine with same code & configuration in SAP. Now we are changing the vendor & implmenting our contact center with new vendor(New CTI system).
    WE have not used App ID & XSLT program in the current Prod version, but still it is working.
    So if we are getting the BP guid in the CAD in the function module phonecall_changed, why in SAP it is searching through Telephone(Caller number)? It is thinking that Internal & External CAD is empty.
    Pls suggest what we are missing here.
    Thx so much for your help.
    Thanks.
    Sarma

    Hi Sarma,
    Check that the capability list for the phone changed event includes the capability for "reading CAD". You can see this in the ICI trace of that event. Check the ICI Specification document for the meaning of the capabilities and if the capability for "reading CAD" is missing, that may explain the issue if you are sure the rest of your config is correct.
    What vendor are you using?
    Sincerely,
    Glenn
    Glenn Abel
    Covington Creative
    www.covingtoncreative.com

  • Automatic Creation of Business Partner from Customer

    Hello,
    I'm creating automatically BP using Tcode FLBPD1 (singular) and MDS_LOAD_COCKPIT (massive).
    I don't want to see some fields of customers in BP master data. Is it possible exclude this data before execute automatical creation?
    Thanks!
    Best Regards!
    Nicola

    Hi David,
                 If you are creating customers from BP. i.e. first the BP will get created and then customer gets created, the way system behaves is that it creates the BP and get a number is generated for it, then it goes and create a customer with the same number by passing the number already created as BP.
    So the number range for BP should be internal and for the customer account group should be external. you might need to create a different customer account group for REFX customers.
    Assumption: same number range tick is selected in the assignment where we assign the BP group and customer account group.
    Regards,
    Deepak M

  • Automatic business partner reconciliation

    Hi reconciliation experts,
    We have recently upgraded to version 2007A and have heard that the reconciliaton engine is much improved.  We are hoping it will resolve what has been a difficult task for us up until now.  At any one time we have a large number of business partners with a zero current balance and a number of un-reconciled transactions.  We can reconcile these manually through business partner internal reconciliation and selecting all the transactions.  This seems like a job better suited to a computer than a person so we would like to do this process automatically.  I have tried the automatic option on Business Partner reconciliation but it doesn't do any matching.  The amounts of the credit and debit transactions may not match but they total to zero.  Can this matching be done automatically?  How?

    Dear experts,
    I am also facing one problem with automatic business partner reconciliation.
    The system actually posts any differences found during the transactions reconciliation, to the General Ledger 'automatic' reconciliation account!!! That's the opposite of the 'manual' reconciliation of payments, where no posts are made.
    I want to know, if there is any way to run the 'automatic' reconciliation without having posts in my general ledger accounts, so to act like the 'manual' one  where no G/L accounts are modified.
    That is why if we have posts, they count like additional paymens from the customer, and their value decrease the open balance, which is false.
    Thank you in advance..

  • DTW problem when updating business partner

    Hi Experts,
    I want to update business partner master data via DTW.
    I only want to update the Remarks.
    In my import file only the fields RecordKey, CardCode and FreeText are filled.
    Example:
    RecordKey: 1
    CardCode: C20000
    FreeText: My Remarks
    The import is successful and the remarks were filled but the DTW has also updated other fields in the business partner master data.
    Before update via DTW the business partner has no payment methods included on the payment system tab but after update via DTW the payment method is included and is defined as Standard.
    Any idea?
    Thanks for help.
    Jacqueline

    Hi,
    yes, the existing payment methods were defined manually before update.
    But the payment method was not included for that business partner.
    Here are some hardcopys before update and after update.
    [BP Master Data Before Update DTW|http://www.sap-potsdam.de/BoneUpload/BP_before_Update.JPG]
    [BP Master Data After Update DTW|http://www.sap-potsdam.de/BoneUpload/BP_after_Update.JPG]
    Jacqueline

  • Business Partner and IBase in SolMan

    Hello all,
    Anybody have a material for create a business partner, IBase and its users in Solution Manager?
    Or procedure for its creating.
    Thanks.
    Att.
    Rogério

    Hi,
    for ibase you can use
    Ib_gen transaction extract from SPRO for some more info.
    For some functions, such as Service Desk, Issue Management or Change Management, the system landscape must be defined as installation (iBase). An IBase  component is created in the installation for each system in the installation. An iBase contains general data and components (e.g. products, texts, etc.)
    The IBase components for the IBase structure SOL_MAN_DATA_REP (installation 1) can be created and assigned automatically or manually .
    You can generate the IBase solution-dependently, or solution-independently, as explained in the following activities.
    Each system appears only once in the installations, so a system does not appear in an iBase if it was previously in another iBase
    Default Settings
    If you create new systems or change existing ones in the System Landscape Maintenance (transaction SMSY), the system creates the IBase component. You can also deactivate the automatic generation of the IBase.
    Requirements
    You have specified your system landscape in Solution Manager System Landscape (transaction SMSY).
    and
    for BP
    you can use BP_gen
    In addition check this blogs.
    /people/bruyneel.guillaume/blog/2008/05/02/service-desk-implementation-guide-part-i
    /people/bruyneel.guillaume/blog/2008/06/13/service-desk-implementation-guide-part-ii
    /people/dolores.correa/blog/2007/10/06/service-desk-support-team-determination
    Regards
    Prakhar

Maybe you are looking for

  • Error not send data a database of oracle please

    I cannot send data from a variable a the database of oracle. variables they are = unot,dost,trest but it does not recognize its values...... it does not insert anything in the fields of the data base this code: con = DriverManager.getConnection(url,"

  • HT5567 how do I download ios 6 for ipod touch

    how do I download ios 6 for ipod touch

  • Multi R/3 systems connections to CRM

    Hi Gurus, I need one clarification related to the multi R/3 connectivity to the single CRM server. The scenario is like this we have two R/3 servers based in two different countries and we have one CRM server in one of these coutries. We have refered

  • Lifestreaming to my iweb page from a mobile phone

    Wondering if I can use my Nokia N95 to post directly to my iWeb page. I'd like to be able to add photos, short text entries, video, etc. Can i do that directly from a mobile phone, or only via iWeb? Ideally, I'd like it to be as easy as posting photo

  • Mac: Elements 8 missing printer profiles

    Hi guys, I tried printing an image using Elements 8 yesterday, having upgraded from 6 on my Mac. Strangely, it didn't bring up any of the manufacturer printer profiles, nor my custom made one, when I tried to print and select them under colour manage