Create and save a BuilMktAttribute entity in a report?

Hi all,
I've to do a mass import of marketing attributes from a flatfile to some business partners.
I try to do this using the BOL (see test coding below).
All values are submitted to the BOL entity and corresponding to the values of the tables KLAH, CABN and CAWN.
But when saving the table GT_MKTBP_GLOB in FM CRM_MKTBP_SAVE_AND_CHECK_OB contains no values in column ATWRT and so no attribute will be saved. Anyhow, the success flag is set to TRUE.
Any idea, whats my mistake?
Regards Martin
PARAMETERS: pa_part   TYPE bu_partner OBLIGATORY
          , pa_klass  TYPE klasse
          , pa_merk   TYPE atinn
          , pa_wert   TYPE atwrt
CALL METHOD cl_crm_bol_core=>get_instance
*  EXPORTING
*    iv_display_mode_support = ABAP_FALSE
  RECEIVING
    rv_core                 = gr_core
SELECT SINGLE * FROM but000
                INTO ls_but000
                WHERE partner = pa_part.
CHECK sy-subrc EQ 0.
lv_object_id = ls_but000-partner_guid.
TRY.
    CALL METHOD gr_core->start_up
      EXPORTING
        iv_appl_name            = 'BP_APPL'
*    iv_display_mode_support = ABAP_FALSE
    lv_query_name = 'BuilHeaderAdvancedSearch'.
    ls_selection_parameters-attr_name = 'PARTNER'.
    ls_selection_parameters-sign = 'I'.
    ls_selection_parameters-option = 'EQ'.
    ls_selection_parameters-low = pa_part.
    ls_selection_parameters-high = ''.
    APPEND ls_selection_parameters TO lt_selection_parameters.
    CALL METHOD gr_core->dquery
      EXPORTING
        iv_query_name           = lv_query_name
        is_query_parameters     = ls_query_parameters
        it_selection_parameters = lt_selection_parameters
*    iv_view_name            = lv_view_name
      RECEIVING
        rv_result               = lr_result
    CALL METHOD lr_result->get_first
      RECEIVING
        rv_result = gr_entity.
    CALL METHOD gr_core->reread_entity
      EXPORTING
        iv_entity = gr_entity.
  CATCH cx_crm_genil_general_error .
ENDTRY.
CLEAR: ls_marketing
TRY.
    CALL METHOD gr_entity->create_related_entity
      EXPORTING
        iv_relation_name = 'BuilMktAttributeRel'
      RECEIVING
        rv_result        = lr_entity.
  CATCH cx_crm_genil_duplicate_rel .
  CATCH cx_crm_genil_model_error .
ENDTRY.
IF NOT lr_entity IS BOUND.
  MESSAGE e900(z_mk_messages).
*   Es konnte keine Entität erzeugt werden!
ENDIF.
CALL METHOD gr_core->modify
ls_marketing-attribute_set = pa_klass.
ls_marketing-attribute     = pa_merk.
ls_marketing-language_int  = sy-langu.
ls_marketing-value         = pa_wert.
CALL METHOD lr_entity->if_bol_bo_property_access~set_properties
  EXPORTING
    is_attributes = ls_marketing.
CALL METHOD gr_core->modify
CALL METHOD gr_core->get_transaction
  EXPORTING
    iv_entity = gr_entity
  RECEIVING
    rv_result = lr_transaction.
CALL METHOD lr_transaction->save
*  EXPORTING
*    iv_force_save = ABAP_FALSE
  RECEIVING
    rv_success    = lv_success
IF lv_success = abap_true.
  CALL METHOD lr_transaction->commit
*  EXPORTING
*    iv_keep_locks = ABAP_FALSE
ELSE.
  CALL METHOD lr_transaction->rollback
ENDIF.
WRITE:/ lv_success
Edited by: Martin Knittel on Apr 19, 2010 10:14 AM

How did u solve this issue?

