Custom datatypes in oracle
hi,
i need to know about custom datatypes in oracle? Where can i get that. Any good link which explains the topic???
Thanks,
Noble
How about starting with the documentation...
http://www.oracle.com/pls/db102/search?remark=quick_search&word=user+defined+datatypes&tab_id=&format=ranked
Similar Messages
-
Hi All,
I am trying to figure out how to map custom datatypes.My scenario is simple.Employee table has address information in a column named addr which is of a custom datatype called Address.I have Employee and Address classes in my object model.
I have mapped all the fields (except address) of employee class to respective fields in employee table and I have used the Descriptor amendment method to map the address field of employee class using StructureMapping
StructureMapping mapping = new StructureMapping();
mapping.setFieldName("ADDR"); // Database Field Name in employee table
mapping.setAttributeName("addr"); //Address field in Employee class
mapping.setReferenceClass(Address.class);
descriptor.addMapping(mapping);
I get the following error when I try to login to the session
Exception [TOPLINK-197] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.DescriptorException
Exception Description: The mapping [addr] is not the appropriate type for this descriptor
Please let me know where I am going wrong.
Thanks in advance
PrasannaThe source descriptor also needs to be of type ObjectRelationalDescriptor. If you are using the MW to map the source you can edit the XML or source and change the descriptor type. Or you could create a new ObjectRelationalDescriptor and copy the mappings and properties over from the RelationalDescriptor and replace it in the Session. Or just map the source in code as well.
-
How to add a custom attributes in Oracle HTML Quotes page?
Hi,
Could someone advice on the best way to add a custom attribute in Oracle HTML Sales Quoting page.
As this page is not an OA page, we are not able to use the concept of View Objects using AK Developer.
Thanks,
ArathiI have a requirement from our end users that all of them requires a shortcut button in toolbar for submitting a request instead of going the normal way in order to submit a single request.
please can any one help me out in solving this query.Any reason you want to use a shortcut rather than using (Requests > Submit) window?
You can use "FND_REQUEST.SUBMIT_REQUEST" API -- https://forums.oracle.com/forums/search.jspa?threadID=&q=FND_REQUEST.SUBMIT_REQUEST&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
How To Submit A Concurrent Request Set Using Fnd_Request.Submit_Request [ID 382791.1]
How To Set ORG_ID When Submitting A Concurrent Request Using FND_REQUEST.SUBMIT_REQUEST in Release 12 [ID 1383266.1]
Thanks,
Hussein -
How to create a custom plugin in Oracle Access Manager to create a cookie
How to create a custom plugin in Oracle Access Manager to create a cookie or Header Variable..
VipinIts has more steps which you need to consider in addition to Note:101048.1 which is mentioned by Prashant_Pathak. Both notes have enough information. If not, let's know what else you need to set
-
Creation of a Custom Folder in Oracle Discoverer Administration Edition
Hi
Could anybody help me in solving this problem while creating a Custom Folder in Oracle Discoverer Administration Edition ?
My Requirement is :
I Connect to EUL_US/EUL_US@<HOST_STRING> under Oracle Discoverer Administration Edition.
I selected a Pre-Defined Business Area Eg. General Ledger
There i created a Custom Folder by Name Test Custom Folder
The Query which i used in my Custom Folder is
SELECT NAME FROM GL.GL_JE_BATCHES
When i Used this Query it says Table or view does not exist.
The Folder is getting created but without a Query.
I am not able to preceed further.
Any Help would be appreciated
Regards
Nakul VenkataramanHi Nakul, you may be running into a problem with the sql for your custom folder. For some reason Discoverer Admin will allow you to create a custom folder with sql, but then if you change it and it has any advanced sql, i.e. grouping sets, analytic functions etc., you probably receive an error.
An option is to create a view using the same sql and create a folder from the database using this view.
Hope this helps.
Brent. -
WSDL, custom datatypes, fault element name issues
Hello all,
I am having a LOT of problems with BEAs webservices. I am posting
this here in the hope that someone can help me and tell me what I am
doing incorrectly. I am running
WebLogic Server 7.0 SP1 Mon Sep 9 22:46:58 PDT 2002 206753
WebLogic XMLX Module 7.0 SP1 Mon Sep 9 22:54:41 PDT 2002 206753
Background:
My goal is to make my company's product web services aware. I take an
EJB, try to run it through the standard ant tasks and generate a web
services accessible EJB. Sounds pretty easy, but complex types seem
to make this quite difficult.
I have been able to create a web service accessible EJB (only since
7.0.1), but I am quite unhappy with the quality of what I am able to
produce.
I have a datatype which acts as a key, but it does not follow the
javabeans idiom - i.e. it does not have a default constructor or
accessor methods and I am not in the position to change it. I have
created a codec for this class which works and an xml schema (both by
hand). Its name is AgentKey. I have also had to use the autotyper to
create codecs and typemapping entries for java.util.Properties,
I can connect using the WebLogic classes and I am now trying to
interact using MS Excel and Apache's Axis as my test clients.
Issues:
My first question deals with generating a client. There seem to be
two ways to generate a client. Firstly via the <client> subtask of
<servicegen><service>, the second way via <clientgen> task. Since I
am using a custom data type (AgentKey) I have to manually insert the
AgentKey schema into the web-services.xml file generated by
servicegen. When I try to generate a client via the
servicegen/service/client task there is no opportunity for me to
insert this datatype schema information and I therefore get the
following messages (lots of them, but I'm only including one):
[servicegen] WARNINIG: Unable to find a javaType for the xmlType:['java:net.agentis.apml.runtime']:AgentKey.
Make sure that you have registered this xml type in the type mapping
[servicegen] Using SOAPElement instead
BTW: I am also receiving the same problem with java.util.Properties.
BTW: WARNING is misspelt
If I attempt to generate a client class via the <clientgen> task, I
need to supply either a wsdl or ear file as a parameter. I cannot
supply a wsdl file because I haven't deployed the EAR yet (and I don't
want to until the EAR has the client classes in it), and I can't
supply the EAR because I want the ear to include the client classes.
It is a bit of a catch 22 situation. Is there a solution I can't see?
NOTE: it would be very, very nice if you added a schemaMapping
attribute to the <servicegen/service> task so the web-services.xml
file didn't have to be manually hacked. Something similar to the
typemapping attribute already in the servicegen/service task would do
it.
My next problem deals with the validity of the WSDL. I am seeing that
the WSDL created has exceptions defined multiple times. I saw a
message from Manjo saying that it looked like a bug. I agree and
would like to get a copy of the patch. On a more significant note,
when is either SP2 or 7.1 due for release?
Another problem with the WSDL (once you have cleansed the multiple
exception messages) is that the fault elements of the
binding/operation elements require names and they don't have any. For
example, this is straight from the deployed EJB WSDL file:
<binding name="ExampleAgentPortSoapBinding" type="tns:ExampleAgentPort">
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="serviceWithPrimitiveDatatypes">
<soap:operation soapAction="" style="rpc"/>
<input>
<soap:body use="encoded" namespace="http://sillyurl.com/reallysilly"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</input>
<output>
<soap:body use="encoded" namespace="http://sillyurl.com/reallysilly"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</output>
<fault>
<soap:body use="encoded" namespace="http://sillyurl.com/reallysilly"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</fault>
</operation>
<operation ...
The schema definition at http://schemas.xmlsoap.org/wsdl/ says the
fault element require a name attribute:
<complexType name =" tBindingOperationFault">
<complexContent>
<extension base="wsdl:tExtensibleDocumented">
<attribute name="name" type="NCName" use="required"/>
</extension>
</complexContent>
</complexType>
The name of the fault should be the same name as the fault in the
portType definition. In my example the name is "AgentisException" as
evidenced by this snippet:
<portType name="ExampleAgentPort">
<operation name="serviceWithPrimitiveDatatypes">
<input message="tns:serviceWithPrimitiveDatatypes"/>
<output message="tns:serviceWithPrimitiveDatatypesResponse"/>
<fault name="AgentisException" message="tns:AgentisException"/>
</operation>
Once these changes have been made then the WSDL will validate. Are
there plans to fix these bugs?
On a different note, when I try to interact with a method that uses a
custom data type, such as AgentKey, via the "WebLogic Webservice
standard testing home page" the custom data type without a default
constructor cannot be rendered correctly. For instance, the AgentKey
value is:
<!-- Do not know how to create a sample instance for this part due to the following
exception:java.lang.InstantiationException: net.agentis.apml.runtime.AgentKey.
Pls replace this with the correct XML before invoking the service. --->
<agentKey/>
Since I can't deploy a valid WSDL, I can't get either Axis or Excel to
connect to my web services.
When I attempt to invoke Axis' (beta 1.1) wsdl2java I recieve the
following message.
java.io.IOException: ERROR: Fault is missing a name= attribute in operation
"serviceWithPrimitiveDatatypes", in binding {http://sillyurl.com/reallysilly}ExampleAgentPortSoapBinding.
This seems understandable considering the issues I mentioned earlier.
Unfortunately Excel doesn't really give me anything to go with. If I
type in the WSDL URI then it will give me a list of methods I can
invoke, but if I try to add the service I get the very unhelpful "The
Web Service References Tool could not generate the requested code.
Any changes that were made to your project have been rolled back."
Any help with those two issues would be greatly appreciated also.
One final issue is that I cannot seem to fix is taskdef'ing
<servicegen> properly from Ant. I can do the actual taskdef but then
it cannot find classes from within the weblogic.jar. If I run the
setExamplesEnv.cmd first the I don't need to do the taskdef and
everything works fine. Has anyone else had this issue? (we can't run
that command on our clients desktops before we build our build scripts
- anyway, I've put it down to one of those weird Ant classpath
issues.)
In summary:
Problems I can see and would like some help on are:
- multiple exception messages
- fault operations with no name
- the ability to generate client code with complex data types before
the EAR is deployed.
Could the product team add
- a clean way to add in schema datatypes without having to manually
hack the web-services.xml file.
I know this has been quite a long email, but it has been months in the
making. Anyone's time would be greatly appreciated.
Mark Mansour
Agentis Software
[email protected]Hi Mark,
From your base post:
My next problem deals with the validity of the WSDL. I am seeing that
the WSDL created has exceptions defined multiple times. I saw a
message from Manjo saying that it looked like a bug. I agree and
would like to get a copy of the patch. On a more significant note,
when is either SP2 or 7.1 due for release?I would recommend starting here with support since getting valid WSDL seems to be the root of most of
your issues.
Concerning the upcoming release, I believe it is scheduled for late this quarter; contact Michael
([email protected]) for more information.
Also, at the bottom of this post:
I would just like to see an automated way to do this (I've had to write my own
utility to do this for me :(Does the autotype ant task help in this situation? Have you taken a look at this?
http://e-docs.bea.com/wls/docs70/webserv/anttasks.html#1080062
Thanks,
Bruce
Mark Mansour wrote:
Hiya Bruce,
I will try and get some time to follow this up with the support people too.
In response:
Problems I can see and would like some help on are:
- multiple exception messages
In your client code, you can set the following property to avoid the exceptionmessages so that the typemapping
registry can be setup.
//dont parse wsdl till we set the typemapping
System.setProperty( "weblogic.webservice.servicenamechecking","false" );
This is not a client issue. The WSDL is generating incorrect WSDL. Here is a
little snippet :
<message name="AgentisException" >
<part name="AgentisException" xmlns:partns="http://www.w3.org/2001/XMLSchema"
type="partns:string" />
</message>
<message name="setTraceLevel" >
<part name="agentKey" xmlns:partns="java:net.agentis.apml.runtime" type="partns:AgentKey"
/>
<part name="intVal" xmlns:partns="http://www.w3.org/2001/XMLSchema" type="partns:int"
/>
</message>
<message name="AgentisException" >
<part name="AgentisException" xmlns:partns="http://www.w3.org/2001/XMLSchema"
type="partns:string" />
</message>
As you can see the AgentisException is defined twice (in my real WSDL it is redefined
every time a method has the AgentisException in its interface (which in my case
is 5 times))
- fault operations with no nameI believe the fault issues that you have raised have been addressed in the upcomingrelease that will be
available for beta testing shortly. Contact [email protected] if you
want to participate in the beta.
great. Is there any ETA on the final release date?
- the ability to generate client code with complex data types before
the EAR is deployed.
There is an example to show how to do this: http://dev2dev.bea.com/direct/webservice/dyncmplx.zip
Unfortunately this doesn't solve my problem. I still don't have an EAR or WSDL
file from which I can generate a client to be included in the final EAR file that
gets deployed to the server. My original post explains this a bit better.
Could the product team add
- a clean way to add in schema datatypes without having to manually
hack the web-services.xml file.
Take a look at http://dev2dev.bea.com/direct/webservice/wswa.html#qz50 and others
in this area.
This was more in reference to the building of the web services in the first place
rather than registering custom datatypes at runtime. The manual procedure is
documented at http://edocs.bea.com/wls/docs70/webserv/customdata.html#1058102,
I would just like to see an automated way to do this (I've had to write my own
utility to do this for me :(
Hope this helps,
Bruce
Thanks Bruce.
Mark -
TIMESTAMP datatype in Oracle 8i.
'TIMESTAMP' datatype is not to be available in Oracle 8i.
Is there an equivalent datatype in Oracle 8i as 'TIMESTAMP' in 9i?
Regards,
BhagatTimestamp was a new globalization feature in 9i. The only way to handle time in 8i is with the regular DATE type and traditional date arithmetics.
-
Migrating a Forms 6i custom application to Oracle Apps R12 custom bolt on
Hi,
I need to migrate an oracle forms custom application built in 6i to sit within oracle apps R12 (Forms 10g) and use Oracle Apps user authentication and session. It could become a custom bolt on to Oracle Apps and might be accessed from a custom responsibility in oracle applications.
a) How easy/difficult is this?
b) What are the challenges or things to look for to do this migration?
Thanks,
Ayyappa979379 wrote:
Hi,
We have two node architecture for R12.1.1 on windows 2008 32 Bit. One node for Database and the other node for application.
As we are facing a lot of memory issues, we are planning to go for 64 Bit.
I Have already read the document
Migrating Oracle E-Business Suite R12 to Microsoft Windows Server 2008 R2 [ID 1188535.1]
The doc says in place OS upgrades are not supported....
So my question is...
While keeping the production, how can i migrate using the same servers. Coz my company does not want to buy new servers..
Please suggest.Complete all the steps in the doc for Rapid Clone and other steps, then take a backup of the files after you run preclone and create a trace file for the database. Once you have the backup ready, install a 64-bit version of the OS and install 11gR2 software and restore the files from the backup and complete the migration.
Thanks,
Hussein -
How to handle national character set datatypes in oracle?
Hi
Can anyone tell me how to handle national character set datatypes in oracle?
Thanks in advanceAnd for data manipulation, append "N" the literal values being used in the command.
The "N" indicates that the string is to be treated as Unicode Text.
For Example: insert into TableName (ColumnName) values (N'ValueToBeInserted'); -
Equivalent datatype in Oracle for datetime of SQL Server
Hello Everyone,
I'm very much new to Oracle. I have been working with SQL Server since 3yrs. Currently I'm working with Oracle 11g.
What is the equivalent datatype in oracle for datetime in sql server with which has the format YYYY-MM-DD HH:MM:SS?
I tried with timestamp and date which didnt solve my prob.... Please help me in using the equivalent datatype for the format provided above...
Regards,
Bhanu Yalamanchi.Oracle date format can be anything you want, either by default at the session level or preferably explicitly using to_char and a format mask.
Format masks are documented here.
http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/sql_elements004.htm#CDEHIFJA
SQL> create table t (d date);
Table created.
SQL> insert into t values (sysdate);
1 row created.
SQL> select * from t;
D
19-JUL-11
SQL> alter session set nls_date_format = 'YYYY-MM-DD HH:MI:SS';
Session altered.
SQL> select * from t;
D
2011-07-19 08:27:59
SQL> select d, to_char(d, 'YYYY-MM-DD'), to_char(d,'Day') from t;
D TO_CHAR(D, TO_CHAR(D
2011-07-19 08:27:59 2011-07-19 Tuesday
SQL> alter session set nls_date_format = 'DD-MON-YY';
Session altered.
SQL> select d, to_char(d, 'YYYY-MM-DD HH24:MI:SS') from t;
D TO_CHAR(D,'YYYY-MM-
19-JUL-11 2011-07-19 08:27:59 -
Custom reports in Oracle Designer - HELP!
I have a need to write some custom reports in Oracle Designer. I know all the information is in the repository but don't know how to get it out.
Would anyone happen to know where I can get my hands on an ER diagram depicting the relationships across repository tables (meta model)?!Start the RON. Choose a workarea. Select an object (table definition, view definition etc). Now open the properties. Select a line in the properties window and press F5. Now choose the "Model" button.
IExplorer is opened with information on the View in which these objects can be found. -
Converting ntext datatype of MS SQL to LOB datatype of Oracle using ODI
Hi
Could anyone help me how I can convert ntext datatype of MS SQL to BLOB/CLOB datatype of ORACLE using ODI tool? I have tried and it seems that ODI couldn't able to create working table with datatype of LOB.
Thank you in advance.
MyatTry using the Incremental Update (PL/SQL) IKM. I believe this will only handle 1 CLOB column in any interface - also pay attention to the KM notes for additional constraints and requirements.
Make your staging area the same as the target.
Use the TO_CLOB function to convert the data for your field, and execute this on the target. -
Can I use custom datatype on a column?
Can I create a column using custom datatypes?
Something like this?????????????
ALTER TABLE ed_fotos ADD foto "ORDSYS.ORDVIR";
The datatype "ORDSYS.ORDVIR" has been created to replace a virage datatype on my development environment.
CREATE OR REPLACE TYPE "ORDSYS.ORDVIR" AS OBJECT (
MEMBER FUNCTION getwidth RETURN NUMBER,
MEMBER FUNCTION getheight RETURN NUMBER
CREATE OR REPLACE TYPE BODY "ORDSYS.ORDVIR" AS OBJECT (
MEMBER FUNCTION getwidth RETURN NUMBER IS
BEGIN
return 1000;
END getwidth;
MEMBER FUNCTION getheight RETURN NUMBER IS
BEGIN
return 1000;
END getheight;
/Hi, tks for the help.
It is almost working... I can create a column but I cant select the data:
select foto from ed_fotos
ORA-00932: unconsistent data types: NUMBER expected ORDVIR returned
select foto.getwidth() from ed_fotos
ORA-00904: "FOTO"."GETWIDTH": invalid identifier
This is my methods:
CREATE OR REPLACE TYPE ORDVIR AS OBJECT (
ID NUMBER,
MEMBER FUNCTION getwidth RETURN NUMBER,
MEMBER FUNCTION getheight RETURN NUMBER
CREATE OR REPLACE TYPE BODY ORDVIR AS OBJECT (
MEMBER FUNCTION getwidth RETURN NUMBER IS
BEGIN
return 1000;
END getwidth;
MEMBER FUNCTION getheight RETURN NUMBER IS
BEGIN
return 1000;
END getheight;
/ -
JMS custom headers in Oracle SOA suite 11g
Hi,
Can any body expalin me how to implement JMS custom headers in Oracle SOA suite.Please help
Thanks,
KumarKumar,
It is jca.jms.JMSProperty which is used to set and get custom JMS headers. So if you want to set two custom JMS headers say Test1 and Test2 then add them as a property in your invoke action as below -
<invoke name="InvokeTest"
inputVariable="InvokeTest_Produce_Message_InputVariable"
partnerLink="test" portType="ns2:Produce_Message_ptt"
operation="Produce_Message" bpelx:invokeAsDetail="no">
<bpelx:inputProperty name="jca.jms.JMSProperty.Test1" variable="testA"/>
<bpelx:inputProperty name="jca.jms.JMSProperty.Test2" expression="'foo'"/>
</invoke>
Here we have assigned value of variable testA into custom JMS header Test1 and expression "foo" into custom JMS header Test2.
Regards,
Anuj -
Custom Colors in Oracle Forms.
Hi,
As we know we can create custom color in oracle forms and process to create is
Creating Custom colors :
a)Go to Tools->Preferences. In General Tab On the Color Mode drop-down, select Editable then exit Forms builder.
b)Restart forms builder.
c)Open up a canvas window, then go to Format->Layout Options->Color Palette.
d)select any colour on the palette and edit it
say we created a color with rgb value r0g0b100 i edit the from rgb value to FrameColor.Therefore my new custom color name wil be "*FrameColor"*
Is there any way to know the rgb value after changing Name?
Kindly help me to know the solution.
Thanks,
ManasaTo see the rgb value you must have set the colour palette to be editable. Then open the colour palette select the custom colour you want to see the value of then click on the Edit button where you will be able to see the rgb value for that colour.
In 10g
Set to Editable
Edit -> Preferences -> change colour mode to Editable -> Exit form builder
Add Custom Colour
Re-open the form
Open a canvas
Edit -> Layout Options -> Colour Palette
Select a colour to edit by clicking on an undefined colour i.e. a white square on the bottom far left of the palette
In the current colour dialog it will say something like custom5 change it to a more meaningful name you can call it the rgb value
Then click on rename -> then Edit -> change the rbg value to the colour you want to add-> click OK
Export the custom colour palette
From the canvas -> Edit -> Export -> Colour Palette -> give it a name
Maybe you are looking for
-
Hi, I have followed all the steps in the "Customizing the LiveCycle Workspace ES User Interface" document and am stuck on page 22, point #8 for those of you that might have the document to hand. I have created my custom ear file but cannot find the c
-
Creating a module level variable??
Greetings, I'm trying to create a variable that stays in memory during the duration of the current open module. I want to be able to access it and also change it in multiple blocks. I tried using a Global Variable, but learned finally that it can onl
-
Hi Apple Experts, My Macbook Pro laptop charger stopped working after it was lying on the floor and my room filled with water due to water logging in the pipes in the bathroom adjacent to my room. I tried drying the charger with a hair dryer but it i
-
I am using Windows XP with Explorer 8. I get a run time error when trying to read PDF files! Is there a fix for Exploader 8? I have no problem with Firefox reading PDF files.
-
Servlet not showing BLOB image from Oracle in JSF
hi forum. i have a table in oracle in which i m storing images in a BLOB field and file extention (mime type) in a varchar2 field. i can successfully store image. but i want the stored image to be displayed in a graphicimage tag from BLOB. i searched