How to return new blob object?

Hi,
I am trying to find documentation on how to return a custom abstract data type (ADT) using the CREATE TYPE... and BLOB interface.
How can I return a new object type defined inside a blob. Can I return a blob (without initializing the lob locator first)?
Please advise.

Hi,
Please check the below link.
http://docs.oracle.com/cd/E24693_01/appdev.11203/e17126/create_type.htm
Regards,
Sailaja

Similar Messages

  • How to return array of object

    public class A{
    public class B{
    publc C[] sample()
    int i=0;
    ResultSet rset = s.executeQuery("select name, id  from emp ");
    while(rs.next()){
    name = rset.getString("nam");
    id = rset.getInt("id");
    c.setName(name )
    c[i].setId(id)
    return c[]
    public class C{
    // here i have getter and setter metod for name & id
    When I try to return the object c[]..i am getting "cannot conver from C to C[]".
    Can u pls help me, how to return array of object and how to get name and id values in other class using this array object
    Thanks for ur help

    public class Starting{
    public long empID;
    Data data = new Data();
    Value[] value;
    int count = 0;
         public static void executeDe(){
              value = new Value[100]
              try{
                     data.getDetails()
                     processDetails(value);
                   }catch(Exception e){e.printStackTrace();}
         public static void processDetails(Value[] value){
         count = data.i;
              int i;
              for(i=0;i<count;i++){
                  empID=value.getempID(); \\ here i am not getting all values..... am getting only last value of the array
    public class Data{
    public long empID;
    public int i=0;
    static Value[] value = new Value[100];
    public static Value[] getDetails(){
    Connection con=null;
    try {
    Class.forName("oracle.jdbc.driver.OracleDriver");
    con=DriverManager.getConnection("jdbc:oracle:thin:@" + hostname + ":1521:" + sid, user, password);
    System.out.println(" conn " + con);
    System.out.println("");
    Statement s=con.createStatement();
    try{
         ResultSet rset = s.executeQuery("select EMPID from Employee ");
         while(rset.next()){
    empID = rset.getLong("EMPID");
    value[i].setCycleID(cy_i);
    i++;
         rset.close();
         con.close();
    }catch (SQLException sqle){sqle.printStackTrace();}
         finally{
              try{
              s.close();
         con.close();
              }catch(SQLException e){e.printStackTrace();}
    catch(Exception e){e.printStackTrace();}
    return value;
         public class Value {
         public static long cycleID;
              public static void setempID(long empID) {
                   Value.empID = empID;
              public static long getempID() {
                   return empID;
    This is my actual code..... I am able to set the values in Value class from Data class using getDetails() method, which is returning array of value object.
    In Starting class, I am trying to get values using value[i].. i am getting last value of the array. This is my actual problem... here i want to get all values.
    Please help me how to resolve this.

  • How to create new authorisation object for Transactions?

    Hi,
    How to create new authorisaton object and how to assign that object on a transaction code?
    Case ->
    The transaction code VL01N have the object called V_LIKP_VST under Class "LE_V" that have two auth. fields. one is 'Activity' and other one is "Shipping Point/Receiving Point".
    Here I want to add "Storage location" also. I have created one object called "Z_LIKP_VST" under same calass "LE_V". and added "Activity", "Shipping Poing/Receiving Poing" and "Storage Location". After that I added that object ("Z_LIKP_VST") for particular transaction through "SU24". I maintained the "Display check indicator" for VL01N.
    I created one new role and assigend the particular transacation for a user. but still SAP taking  V_LIKP_VST insted of Z_LIKP_VST.
    How can I change my Z_LIKP_VST on profile.
    Please help
    Thanks in Advance
    Lal

    Hi Kariyath,
    I suppose its not about interest but a MUST.. sorry but.. unless u include the Logic in the program how can SAP pick these custom Z objects ?
    after u create them and assign to a Tcode in SU24 there is no logic to check these objects. Frankly i see no other chance.... unless SAP comes to us with a great easy way to input these Custom objects
    Keep looking and please Update me if u have any Inputs....on this front..
    All the Best
    Br,
    Sri
    Award points for helpful answers

  • How to create new java objects in native methods?

    Hello,
    Is it possible to create java objects and return the same to the java code from a native method?
    Also is it possible to pass java objects other than String objects (for example, Vector objects) as parameters to native methods and is it possible to return such objects back to the java code?
    If so how can I access those objects (say for example, accessing Vector elements) inside the native code?
    What should I do in order to achieve them?
    Regards,
    Satish

    bschauwe is correct in that constructing Java objects and calling methods on Java objects from native code is tough and takes some study. While you're at it, you might want to check out Jace, http://jace.reyelts.com/jace. It's a free open-source toolkit that really takes the nastiness out of doing this sort of stuff. For example,/**
    * A C++ function that takes a java.util.Vector and plays around with it.
    public void useVector( java::util::Vector& vector ) {
      // Print out all the contents of the vector
      for ( Iterator it = vector.iterator(); it.hasNext(); ) {
        cout << it.next();
      // Add some new elements to the vector
      vector.addElement( "Hello" );
      vector.addElement( "world" );
    } All this code just results in calls to standard JNI functions like FindClass, NewObject, GetMethodID, NewStringUTF, CallObjectMethod, etc...
    God bless,
    -Toby Reyelts

  • JAVA&SOAP:how to return a complex object( the object has an object within)

    Lets say my Complex object is :
    public class PersonWithAddress {
    private String name;
    private int ssn ;
    private Address add;
    PersonWithAddress() {
    name="Gagan Tandon" ;
    ssn =1111;
    add = new Address("1113","WestPlum Street");
    public String getName() {
    return name;
    public int getSSN() {
    return ssn;
    public Address getAddress() {
    return add;
    This complex object has Address object embedded in it.
    public class Address {
    private String house;
    private String street;
    public Address (String myHouse,String myStreet) {
    house = myHouse;
    street = myStreet;
    public String getHouse() {
    return house;
    public String getStreet() {
    return street;
    My deployment Descriptor is as following: check the mappings part.
    <isd:service xmlns:isd=
    "http://xml.apache.org/xml-soap/deployment"
    id="urn:xml-soap-person-demo">
    <isd:provider type="java"
    scope="Application"
    methods="getPersonWithAddress">
    <isd:java class="PersonServer"/>
    </isd:provider>
    <isd:faultListener>
    org.apache.soap.server.DOMFaultListener
    </isd:faultListener>
    <isd:mappings>
    <isd:map
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:x="urn:xml-soap-person-demo" qname="x:PersonWithAddress"
    javaType="PersonWithAddress"
    java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
    xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
    <isd:map
    encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:x="urn:xml-soap-person-demo" qname="x:Address"
    javaType="Address"
    java2XMLClassName="org.apache.soap.encoding.soapenc.BeanSerializer"
    xml2JavaClassName="org.apache.soap.encoding.soapenc.BeanSerializer"/>
    </isd:mappings>
    </isd:service>
    And in my SOAPRPC code at client end calls the following: check the mappingregistry code...
    String serverHost = "http://localhost:8082/soap/servlet/rpcrouter";
    SOAPMappingRegistry smr = new SOAPMappingRegistry();
    Parameter p= null;
    try {
    System.out.println("here 0");
    Response r=null;
    Call c=new Call();
    Vector parameters = new Vector();
    System.out.println("here 1");
    c.setTargetObjectURI ("urn:xml-soap-person-demo");
    c.setMethodName ("getPersonWithAddress");
    System.out.println("here 3");
    c.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
    // parameters.addElement (new Parameter("name", String.class, "Web Services Client", null));
    // c.setParams (parameters);
    c.setSOAPMappingRegistry(smr);
    BeanSerializer beanSer = new BeanSerializer();
    smr.mapTypes(Constants.NS_URI_SOAP_ENC,new QName("urn:xml-soap-person-demo","Address"),Address.class,beanSer,beanSer);
    smr.mapTypes(Constants.NS_URI_SOAP_ENC,new QName("urn:xml-soap-person-demo","PersonWithAddress"),PersonWithAddress.class,beanSer,beanSer);
    try
    System.out.println("here 4");
    r = c.invoke ( new URL(serverHost), "" );
    // org.apache.soap.SOAPException can be thrown
    catch ( Exception e )
    e.printStackTrace();
    // Check the response.
    if (r.generatedFault ()) {
    Fault f = r.getFault();
    System.out.println ("Error Occurred: ");
    System.out.println (" Fault Code = " + f.getFaultCode());
    System.out.println (" Fault String = " + f.getFaultString());
    // return f.getFaultString();
    // return new String("gagan");
    return null;
    else {
    System.out.println("here 5");
    p = r.getReturnValue();
    System.out.println("here 6");
    // System.out.println( (String)greeting.getValue() );
    System.out.println("SSN: " + ((PersonWithAddress)p.getValue()).getSSN());
    return (PersonWithAddress) p.getValue();
    catch( Exception e ){
    e.printStackTrace();
    // finally {
    // return null;// String("not OK");
    if (p==null)
    return null;
    else
    return (PersonWithAddress) p.getValue();
    When running this code..
    The following error is thrown.
    System.out.println("here 4") is printed.
    [SOAPException: faultCode=SOAP-ENV:Client; msg=Unable to instantiate 'PersonWithAddress': Class org.apache.soap.encoding.soapenc.BeanSerializer can not access a member of class PersonWithAddress with modifiers ""; targetException=java.lang.IllegalArgumentException: Unable to instantiate 'PersonWithAddress': Class org.apache.soap.encoding.soapenc.BeanSerializer can not access a member of class PersonWithAddress with modifiers ""]
    at org.apache.soap.rpc.Call.invoke(Call.java:294)
    at PersonClient.getPersonWithAddress(PersonClient.java:92)
    at PersonClient.<init>(PersonClient.java:11)
    at PersonClient.main(PersonClient.java:20)
    java.lang.NullPointerException
    at PersonClient.getPersonWithAddress(PersonClient.java:96)
    at PersonClient.<init>(PersonClient.java:11)
    at PersonClient.main(PersonClient.java:20)
    I am here 1
    Exception in thread "main" java.lang.NullPointerException
    at PersonClient.<init>(PersonClient.java:13)
    at PersonClient.main(PersonClient.java:20)
    What could be the problem..? Is there any info on net how could i pass complex objects of this type in Java through SOAP RPC.
    GAGAN

    Have you managed to sole the problem ? I have got similar one...
    [SOAPException: faultCode=SOAP-ENV:Client; msg=Unable to instantiate 'auction.common.Property': auction/common/Property]
         at proxy.soap.AuctionHistoryProxy.addAuctionProperty(AuctionHistoryProxy.java:515)
         at java.lang.reflect.Method.invoke(Native Method)
    (...)

  • Return new remote object

    Hi All!
    Help me!
    public interface Server extends Remote {
    QueryServer I() throws RemoteException;
    public class ServerImplementation extends UnicastRemoteObject implements Server {
    public QueryServer I() throws RemoteException {
    return new QueryServerImplementation();
    public ServerImplementation() throws RemoteException {
    super();
    public interface QueryServer extends Remote {
    String Y() throws RemoteException;
    public class QueryServerImplementation extends UnicastRemoteObject implements QueryServer {
    public String Y() throws RemoteException {
    return "Hello";
    public QueryServerImplementation() throws RemoteException {
    super();
    Server:
    public static void main(String args[]) {
    if (System.getSecurityManager() == null) {
    System.setSecurityManager(new RMISecurityManager());
    Registry registry = LocateRegistry.createRegistry();
    ServerImplementation serverImpl = new ServerImplementation();
    registry.bind("XXX", serverImpl);
    Client:
    public static void main(String args[]) {
    if (System.getSecurityManager() == null) {
    System.setSecurityManager(new RMISecurityManager());
    server = (Server) Naming.lookup("XXX");
    QueryServer qserver = server.I();
    String s = qserver.Y();
    Exception java.rmi.NoSuchObjectException
    What is uncorrect????
    Thank you!

    Works for me in JDK 1.3.1. What JDK are you using? and how much time if any elapses between the various client lookups and remote calls?
    In general RMI clients do have to be prepared to deal with NoSuchObjectExceptions. They simply mean that the stub is stale in the DGC sense and has to be reacquired. In your case the qserver stub must be reacquired by calling server.I(). If that throws NoSuchObjectException you must reacquire the server stub by repeating the lookup.

  • How to return a java object to VB through the activex bridge?

    Hello,
    I am trying to return more than just a primitive data type to VB from Java. To do this, I compile the two attached files and jar them into FastStatWrapper.jar which I then run through packager.exe and thus end up with an activex object. I then instantiate the FastStatWrapper object in VB and call execute in the following way:
    dim result as Object
    Dim wrapper as Object
    Set wrapper = CreateObject("FastStatWrapper.Bean.1")
    Set result = wrapper.execute("SOMETHING")However, I can't seem to access the result object. It doesn't have any methods. Do I have to package it as a separate bean?
    package test;
    public class FastStatWrapper
         public FastStatWrapper()
         public StatData execute(String _command)
              return new StatData("A", 3.0);
    }and here the data object...
    package test;
    public class StatData
         private String name = null;
         private double value;
         public StatData(String _name, double _value)
              name = _name;
              value = _value;
         public String getValueType()
              return name;
         public double getValue()
              return value;
    }                    

    The returned java object will be exposed as a dispatch object. You should be able to call methods on the returned java object. However, type information will not be available for that object and hence no support for code completion and syntax checking.

  • HOW TO ADD NEW HR OBJECTS ????

    Hi,
    i would like to new objects in HR object selection list,especially for PPOCE.
    I donot know how to add new objects in the object selection list.
    pls anyone who knows this ,could share your knowledge with me.
    tks
    theresita

    Hi Theresita,
    All the configuration is in the IMG under Personnel Management > Organizational Management > Hierarchy Framework.  You'll want to review all the entries and related documentation, as adding objects to PPOME/PPOCE is not a simple 'one table' process.  You may need new evaluation paths to support the views you want to see in the framework, so set these up ahead of time.  Parameters to support your configuration are: OM_ARRAYTYPE_DISPLAY; OM_DIS_OBJECTMANAGER; OM_FRAMEWORK_OBJ_NR; OM_FRAM_SCEN_DISPLAY: OM_OBJIM_SCEN_DISPLAY: OM_TABTYPE_DISPLAY.  You'll notice once you add these parameters, you can see the technical names of the scenarios you're working with in PPOME/PPOCE.
    Good luck,
    Sharon

  • EJB : How to return user defined object

    hi,
    i am a newbie in EJB. i have the following simple problem:
    public interface MyApp extends EJBObject
       public String getResult() throws RemoteException;
    }the above code will be ok because it is returning String object.
    however, i need to return a user defined object like:
    public interface MyApp extends EJBObject
       public MyResult getResult() throws RemoteException;
    }then i got java.lang.ClassCastException during runtime.
    please tell me how to resolve this problem.
    thank you very much

    since you are a newbie, let me explain something to you. Ask your question in the proper forum. In case, you still don't understand there is a forum for EJB questions.

  • How to create new bol object  for  BT in sap crm

    HI
         I need to create new bol for BT with relationship  with out using AET ,Could you please explain step by step.
    Thanks and best regards
    Brahmaiah

    Hi Kariyath,
    I suppose its not about interest but a MUST.. sorry but.. unless u include the Logic in the program how can SAP pick these custom Z objects ?
    after u create them and assign to a Tcode in SU24 there is no logic to check these objects. Frankly i see no other chance.... unless SAP comes to us with a great easy way to input these Custom objects
    Keep looking and please Update me if u have any Inputs....on this front..
    All the Best
    Br,
    Sri
    Award points for helpful answers

  • How to Use new Authorization Objects

    Hi guys i need to implement the new schema of authorizations and i have created an authrization and add the 0comp_code characteristic (previously i set i it up as authorization relevant) and i need to add the restrictions for infoprovider but i need to add the new infoobjects 0TCAIPROV, 0TCAACTVT, 0TCAVALID, but this infoobjects i ve activated are not authorization relevant and i am not using them in any infocube, thats the reason why i cant use them in an authorization.....
    Do i need to add them in my infocube or theres another configuration in order to use them?
    Regards

    Hello Oscar,
    You do not have to add the 0TCA* characteristics to your InfoCube. Instead you have to set these characteristics to authorization relevant. Then everything should work as intended.
    General information on how to use the new analysis authorizations can be found here: https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/ded59342-0a01-0010-da92-f6b72d98f144
    Kind regards,
    Stefan

  • How to create new program object in 3.1

    Hello Experts,
    I created a java program and would like to publish it to BO XI 3.1
    But I donot find any "Objects mangement area of the CMC" in 3.1 as we have it in XI R2.
    Thanks,
    Praveen.

    As there is no more objects section in 3.x it was moved to the BOE applications > central management server > right click (one of the 3 options)
    Regards,
    Tim

  • How to return custJava Object from Java Stored Function/Procedure to Java Application

    I WILL PAY $100 FOR SOLUTION.
    Oracle JDBC documentation gives step by step on how to return Oracle Type Object to Java Application. No question here.
    But is it possible to create Java Stored Function [getMyClass() ] which returns CUSTOM Java based object [MyClass] to Java application like:
    //java stored function
    class Foo
    public static MyClass getMyClass()
    return new MyClass();
    //java class I want to return to Java
    class MyClass
    public String getGreetings(String name)
    return "Hello " + name;
    I tried to do it using intermittent Oracle
    Type Object and OracleConnection map to make binding between Java->Oracle->Java. I could
    not get throgh meaningless run time ORA Errors. Any kind of help would be greatly
    appreciated. If you know the answer please
    post it or e-mail [email protected]
    null

    You don't say which version of the database you are on. There's an interesting looking article on OTN on handling CLOBs in JDBC in 10g. It may well be useful for earlier versions too (but no guarantees).
    Cheers, APC

  • How to add new EEW Business Objects

    Hi guys,
    could you please give me a solution how to add new business objects? Following are the SAP Objects that you can Enhance Using EEWB:
    ADS Analytical Data Storage
    BUPA Business Partner
    BUPR Business Partner Relationships
    BUSINESS_ACTIVITY Business Activity
    BUSINESS_TRANSACTION CRM Business Transaction
    CATEGORY_ENHANCEMENT Category Extension
    COMPLAINTS Complaint
    COUNTERS Counter
    CRM_CASE СRM Case
    CRM_RPT Resource Planning Tool
    GRANTOR_PROJECT Grantor Project
    INDIVIDUAL_OBJECT Individual Object
    INSTALLED_BASE Installed Base
    LEAD Lead
    MARKETING_ELEMENT Marketing Element
    OPPORTUNITY Opportunity
    PPR Partner/Product Range
    RELTYPE Relationship Category
    SALES_CONTRACT Sales Contract
    SALES_TRANSACTION Sales Transaction
    SERVICE_CONFIRMATION Service Completion Confirmation
    SERVICE_CONTRACT Service Contract
    SERVICE_TRANSACTION Service Process
    SOLUTION_DATABASE Solution Database
    But, i didn`t find how add it.

    Hi,
    To my knowledge adding objects to EEWB is possible by customers, SAP controls which all objects enhancement are possible through EEWB, the objects which you have listed are supported by sap for enhancement via EEWB.
    If you are on CRM 7.0 you can use AET which supports more objects that can be enhanced.(AXTREG - transaction for AET supported objects)
    Hope this helps.
    Cheers,
    Sumit Mittal

  • Addition of New Authorization Objects in DMS

    Dear All,
    How to add new authorization objects in DMS?
    For ex: I have defined Projects in additional data through class/characterstics, now i want to bring that field in to authorization control and want control document creation with respect to characterstics values(Projects).
    Looking for documents or step by step procedures
    Kindly help me.
    Thanks in advance
    [email protected]

    Hi
    Im not so sure but you can create an Auth Key using BS52
    You can add it to Auth obj of Class/ characteristic
    You can get a list of auth obj in SUIM
    Niranjan
    Let me know if it helps...!!!

Maybe you are looking for

  • InfoSet to DSO Transformation

    Hi all, I am trying to transfer data from an infoset to a DSO, the infoset is composed of a DSO and an InfoObject, and data from the DSO shows up but data from the InfoObject does not show up in the final DSO My infoset which combines these two: DSO:

  • I need firefox 3.6.19 but cannot find it,,where can I find it?

    I need 3.6.19 as I play fallensword and fallensword helper does not work with anything else...where can I find it please?

  • BADI or function module

    Hi, Anyone know of any BADI or function module for amending Account Assignment in Purchasing Document (PR, PO)?

  • Need help with Gradient Mesh

    So I am trying to make a gradient mesh of the shape shown here... But when I apply gradient mesh to it, I get a very unworkable result (as shown below) ...any suggestions on how I can make this?

  • Urgent need for C6500-fpd-pkg.151-1.sy1.pkg

    Hi everybody, Problem:  I've recently got a new C6506E along with an ASASM for a client. But unfortunately during the boot-up process, the switch powers ASASM down and alerts of a software incompatibility! and it needs a FPD package that doesn't exis