RV_INVOICE_CREATE u0096 Issue creating more then one invoice

Hi All,
I am creating Billing document using “<b>RV_INVOICE_CREATE</b>”. For single sales record it creates fine, but when I pass multiple sales order to create invoice, it only creates billing document for first sales order rest ignored. I am using “<b>RV_INVOICE_REFRESH</b>” after each create, still it doesn’t work. Am I missing any thing here? Thanks in advance. Please check code for further details.
Regards,
Tim
CODE ....
loop at GT_INIT_ITAB2 into GS_INIT_ITAB2.
    concatenate GS_INIT_ITAB2-afdat6(4) GS_INIT_ITAB2-afdat3(2) GS_INIT_ITAB2-afdat+0(2)
                into gl_date.
    condense gl_date.
    MOVE-CORRESPONDING GS_INIT_ITAB2 to gt_xkomfk.
    gt_xkomfk-fkimg = GS_INIT_ITAB2-KWMENG.
    gt_xkomfk-SELDAT = gl_date.
    append gt_xkomfk.
Create Billing document at end of each Sales Document
    AT END OF VBELN.
      gs_vbsk-mandt = sy-mandt.
      gs_vbsk-smart = 'F'.
      gs_vbsk-ernam = sy-uname.
      gs_vbsk-erdat = sy-datum.
      gs_vbsk-uzeit = sy-uzeit.
Call function module to create Invoice
      CALL FUNCTION <b>'RV_INVOICE_CREATE'</b>
        EXPORTING
        DELIVERY_DATE   = sy-datum
        INVOICE_DATE    = gl_date
          INVOICE_TYPE    = p_fkart
          PRICING_DATE    = sy-datum
        ID_NO_ENQUEUE   = 'X'
          vbsk_i          = gs_vbsk
          with_posting    = 'B'
        IMPORTING
          vbsk_e       = gs_vbsk
        TABLES
          xkomfk       = gt_xkomfk
          xkomv        = gt_xkomv
          xthead       = gt_xthead
          xvbfs        = gt_xvbfs
          xvbpa        = gt_xvbpa
          xvbrk        = gt_xvbrk
          xvbrp        = gt_xvbrp
          xvbss        = gt_xvbss.
      loop at gt_xvbfs.
        append gt_xvbfs-vbeln to gt_vbeln.
      endloop.
     CALL FUNCTION 'DEQUEUE_EVVBAKE'
       EXPORTING
         VBELN = GS_INIT_ITAB2-vbeln.
     DESCRIBE TABLE gt_xvbrk LINES SY-SUBRC.
     IF SY-SUBRC = 0.
      DELETE GT_INIT_ITAB2.
       REFRESH GT_XKOMFK.
     ELSE.
        CALL FUNCTION <b>'RV_INVOICE_REFRESH'</b>
          EXPORTING
            WITH_POSTING = ' '
          TABLES
            XKOMFK       = GT_XKOMFK
            XKOMV        = GT_XKOMV
            XTHEAD       = GT_XTHEAD
            XVBFS        = GT_XVBFS
            XVBSS        = GT_XVBSS
            XVBPA        = GT_XVBPA
            XVBRK        = GT_XVBRK
            XVBRP        = GT_XVBRP.
    ENDIF.
      REFRESH: gt_xkomfk,    gt_xkomv,gt_xthead,gt_xvbfs,gt_xvbpa,
               gt_xvbrk,gt_xvbrp,gt_xvbss .
    ENDAT.
  endloop.

Hi Narendarn,
Thanks for your feed back. I am calling “RV_INVOICE_REFRESH” before looping thru internal table. So first one created fine. I am calling “RV_INVOICE_REFRESH” again once I process “RV_INVOICE_CREATE”. But there onwards billing document not created but I do get billing document number. But when I check in VF03 that billing document no doesn’t exist at all in system. I don’t know what wrong?
here is the code
Call function module to create Invoice
  CALL FUNCTION 'RV_INVOICE_REFRESH'
    EXPORTING
      WITH_POSTING = 'B'
    TABLES
      XKOMFK       = GT_XKOMFK
      XKOMV        = GT_XKOMV
      XTHEAD       = GT_XTHEAD
      XVBFS        = GT_XVBFS
      XVBSS        = GT_XVBSS
      XVBPA        = GT_XVBPA
      XVBRK        = GT_XVBRK
      XVBRP        = GT_XVBRP.
This value will be imported back in Billing document routine(VOFM)
Routine number 906 - For consolidation logic
  EXPORT P_CONSOL TO MEMORY ID 'ZSD_OPWS_PRE_INVOICE'.
  if gv_lock  is initial and
     gv_block is initial.
    loop at GT_INIT_ITAB2 into GS_INIT_ITAB2.
      clear: gt_xvbfs.
      refresh: gt_xvbfs.
      CALL FUNCTION 'DEQUEUE_EVVBAKE'
        EXPORTING
          MANDT = SY-MANDT
          VBELN = GS_INIT_ITAB2-VBELN.
      concatenate GS_INIT_ITAB2-afdat6(4) GS_INIT_ITAB2-afdat3(2) GS_INIT_ITAB2-afdat+0(2)
                  into gl_date.
      condense gl_date.
      MOVE-CORRESPONDING GS_INIT_ITAB2 to gt_xkomfk.
      gt_xkomfk-fkimg = GS_INIT_ITAB2-KWMENG.
      gt_xkomfk-SELDAT = gl_date.
  gt_xkomfk-SELDAT = GS_INIT_ITAB2-afdat.
      append gt_xkomfk.
      CASE P_CONSOL.
        WHEN 'N'.
