How to use the ColumnDescriptor's type as CLOB?

I want to build a metric which are used to record the content of a file. But the length of the content is too long, it may not be stored with a ColumnDescriptor's type STRING. I tried to make the TYPE='CLOB', but failed. I though it might be something wrong with my output, but I have no idear how to make it right. Does it supposed to point to a file? Could anyone tell me how to do it?
Here is my code:
metadata.xml
<Metric NAME="TEST_LOB" TYPE="RAW" HELP="NO_HELP">
<TableDescriptor TABLE_NAME="TEST_LOB">
<ColumnDescriptor NAME="TIMES" COLUMN_NAME="TIMES" TYPE="STRING" IS_DATE="TRUE"/>
<ColumnDescriptor NAME="CONTENT" COLUMN_NAME="CONTENT" TYPE="CLOB" />
</TableDescriptor>
<QueryDescriptor FETCHLET_ID="OSLineToken">
<Property NAME="command" SCOPE="GLOBAL">"%perlBin%/perl" "%scriptsDir%/emx/%TYPE%/testlob.pl"</Property>
<Property NAME="delimiter" SCOPE="GLOBAL">%mydelimiter%</Property>
<Property NAME="startsWith" SCOPE="GLOBAL">em_result=</Property>
<Property NAME="errStartsWith" SCOPE="GLOBAL">em_error=</Property>
</QueryDescriptor>
</Metric>collection.xml
<CollectionItem NAME="TEST_LOB">
<Schedule>
<IntervalSchedule INTERVAL="5" TIME_UNIT="Min" />
</Schedule>
<MetricColl NAME="TEST_LOB" />
</CollectionItem>The output of script testlob.pl looks like as below. It started with "em_result=", and delimited by "|".
em_result=2009-07-30 15:30:35|*** (1) TRANSACTION:
TRANSACTION 2 1235033361, ACTIVE 0 sec, process no 14811, OS thread id 1158457696 inserting
mysql tables in use 1, locked 1
LOCK WAIT 3 lock struct(s), heap size 368, undo log entries 4
MySQL thread id 26693314, query id 5239203160 192.168.95.138 passportuser update
insert into digital_id_info (digital_id) values (0x3930303636363734)
*** (1) WAITING FOR THIS LOCK TO BE GRANTED:
RECORD LOCKS space id 45 page no 14 n bits 392 index `idx_unq_digitalid` of table `passport/digital_id_info` trx id 2 1235033361 lock mode S waiting
Record lock, heap no 5 PHYSICAL RECORD: n_fields 2; compact format; info bits 0
0: len 8; hex 3930303636363734; asc 90066674;; 1: len 4; hex 0014dae7; asc ;;
*** (2) TRANSACTION:
TRANSACTION 2 1235033200, ACTIVE 0 sec, process no 14811, OS thread id 1215965536 setting auto-inc lock
mysql tables in use 1, locked 1
3 lock struct(s), heap size 6752, undo log entries 323
MySQL thread id 26693430, query id 5239203161 10.10.71.74 passportuser update
insert into digital_id_info (digital_id) values (0x3930303637343639)
*** (2) HOLDS THE LOCK(S):
RECORD LOCKS space id 45 page no 14 n bits 392 index `idx_unq_digitalid` of table `passport/digital_id_info` trx id 2 1235033200 lock_mode X locks rec but not gap
Record lock, heap no 5 PHYSICAL RECORD: n_fields 2; compact format; info bits 0
0: len 8; hex 3930303636363734; asc 90066674;; 1: len 4; hex 0014dae7; asc ;;
*** (2) WAITING FOR THIS LOCK TO BE GRANTED:
TABLE LOCK table `passport/digital_id_info` trx id 2 1235033200 lock mode AUTO-INC waiting
*** WE ROLL BACK TRANSACTION (1)the scripts for creating table "TEST_LOB",
CREATE TABLE TEST_LOB
TIMES DATE,
CONTENT CLOB
);Any help will be appreciated!!!
Thanks,
Satine

Sorry, that doesn't solve my problem. Please read the question more closely - I want my USERS to be able to do this without changing their configurations. My users are public school elementary teachers and parents. I can't ask them to toggle any settings - I'm looking for a way that my users can do this on their own.
Thanks

