[eval 1.1.0.21]sort in user-defined ended with ; report produces ORA-00911

reproduce it with :
1) user defined reports --> add report --> SQL :
select * from scott.emp;2) click on the sort icon in the header of the column
the workaround is to not include the ; in the sql
regards
Laurent
Message was edited by:
Laurent Schneider
prefixed!

Laurent,
Please can you prefix your comments with Eval 1.1.0.21.4.1? We'll be doing regular eval releases for the next few weeks and many of the folk on the forum are still on 1.0 (15.57), so we need to try to keep queries clear.
I know what you are testing and using, but others migt not.
As for the comment: Yes, thanks - no need for ';' on any user defined reports. You'll see if you copy the shipped reports they don't have it either. Useful to note.
Sue

Similar Messages

  • Problem with sorting involving user defined types and reports

    Hello!
    I have a problem with sorting involving Reports and user defined objet types.
    I have created the following object types
    CREATE TYPE type_balance_compte AS OBJECT
    NUM_CPT_SEQ NUMBER(8)
    ,NUM_CPT VARCHAR2(35)
    CREATE TYPE TB_type_balance_compte IS TABLE OF type_balance_compte
    At the reports query I use:
    SELECT ...
    FROM table(cast(test_pkg.balance_comptes(:P_num_soc) as TB_type_balance_compte)) c
    The procedure balance_comptes will retrieve data from various tables into the type.
    The report is ordered by a certain string field that usually contains characters and numbers.
    I need to have numbers always before characters, meaning the data should come in this order in the report for example:
    0
    1
    A
    B
    So, before the report query, I have placed a call to DBMS_SESSION.SET_NLS( 'nls_sort', 'binary' ) to guarantee NLS_SORT in case it is originally set to FRENCH.
    The problem here is that even after this call, I have the report ordered like this
    A
    B
    0
    1
    And not the numbers before as it should be.
    To try and find out where the problem was, I have created a table to use instead of the object type described above. In this case, it worked correctly. So all I know by now is that is has something to do with the type or cast, but what exactly? Does anybody now how to solve this without using a table?
    Many thanks
    Ariadne

    I have placed a call to DBMS_SESSION.SET_NLS( 'nls_sort', 'binary' ) why not order directly then:
    SQL> select *
          from table (sys.dbms_debug_vc2coll ('A', 1, '5', 'C', 'a'))
    order by nlssort (column_value, 'NLS_SORT = binary')
    COLUMN_VALUE                                                                   
    1                                                                              
    5                                                                              
    A                                                                              
    C                                                                              
    a                                                                              
    5 rows selected.?

  • How to Insert a User Defined Column with CheckBox In ADF Swings

    I have create JTable by dragging a view object from Data Control Palette .But apart from columns listed in JTable i need to insert a User Defined column with Check Box selection option in each row .
    Can any one help me out to sort the problem.
    Regards
    Bhanu Prakash
    Message was edited by:
    user579125

    I retrieve 10 column from Database and build JTable. But apart from 10 column displayed i need to display one more column( User Defined) at run time with the check box option for each row . Because on select of corresponding check box i need to do some mathematical calculation. add also How do i know whether check box is selected or not.
    Regards
    Bhanu Prakash

  • LMS 4.2.4 User Tracking End Host Report The system cannot find the path specified

    Hello at all,
    I have a problem when creating a scheduled User Tracking End Host Report.
    I always get the message "The system cannot find the path specified" and the job fails.
    An immediate report is successful.
    I tried to change the "Report Publish Path" from "C:/Program Files (x86)/CSCOpx/" to "C:/PROGRA~2/CSCOpx/", but that did'nt worked.
    Has anybody an idea?
    Regards, Kerstin

    Share the screenshot of the following directory :
    NMSROOT\CSCOpx\campus\etc\cwsi
    In case it is blank, try following :
    1.Stop the services : net stop crmdmgtd 
    2.Take a copy of > C:/Progra~2/campus/etc/users and place it under C:/Progra~2/campus/etc/cwsi
    3.Start the services : net start crmdmgtd
    Please try and let me know the updates.
    -Thanks
    Vinod
    **Encourage Contributors. RATE them.**

  • User-defined rules with SPIN (SPARQL CONSTRUCT)

    Hi,
    We are looking at SPIN as an alternative to define and execute user-defined rules. It is very expressive and in that point looks superior over Jena, SWRL and Oracle type of user-defined rules with IF (filter) -> THEN type of syntax. Although, SPIN is TopQuadrant's, it is entirely SPARQL, and Oracle supports SPARQL CONSTRUCT via Jena Adapter. TopBraid Composer provides and excellent tool support and rule editor for SPIN rules as well.
    There is no problem to execute SPIN rules via Jena Adapter, and I believe even via TopQuadrant's SIN API, which is TopQuadrants's SPARQL based infrence engine's API.
    My question is about whether Oracle has looked into supporting SPARQL CONSTUCT based user-defined rules in its native inference engine?
    Do you have a recommendation for how to use SPIN based user rules in combination with Oracle inference today?
    Thanks
    Jürgen

    Hi Jürgen,
    We are actually looking into a general mechanism that allows users to plug in their own queries/logic during inference. Thanks very much for bringing SPIN up. This general mechanism is very likely going to cover CONSTRUCT queries.
    To extend the existing inference engine using the existing Jena Adapter release, one possible way is as follows.
    1) Assume you have an ontology (model) A.
    2) Create an empty model B.
    3) run performInference on both A and B using OWLPrime.
    4) run SPARQL CONSTRUCT queries against A, B and inferred data
    5) store the query results (in the form of Jena models) back into model B.
    6) If the size of model B does not change, then stop. Otherwise, repeat 3)
    Note that model B is created to separate your original asserted data from inferred data.
    If you don't need such a separation, then don't create it.
    Thanks,
    Zhe Wu

  • CM21/cm25 sorting of user defined field in table area

    Hallo,
    I implemeted the field MARC-MATGR in the table area of the CM21 with user exit CYPP0005 and now I'm trying to use the user exit CYPP0002 for sorting in order of this field like explained in oss note 605217.
    I implemented the coding like shown in the examples of the user exits but sorting is not workiing.
    By debugging the user exit I'm not shure where I can change the internal tables to get a result sorted by this "MARC-MATGR".
    Perhaps someone can help me giving me an hint how the user exit is working and what has to be changed ?
    Thanks a lot in advance,
    Volker

    Dear ,
    I have posted a similar kind of reply in one of the thread  which may help u defining the User Defined Tabel /Filed .Just check this Out :
    For cm25/CM21 : Assuming that you have all the other set up for Capacity Requirement in place , please note the belwo steps for layout design for CM25 OR cm21 or cm22( all you will be used same overall profile )
    1.Make sure that you have proper Overall profile defined in OPD0-Define Overall profile .Here u will define Time Profile , Startegy prfoile . Lay out Profile etc .
    2.To paint your layout your soultion is to Goto -CY38-Pop down the menu -Select the Lay out Key which have been used as lay out -Goto Change Mode (Pencil symbol)-Now you will find the fields are high ligheted as per CM25 dipaly in a sequnce -You can un chekcde the Filed like Operation , Operation text , Setup what ever you do not want to show in Order Pool and Hit SAVE butotn and come back .
    CM25 --> Settings --> Display Profiles --> Planning tab.profile --> I01 --> Layout ID ( Example : 'SAPSFCLA05') which is Main Capacity Lay out id .
    If you goto CY38-Pop down the menu -You will find Main Capcitity Lay out Id : Example SAPSFCAS01 -Enter this lay out and chenage accordingly as I have explained in above
    Once you save this , then go back to CM25 and execute with coupe of work centres to check how is the order pool looks now .
    Refer this threade for Layout Id and option which u may need for CM25 front end
    Exception messages in CM21 or CM25
    I hope this should work
    Regards

  • Error while using user defined function in reports

    Hi,
    When I use the below user defined function in oracle reports I got the wrong number of arguments error
    select test_function(id,a_number,v_date-14,b_number) from dual;
    If I remove -14 from the argument it works. But iIneed to subtract 14 days from the date.
    Thanks for your help.

    select test_function(id,a_number,v_date-14,b_number) from dual;
    you have to give the command like this to_date(v_date,'dd-mon-yyyy')-14
    because the v_Date you choose in the parameter form is not having the corrent date format
    the format dd-mon-yyyy is the format in which v_date is passed by the user.

  • What the best way to create User defined table with ADDON purpose

    Hi folks, how are you ?
    I´m beginner in development to business one, and I m studying to develop ISV addons.
    But, during my exercises and analisys, I learned that have two ways to create tables and fields in business one. One way is throght by wizard in business one using Tools Menu > Configuration Tools > User Defined Tables >
    Obs: I ´m using Business One Patch Level 9.
    Other way, is create the tables and fields using DI API
    But, my question is. When I develop one addon, or one UDO form that uses one set of user defined tables or used defined fields that where created by the first way (by wizard in B1), how I deploy this in other business one installation ? The package process will ensure the creation of this tables in another enviroment or I must implement the creation of user defined tables using DI API so that this code is called during the installation?
    If in cases of addon develop I must use DI API to create user defined tables, How can I use my classes with this responsibility in package process ?
    Thanks my friends.

    Hi Renan,
    You just need to put your logic in to the startup of your application, after you've established your connection to the UI API and DI API. All this will be triggered in the constructor of your main class.
    namespace MyNamespace
    public class MyAddon
      bool runAddon = true;
      bool initialised = false;
      const string ADDON_NAME = "My Addon";
      public static void Main()
            MyAddon addOn = new MyAddon();
            if(runAddon)
                  System.Windows.Forms.Application.Run();
            else
             Application.Exit();
      public MyAddon()
            // Connect to SBO session for UI
            if(!SetApplication()) runAddon = false;
      private bool SetApplication()
            // Code goes in here to establish UI API and DI API connections
            // See SDK samples for examples
            // You should also define and filter the UI API events your addon will trap at this stage and create any menus
            // Call your routine to check if the required UDFs/UDTs exist on this company
            initialised = CheckInitialisation();
            if (!initialised)
               //  AddOn not yet intialised on this company so prompt the user to run the intialisation process
              int iResponse = app.MessageBox("The " + ADDON_NAME + " addon will now create all required fields and tables."
                                             + System.Environment.NewLine + System.Environment.NewLine
                                             + "WARNING: It is strongly recommended that all other users are logged out of this company "
                                             + "before running this process. Are you sure you wish to continue?", 2, "Yes", "No", "");
              if (iResponse == 1) initialised = InitialiseAddOn(); // Call your routine to create the objects
            return true;
    Kind Regards,
    Owen

  • Can't remove a user defined field with DI API.

    Hi,
    I'm using the code below to remove a user field.  However, the first time I run it, I get the message that:
    "Ref count for this object is higher then 0"
    The second time I run it, I get the message that:
    "No matching records found (ODBC -2028)"
    As you can see, I am killing the UserFieldsMD object.  In fact, when the function is entered, the object is nothing but later instantiated with oCompany.
    The result in both cases is that the field doesn't get removed.  What am I missing?  Any ideas?
    Thanks,
    Mike
        Public Function RemoveUserField(ByVal FieldName As String, ByVal TableName As String, ByRef ErrMsg As String) As Boolean
            Dim Result As Boolean = False
            Dim Err As Integer
            Dim oUserFieldsMD As SAPbobsCOM.UserFieldsMD
            Try
                If Not FieldExists(TableName, FieldName) Then
                    Result = True
                Else
                    oUserFieldsMD = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserFields)
                    With oUserFieldsMD
                        .TableName = TableName
                        .Name = FieldName
                        Err = .Remove
                        If Err Then
                            oUtilCompany.GetLastError(Err, ErrMsg)
                            If ErrMsg = "No matching records found (ODBC -2028)" Then
                                Result = True
                            Else
                                ErrMsg = "Was not able to remove field " & FieldName & " from table " & TableName & " programmatically." & vbCrLf & _
                                         "Please remove it manually using the Tools menu."
                            End If
                        Else
                            Result = True
                        End If
                    End With
                End If
            Catch ex As Exception
                Throw ex
            Finally
                KillObject(oUserFieldsMD)
            End Try
            Return Result
        End Function
        Public Sub KillObject(ByRef Obj As Object)
            If Not Obj Is Nothing Then ObjectRelease(Obj)
        End Sub
        Private Sub ObjectRelease(ByRef Obj As Object)
            'This routine releases objects that were acquired with oCompany.GetBusinessObject().
            System.Runtime.InteropServices.Marshal.ReleaseComObject(Obj)
            Obj = Nothing
            GC.Collect()
        End Sub

    Hi Mike,
    The issue with your code is that you are not calling the GetByKey method of the field object. Until you do this the FieldID property is 0 so when the Remove method is called it will not try and remove the correct UDF (if you run SQL profiler then you'll see that SBO is looking for the UDF based on the table and fieldID values).
    Something like the following works for me:
    private void DeleteUDF(string sTableID, string sFieldName)
        SAPbobsCOM.UserFieldsMD sboField = (SAPbobsCOM.UserFieldsMD)_sboCompany.GetBusinessObject(BoObjectTypes.oUserFields);
        try
            int iFieldID = GetFieldID(sTableID, sFieldName);
            if(sboField.GetByKey(sTableID, iFieldID))
                if (sboField.Remove() != 0)_sboApp.SetStatusBarMessage("Error removing UDF: " + _sboCompany.GetLastErrorDescription(), SAPbouiCOM.BoMessageTime.bmt_Short, true);
        finally
            System.Runtime.InteropServices.Marshal.ReleaseComObject(sboField);
            sboField = null;
            GC.Collect();
    private int GetFieldID(string sTableID, string sAliasID)
        int iRetVal = 0;
        SAPbobsCOM.Recordset sboRec = (SAPbobsCOM.Recordset)_sboCompany.GetBusinessObject(BoObjectTypes.BoRecordset);
        try
            sboRec.DoQuery("select FieldID from CUFD where TableID = '" + sTableID + "' and AliasID = '" + sAliasID + "'");
            if (!sboRec.EoF) iRetVal = Convert.ToInt32(sboRec.Fields.Item("FieldID").Value.ToString());
        finally
            System.Runtime.InteropServices.Marshal.ReleaseComObject(sboRec);
            sboRec = null;
            GC.Collect();
        return iRetVal;
    Note that the parameter sAliasID is the field name without the U_ prefix.
    Kind Regards,
    Owen

  • User defined Variable with multiple value

    Hi Experts,
    customer requirement is the following:
    Build a layout in which to have in Lead Column the cost center characteristics, but not all cost center in master data but only those chosen by user with manual input. To achieve this goal i have created a variable of type characteristics (associatd to cost center CH) with replacement type "user defined values", then i have put this var in planning level. I have created a layout with Cost Center in Lead Column and set "all possible ch combination" in additional setting.
    Thanks to the varable created, the user can enter Cost Center value, but the problem is that he cannot select more than one single cost center value, for example:
    User want to see in layout CosCen1 and CosCen4, by now he can set variable in order to see the entire range from CosCen1 to CosCen4 (included all intermediate Cost Center) or to see only one between those 2 Cost Center, but it's not possible (or better i don't know how to..) to select both cost center and display the layout with ONLY those 2 Cost Center in Lead Column (CosCen1 and CosCen4).
    In other word, is it possible to set a variable with more than one single value without using range from-to?
    If not, does exist an alternative?
    Thanks in advance.
    Fabio

    Hi Fabio,
    It works as follows.
    let's say you have 3 multiple single lines for your cost center variable.
    once you are in the folder, select any single value & the layout is ready for planning with the corresponding cost center.
    now, select the "Cost center variable row" in the header of the folder within section "Name of Variable" & click on "Trash Can" icon to "Delete Selection" of variable.
    this basically deletes all the entered selections (3 entries) & displays for all.
    It works this way, because we don't have "resriction of values required by user".
    if am not wrong & correct me if am wrong,
    overall, this is nothing but equal to "planning level not restricted with any variable".
    I just tested this & the flaw in this is that, it is not only displaying for all the initially entered 3 lines but it displays for each & every cost center irrespective of the variable selections.
    hope it is clear.

  • Oracle 11g AQ : problem enqueue user-defined type with varchar2 attribute

    Hello.
    I have a problem enqueuing a user-defined type to the queue on Oracle 10g.
    I'm using jdbc driver (ojdbc5.jar, version 11.1.0.6.0) as they provide oracle.jdbc.aq package.
    The type is following:
    CREATE OR REPLACE TYPE FIXED_T5 AS OBJECT
    (id integer,
    label varchar2(100),
    code integer,
    today date
    )I have created a java class for this type with jpub utility supplied with oracle 11g client package:
    jpub -user=scott/tger -url=jdbc:oracle:thin:@host:sid-sql=FIXED_T5:ru.invito.FixedType -compile=falseIt generated FixedType.java and FixedTypeRef.java files. Don't understand why i need the latter (FixedTypeRef).
    Then in test app:
    package ru.invito;
    import java.io.IOException;
    import java.net.InetAddress;
    import java.net.UnknownHostException;
    import java.sql.SQLException;
    import java.sql.Timestamp;
    import java.util.Date;
    import java.util.Properties;
    import java.util.UUID;
    import junit.framework.TestCase;
    import oracle.jdbc.aq.AQAgent;
    import oracle.jdbc.aq.AQEnqueueOptions;
    import oracle.jdbc.aq.AQFactory;
    import oracle.jdbc.aq.AQMessage;
    import oracle.jdbc.aq.AQMessageProperties;
    import oracle.jdbc.aq.AQEnqueueOptions.DeliveryMode;
    import oracle.jdbc.aq.AQEnqueueOptions.VisibilityOption;
    import oracle.jdbc.driver.OracleConnection;
    import oracle.jdbc.driver.OracleDriver;
    import oracle.sql.Datum;
    import oracle.sql.STRUCT;
    import oracle.sql.StructDescriptor;
    import org.apache.commons.logging.Log;
    import org.apache.commons.logging.LogFactory;
    public class AqTest extends TestCase {
         protected Log logger = LogFactory.getLog(getClass());
         public void testEnqueue() throws Exception {
              OracleDriver dr = new OracleDriver();
              Properties prop = new Properties();
              prop.setProperty("user", Config.USERNAME);
              prop.setProperty("password", Config.PASSWORD);
              OracleConnection connection = (OracleConnection) dr.connect(Config.JDBC_URL, prop);
              assertNotNull(connection);
              connection.setAutoCommit(false);
              enqueueMessage(connection, "INVITO.FIXED_T5Q", null);
              connection.commit();
         private void enqueueMessage(OracleConnection conn, String queueName, AQAgent[] recipients) throws SQLException,
                   IOException {
              logger.debug("----------- Enqueue start ------------");
              AQMessageProperties props = makeProps(queueName);
              AQMessage mesg = AQFactory.createAQMessage(props);
              String msqText = String.format("Hello, %s!", queueName);
              FixedType data = createData(36, msqText);
              Datum d = data.toDatum(conn);
              STRUCT s = (STRUCT) d;
              debugStruct("s", s);
              String toIdStr = byteBufferToHexString(s.getDescriptor().getOracleTypeADT().getTOID(), 20);
              logger.debug("s.toIdStr: " + toIdStr);
              StructDescriptor sd = StructDescriptor.createDescriptor("INVITO.FIXED_T5", conn);
              logger.debug("sd.toXMLString(): " + sd.toXMLString());
              mesg.setPayload(s);
              AQEnqueueOptions opt = makeEnqueueOptions();
              logger.debug("sending............");
              // execute the actual enqueue operation:
              conn.enqueue(queueName, opt, mesg);
              debugMessageId(mesg);
              logger.debug("----------- Enqueue done ------------");
         private void debugMessageId(AQMessage mesg) throws SQLException {
              byte[] mesgId = mesg.getMessageId();
              if (mesgId == null) {
                   throw new IllegalStateException("message id is NULL");
              String mesgIdStr = byteBufferToHexString(mesgId, 20);
              logger.debug("Message ID from enqueue call: " + mesgIdStr);
          * @return
          * @throws SQLException
         private FixedType createData(int ID, String label) throws SQLException {
              FixedType data = new FixedType();
              data._struct.setNChar(1);// initializes the flag for 'label' field
              data.setId(ID);
              data.setLabel(label);
              data.setCode(1);
              Date today = new Date();
              data.setToday(new Timestamp(today.getTime()));
              return data;
          * @param string
          * @param s
          * @throws SQLException
         private void debugStruct(String string, STRUCT s) throws SQLException {
              logger.debug(s + ".debugString(): " + s.debugString());
              logger.debug(s + "s.dump(): " + s.dump());
          * @return
          * @throws SQLException
         private AQAgent makeAgent() throws SQLException {
              AQAgent ag = AQFactory.createAQAgent();
              ag.setName("AQ_TEST");
              String agentAddress = null;
              try {
                   agentAddress = InetAddress.getLocalHost().getHostAddress();
              catch (UnknownHostException e) {
                   logger.error("cannot resolve localhost ip address. will not set it as AQ Agent address");
                   agentAddress = "NA";
              ag.setAddress(agentAddress);
              return ag;
         private AQMessageProperties makeProps(String queueName) throws SQLException {
              final String EXCEPTION_Q_TEMPLATE = "AQ$_%sT_E";
              final int DEFAULT_DELAY = 0;
              final int DEFAULT_EXPIRATION = -1;
              final int DEFAULT_PRIORITY = 0;
              AQMessageProperties propeties = AQFactory.createAQMessageProperties();
              propeties.setCorrelation(UUID.randomUUID().toString());
              propeties.setDelay(DEFAULT_DELAY);
              propeties.setExceptionQueue(String.format(EXCEPTION_Q_TEMPLATE, queueName));
              propeties.setExpiration(DEFAULT_EXPIRATION);
              propeties.setPriority(DEFAULT_PRIORITY);
              // propeties.setRecipientList(null);//should not set
              propeties.setSender(makeAgent());
              return propeties;
          * @return
          * @throws SQLException
         private AQEnqueueOptions makeEnqueueOptions() throws SQLException {
              AQEnqueueOptions opt = new AQEnqueueOptions();
              opt.setRetrieveMessageId(true);
              // these are the default settings (if none specified)
              opt.setDeliveryMode(DeliveryMode.PERSISTENT);
              opt.setTransformation(null);
              opt.setVisibility(VisibilityOption.ON_COMMIT);
              return opt;
          * Form the AQ reference
          * @param buffer
          * @param maxNbOfBytes
          * @return
         private static final String byteBufferToHexString(byte[] buffer, int maxNbOfBytes) {
              if (buffer == null)
                   return null;
              int offset = 0;
              StringBuffer sb = new StringBuffer();
              while (offset < buffer.length && offset < maxNbOfBytes) {
                   String hexrep = Integer.toHexString((int) buffer[offset] & 0xFF);
                   if (hexrep.length() == 1)
                        hexrep = "0" + hexrep;
                   sb.append(hexrep);
                   offset++;
              String ret = sb.toString();
              return ret;
    }The output is following:
    [main] 2008-07-03 19:09:49,863 DEBUG [ru.invito.AqTest] - ----------- Enqueue start ------------
    [main] 2008-07-03 19:09:50,348 DEBUG [ru.invito.AqTest] - [email protected](): name = INVITO.FIXED_T5 length = 4 attribute[0] = 36 attribute[1] = Hell
    o, INVITO.FIXED_T5Q! attribute[2] = 1 attribute[3] = 2008-07-03 19:09:49.0
    [main] 2008-07-03 19:09:50,363 DEBUG [ru.invito.AqTest] - [email protected](): name = INVITO.FIXED_T5
    length = 4
    ID = 36
    LABEL = Hello, INVITO.FIXED_T5Q!
    CODE = 1
    TODAY = 2008-07-03 19:09:49.0
    [main] 2008-07-03 19:09:50,363 DEBUG [ru.invito.AqTest] - s.toIdStr: 507ccce5b6e9f572e040007f01007203
    [main] 2008-07-03 19:09:50,363 DEBUG [ru.invito.AqTest] - sd.toXMLString(): <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <StructDescriptor sqlName="INVITO.FIXED_T5" >
      <OracleTypeADT sqlName="INVITO.FIXED_T5"  typecode="0" tds_version="1"
               is_embedded="false" is_top_level="true" is_upt="false" finalType="true" subtype="false">
        <attributes>
          <attribute name="ID"  type="INTEGER" >
            <OracleType typecode="2" />
          </attribute>
          <attribute name="LABEL"  type="VARCHAR2" >
            <OracleType typecode="12" />
          </attribute>
          <attribute name="CODE"  type="INTEGER" >
            <OracleType typecode="2" />
          </attribute>
          <attribute name="TODAY"  type="DATE" >
            <OracleType typecode="0" />
          </attribute>
        </attributes>
      </OracleTypeADT>
    </StructDescriptor>
    [main] 2008-07-03 19:09:50,379 DEBUG [ru.invito.AqTest] - sending............
    [main] 2008-07-03 19:09:50,395 DEBUG [ru.invito.AqTest] - Message ID from enqueue call: 511ff143bd4fa536e040007f01003192
    [main] 2008-07-03 19:09:50,395 DEBUG [ru.invito.AqTest] - ----------- Enqueue done ------------But when dequeueing the 'label' attribute is lost:
    DECLARE
    dequeue_options     DBMS_AQ.dequeue_options_t;
    message_properties  DBMS_AQ.message_properties_t;
    message_handle      RAW(16);
    message             fixed_t5;
    BEGIN
      dequeue_options.navigation := DBMS_AQ.FIRST_MESSAGE;
      DBMS_AQ.DEQUEUE(
         queue_name          =>     'fixed_t5q',
         dequeue_options     =>     dequeue_options,
         message_properties  =>     message_properties,
         payload             =>     message,
         msgid               =>     message_handle);
      DBMS_OUTPUT.PUT_LINE('ID   : '||message.id);
      DBMS_OUTPUT.PUT_LINE('Label: '||message.label);
      DBMS_OUTPUT.PUT_LINE('Code : '||message.code);
      DBMS_OUTPUT.PUT_LINE('Today: '||message.today);
      COMMIT;
    END;
    ID   : 36
    Label:
    Code : 1
    Today: 03.07.08
    Could anyone tell me what is wrong with the setup/code?
    Why 'label' not saved in queue, though i saw it is not empty in STRUCT?

    Thank you for the reply!
    I have enqueued:
    [main] 2008-07-04 15:30:30,639 DEBUG [ru.invito.UserDefinedTypeAqTest$1] - [email protected](): name = INVITO.FIXED_T5
    length = 4
    ID = 41
    LABEL = Hello, INVITO.FIXED_T5Q!
    CODE = 1
    TODAY = 2008-07-04 15:30:30.0and in table (select * from FIXED_T5QT) the 'label' is blank:
    Q_NAME     FIXED_T5Q
    MSGID     51310809B5EA3728E040007F01000C79
    CORRID     b8f38fd3-4fa6-4e0f-85d1-2440d02d655e
    PRIORITY     0
    STATE     0
    DELAY     
    EXPIRATION     
    TIME_MANAGER_INFO     
    LOCAL_ORDER_NO     0
    CHAIN_NO     0
    CSCN     0
    DSCN     0
    ENQ_TIME     04.07.2008 15:28:44
    ENQ_UID     INVITO
    ENQ_TID                       4012
    DEQ_TIME     
    DEQ_UID     
    DEQ_TID     
    RETRY_COUNT     0
    EXCEPTION_QSCHEMA     AQ$_INVITO
    EXCEPTION_QUEUE     FIXED_T5QT_E
    STEP_NO     0
    RECIPIENT_KEY     0
    DEQUEUE_MSGID     
    SENDER_NAME     AQ_TEST
    SENDER_ADDRESS     10.1.1.137
    SENDER_PROTOCOL     
    USER_DATA.ID     41
    USER_DATA.LABEL     
    USER_DATA.CODE     1
    USER_DATA.TODAY     04.07.2008 15:30:30I must point to a strange thing: when the FixedType instance is created (via new operator) and then the setLabel("....") called as:
    FixedType data = new FixedType();
    // hack: proper initialization for 'label' field
    data._struct.setNChar(1);
    data.setId(ID);
    data.setLabel(label);
    data.setCode(1);
    Date today = new Date();
    data.setToday(new Timestamp(today.getTime()));
    Datum d = data.toDatum(connection);
    STRUCT s = (STRUCT) d;
    logger.debug(s + ".debugString(): " + s.debugString());
    logger.debug(s + ".dump(): " + s.dump());and if i comment line (data._struct.setNChar(1);) the debug messages for created STRUCT also shows empty value for label.
    But if i explicitly call data._struct.setNChar(1) then debug contains the label i defined in call to the setLabel method.

  • How to use user defined object with linked button

    Hi experts
    Can I use user defined table data with linked button. If yes then how. plz give me sample examples.
    Regards
    Gorge

    If you have an UDO in your form, or any other, the FormDataLoad eventhandler should be used.
    Take care, it is not inside the eventhandler.
    for VB:
    Select SBO_APPLICATION in the classes, and select FormDataLoad event
    Private Sub SBO_Application_FormDataEvent(ByRef BusinessObjectInfo As SAPbouiCOM.BusinessObjectInfo, ByRef BubbleEvent As Boolean) Handles SBO_Application.FormDataEvent
    in C#
    Add a new eventhandler as
    // declaration
    SBO_Application.FormDataEvent += new SAPbouiCOM._IApplicationEvents_FormDataEventEventHandler(ref SBO_Application_FormDataEvent);
    // eventhandler:
    public void SBO_Application_FormDataEvent(ref SAPbouiCOM.BusinessObjectInfo BusinessObjectInfo, out bool BubbleEvent)

  • Need to call user defined table in Report

    Hi there,
    In my report, need to call user defined database table. This table contains 2 columns one for checkbox. After calling this table, user has to check required rows and save changes. can we create transaction code for this table and call from within report? anybody pls suggest how to implement this requirement.
    Regards,
    Zakir.

    Zakir,
    U can do it in both the ways (TXN or rept).
    If rept, use an itab to check and insert rows to the DB tab.
    If mod pol, use a table control and update db tab...
    Reward if helpful,
    Karthik

  • Dealing with User Defined Tables with the DI Server

    I have a general question about the best way of working with the data in user defined tables using the DI Server. It appears from previous posts that it is not possible to use the standard methods such as UpdateObject. Also since update/insert and delete statements or explicitly forbidden using the ExecuteSQL method then how do we interact with the data in the tables?
    Do we need to code our own data access layer for this type of access and is this a good practice?
    Is this type of functionality going to be available in a future release of the DI Server?
    Thanks

    Using SQL for Update/Insert/Delete is not forbidden on UDTs (at least non-UDO UDTs; UDO UDTs are somehow in a gray area since they carry internal fields + e.g. inserts require further manipulation in B1 tables...)...
    I.e. using ExecuteSQL to add data into UDTs is OK for DI Server...
    HTH,
    Frank

  • User defined field with Linked Table property

    Hi All,
    I know this has been posted several times but I cannot get this to work.  I am trying to add a user defined field and link it to a table. 
    I am getting the error "The field 'Related Table' should consist of 8 alphanumeric characters with no valid or default values " 
    Everything I check says that the code I am using is correct.  Is it possible the problem is that I am trying to connect to an SAP table instead of a user defined table.  Is it possible to link a user defined field to an SAP table?
    My code below:
                    oUserFieldsMD.TableName = "OITM"
                    oUserFieldsMD.Name = "SHP"
                    oUserFieldsMD.Description = "Must ship via"
                    oUserFieldsMD.LinkedTable = "OSHP"
                    oUserFieldsMD.Type = SAPbobsCOM.BoFieldTypes.db_Alpha
                    oUserFieldsMD.SubType = SAPbobsCOM.BoFldSubTypes.st_None
                    oUserFieldsMD.EditSize = 8
                    oUserFieldsMD.Size = 8
                    oUserFieldsMD.Mandatory = SAPbobsCOM.BoYesNoEnum.tNO
    Thanks
    Karen

    Hello  Karen,
    you cannot link a userfield to a system table. it has to be link to a user table.
    oUserFieldsMD.LinkedTable = "OSHP"
    when you have error, just try to do it using the same value in the application. If you cannot do it, it means you cannot do it neither with the DI
    Sebastien

Maybe you are looking for