Create Billing document at end of each Sales Document
          AT END OF VBELN.
            gs_vbsk-mandt = sy-mandt.
            gs_vbsk-smart = 'F'.
            gs_vbsk-ernam = sy-uname.
            gs_vbsk-erdat = sy-datum.
            gs_vbsk-uzeit = sy-uzeit.
            CALL FUNCTION 'RV_INVOICE_CREATE'
              EXPORTING
            DELIVERY_DATE   = sy-datum
                INVOICE_DATE    = sy-datum
                INVOICE_TYPE    = p_fkart
                PRICING_DATE    = sy-datum
                vbsk_i          = gs_vbsk
                with_posting    = 'B'
                id_no_enqueue   = 'X'
              IMPORTING
                vbsk_e       = gs_vbsk
              TABLES
                xkomfk       = gt_xkomfk
                xkomv        = gt_xkomv
                xthead       = gt_xthead
                xvbfs        = gt_xvbfs
                xvbpa        = gt_xvbpa
                xvbrk        = gt_xvbrk
                xvbrp        = gt_xvbrp
                xvbss        = gt_xvbss.
            CLEAR:   gt_xkomfk.
            REFRESH: gt_xkomfk.
          ENDAT.
          loop at gt_xvbfs.
            gs_vbeln-vbeln    = gt_xvbfs-vbeln.
            gs_vbeln-vbeln_so = GS_INIT_ITAB2-vbeln.
            append gs_vbeln to gt_vbeln.
          endloop.
Call function module to create Invoice
          CALL FUNCTION 'RV_INVOICE_REFRESH'
            EXPORTING
              WITH_POSTING = 'B'
            TABLES
              XKOMFK       = GT_XKOMFK
              XKOMV        = GT_XKOMV
              XTHEAD       = GT_XTHEAD
              XVBFS        = GT_XVBFS
              XVBSS        = GT_XVBSS
              XVBPA        = GT_XVBPA
              XVBRK        = GT_XVBRK
              XVBRP        = GT_XVBRP.
        WHEN 'Y1'.
Create Billing document at end internal table all togather in one Billing document
          AT LAST.
            gs_vbsk-mandt = sy-mandt.
            gs_vbsk-smart = 'F'.
            gs_vbsk-ernam = sy-uname.
            gs_vbsk-erdat = sy-datum.
            gs_vbsk-uzeit = sy-uzeit.
            CALL FUNCTION 'RV_INVOICE_CREATE'
              EXPORTING
            DELIVERY_DATE   = sy-datum
                INVOICE_DATE    = sy-datum
                INVOICE_TYPE    = p_fkart
                PRICING_DATE    = sy-datum
                vbsk_i          = gs_vbsk
                with_posting    = 'B'
                id_no_enqueue   = 'X'
              IMPORTING
                vbsk_e       = gs_vbsk
              TABLES
                xkomfk       = gt_xkomfk
                xkomv        = gt_xkomv
                xthead       = gt_xthead
                xvbfs        = gt_xvbfs
                xvbpa        = gt_xvbpa
                xvbrk        = gt_xvbrk
                xvbrp        = gt_xvbrp
                xvbss        = gt_xvbss.
            CLEAR:   gt_xkomfk.
            REFRESH: gt_xkomfk.
          ENDAT.
          loop at gt_xvbfs.
            gs_vbeln-vbeln    = gt_xvbfs-vbeln.
            gs_vbeln-vbeln_so = GS_INIT_ITAB2-vbeln.
            append gs_vbeln to gt_vbeln.
          endloop.
      ENDCASE.
    endloop.
    commit work.
Regards,
Tim