Similar Messages

  • Hi all!How to use the fault message types

    Hi all, i am new beginner on XI.
    I have read the introduction in SAP Library about
    fault message types
    but the steps of how to use fault message are clear
    could you help me?
    could you give me some guide or docs or links?

    Hi,
    These might help you:
    http://help.sap.com/saphelp_nw04/helpdata/en/f3/c26c3cbfac384fe10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/5d/a45c3cff8ca92be10000000a114084/frameset.htm
    Regards,
    Chandra

  • How to use the customer types in customer master data

    how to use the customer types in customer master data?
    menu path is Extras -> account group info -> customer types

    hi,
    This is an option given to you to choose (if you need to) the way you perceive this customer.Here you get options including ompetitors,Salespartner, prospect,
    default sp ,consumer.
    See it helps you to differentiate between prospect(which you may use for quotation or inquiry purpose)Sales partner and the competetor.
    I hope this clarifies your quiery.Reward points if so.
    Thanking you,
    Best regards,
    R.Srinivasan

  • [svn:osmf:] 13113: Changing to not use an embedded font by default, and adding instructions on how to use the free 'type writer' bitmap font.

    Revision: 13113
    Revision: 13113
    Author:   [email protected]
    Date:     2009-12-21 01:08:10 -0800 (Mon, 21 Dec 2009)
    Log Message:
    Changing to not use an embedded font by default, and adding instructions on how to use the free 'type writer' bitmap font.
    Modified Paths:
        osmf/trunk/libs/ChromeLibrary/.flexLibProperties
        osmf/trunk/libs/ChromeLibrary/src/org/osmf/chrome/controlbar/widgets/ScrubBar.as
        osmf/trunk/libs/ChromeLibrary/src/org/osmf/chrome/controlbar/widgets/URLInput.as
    Added Paths:
        osmf/trunk/libs/ChromeLibrary/src/org/osmf/chrome/fonts/
        osmf/trunk/libs/ChromeLibrary/src/org/osmf/chrome/fonts/Fonts.as
    Removed Paths:
        osmf/trunk/libs/ChromeLibrary/assets/images/stop_up.png_1

    Your site was built using tables, whose sizes are defined in your site.
    If we look at your first table definition, we can see:
    <table width="861" height="1449" border="3" cellpadding="0" cellspacing="0" bordercolor="#868787">
    Your table has a width of 861 pixels and an overall height of 1449 pixels. Anything you put into that overall box must fit those dimensions, else
    it won't be visible. Anything you add above it will push everything down. You can redefine your sizing to let you edit more inside of the table elements.
    This is why, when you type in more text, things act weird. If you are in Dreamweaver, you must find the right cell to put your text into and then enter
    text there. Unfortunately, this is going to push things around, which were all lined up using tables. And this gets everything offset with respect to
    everything else in your website.
    And that is why everyone is saying, "Start Over!"
    I just inherited a website that has been put together using tables. I'm going to have to expend considerable effort in rewriting the entire design of the
    website because of that. because everything I intend to add to the pages on the site is going to need to be deconstructed in order to get it to work
    properly if I'm adding text and pictures that need to line up with each other.
    You need something done quick and dirty and the only way I can recommend you do that is to use Dreamweaver to show you the tables you have
    and put what you need in a new table that is defined above or below the tables you all ready have defined. Do that and then get back to someone here
    who knows how to make a website correctly to clean up your entire website and make it editable -- which will cost you some money, but it will be
    money well-spent.
    I like to quote this maxim: Good, Fast, Cheap. Pick any two. This works for website design. You can get it fast and cheap, but it won't be good. I
    think you may have chosen that route.

  • Okay so I set up my Time Capsule already and is now backing up 2 of my iMacs. Works great. What I want to know is how to use the TC to directly store files? I want to do this to delete some files but still have them on the TC for future reference..

    Okay so I set up my Time Capsule already and is now backing up 2 of my iMacs. Works great. What I want to know is how to use the TC to directly store files? I want to do this to delete some files on iMac 20inch but still have them on the TC for future reference..eg some movies on iTunes. I want to directly save them on the drive so I can delete them from iTunes and gain some storage. (Ps on iMac 20 inch (it's almost full - 320 GB) when I enter time machine, a tab comes up on finder which reads "Time Machine backups" it's able to be ejected like a disc or a connected device. On the iMac 20 inch, I dragged some files onto there as if using it like a hard drive. Is this the correct method? Then I went to my 27inch iMac and saw the "Time Machine Backups" hoping to see the files I dragged from the 20inch iMac. But the files were not there except a folder that said "Backups.backupdb". Can someone help me?

    It's not a good idea to use a network disk for both Time Machine backups and other things.  By design Time Machine will eventually consume all the space on its output disk, which will then cause problem for your other files.  I'd store those other files on an external disk connected to the Time Capsule.  The problem with that is that Time Machine will only back up files that are local to your Mac.  That means that you'll only have one copy of the files on or attached to your Time Capsule.
    By the way, you've been misled by poor field labeling on this forum into typing a large part of your message into the field intended for the subject.  In the future just type a short summary of your post into that field and type the whole message into the field below that.

  • How to use the t-code vf31 tor taking print out of invoice

    Hi,
      How to use the t-code vf31 for taking print out,am getting an error like no message for initial processing exist,
    venu

    Hi,
    Please find the steps
    Output type                     RD00
    Transmission medium             1
    Sort order                      01
    Processing mode                 1
    Please give the oppropriate fields,
    if the still error persists  check the configuration in NACE transaction code.
    thanks
    Kuntla

  • How to use the table maintenance events for validating the input entries..?

    Hi,
    I have created a Z table with 6 fields in which all are KEY fields. All are of CHAR type. I have created the Table Maintenance Generator for the same. While maintaining the entries in the table, even though I maintain a blank entry for a field it is saving the entry. But, I don't want that way. All the fields are mandatory in my table. One should enter all the fields. Otherwise it should not allow to save the entry. So, I think it can be done using the Table Maintenance Events. can someone tell me how to use the Table Maintenance Events. and which event to use for my reuqirement and what is the logic to be written.
    Or Is there any other way to solve my problem.
    Please share your inputs. Thanks in advance.
    Best regards,
    paddu.

    In the table maintenance generator, Environment --> Modifications --> Events then a screen will be appear here,we need to create the Events.In the EVENTS screen, press new Entries, there give 01(Before Saving the Data in the Database) and give a name(This will become a PERFORM), then click the Editor pushbutton, this will be there at the right side of the entry, then a popup will be appear, you can create an include program, there inside of the include program write ur code.
    Here is documentation for Event 01(Before Saving the Data in the Database )
    Event 01: Before Saving the Data in the Database
    Use
    This event occurs before new, changed or deleted entries are written to the database. Other activities can be performed, for example:
    hidden entry processing
    fill hidden fields
    flag data to be written to hidden tables after the database change.
    To have the changes saved by the central maintenance dialog routines, SY-SUBRC must be set to 0 at the end of the routine.
    Realization
    This event has no standard routine. The following global data is available for the realization of the user routine:
    internal table TOTAL
    field symbols
    field symbols <ACTION> and <ACTION_TEXT>
    <STATUS>-UPD_FLAG
    If internal table data are to be changed before saving, t he changes should be made in both the internal table TOTAL and in the internal table EXTRACT.
    FORM abc.
    DATA: F_INDEX LIKE SY-TABIX. "Index to note the lines found
    LOOP AT TOTAL.
    IF <ACTION> = desired constant.
    READ TABLE EXTRACT WITH KEY <vim_xtotal_key>.
    IF SY-SUBRC EQ 0.
    F_INDEX = SY-TABIX.
    ELSE.
    CLEAR F_INDX.
    ENDIF.
    (make desired changes to the line TOTAL)
    MODIFY TOTAL.
    CHECK F_INDX GT 0.
    EXTRACT = TOTAL.
    MODIFY EXTRACT INDEX F_INDX.
    ENDIF.
    ENDLOOP.
    SY-SUBRC = 0.
    ENDFORM.
    Regards,
    Joy.

  • How to use the checksumdll.lib in LabWindow/CVI to create CRCChecksum();

    Hi All,
    Any one know how to use the checksumdll.lib in LabWindow/CVI to create CRCChecksum() ?
    Thank you.

    Do you ave some documentation about that dll?
    Have you looked into dll properties searching for vendor name? Maybe you can look int vendorìs site and obtain some help.
    Ultimately: are you forced to use that dll or can you use any software to calculate the checksum? There are several CRCs that you can use: provided you know which is the type used you could find an algorithm to calculate the CRC and check an existing one.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • How to use the selection profile and status profile for production order?

    Hi expert,
       I want to know how to use the selection profile and status profile for production order. what's the usage for these two selection profile and status profile ?
      Please help me.
      thanks in advance.
      george.shi

    Hi George,
    There are are two types of statuses.One is system status and second one is user status.These statuses will tell us current situation of an order.
    We can't change system statuses.But we can create our own statuses through status profile.With this profile we can control user statuses.
    In this status profile,
    1.We define the sequence in which user statuses can be activated,
    2.We define initial statuses
    3. Allow or prohibit certain business transactions.
    Selection profiles are used to select the objects (say production orders) with different status combinations.We assign status profiles to selection profiles in BS42 T-Code.
    Regards,
    Raja.
    Edited by: Rajarao on Oct 30, 2008 6:21 AM
    Edited by: Rajarao on Oct 30, 2008 6:22 AM

  • How to stop the "minority report" type of personalized ads triggered by one's google search and appearing in the firefox browser?

    Please advise how to stop the "minority report" type of personalized advertising apparently triggered by one's google search and appearing in the firefox browser.
    == This happened ==
    Every time Firefox opened
    == a few months ago

    If another uses the computer with their own user account, everything
    is kept separate in each users folder. Only if someone used your account
    would that be an issue.
    Sometimes a problem with Firefox may be a result of malware installed on your computer, that you may not be aware of.
    You can try these free programs to scan for malware, which work with your existing antivirus software:
    * [http://www.microsoft.com/security/scanner/default.aspx Microsoft Safety Scanner]
    * [http://www.malwarebytes.org/products/malwarebytes_free/ MalwareBytes' Anti-Malware]
    * [http://support.kaspersky.com/viruses/disinfection/5350 Anti-Rootkit Utility - TDSSKiller]
    * [http://general-changelog-team.fr/en/downloads/viewdownload/20-outils-de-xplode/2-adwcleaner AdwCleaner] (for more info, see this [http://www.bleepingcomputer.com/download/adwcleaner/ alternate AdwCleaner download page])
    * [http://www.surfright.nl/en/hitmanpro/ Hitman Pro]
    * [http://www.eset.com/us/online-scanner/ ESET Online Scanner]
    [http://windows.microsoft.com/MSE Microsoft Security Essentials] is a good permanent antivirus for Windows 7/Vista/XP if you don't already have one.
    Further information can be found in the [[Troubleshoot Firefox issues caused by malware]] article.
    Did this fix your problems? Please report back to us!

  • How to use the created search helps in the program?

    Hi Everyone,
    I know how to create Search help elementary / collective search help through SE 11. I have a question, how can I make use of the created search help in the program.
    How to use the Search help in the programs, which is created through SE11
    Subbu.

    Hi,
    In case if you want to use in parameters statement, then we can use the suffix MATCHCODE OBJECT syntax.
    Eg.
    report abc.
    parameters : a(10) type c matchcode object ZBELNR.
    Hope this helps.
    regards,
    amit m.

  • Gantt chart: Don't know how to use the tooltipkeys and toolkeylabel

    I have a problem. Don't know how to use the tooltipkeys and toolkeylabel. I used jquery to select the gantt bars and on mouse over i was getting the task id "tid" then passing it to adf bean with serverlistener and showing a popup that is adf component with javascript. For positioning of the popup I used a button that has width and height 0 and has position absolute and gets the coordinates of the mouse.
    "div[et]" is a jquery selector that selects all the elements that have attribute et. I noticed that all the bars have that attribute as a few other attributes as well "part"...
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
            xmlns:dvt="http://xmlns.oracle.com/dss/adf/faces">
        <af:document title="untitled1.jsf" id="d1">
            <af:resource type="javascript" source="https://ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js"/>
            <af:resource type="javascript" source="resources/js/home.js"/>
            <af:messages id="m1"/>
            <af:form id="f1">
               <af:commandButton text="commandButton 1" id="cb1" inlineStyle="visibility:hidden; width:0; height:0" />
                <af:popup id="noteWindow" contentDelivery="lazyUncached" binding="#{homeBean.popup}">
                    <af:noteWindow id="popupWindow">
                        <af:panelFormLayout id="pfl2">
                            <af:panelLabelAndMessage label="Task id" id="plam5">
                                <af:outputText value="#{homeBean.taskId1}" id="ot64"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="Start Location Name" id="plam6">
                                <af:outputText value="#{homeBean.startLocation}" id="ot7"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="Stop Location Name" id="plam7">
                                <af:outputText value="#{homeBean.stopLocation}" id="ot8"/>
                            </af:panelLabelAndMessage>
                            <af:panelLabelAndMessage label="tasktype" id="pla2m7">
                                <af:outputText value="#{homeBean.taskType}" id="ot9"/>
                            </af:panelLabelAndMessage>
                        </af:panelFormLayout>
                    </af:noteWindow>
                </af:popup>
                <af:serverListener type="jsServerListener" method="#{homeBean.serverEventHandler}"/>
                <dvt:schedulingGantt id="gantt1" value="#{bindings.PersonView1.schedulingGanttModel}" var="row"
                                     startTime="2011-07-04 00:00:00" endTime="2011-07-04 23:00:00" summary="gsg"
                                     showMenuBar="false" showToolbar="false" iconPlacement="left"
                                     showTasksAsDailyBar="false">
                    <f:facet name="major">
                        <dvt:timeAxis scale="days" id="ta1"/>
                    </f:facet>
                    <f:facet name="minor">
                        <dvt:timeAxis scale="hours" id="ta2"/>
                    </f:facet>
                    <f:facet name="nodeStamp">
                        <af:column sortProperty="#{bindings.PersonView1.hints.PersonId.name}" sortable="false"
                                   headerText="#{bindings.PersonView1.hints.PersonId.label}" id="c1">
                            <af:outputText value="#{row.PersonId}" id="ot1">
                                <af:convertNumber groupingUsed="false"
                                                  pattern="#{bindings.PersonView1.hints.PersonId.format}"/>
                            </af:outputText>
                        </af:column>
                    </f:facet>
                </dvt:schedulingGantt>            
            </af:form>
        </af:document>
    </f:view>javascript:
    $(document).ready(bindEvents());
    function bindEvents() {
        $("div[et]").live('mouseover', function (e) {
             $('#cb1').css("position", 'absolute');
             $('#cb1').css("top", e.pageY-4);
             $('#cb1').css("left", e.pageX);
            var popup = AdfPage.PAGE.findComponentByAbsoluteId("noteWindow");
            var element = AdfPage.PAGE.findComponent("f1");
            var taskIdToPass = null;
            if ($(this).attr("tid") !=undefined) {
                 taskIdToPass = $(this).attr('tid').toString();
            } else {
                taskIdToPass = $(this).parent().attr('tid').toString();
            var param = {            taskId : taskIdToPass        };
            AdfCustomEvent.queue(element, "jsServerListener", param, true);
            if (!popup.isPopupVisible()) {
                var hints = {};
                hints[AdfRichPopup.HINT_LAUNCH_ID] = "cb1";
                hints[AdfRichPopup.HINT_ALIGN_ID] =  "cb1";
                hints[AdfRichPopup.HINT_ALIGN] = AdfRichPopup.ALIGN_AFTER_START;
                popup.show(hints);
        }).live("mouseout", function () {
            var popup = AdfPage.PAGE.findComponentByAbsoluteId("noteWindow");
            popup.hide();
    };My bean that is session bean:
    package view;
    import oracle.adf.model.BindingContext;
    import oracle.adf.model.binding.DCDataControl;
    import oracle.adf.view.rich.component.rich.RichPopup;
    import oracle.adf.view.rich.render.ClientEvent;
    import oracle.jbo.ApplicationModule;
    import oracle.jbo.Key;
    import oracle.jbo.Row;
    import oracle.jbo.RowSetIterator;
    import oracle.jbo.ViewObject;
    public class HomeBean {
        private RichPopup popup;
        private String taskId1;
        private String startLocation;
        private String stopLocation;
        private long taskId;
        private String taskType;
        public HomeBean() {
            super();
        public void serverEventHandler(ClientEvent clientEvent) {    
            String taskIdString = clientEvent.getParameters().get("taskId").toString();
            this.taskId = Long.parseLong(taskIdString);
            DCDataControl dc1 = BindingContext.getCurrent().findDataControl("AppModuleDataControl");
            ApplicationModule am = dc1.getApplicationModule();
            ViewObject vo = am.findViewObject("PdTrfDayView1");  
            RowSetIterator rowSetIterator = vo.createRowSetIterator(null);
            Row[] rows = rowSetIterator.findByKey(new Key(new Object[] {taskId}), 1);
            Row row = rows[0];
           this.taskId1 =  row.getAttribute("PdTrfDayId").toString();
           this.startLocation = row.getAttribute("StartLocation").toString();
           this.stopLocation = row.getAttribute("StopLocation").toString();
           this.taskType = row.getAttribute ("PdTrfTypeId").toString();
            RichPopup.PopupHints ph = new RichPopup.PopupHints();
            vo.closeRowSetIterator();
        public long getTaskId() {
            return taskId;
        public void setPopup(RichPopup popup) {
            this.popup = popup;
        public RichPopup getPopup() {
            return popup;
        public String getTaskId1() {
            return taskId1;
        public String getStartLocation() {
            return startLocation;
        public String getStopLocation() {
            return stopLocation;
        public String getTaskType() {
            return taskType;
    }I am wondering If i can use setCurrentRow on the iterator that i create and use it for displaying on the popup instead of binding startLocation and stopLocation to the bean and if there is any benefit of that at all...
    Edited by: 897833 on Nov 24, 2011 11:37 AM

    Hi,
    To use tooltipkeys and tooltiplabel in gantt, you can add following code in managed bean
    public String[] getTooltipKeys()
    return new String[]{"columnA", "columnB", "StartDate", "EndDate"};
    public String[] getTooltipLabels()
    return new String[]{"A", "B", "Start Date", "End Date"};
    where , the string array in the ToolTipKeys represents the columns, of the table you have in the gantt component , and the string array in TooltipLabels displays the label you want to display for the table columns.
    In the jsff, you could call the bean methods as follows:
    tooltipKeys="#{GanttBean.tooltipKeys}"
    tooltipKeyLabels="#{GanttBean.tooltipLabels}"

  • How to access the Custom Data type variable given in Expression edit control To and From LabVIEW

    Hello, I would like to know how to access the custom data type variable given in the Espression Edit Control from LabVIEW and vice-versa
    Say, the FileGlobals.Reference_Handle (Custom Data Type Variable) contains the
    VISA I/O session (Which in turn contains VISA_DeviceName: String, Session: Number),
    Channel1: Number and
    Channel2: Number
    I am expecting the user to give FileGlobals.Reference_Handle as the input at the ExpressionEdit Control in the edit screen of the VI Call.
    I would like to know how to get the values of this custom data type to LabVIEW?
    Say, if I have the Cluster in LabVIEW like VISA I/O session (Deive Name and Session Number), Channel1 and Channel2
    how do i need to set this cluster to the Custom Data type variable in TestStand?
    Thanks and Regards
    Prakash 

    Hi,
    TestStand to LabVIEW: i didnt understand what you r trying to achieve. But if you are using references, Use Property nodes and Invoke nodes to achieve what you want in LabVIEW.
     LabVIEW to TestStand: check the image below: You need to click the button next to 'container'. I have used a cluster output in the VI.
    Hope this helps
    .......^___________________^
    ....../ '---_BOT ____________ ]
    ...../_==O;;;;;;;;_______.:/
    Attachments:
    1.JPG ‏187 KB

  • How to use the function module ....

    hi
    how to use the function module ssf_function_module_name in smartforms

    Hi..
    If you are using this Function module, you can get the generated function module name of smartform dynamically. It is good progrmaming practice to get the fucntion module name dynamically because there might be some problems if you are hard coding in program.
    This will return the name of the function module and then from the exporting parameters you can use the fucntion module name to pass parameters to Smartforms.
    Check this link.I am expalining here how to use this function module.
    https://wiki.sdn.sap.com/wiki/pages/pointstab/viewpageversion.action?pageId=36109&version=2
    Calling SMARTFORMS from your ABAP program
    REPORT ZSMARTFORM.
    Calling SMARTFORMS from your ABAP program.
    Collecting all the table data in your program, and pass once to SMARTFORMS
    SMARTFORMS
    Declare your table type in :-
    Global Settings -> Form Interface
    Global Definintions -> Global Data
    Main Window -> Table -> DATA
    Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming
    http://sapr3.tripod.com
    TABLES: MKPF.
    DATA: FM_NAME TYPE RS38L_FNAM.
    DATA: BEGIN OF INT_MKPF OCCURS 0.
    INCLUDE STRUCTURE MKPF.
    DATA: END OF INT_MKPF.
    SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001.
    SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR.
    MOVE-CORRESPONDING MKPF TO INT_MKPF.
    APPEND INT_MKPF.
    ENDSELECT.
    At the end of your program.
    Passing data to SMARTFORMS
    call function 'SSF_FUNCTION_MODULE_NAME'
    exporting
    formname = 'ZSMARTFORM'
    VARIANT = ' '
    DIRECT_CALL = ' '
    IMPORTING
    FM_NAME = FM_NAME
    EXCEPTIONS
    NO_FORM = 1
    NO_FUNCTION_MODULE = 2
    OTHERS = 3.
    if sy-subrc <> 0.
    WRITE: / 'ERROR 1'.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    call function FM_NAME
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
    CONTROL_PARAMETERS =
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
    OUTPUT_OPTIONS =
    USER_SETTINGS = 'X'
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
    JOB_OUTPUT_INFO =
    JOB_OUTPUT_OPTIONS =
    TABLES
    GS_MKPF = INT_MKPF
    EXCEPTIONS
    FORMATTING_ERROR = 1
    INTERNAL_ERROR = 2
    SEND_ERROR = 3
    USER_CANCELED = 4
    OTHERS = 5.
    if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    <b>Reward points if useful</b>
    Regards
    Ashu

  • How to use the function module /IRM/IPBB_AGREEMENT_CREATE.

    Hi all,
    Please help me how to use the function module /IRM/IPBB_AGREEMENT_CREATE.
    It is a Vistex fuction module which is used to create Sales contract in SAP-Vistex. If anyone has use the function module and do have the sample code please share it.
    Thanks.

    FORM create_agreement TABLES pt_agreement
                                           CHANGING po_agreement .
      CONSTANTS: c_strt_knumh TYPE knumh VALUE '0000000000'.
      DATA: lc_kona  TYPE /irm/s_gkona,
            lc_cbasp TYPE /irm/s_ipcbasp,
          lt_cbapr TYPE /irm/t_ipcbapr,         "Partners
          lc_cbapr TYPE /irm/s_ipcbapr,
          lt_cbadt TYPE  /irm/t_ipcbadt,        "Dates
          lc_cbadt TYPE  /irm/s_ipcbadt,
          lt_cbafs TYPE  /irm/t_ipcbafs,
          lc_cbafs TYPE  /irm/s_ipcbafs,
          lt_cbacn TYPE  /irm/t_ipcbacn,
          lc_cbacn TYPE  /irm/s_ipcbacn,
          lt_cbacl TYPE  /irm/t_ipcbacl,
          lc_cbacl TYPE  /irm/s_ipcbacl,
          lt_cbtpv TYPE  /irm/t_ipagtpv,
          lc_cbtpv TYPE  /irm/s_ipagtpv,
          lt_texts TYPE  text_lh,
          lc_texts TYPE  itclh,
          lt_cbasd TYPE  /irm/t_ipcbasd,
          lc_cbasd TYPE  /irm/s_ipcbasd,
          lc_agreement    TYPE  /irm/s_ipcbasp_doc,
          lc_e_log_number TYPE  balognr,
          lt_messages     TYPE  /irm/t_gprolog.
      DATA: lt_vake      TYPE  cond_vakevb_t,
            lc_vake      TYPE LINE OF cond_vakevb_t,
            lt_konh      TYPE  /irm/t_gkonh,
            lc_konh      TYPE LINE OF /irm/t_gkonh,
            lt_konp      TYPE  /irm/t_gkonp,
            lc_konp      TYPE LINE OF /irm/t_gkonp,
            lt_konw      TYPE  /irm/t_gkonwu,
            lc_konw      TYPE LINE OF /irm/t_gkonwu,
            lt_konm      TYPE  /irm/t_gkonmu,
            lc_konm      TYPE LINE OF  /irm/t_gkonmu,
            lt_komg      TYPE  /irm/t_gkomg_index,
            lc_komg      TYPE LINE OF /irm/t_gkomg_index,
            lt_user_data TYPE  /irm/t_gpraxfu_index,
            lc_user_data TYPE LINE OF /irm/t_gpraxfu_index.
      DATA: lc_updt(1) TYPE c.
      DATA: lc_knumh TYPE knumh.
      DATA: BEGIN OF lc_str_knumh,
             hd(2) TYPE c VALUE '$$',
             inc_num(8) TYPE c,
            END OF lc_str_knumh.
      DATA: blank_agree_key TYPE knuma VALUE '~~~~~~~~~~'.
      FIELD-SYMBOLS <konh_line> LIKE LINE OF lt_konh.
      FIELD-SYMBOLS <konp_line> LIKE LINE OF lt_konp.
      DATA: lc_rule TYPE type_key_rule.
      READ TABLE pt_agreement INTO lc_rule INDEX 1.
    SELECT SINGLE * FROM  kona
            WHERE  vkorg   = lc_rule-vkorg
            AND    vtweg   = '10'
            AND    spart   = '10'
            AND    boart   = 'ZPS1'
            AND    botext  = lc_rule-sap_agkey.
    IF sy-subrc = 0.
       lc_updt = 'U'.
    ELSE.
      lc_updt = 'I'.
    ENDIF.
      LOOP AT pt_agreement INTO lc_rule.
        MOVE sy-tabix TO lc_str_knumh-inc_num.
        CONDENSE lc_str_knumh-inc_num NO-GAPS.
        WHILE lc_str_knumh-inc_num+7(1) = ' '.
          CONCATENATE '0' lc_str_knumh-inc_num INTO lc_str_knumh-inc_num.
          CONDENSE lc_str_knumh-inc_num NO-GAPS.
        ENDWHILE.
        CONCATENATE '$$' lc_knumh INTO lc_knumh.
        MOVE lc_str_knumh TO lc_knumh.
       MOVE c_strt_knumh TO lc_knumh.
        CLEAR: lc_konh, lc_konp, lc_komg.
        MOVE: lc_rule-vkorg    TO lc_komg-komg-vkorg,
              '10'             TO lc_komg-komg-vtweg,
              '10'             TO lc_komg-komg-spart,
              p_waers          TO lc_komg-komg-waerk,
              '1300'           TO lc_komg-komg-bukrs,
              lc_rule-lifnr    TO lc_komg-komg-lifnr,
              lc_knumh         TO lc_komg-knumh,
              lc_knumh         TO lc_konh-knumh,
              lc_knumh         TO lc_konp-knumh,
              lc_rule-datab    TO lc_konh-datab,
              lc_rule-datbi    TO lc_konh-datbi.
        CASE lc_rule-tablnam.
          WHEN 'A701'.                   "Every Agreement will have a A701 rule -
            "Therefore we acn setup the header using A701
            MOVE: 'New       '  TO lc_kona-knuma,
                  lc_rule-vkorg TO lc_kona-vkorg,
                  '10'          TO lc_kona-vtweg,
                  '10'          TO lc_kona-spart,
                  'ZPS1'        TO lc_kona-boart,
                  'C'           TO lc_kona-abtyp,
                  'V'           TO lc_kona-kappl,
                  p_waers       TO lc_kona-waers,
                  lc_rule-knuma_ag TO lc_kona-abrex,
                  'ZPS2'        TO lc_kona-kobog,
                  lc_rule-datab TO lc_kona-datab,
                  lc_rule-datbi TO lc_kona-datbi,
                  lc_rule-sap_agkey TO lc_kona-botext,
                  '1300'        TO lc_kona-bukrs,
                  'I'           TO lc_kona-updkz.
            MOVE: 'New       '  TO lc_cbasp-knuma_ag,
                  'ZPS1'        TO lc_cbasp-boart_ag,
                  p_waers       TO lc_cbasp-waers,
                  'A'           TO lc_cbasp-setl_mth,
                  'B'           TO lc_cbasp-setl_typ,
                  'A2'          TO lc_cbasp-ident,
                  'E'           TO lc_cbasp-setlm,
                  'ZPDA'        TO lc_cbasp-pargr,
                  'X'           TO lc_cbasp-npric,
                  'LF'          TO lc_cbasp-stprl,
                  lc_rule-lifnr TO lc_cbasp-stpar,
                  lc_rule-contract_rev  TO lc_cbasp-rvnum,
                  'I'           TO lc_cbasp-updkz.
            CONCATENATE: blank_agree_key
                   lc_rule-lifnr        INTO lc_konh-vakey.
            MOVE: lc_rule-lifnr TO lc_konp-lifnr.
          WHEN 'A703'.
            CONCATENATE: blank_agree_key
                         lc_rule-kunnr      INTO lc_konh-vakey.
            MOVE lc_rule-kunnr TO lc_komg-komg-kunnr.
          WHEN 'A709'.
            CONCATENATE: blank_agree_key
            lc_rule-zzprodh1  lc_rule-zzprodh2  lc_rule-zzprodh3
                   lc_rule-zzprodh4  lc_rule-zzprodh5 INTO lc_konh-vakey.
            CONCATENATE: lc_rule-zzprodh1  lc_rule-zzprodh2  lc_rule-zzprodh3
                   lc_rule-zzprodh4  lc_rule-zzprodh5 INTO lc_komg-komg-prodh.
          WHEN 'A710'.
            CONCATENATE: blank_agree_key
                lc_rule-matkl   INTO lc_konh-vakey.
            MOVE lc_rule-matkl TO lc_komg-komg-matkl.
          WHEN 'A711'.
            CONCATENATE: blank_agree_key
                 lc_rule-matnr   INTO lc_konh-vakey.
            MOVE lc_rule-matnr TO lc_komg-komg-matnr.
            IF lc_rule-kschl = 'ZPPL'.
              MOVE: 'C'              TO lc_konp-krech,
                    'CAD'              TO lc_konp-konwa.
              lc_konp-kbetr = lc_rule-net_po_price * 1.
            ENDIF.
          WHEN 'A717'.
          WHEN 'A718'.
            CONCATENATE: blank_agree_key
                 lc_rule-zzextwg INTO lc_konh-vakey.
            MOVE lc_rule-zzextwg TO lc_komg-komg-zzextwg.
         WHEN 'A719'.
           CONCATENATE: blank_agree_key
                lc_rule-werks INTO lc_konh-vakey.
           MOVE lc_rule-werks TO lc_komg-komg-werks.
         WHEN 'A721'.
           CONCATENATE: blank_agree_key
                 lc_rule-kunnr lc_rule-werks INTO lc_konh-vakey.
           MOVE: lc_rule-kunnr TO lc_konp-kunnr,
                 lc_rule-kunnr TO lc_komg-komg-kunnr.
          WHEN 'A722'.
            CONCATENATE: blank_agree_key
                         lc_rule-vkbur INTO lc_konh-vakey.
            MOVE lc_rule-vkbur TO lc_komg-komg-vkbur.
          WHEN 'A724'.
            CONCATENATE: blank_agree_key
                          lc_rule-kunnr lc_rule-vkbur INTO lc_konh-vakey.
            MOVE: lc_rule-kunnr TO lc_konp-kunnr,
                  lc_rule-kunnr TO lc_komg-komg-kunnr,
                  lc_rule-vkbur TO lc_komg-komg-vkbur.
        ENDCASE.
        MOVE: 'A'                  TO lc_konh-kvewe,
              lc_rule-tablnam+1(3) TO lc_konh-kotabnr,
              lc_rule-kappl        TO lc_konh-kappl,
              lc_rule-kschl        TO lc_konh-kschl.
        REPLACE ALL OCCURRENCES OF '~' IN lc_konh-vakey WITH ' '.
        APPEND lc_konh TO lt_konh.
        CLEAR lc_konh.
    *--- Add in the KONP.Do we need to add
        MOVE: lc_rule-kappl        TO lc_konp-kappl,
              lc_rule-kschl        TO lc_konp-kschl,
              'G'                  TO lc_konp-krech.
        IF lc_rule-kschl+3(1) = '%'.
          MOVE: 'A'              TO lc_konp-krech,
                '%'              TO lc_konp-konwa.
          lc_konp-kbetr = lc_rule-rebate_perc * 1.
        ENDIF.
        APPEND lc_konp TO lt_konp. CLEAR lc_konp.
        APPEND lc_komg TO lt_komg. CLEAR lc_komg.
      ENDLOOP.
      IF  lc_updt = 'I'.
        CALL FUNCTION '/IRM/IPCB_AGREEMENT_CREATE'
          EXPORTING
          I_MESSAGES_DISPLAY        = ' '
          I_SAVE_MESSAGES           = ' '
          I_COMMIT_WORK             = 'X'
          I_CALL_FROM_WS            = ' '
            is_kona                   = lc_kona
            is_cbasp                  = lc_cbasp
            it_cbapr                  = lt_cbapr
            it_cbadt                  = lt_cbadt
            it_cbafs                  = lt_cbafs
            it_cbacn                  = lt_cbacn
            it_cbacl                  = lt_cbacl
            it_cbtpv                  = lt_cbtpv
            it_texts                  = lt_texts
            it_cbasd                  = lt_cbasd
          IMPORTING
            es_agreement              = lc_agreement
            e_log_number              = lc_e_log_number
          TABLES
            t_messages                = lt_messages
         CHANGING
          CT_VAKE                   = lt_vake
          ct_konh                   = lt_konh
          ct_konp                   = lt_konp
          CT_KONW                   = lt_konw
          CT_KONM                   = lt_konm
           ct_komg                   = lt_komg
          CT_USER_DATA              = lt_usr_data
          EXCEPTIONS
            no_documents_to_process   = 1
            no_authorization          = 2
            creation_failed           = 3
            new_pricing_not_maitained = 4
            OTHERS                    = 5.
        IF sy-subrc <> 0.
    Implement suitable error handling here
        ELSE.
          MOVE: lc_agreement-knuma_ag TO po_agreement,
                lc_agreement-knuma_ag TO lc_kona-knuma.
        ENDIF.
        APPEND LINES OF lt_messages TO gt_messages.
      ELSE.
        MOVE-CORRESPONDING kona TO lc_kona.
      ENDIF.
      LOOP AT lt_konh ASSIGNING <konh_line>.
        MOVE lc_kona-knuma TO <konh_line>-vakey+0(10).
       move '&'           to <konh_line>-knumh+0(1).
      ENDLOOP.
      LOOP AT lt_konp ASSIGNING <konp_line>.
       MOVE lc_kona-knuma TO <konp_line>-vakey+0(10).
        move '&'           to <konh_line>-knumh+0(1).
      ENDLOOP.
      lc_kona-updkz = 'U'.
      lc_cbasp-updkz = 'U'.
      CLEAR lt_messages.
      CALL FUNCTION '/IRM/IPCB_AGREEMENT_CHANGE'
        EXPORTING
        I_MESSAGES_DISPLAY      = ' '
        I_SAVE_MESSAGES         = ' '
        I_COMMIT_WORK           = 'X'
        I_INIT_DATA             = 'X'
          is_kona                 = lc_kona
          is_cbasp                = lc_cbasp
         it_cbapr                = lt_cbapr
         it_cbadt                = lt_cbadt
         it_cbafs                = lt_cbafs
         it_cbacl                = lt_cbacl
         it_cbacn                = lt_cbacn
        IT_FIELDS               =
         it_texts                = lt_texts
       IMPORTING
         e_log_number            = lc_e_log_number
         TABLES
           t_messages              = lt_messages
        CHANGING
          cs_agreement            = lc_agreement
        CT_VAKE                 = lt_vake
          ct_konh                 = lt_konh
          ct_konp                 = lt_konp
        CT_KONW                 = lt_konw
        CT_KONM                 = lt_konm
          ct_komg                 = lt_komg
        CT_USER_DATA            = lt_usr_data
        EXCEPTIONS
          no_documents_to_process = 1
          no_authorization        = 2
          change_failed           = 3
          agreement_locked        = 4
          OTHERS                  = 5.
    IF sy-subrc <> 0.
    Implement suitable error handling here
    ENDIF.
      APPEND LINES OF lt_messages TO gt_messages.
    ENDFORM.                    " CREATE_AGREEMENT

Maybe you are looking for

  • The service cannot be found for the endpoint reference (EPR) 127.0.0.1/a

    Hi All: I need help!!! I am using axis2-1.5.1, jdk 1.6, eclipse 3.5, and Axis2_Codegen_Wizard_1.3.0 and windows xp. I used Axis2_Codegen_Wizard_1.3.0 to generate the client stub and proxy. I get the following error when I tried to call the web servic

  • Need Inputs on ECS and XSD modifications

    Hi All, I need some inputs regarding the modification of ECS and XSD. Following are the details. In our production environment, we have already deployed the ECS and XSD and there are around 20 TP set-ups and configurations using that ECS and XSD for

  • Links in old posts broken

    I've been getting alerts from old threads where a poster complains about a post I made with a link and the link is broken.  Here's an example.  Finding back these posts hasn't been easy until I discovered the pattern.  The original link in the post w

  • Calling RFC in dynpro: Issue

    Hi, With reference to the material creation blog on sdn, I'm trying to access BAPI_MATERIAL_SAVEDATA. I have taken following fields for material creation 1. Material No. 2. Description 3. Industry sector 4. Material type After deployment I created th

  • CM 14 and BI Publisher

    I am currently using CM 14 and BI Publisher for the reports. When I create a report, it makes all of the sentences run back to back, even if I have pressed enter between sentences and spaced them out in CM 14. Is there a way to format this to make it