Similar Messages

  • How to Create and Save a workbook on Enterprise Portal

    Hi,
    I need to find out how I can create and save a workbook (for a query) in Enterprise portal. Can we save a work book and run it in the same format?
    Thanks

    Hi,
    refer below thread
    Re: How do you save the Workbook as View when the workbook do not have quer
    also see sap help
    http://help.sap.com/saphelp_nw04/helpdata/en/4d/f3fa40badbf36fe10000000a1550b0/frameset.htm
    Thanks

  • How to create and save a file in flex web application ?

    Hi,
          I want to create and save a file form flex web application. Is it possible ?
    I have done some googling and found that its only possible through file referece, which needs some serverside implementation be called.
    Is it not possible with file reference to create and save file directly ?
    Can any one suggest how to over come this.
    Thanks in advance.

    Alex,
    code written with the Flex Builder 3 libraries will certainly run in Flash Player 10. However, what you need is not so much the capabilities of FP10 but the library functionalities of the Flex 4 package. And I think that Flex 4 code will only run in FP10 and not 9 (but haven't tested this as at work we have not yet been permitted to upgrade, so there is not a lot of point going for Flex 4!).
    Richard

  • SAP Query (SQ01) - create and save queryies

    Hi Expert;
    We wanted to implement SAP query reporting (SQ01) tool, and already developed custom HR infoset and user groups and transported to QAS.  We experienced the problem that we can not directly "save" any queries in SQ01. We pretty much have the client opened up and set at "Changes without automatic recording".  But keep getting a "transport object create" dialog upon "save" query.  But in Adhoc (PQAH), we don't encounter same problem.    We wanted our users be able to create and save any queries directly without creating any local objects. Is there another setting that needs to be set? 
    Thanks for any information that you can provide.  Points will be awarded.
    Helen

    Hello Helen,
    in SQ01 you can save queries like in HR Ad Hoc Query (or Infoset query as it is called outside HR).
    However this is only possible in the "Standard Area" not in the "Global Area". However as Ad Hoc Query is based on the SQ0x basics it only hides this effect.
    If you are doing HR specifics you should consider the documetnation on the special HR switches:
    http://service.sap.com/~form/sapnet?_SHORTKEY=01200252310000076208&
    In general if you are new to the topic you should consider the courses BC407 for Query Basics and HR580 for reporting in HR.
    Also to get a feeling for the different types of reporting with the InfoSet Query you can look at the following documentation:
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/a8/2e7237a323427ee10000009b38f8cf/frameset.htm
    HR Reporting Tools -> Sap Query -> InfoSet Query -> Calling InfoSet Query.
    Or you can book a special training if you need a contact let me know your email adress
    Best regards,
    Michael

  • Is it possible to create and save a .PDF without any compression to the resulting .PDF?

    I need an uncompressed file so I can use the resulting PDF to do a find/replace. Can't do it with compression.
    Thanks
    JDRHC1115

    Dave,
    Thanks for the reply. Of all the suggestions I've received this seemed to
    be most promising. I gave it a try and the problem is that when I attempt
    to save as optimized a message box pops up and says I have to save my
    document first. Low and behold when I save it, compression occurs. Even
    when I select the options you suggest I'm left with a compressed document.
    I'm using Acrobat Pro X
    Jeff
    From:   Dave Merchant <[email protected]>
    To:     Jeff Ross <[email protected]>
    Date:   01/06/2011 09:35 AM
    Subject:        Is it possible to create and save a .PDF
    without any compression to the resulting .PDF?
    You don't want the UncompressPDF plugin - that's designed to split out the
    COS objects but doesn't remove the Flate encoding (plus if you've never
    compiled a plugin before, it's not really the time to learn).
    Instead, simply save your PDF file using the PDF (Optimized) file type,
    click the Settings button and under "Clean Up" - "Object compression
    options", choose "Remove compression". Turn everything else off if you
    want to retain the PDF content exactly as it was before.
    Your document-level scripts will then be in the file as plain text.

  • Create and save a .pdf file

    Afternoon!  I am creating a pdf utilizing the cfdocument tag and it works great.  It opens and displays well.  My question is, is there a way to automatically save that generated pdf on the server without opening it?  My end goal is to run a scheduled task every week that creates and saves a pdf automatically.

    <cfdocument format="pdf" orientation="landscape" filename="YourPDFName.pdf" overwrite="yes">
    it will save a copy of the pdf in the same folder as the <cfdocument> is run from, the problem I got is it wond display the pdf at creation time, all that is returned to my screen is the letter "z"
    so may be best to fun the code in a loop and one time add in the filename and overwrite paramaters, if you dont need it displayed, then your gold.
    Craig Wiseman

  • Create and save custom transition

    Hi, I made a custom transition in FCP using video filters and keyframes and would like to save it to be able to use it again. Is there any way in FCP to create and save transitions? What files actually are the transitions included in FCP?

    I did a search and now I know, that the filters and transitions are written in FXScript languge. For those who're interested, there's an official Apple Using FX Script pdf ( http://developer.apple.com/documentation/AppleApplications/Conceptual/Using_FXSc ript/UsingFXScript.pdf ) and a really nice website with FX Script reference - http://www.fxscriptreference.org/ ...

  • How to create and save playlist using JMF?

    Hello i m new to JMF. Can anyone tell me how to create and save a playlist of media files using JMF.
    also how can i play .DAT files using JMF?
    Does JMF supports AVI,Asf files?

    Hello i m new to JMF. Can anyone tell me how to create and save a playlist of media files using JMF.
    also how can i play .DAT files using JMF?
    Does JMF supports AVI,Asf files?

  • How do you create and save icc profiles using photoshop?

    How do you create and save icc profiles using photoshop?

    You don't. Color profiles require specific measurement hardware and software.
    Mylenium

  • How does APEX create and save new files. What extension does it save in?

    Hi can someone help me with this question?
    How does APEX create and save new files. What extension does it save in?
    Cheers!
    VJ

    It's really too bad we can't see VJ's face when the concept sinks in. This is one of my favorite moments when teaching APEX classes. Most people love it, some people don't. If nothing else it really proves the power and performance of the Oracle database. Each page view can generate 40+ queries, yet on the average system this takes less than .04 seconds.
    Keep in mind there are no undocumented features or "Oracle Internals" that the APEX team uses to achieve this performance, just sound database design. With every feature they add they evaluate how it will be used and design the tables and indexes to most efficiently answer the query. Sometimes this means going against "purist" normalized principals.

  • My boss cannot create a new subfolder by pressing "new folder" until he's already saved the file to his desktop. A "read only" error appears the first time. Is there a way to create and save to subfolder directly? It's Mavericks/Macbook Pro

    Hi, when my boss wants to save a new file in a new subfolder, he presses "new folder" but cannot create a new one because a “read only” error box appears. Once he saves the file to his Desktop he clicks on “save as” again and then he can create a new subfolder by pressing “new folder.” Is there a way to create and save to a subfolder directly without having to first save somewhere else?

    Your server file handling has nothing, and really nothing to do with Adobe software. If files don't get locked for (over-)writing and/or lose connection to the program opening them, then your server is misconfigured. It's as plain and simple and that. Anything from "known file types"/ file associations not being set correctly, MIME types being botched, crooked user privileges and file permissions, missing Mac server extensions, delayed file writing on the server, generic network timeout issues and what have you. Either way, you have written a longwinded post with no real value since you haven't bothered to provide any proper technical info, most notably about the alleged server. Either way, the only way you can "fix" it is by straightening out your server and network configuration, not some magic switch in Adobe's software.
    Mylenium

  • Idoc creation on production order create and save

    I need to know if there is a way to create an idoc on the change and save of a production order.  We will need to base this on plants (not all plants get an idoc).  Is there any "safe" way to do this automatically?  We previous had a system in place that used the user exit of a production order save but it no longer works. 
    Regards,
    Davis

    It's not an error as such.  The program is doing exactly what it has been told to do.
    If you go to SE38, and look at ZXCO1U06, you'll find that there is a statement "BREAK-POINT".  This is hard-coded way of opening the debugger.
    Your best approach is to find the developer responsible for doing this, and ask them to change it.  If this is happening outside of development system - perhaps in test or production, then perhaps
    a) The programmer needs to be disciplined shot
    b) The development team need to introduce some review procedure of ALL coding, before transport.
    Regards
    matt

  • Photoshop Elements 11- Create and save multiple page PDF's?  Software bug or new limitation?

    I just upgraded from Photoshop Elements 10 to Photoshop Elements 11.  One of the reasons I stayed with Adobe rather than Corel was the ability to work with multipage PDF's.
    I noticed that I can't add more than one page to a project and save a multiple page PDF.  I can open a multiple page PDF, but not create or save one.
    Is this a new limitation, or just a software bug Adobe plans to fix?
    Has anyone found a way to work with multiple page PDF's in Photoshop Elements 11?

    It's a new limitation in PSE 11, for one of those mysterious adobe reasons.

  • How do a create and save a contact sheet in Elements12?

    I saw how to create and print a contact sheet, but I want to save it and then email it.  I don't see how to do that.
    Thank you

    Jellis96 wrote:
    I saw how to create and print a contact sheet, but I want to save it and then email it.  I don't see how to do that.
    Thank you
    Since you know how to create and print then saving it should be pretty easy.  However, before I tell you how to do this, let me ask you have you got Adobe Acrobat (full version) or some other pdf creator?  There are many free pdf creator out there but you might already have something on your system.
    Assuming you have a pdf creator then instead of printing to a printer, try "printing to a pdf file" and this should allow you to save the file which can then be emailed to your friends and colleagues.
    Hope this helps.

  • Create and Save Interactive Form

    I have created my form which I would like to have users fill in and save.  I have done something wrong because it gives a message that it cannot save entered data.  The form works, it just won't save entered data.  Thanks.

    Hi Ibgolfin,
    That's par for the course.
    What you need to do is enable Reader Useage Rights by:
    open your form in Acrobat Pro
    Select Advanced
    Select Extend Features in Adobe Reader
    That's it. No puttering around needed.
    Stephen

Maybe you are looking for

  • Which hard-drive modules should I load for the mkinitcpio.conf file?

    Hey all, I've always been confused by all the weird module names in the image files, anyway, here goes, since I have a laptop, I won't be upgrading my harddrive to a new interface. but.. that's not the problem, the problem is I don't know which modul

  • Material Number should be based on Material Group

    Hi Experts,        I have a Requirement in MM01 the material number should be depends on material Group . The material number should generate base on material group. Is there Any BADI / Exit For this. Regards, Ravi.

  • Signed applet stopped working with 1.4.2_04

    We have a signed applet that accesses the file system. After installing 1.4.2_04 it produces this exception java.security.AccessControlException: access denied (java.io.FilePermission <<ALL FILES>> execute)      at java.security.AccessControlContext.

  • My thumbnails in iPhoto 9.2.1 are not working

    Hello. It has been a while I haven't been into discussions. but my library ceases working. My thumbnails are not working and now I realized neither are the pictures. I show the total number of photos in each album, but there is nothing there. Also, I

  • OBIEE11.1.1.6 integration with SmartView

    Hello Could anyone tell me how to integrate SmartView 11.1.1.3 with OBIEE 11.1.1.6. Regds