Similar Messages

  • Printing salesinvoices, is it possible to do it for more then one invoice?

    Is there a method to use VF03 with a selection for more then one sales invoices?
    I want to print them as pdf file, so I have to fill in the field billingdocument, but I need it for more then one invoice at the same time.
    I tried but it seems not to work. Is it not possible? Or is there another solution to print more then one invoices at the same time?

    Hi,
    check in the Commnication method of your Output type whether In the NUMBER OF MESSAGES field was maintained as 4
    No of messages field will control the Number of invocies to print
    check this and revert
    thanks
    santosh

  • Can I create More Then One seesion in one script?

    Hi all ,
    I have got a requirment to create more then one seesion in one script only
    (means I have to login using multiple USER's in a single script.).
    and also there is no way for LOG-OFF.
    Thanks in advnc.

    Yes. This is a very common task.
    You should databank the User and Password parameters. When running many virtual users in e-load, the script will login each script/user from the list you have included in the databank. When running in Functional playback, each new iteration of a single user will login with a new user from the databank.
    There also does not need to be a logoff. In either Functional or Load playback, each time a script or a virtual user starts a new iteration it will begin as though there are no past cookies or cache files.

  • Creating more then one instance in Singleton

    Hi Friends,
    In the Singleton pattern,I want to restrict the no. of instances of a class created to 3 or 4 and not necessarily
    one.I am written this code,that creates duplicate singleton objects,I want to know is this the right way
    to do so.
    public class Test implements Cloneable
    public Object clone() {
                try {
                    return super.clone();
                catch (CloneNotSupportedException e) {
                    throw new InternalError(e.toString());
    public class SingletonObject extends Test
      private SingletonObject(){}
      public static SingletonObject getSingletonObject()
        if (ref == null)
            ref = new SingletonObject();          
        return ref;
    private static SingletonObject ref;
    public class Clone
         public static void main(String args[])
           throws Exception
           SingletonObject obj = SingletonObject.getSingletonObject();
           SingletonObject clone1 = (SingletonObject) obj.clone();
              SingletonObject clone2 = (SingletonObject) obj.clone();
    }Thanks

    More then 1 instance defeats the purpose of the
    Singleton pattern, don't you think?No it doesn't. It's specially noted in the GoFbook
    that one way a Singleton is more flexible than a
    class (with only static members) is that you can
    change your mind and allow more than one instance.Then it's not a singleton anymore. I agree that
    developing the class in the way one does for a
    singleton object is more flexible for that reason,
    but as soon as you allow multiple instances, it's not
    singleton anymore, it's multiton (if that's the
    official term... I'd just call it a normal class).I think most people throw the word multiton out there (I know I do) when talking about a class that needs strict control over how many instances of it are out there, like a Singleton, but isn't strictly limited to a single instance. For example, you might call an immutable class that guarantees no two equal instances exist a "multiton", or perhaps there' a more preferred term out there.

  • How to Create more then one Application in HCP-trial

    Hi all,
    I am new to this field,
    I want to create new application in HCP I have already create one and want to do more hands on this but i cant find where to create second application.
    and one more question.
    can we see the content which we created through Web-based Development Workbench... to our local eclipse based tool because its not visible to me
    Regards
    GB

    Hi vinod,
    Call one BDC after the another, Like if u want to create a sales order and then correspondingly display it as well, u can capture the sales order created afer ur first BDC theu the messages mostly in SYMSGV1 and using this u can do a call txn skip first screne of VA03.
    If u are talking about session, get 2 session names and move them to different sessions or if both txn are dependant on each other, move it one after the other thru call txn. It is the same, howmany ever trx u wabnt to post thru BDC.
    Award points if this helps.

  • E-mail Issue in More then one Contact Person

    Hello Experts,
    I Have One Customer : C20000
    In this Customer having the five contact person and email for that
    now i have creating sales Order and Click on Email Button in Tool Bar,
    Now i want to automatically all five contact person  in To column and email address of respective column in send message window
    Is it Possible through FMS  ?
    Then How ?
    Please Write the query  for that
    Dixit Patel

    Dear Rahul,
    I know the distribution list,
    but I want when Click on Add Recipient and Click on Distribution List,
    Automatically come to those Customer Code in Find field through FMS
    So I have select that List Name
    Dixit Patel

  • Creating more then one JMS Destination using MBeans

    Hi all,
    I am trying to create 2(or more) JMS Destinations (Topics and Queues) in a JMS Server.
    The code looks like:
    MBeanHome home = (MBeanHome) ctx.lookup(MBeanHome.ADMIN_JNDI_NAME);
    ServerMBean srvrMBean = (ServerMBean) home.getMBean("examplesServer", "Server",
    "examples");
    JMSServerMBean jmsServer = (JMSServerMBean)home.findOrCreateAdminMBean("examplesServer",
    "JMSServer", "examples");
    jmsServer.setStore(jmsStore);//jmsStore is JMSJDBCStoreMBean obj
    jmsServer.setTargets(srvrMBean);
    JMSDestinationMBean jmsTopic1 = (JMSTopicMBean)home.findOrCreateAdminMBean("tempTopic1",
    "JMSTopic", "examples", jmsServer);
    jmsTopic1.setJNDIName("com.temp.topic1");
    jmsServer.addDestination(jmsTopic1);
    and the second one is added as:
    JMSDestinationMBean jmsTopic2 = (JMSTopicMBean)home.findOrCreateAdminMBean("tempTopic2",
    "JMSTopic", "examples", jmsServer);
    jmsTopic2.setJNDIName("com.temp.topic2");
    jmsServer.addDestination(jmsTopic2);
    (Actually, the Topics are added to the jmsServer in a method)
    I can see in the console that the first topic is added to the JMS server and to the
    JNDItree of the server instance,
    But for some reason, the second topic is not added to the JNDI tree(but it is added
    to the JMS Server).
    and I can not look up the second object in JNDI.
    Does anybody come across this problem??
    what is the right way to add the destinations??
    thanks for any help
    -Vijay

    Hi Mihir,
    thanks....I tried the same program, but the only difference is i am setting the targets
    to the jms server (i.e. jmsServer.setTarget(tm);) before adding second destination
    to it(i tried both setDestinations and addDestination).
    Because, (according to my requirements) after adding the first destination i have
    to set the target for the jmsserver (which eventually starts the JMSserver).
    So, is there any way to add the destinations to the jmsserver after setting the targets??
    thanks for any help
    -Vijay
    "Mihir Kulkarni" <[email protected]> wrote:
    The following code works for me.
    Btw, I use setDestinations and pass it an array of JMSDestinationMBeans
    instead of using addDestinations()
    Hope this helps...
    mihir
    import java.util.Set;
    import java.util.Iterator;
    import java.rmi.RemoteException;
    import javax.naming.*;
    import weblogic.jndi.Environment;
    import weblogic.management.MBeanHome;
    import javax.management.ObjectName;
    import weblogic.management.WebLogicMBean;
    import weblogic.management.MBeanCreationException;
    import weblogic.management.configuration.ServerMBean;
    import weblogic.management.runtime.ServerRuntimeMBean;
    import weblogic.management.WebLogicObjectName;
    import weblogic.management.configuration.*;
    import javax.management.InvalidAttributeValueException;
    /* Running this program will create a JMS Server and a JMS Connection
    * Factory targetted to the Admin server. It will also add a JMS Topic
    * and a JMS Queue to the JMSServer.
    * This will create the following entries in the config.xml:
    * <JMSServer Name="myJMSServer" Targets="MyServer">
    * <JMSQueue JNDIName="jmx.jms.myJMSQueue" Name="myJMSQueue"/>
    * <JMSTopic JNDIName="jmx.jms.myJMSTopic" Name="myJMSTopic"/>
    * </JMSServer>
    * <JMSConnectionFactory JNDIName="jmx.jms.myJMSConnectionFactory"
    * Name="myJMSConnectionFactory" Targets="MyServer"/>
    public class createJMS {
    public createJMS() {
    public static void main(String[] args) {
    JMSServerMBean jmsServer = null;
    JMSDestinationMBean jmsQueue = null;
    JMSDestinationMBean jmsTopic = null;
    JMSConnectionFactoryMBean jmsConnectionFactory = null;
    JMSSessionPoolMBean jmsSessionPool = null;
    JMSConnectionConsumerMBean jmsConnectionConsumer = null;
    ServerMBean srvrMBean = null;
    MBeanHome home = null;
    JMSServerMBean jmsServerConfig = null;
    file://domain variables
    String url = "t3://localhost:7001";
    String username = "system";
    String password = "mihirk00";
    file://variable Names
    String DOMAIN = "mihirDomain";
    String ADMINSERVERNAME = "MyServer";
    String JMSSERVER = "myJMSServer";
    String JMSCONNECTIONFACTORY = "myJMSConnectionFactory";
    String JMSQUEUE = "myJMSQueue";
    String JMSTOPIC = "myJMSTopic";
    log("Creating AdminMBeans for JMS queue and JMS connection
    factory");
    try
    Environment env = new Environment();
    env.setProviderUrl(url);
    env.setSecurityPrincipal(username);
    env.setSecurityCredentials(password);
    Context ctx = env.getInitialContext();
    home = (MBeanHome)ctx.lookup("weblogic.management.adminhome");
    log("Got AdminHome: " + home);
    String name = DOMAIN + ":,Name=" + ADMINSERVERNAME + ",Type=Server"
    WebLogicObjectName objName = new WebLogicObjectName(name);
    srvrMBean = (ServerMBean)home.getMBean(objName);
    file://srvrMBean =
    (ServerMBean)home.getMBean(ADMINSERVERNAME,"Server",DOMAIN);
    log("Got the serverMBean: " + srvrMBean);
    } catch (Exception e) {
    log("Exception in getting Admin home & srvrMBean: " + e);
    /* the findOrCreateAdminMBean method of the MBeanHome is used to
    create
    * the Admin MBeans for all the JMS stuff needed for this utility
    * the method takes 3 parameters - Name, Type, Domain
    * the type Parameter is the name of the MBean you want to create
    * minus the MBean prefix
    * eg) JMSServer, JMSConnectionFactory, JMSQueue etc..
    * It also takes an addition parameter which is the parent
    AdminMbean
    * if one needs to create a child node in the xml tree.
    * Once the MBean is created you can set attributes on it using
    the
    * exposed API of that MBean
    * Its always better to use the findOrCreateAdminMBean method compared
    * to createAdminMBean method .
    file://use findOrCreateAdminMBean to create JMSConnectionFactory
    try {
    jmsConnectionFactory =
    (JMSConnectionFactoryMBean)home.findOrCreateAdminMBean(JMSCONNECTIONFACTORY,
    "JMSConnectionFactory", DOMAIN);
    if( jmsConnectionFactory.getJNDIName() == null) {
    jmsConnectionFactory.setJNDIName("jmx.jms.myJMSConnectionFactory");
    log("Created a JMSConnectionFactory");
    else
    log("looked up JMS ConnectionFactory: " +
    jmsConnectionFactory.getJNDIName());
    } catch (MBeanCreationException e) {
    log("MBeanCreationException: " + e);
    catch(InvalidAttributeValueException e) {
    log("InvalidAttributeValueException: " + e);
    file://create the JMSServerMBean
    try {
    jmsServer = (JMSServerMBean)home.findOrCreateAdminMBean(JMSSERVER,
    "JMSServer", DOMAIN);
    log("Found or Created a JMSServer");
    } catch (MBeanCreationException e) {
    log("MBeanCreationException: " + e);
    file://create the JMSQueueMBean - use methods of
    JMSDestinationMBean
    file://here we pass the jmsServer as the parent MBean so that the
    file://JMSQueueMBean is created as the child of the JMSServerMBean
    try {
    jmsQueue =
    (JMSDestinationMBean)home.findOrCreateAdminMBean(JMSQUEUE, "JMSQueue",
    DOMAIN, jmsServer);
    if( jmsQueue.getJNDIName() == null) {
    jmsQueue.setJNDIName("jmx.jms.myJMSQueue");
    log("Created a JMSQueue");
    else {
    log("looked up JMS Queue: " + jmsQueue.getJNDIName());
    } catch (MBeanCreationException e) {
    log("MBeanCreationException: " + e);
    catch(InvalidAttributeValueException e) {
    log("InvalidAttributeValueException: " + e);
    file://create the JMSTopicMBean - use methods of
    JMSDestinationMBean
    file://here we pass the jmsServer as the parent MBean so that the
    file://JMSTopicMBean is created as the child of the JMSServerMBean
    try {
    jmsTopic =
    (JMSDestinationMBean)home.findOrCreateAdminMBean(JMSTOPIC, "JMSTopic",
    DOMAIN, jmsServer);
    if( jmsTopic.getJNDIName() == null) {
    jmsTopic.setJNDIName("jmx.jms.myJMSTopic");
    log("Created a JMSTopic");
    else {
    log("looked up JMS Topic: " + jmsTopic.getJNDIName());
    } catch (MBeanCreationException e) {
    log("MBeanCreationException: " + e);
    catch(InvalidAttributeValueException e) {
    log("InvalidAttributeValueException: " + e);
    file://create the target Arrays
    JMSDestinationMBean[] jdm = {jmsQueue,jmsTopic};
    TargetMBean[] tm = {srvrMBean};
    file://set the Destinations for the jms Server
    try {
    jmsServer.setDestinations(jdm);
    log("Added Destination to the jmsServer");
    } catch(Exception e) {
    log("Excpn in setting the property for jmsServer:" + e);
    /* Now target the JMS Server to the appropriate Server
    * As the JMSServerMBean extends the DeploymentMBean, we can
    directly
    * use the addTarget method of the DeploymentMBean
    file://ordering is important
    file://Target the JMS ConnectionFactory
    try {
    jmsConnectionFactory.setTargets(tm);
    log("Targetted the Connection Factory to the admin Server");
    } catch (Exception e) {
    System.out.println("Exception in targetting the
    jmsConnectionFactory to the Admin server: " + e);
    file://Target the JMS Server
    try {
    jmsServer.setTargets(tm);
    log("Targetted the JMS Server to the admin Server");
    } catch (Exception e) {
    System.out.println("\nException in targetting the jmsServer to
    the Admin server: " + e);
    log("Done with registering AdminMBeans for JMS");
    private static void log(String s) {
    System.out.println("\n[createJMS]: " + s);
    "Vijay Bujula" <[email protected]> wrote in message
    news:[email protected]...
    Hi all,
    I am trying to create 2(or more) JMS Destinations (Topics and Queues)in a
    JMS Server.
    The code looks like:
    MBeanHome home = (MBeanHome) ctx.lookup(MBeanHome.ADMIN_JNDI_NAME);
    ServerMBean srvrMBean = (ServerMBean) home.getMBean("examplesServer","Server",
    "examples");
    JMSServerMBean jmsServer =(JMSServerMBean)home.findOrCreateAdminMBean("examplesServer",
    "JMSServer", "examples");
    jmsServer.setStore(jmsStore);//jmsStore is JMSJDBCStoreMBean obj
    jmsServer.setTargets(srvrMBean);
    JMSDestinationMBean jmsTopic1 =(JMSTopicMBean)home.findOrCreateAdminMBean("tempTopic1",
    "JMSTopic", "examples", jmsServer);
    jmsTopic1.setJNDIName("com.temp.topic1");
    jmsServer.addDestination(jmsTopic1);
    and the second one is added as:
    JMSDestinationMBean jmsTopic2 =(JMSTopicMBean)home.findOrCreateAdminMBean("tempTopic2",
    "JMSTopic", "examples", jmsServer);
    jmsTopic2.setJNDIName("com.temp.topic2");
    jmsServer.addDestination(jmsTopic2);
    (Actually, the Topics are added to the jmsServer in a method)
    I can see in the console that the first topic is added to the JMS serverand to the
    JNDItree of the server instance,
    But for some reason, the second topic is not added to the JNDI tree(butit
    is added
    to the JMS Server).
    and I can not look up the second object in JNDI.
    Does anybody come across this problem??
    what is the right way to add the destinations??
    thanks for any help
    -Vijay

  • Creating more then 1 statement in one connection in SQL server

    hi
    am using sql server as my database.here i cannot create more then one statement in the i connections....why does this happen
    secondly is it preferable to create 'x' number of connections at the start of the application or create a connection as and when required...
    Pls if anyone can help me...
    regards
    Praveena

    hi,
    if i'm not wrong try to close the already creted statment if ur creating another with the same nmae otherwise it should not be a problem creating set of statements.u can create any number of statement with a single connections.u need not open connection for every statement.hope this helps u out
    bye

  • How to create a service call for more then one item

    Hi All,
            How to create a service call for more then one item. i.e. the service call should be logged for more then one item

    As you noticed this is not possible by design.
    Maybe you could have a dummy item for that purpose and register the real items to be handled in a UDT...
    HTH

  • If my component has more then one button,how to create click events

    I am learning about java beans
    My java class
    public class ButtonClass extends JButton implements Serializable{
    // ButtonHandler bh;
    public ButtonClass() {
    setText( "Hello world!" );
    setOpaque( true );
    setBackground( Color.ORANGE );
    setForeground( Color.BLUE);
    setVerticalAlignment( CENTER );
    setHorizontalAlignment( CENTER );
    // addActionListener(new ButtonHandler(new JTextArea("Hello")));
    But i want to create Bean having more then one button on my bean.
    But how to create event individually for each button

    Do you mean how do you process each event from the buttons and know which button casued the event?
    If that is what you mean then look at ButtonGroup. You can add the same mouselistener to each button and then check which one cause the event:
    myButtonEvent.getButton()

  • How can I restrict more then one user to access the table?

    Hi !
    I have a problem and two solutions and I am a bit confused as to
    which one is the best one and/or can there be any better way of
    handling the problem ?
    Problem : I have to update a key field of a table when I update
    it in the form 5.0 screen. I am basically doing a maintenance of
    a table and if a certain field is updated then the change has to
    be reflected in two more tables. But the issue is that the field
    is a part of the key in those two tables. So all I can think of
    is that I need to insert new set or rows for that new value of
    the field and delete the old set of records for old values of
    the field.
    There are two ways of doing it;
    1.One option can be to explicitely define two cursors separately
    and fetch the values in them one by one and then insert the new
    records and then delete the old records in both the tables. This
    I feel will be a cumbersome process both in terms of processing
    time and the coding.
    2.Second option I was thinking can be to create two flat tables
    (without keys) and insert the values in them and update the
    changed field there and then insert the rows in the respective
    tables. Delete the old records in the main tables and delets the
    records in these flat tables. This is a bit more faster and
    easier to predict and code. This seems to be a better option for
    me.
    Any comments on these ?
    In both the cases I was thinking of making some provision so
    that more then one person can't update the table simultaneously.
    Since if there are more then one persons doing the processing
    then some inconsistency might creep into the whole process.
    This is easier to do in the second process as if I check the
    data in the flat tables and if there is some data then I can
    presume that some one is doing the processing and I can ask the
    other person to hold for a while. But in this case how can I
    stop more then two people to simultaneously check for the empty
    table and start inserting the record ?
    I was just thinking of having a sepatare table having only one
    field and this will be a key field and as the process begins the
    process will insert a fix value say 'Y' in the key field and at
    the end of the process the record will be deleted and this way
    we can restrict the user to access the process more then one at
    a time..? Since you can't have same value of the key in a table
    more then once.
    Any better way of handling it will be deeply appreciated.
    How about locking the table at the begining and releasing the
    lock at the end ? Will there be any issue in that? since I am
    inserting and deleting the rows in the same transaction.
    Comments welcome,
    Shobhit
    null

    How about performing the update IN the database using a stored
    procedure?
    By using non-database fields on your form to get the
    information, you can then call the procedure in the database to
    perform the updates. If an error occurs in the procedure you
    rollback, if necessary, and send a message or status back to the
    form. If it succeeds you might wish to commit and then re-
    execute the form's query -- using either the original key values
    or the new key values...
    null

  • Common diemsions and more then one fact table join problem

    Hi,
    I have 5 common dimension and 3 fact table which in the same subject area. When I want to display results from more then one fact table sending database then query more then one and I think BI server join this two different result on OBI server. But I think if obi server sending database query for exp. WITH SAWITH0 .... the results get effective.
    +++002002:2ea0000:2ea000f:----2009/03/14 10:12:59
    -------------------- SQL Request:
    SET VARIABLE QUERY_SRC_CD='Report';SELECT "- Common Dimensions"."Year Month" saw_0, "- Subs. Tariff"."Subscriber Current Tariff Type" saw_1, "- Common Measures".Arpu saw_2, "- Common Measures"."Gross Margin" saw_3, "- Call Out"."Callout Dur" saw_4, "- Case".Case_Info_Num saw_5 FROM "CUSTOMER PROFILING" WHERE ("- Common Dimensions"."Year Month" = 200901) AND ("- Subs. Tariff"."Subscriber Current Tariff Type" = 'PREPAID') ORDER BY saw_0, saw_1
    +++002002:2ea0000:2ea000f:----2009/03/14 10:12:59
    -------------------- General Query Info:
    Repository: Star, Subject Area: CUSTOMER PROFILING REV, Presentation: CUSTOMER PROFILING
    +++002002:2ea0000:2ea000f:----2009/03/14 10:13:00
    -------------------- Sending query to database named CENTRAVEA (id: <<471777>>):
    select T223282.DIM_TIME_MONTH_ID as c1,
    T221204.DIM_SUBS_CURRENT_TARIFF_TYPE as c2,
    avg(T223490.FACT_CP_ARPU) as c3,
    sum(T223490.FACT_CP_GROSS_MARGIN) as c4,
    sum(T223490.FACT_CP_CO_DUR) as c5
    from
    DM.DIM_SUBSCRIBER T221204 /* A_DIM_SUBSCRIBER */ ,
    DM.DIM_TIME_MONTH T223282 /* A_DIM_TIME_MONTH */ ,
    DM.FACT_CUST_PROFILING_PART3 T223490 /* A_FACT_CUST_PROFILING_PART3 */
    where ( T221204.DIM_SUBS_ID = T223490.DIM_SUBS_ID and T221204.DIM_SUBS_CURRENT_TARIFF_TYPE = 'PREPAID' and T223282.DIM_TIME_MONTH_ID = T223490.DIM_TIME_MONTH_ID and T223282.DIM_TIME_MONTH_ID = 200901 and T223490.DIM_TIME_MONTH_ID = 200901 )
    group by T221204.DIM_SUBS_CURRENT_TARIFF_TYPE, T223282.DIM_TIME_MONTH_ID
    order by c1, c2
    +++002002:2ea0000:2ea000f:----2009/03/14 10:13:00
    -------------------- Sending query to database named CENTRAVEA (id: <<471881>>):
    select T223282.DIM_TIME_MONTH_ID as c1,
    T221204.DIM_SUBS_CURRENT_TARIFF_TYPE as c2,
    sum(T223294.FACT_CP_CASE_INFO_NO) as c3
    from
    DM.DIM_SUBSCRIBER T221204 /* A_DIM_SUBSCRIBER */ ,
    DM.DIM_TIME_MONTH T223282 /* A_DIM_TIME_MONTH */ ,
    DM.FACT_CUST_PROFILING_PART1 T223294 /* A_FACT_CUST_PROFILING_PART1 */
    where ( T221204.DIM_SUBS_ID = T223294.DIM_SUBS_ID and T221204.DIM_SUBS_CURRENT_TARIFF_TYPE = 'PREPAID' and T223282.DIM_TIME_MONTH_ID = T223294.DIM_TIME_MONTH_ID and T223282.DIM_TIME_MONTH_ID = 200901 and T223294.DIM_TIME_MONTH_ID = 200901 )
    group by T221204.DIM_SUBS_CURRENT_TARIFF_TYPE, T223282.DIM_TIME_MONTH_ID
    order by c1, c2
    I have another subject area and which defined like this subject area contain two dimension and 5 fact table. If I want to display results on this subject area I can see best sql for my database
    My problem is why this two different subject areas create different queries. I think following query is the best for database.
    Thanks for your help
    +++002002:2ea0000:2ea0015:----2009/03/14 10:30:06
    -------------------- SQL Request:
    SET VARIABLE QUERY_SRC_CD='Report';SELECT "Dim - Segments"."Marketing Segment" saw_0, "Fact - Campaign Response"."Fact Campaign Award Amount" saw_1, "Fact - Customer Interaction"."Issue Response Cost" saw_2 FROM "AVEA ALL" ORDER BY saw_0
    +++002002:2ea0000:2ea0015:----2009/03/14 10:30:06
    -------------------- General Query Info:
    Repository: Star, Subject Area: AVEA ALL, Presentation: AVEA ALL
    +++002002:2ea0000:2ea0015:----2009/03/14 10:30:06
    -------------------- Sending query to database named AVEA ALL (id: <<474694>>):
    WITH
    SAWITH0 AS (select sum(T51461.FACT_CMPGN_AWARD_AMOUNT) as c1,
    T49384.DIM_MARKETING_SGMNT_DESC as c2
    from
    DM.DIM_MARKETING_SEGMENT T49384 /* DIM_BI_MARKETING_SEGMENT */ ,
    DM.FACT_CMPGN_RESPONSE T51461 /* FACT_BI_CMPGN_RESPONSE */
    where ( T49384.DIM_MARKETING_SGMNT_ID = T51461.DIM_MARKETING_SGMNT_ID )
    group by T49384.DIM_MARKETING_SGMNT_DESC),
    SAWITH1 AS (select sum(T51503.FACT_CUST_INT_ISSUE_RES_COST) as c1,
    T49384.DIM_MARKETING_SGMNT_DESC as c2
    from
    DM.DIM_MARKETING_SEGMENT T49384 /* DIM_BI_MARKETING_SEGMENT */ ,
    DM.FACT_CUST_INTERACTN T51503 /* FACT_BI_CUST_INTERACTN */
    where ( T49384.DIM_MARKETING_SGMNT_ID = T51503.DIM_MARKETING_SGMNT_ID )
    group by T49384.DIM_MARKETING_SGMNT_DESC)
    select distinct case when SAWITH0.c2 is not null then SAWITH0.c2 when SAWITH1.c2 is not null then SAWITH1.c2 end as c1,
    SAWITH0.c1 as c2,
    SAWITH1.c1 as c3
    from
    SAWITH0 full outer join SAWITH1 On SAWITH0.c2 = SAWITH1.c2
    order by c1

    I find solution on Oracle® Business Intelligence Suite Enterprise Edition Release Notes.
    If you use a version of Oracle Database 10g Release 2 prior to 10.2.0.3, then you might encounter an issue with a Full Outer Join that causes severe database performance issues and appears to hang the database when the Oracle BI Server sends to the database SQL queries that include WITH clauses.
    To work around this issue when using Oracle Database 10g Release 1 or 2, upgrade to Oracle Database 10g Release 2 Patch Set 2 (for 10.2.0.3). For performance reasons, this is the preferred workaround.
    To work around this issue without installing Patch Set 2, modify the Database Features table using the Administration Tool. This configuration prevents the Oracle BI Server from sending SQL constructs that expose the issue in an unpatched Oracle Database 10g.
    To modify the Database Features table:
    In the Administration Tool, open the properties of the Physical Database metadata object.
    Navigate to the Features tab.
    Ensure the values for the PERF_PREFER_MINIMAL_WITH_USAGE and PERF_PREFER_INTERNAL_STITCH_JOIN entries are selected, that is, set to True.

  • DMEE :More than one invoice for a vendor payment

    Hello Experts,
    I'm trying to create a file for payments to vendors  through transaction DMEE.
    I've create a new structure in DMEE, tree PAYM where given pace for atleast 4 invoices with semicloumn.
    but when I'm runing the payment run for more than one invoice for the same vendor, the file only shows the first one with repeation and filling all structurewith only 1st invoice.
    Issue is when payment run for a vendor for more than one invoices, only the first invoice has shown in the file.
    Sturcture of the file  coming after payment run is filled like this , pasting below for your referance.
    000000016000.0020080310             12025000003958560010000710200713      0072394000Spoerle Electronic Kft          HU010               INV.123452345434 ;INV.123452345434 ;INV.123452345434                000066                   
    INV.123452345434 is the 1st invoice.....whcih is entering one after the other instead of 2nd / 3rd invoice.
    Could you please help me?
    Thanks in advance!
    Nupur

    hi,
    i am also having same requirement.
    i have to send the payment advice details to the bank.
    for that i planned to create the settings in the DMEE.
    so plz send the steps which you are created for your requirement
    thanks ,
    Ramu

  • How do I get the text to flow throughout more then one page.

    Hello,
    I am currently using LiveCycke Designer to create a scholarship for my company. I created fields for the form and I would like to insert a text to describe the scholarship. When I insert the text, it doesn't flow onto the next page. I've tried creating a subform and clicking "flowed" and "allow page breaks within content". I also clicked auto-fit for the height, but it just makes a line. For the text box, I've clicked "Expand to fit on the height". It is also a dynamic XML Form. Is there anything else I should be doing?
    I could always send the file to someone to see if they can figure it out.
    Thank you,
    Natalie

    Thank you so much !
    but the link doesn't seem to work. It says that the URL is not in the correct format for an Acrobat.com document link.
    Natalie
    Date: Wed, 12 May 2010 07:53:12 -0600
    From: [email protected]
    To: [email protected]
    Subject: How do I get the text to flow throughout more then one page.
    Here is the corrected form..Even you you set the Subform type to "Flowed" to the subform where the Text box resides, you did not set the Page1 to Flowed (which is the key)..But when I make the Page1 type to "Flowed", all your fields above the Scholrship text boxes' Subform will go one below another.. To fix this, first I have select all the fields and wrap them into a subform and then set the Page1 to Flowed..
    https://acrobat.com/#d=XQ1yfV8fCk85M7sRLD*-gg
    Thanks
    Srini
    >

  • Can I use more then one apple ID on my computer/osx app store

    Hi,
    I use my MBP/iMac/ipad/iphone for both business and home.  Right now everything is setup to my home apple id (and I have made quite a few purchases with that).  With the release of the osx app store and FCPX,  my company wants to buy these for my computers.  But they want to do this on their apple id.  Can I run more then one id on a mac?  How can I make this work as I know they will want me to start getting more apps as they are released.

    You can have apps from multiple Apple IDs on one Mac. The issue will be that to update Mac apps bought with A ID #1 will require signing into A ID #1 in the MAS. And later when apps bought with A ID #2 need an update you will need to sign into A ID #2 in the MAS to update them. If you can keep that straight and can abide that requirement, there should be no issues.
    The same will be true to update iOS apps, but using iTunes.

Maybe you are looking for