472,334 Members | 1,567 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,334 software developers and data experts.

Call Javacode from Pl/SQL

I want to call JavaScript/Java Code from a PL/SQL
If any one has idea, pl share
Thanks in advance
Beena
Aug 11 '08 #1
11 6298
r035198x
13,262 8TB
Javascript != Java.
Which one do you want to call?
Aug 11 '08 #2
Javascript != Java.
Which one do you want to call?
First preferance - java script if not possible then java class
Aug 11 '08 #3
r035198x
13,262 8TB
First preferance - java script if not possible then java class
Are we talking about Java stored procedures here?
Aug 11 '08 #4
I have a java script& javacodes to generate Barcode. I want to call it from a SQL query.
when I load the java class using loadjava errors coming...
Is it possible to call javascript from PL/SQL
Aug 12 '08 #5
r035198x
13,262 8TB
I have a java script& javacodes to generate Barcode. I want to call it from a SQL query.
when I load the java class using loadjava errors coming...
Is it possible to call javascript from PL/SQL
Why don't you explain what your application set up is like? Are you creating a web application using JSPs? How are you mixing the Java and Javascript?
Aug 12 '08 #6
Why don't you explain what your application set up is like? Are you creating a web application using JSPs? How are you mixing the Java and Javascript?
It is a J2EE based web application with oracle 10g as data base.
From one of my JSP, i am calling a Jasper report to print bills. in that bill i want to include barcodes also. I have java script and java code to generate barcodes.
without saving into databse , i have to print it while calling reports.
Aug 12 '08 #7
r035198x
13,262 8TB
It is a J2EE based web application with oracle 10g as data base.
From one of my JSP, i am calling a Jasper report to print bills. in that bill i want to include barcodes also. I have java script and java code to generate barcodes.
without saving into databse , i have to print it while calling reports.
So you know want to save the generated bar codes in the database? Into a column of what type?
Aug 12 '08 #8
So you know want to save the generated bar codes in the database? Into a column of what type?
I don't want to save it into database, while calling report for every bill_no, i want to generate the corresponding barcode of billno.

My requirement is this.

If i have a function barcodegen with input as billno(number) and output as corresponding barcode (as image type), i can call it in the query as
select bill_no,barcodegen(bill_no) ---> this is my requirement, i can place the
image in my report without saving into database.
any idea?
Aug 12 '08 #9
r035198x
13,262 8TB
See if this
helps.
Aug 12 '08 #10
See if this
helps.
I have refered that site.. follwed the steps
1. Creates Class files
2. While loading class files into database, the following errors coming
(My oracle user is kwa and class file is Area.class , which is working fine in java)

D:\oracle\product\10.2.0\db_1\BIN>loadjava -user kwa/kwa Area.class

Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x807
7E76
Function=[Unknown.]
Library=D:\oracle\product\10.2.0\db_1\jdk\jre\bin\ client\jvm.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.


Current Java thread:
at oracle.jdbc.driver.T2CConnection.t2cCreateState(Na tive Method)
at oracle.jdbc.driver.T2CConnection.logon(T2CConnecti on.java:346)
at oracle.jdbc.driver.PhysicalConnection.<init>(Physi calConnection.java:
413)
at oracle.jdbc.driver.T2CConnection.<init>(T2CConnect ion.java:131)
at oracle.jdbc.driver.T2CDriverExtension.getConnectio n(T2CDriverExtensio
n.java:77)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriv er.java:752)
at java.sql.DriverManager.getConnection(DriverManager .java:512)
- locked <0x141ae178> (a java.lang.Class)
at java.sql.DriverManager.getConnection(DriverManager .java:140)
- locked <0x141ae178> (a java.lang.Class)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.getConnection(Dat
abaseOptions.java:180)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.connect(DatabaseO
ptions.java:123)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getConnection(LoadJ
avaState.java:409)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getOldMD5(LoadJavaS
tate.java:696)
at oracle.aurora.server.tools.loadjava.ClientSchemaOb ject.getOldMD5(Clie
ntSchemaObject.java:52)
at oracle.aurora.server.tools.loadjava.SchemaObject.d oCreate(SchemaObjec
t.java:172)



D:\oracle\product\10.2.0\db_1\BIN>loadjava -user kwa/kwa Area.class

Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x807
7E76
Function=[Unknown.]
Library=D:\oracle\product\10.2.0\db_1\jdk\jre\bin\ client\jvm.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.


Current Java thread:
at oracle.jdbc.driver.T2CConnection.t2cCreateState(Na tive Method)
at oracle.jdbc.driver.T2CConnection.logon(T2CConnecti on.java:346)
at oracle.jdbc.driver.PhysicalConnection.<init>(Physi calConnection.java:
413)
at oracle.jdbc.driver.T2CConnection.<init>(T2CConnect ion.java:131)
at oracle.jdbc.driver.T2CDriverExtension.getConnectio n(T2CDriverExtensio
n.java:77)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriv er.java:752)
at java.sql.DriverManager.getConnection(DriverManager .java:512)
- locked <0x141ae178> (a java.lang.Class)
at java.sql.DriverManager.getConnection(DriverManager .java:140)
- locked <0x141ae178> (a java.lang.Class)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.getConnection(Dat
abaseOptions.java:180)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.connect(DatabaseO
ptions.java:123)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getConnection(LoadJ
avaState.java:409)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getOldMD5(LoadJavaS
tate.java:696)
at oracle.aurora.server.tools.loadjava.ClientSchemaOb ject.getOldMD5(Clie
ntSchemaObject.java:52)
at oracle.aurora.server.tools.loadjava.SchemaObject.d oCreate(SchemaObjec
t.java:172)
at oracle.aurora.server.tools.loadjava.SchemaObject.p rocess1(SchemaObjec
t.java:215)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:532)
at oracle.aurora.server.tools.loadjava.LoadJava.addCl ass(LoadJava.java:5
86)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:436)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:380)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:349)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:652)
at oracle.aurora.server.tools.loadjava.LoadJava.proce ssDeferredFiles(Loa
dJava.java:617)
at oracle.aurora.server.tools.loadjava.LoadJava.proce ss(LoadJava.java:81
8)
at oracle.aurora.server.tools.loadjava.LoadJava.comma nd(LoadJava.java:25
1)
at oracle.aurora.server.tools.loadjava.LoadJavaMain.r un(LoadJavaMain.jav
a:103)
at oracle.aurora.server.tools.loadjava.LoadJavaMain.m ain(LoadJavaMain.ja
va:28)

Dynamic libraries:
0x00400000 - 0x0040B000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\java.e
xe
0x7C900000 - 0x7C9B0000 C:\WINDOWS\system32\ntdll.dll
0x7C800000 - 0x7C8F5000 C:\WINDOWS\system32\kernel32.dll
0x77DD0000 - 0x77E6B000 C:\WINDOWS\system32\ADVAPI32.dll
0x77E70000 - 0x77F01000 C:\WINDOWS\system32\RPCRT4.dll
0x77C10000 - 0x77C68000 C:\WINDOWS\system32\MSVCRT.dll
0x08000000 - 0x08138000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\client
\jvm.dll
0x7E410000 - 0x7E4A0000 C:\WINDOWS\system32\USER32.dll
0x77F10000 - 0x77F57000 C:\WINDOWS\system32\GDI32.dll
0x76B40000 - 0x76B6D000 C:\WINDOWS\system32\WINMM.dll
0x76390000 - 0x763AD000 C:\WINDOWS\system32\IMM32.DLL
0x10000000 - 0x10007000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\hpi.dl
l
0x00390000 - 0x0039E000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\verify
.dll
0x003B0000 - 0x003C9000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\java.d
ll
0x003D0000 - 0x003DE000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\zip.dl
l
0x62F00000 - 0x62F13000 D:\oracle\product\10.2.0\db_1\BIN\ocijdbc10.dll
0x02E70000 - 0x02EC7000 D:\oracle\product\10.2.0\db_1\BIN\OCI.dll
0x7C340000 - 0x7C396000 D:\oracle\product\10.2.0\db_1\BIN\MSVCR71.dll
0x76C90000 - 0x76CB8000 C:\WINDOWS\system32\imagehlp.dll
0x59A60000 - 0x59B01000 C:\WINDOWS\system32\DBGHELP.dll
0x77C00000 - 0x77C08000 C:\WINDOWS\system32\VERSION.dll
0x76BF0000 - 0x76BFB000 C:\WINDOWS\system32\PSAPI.DLL

Heap at VM Abort:
Heap
def new generation total 576K, used 77K [0x10010000, 0x100b0000, 0x104f0000)
eden space 512K, 13% used [0x10010000, 0x10021b20, 0x10090000)
from space 64K, 11% used [0x10090000, 0x10091cd0, 0x100a0000)
to space 64K, 0% used [0x100a0000, 0x100a0000, 0x100b0000)
tenured generation total 1408K, used 243K [0x104f0000, 0x10650000, 0x14010000
)
the space 1408K, 17% used [0x104f0000, 0x1052cdd0, 0x1052ce00, 0x10650000)
compacting perm gen total 4096K, used 2414K [0x14010000, 0x14410000, 0x1801000
0)
the space 4096K, 58% used [0x14010000, 0x1426b810, 0x1426ba00, 0x14410000)

Local Time = Mon Aug 11 12:18:03 2008
Elapsed Time = 0
#
# HotSpot Virtual Machine Error : EXCEPTION_ACCESS_VIOLATION
# Error ID : 4F530E43505002EF
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Java VM: Java HotSpot(TM) Client VM (1.4.2_08-b03 interpreted mode)
#
# An error report file has been saved as hs_err_pid2940.log.
# Please refer to the file for further information.
#

D:\oracle\product\10.2.0\db_1\BIN>
Aug 12 '08 #11
I have refered that site.. follwed the steps
1. Creates Class files
2. While loading class files into database, the following errors coming
(My oracle user is kwa and class file is Area.class , which is working fine in java)

D:\oracle\product\10.2.0\db_1\BIN>loadjava -user kwa/kwa Area.class

Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x807
7E76
Function=[Unknown.]
Library=D:\oracle\product\10.2.0\db_1\jdk\jre\bin\ client\jvm.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.


Current Java thread:
at oracle.jdbc.driver.T2CConnection.t2cCreateState(Na tive Method)
at oracle.jdbc.driver.T2CConnection.logon(T2CConnecti on.java:346)
at oracle.jdbc.driver.PhysicalConnection.<init>(Physi calConnection.java:
413)
at oracle.jdbc.driver.T2CConnection.<init>(T2CConnect ion.java:131)
at oracle.jdbc.driver.T2CDriverExtension.getConnectio n(T2CDriverExtensio
n.java:77)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriv er.java:752)
at java.sql.DriverManager.getConnection(DriverManager .java:512)
- locked <0x141ae178> (a java.lang.Class)
at java.sql.DriverManager.getConnection(DriverManager .java:140)
- locked <0x141ae178> (a java.lang.Class)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.getConnection(Dat
abaseOptions.java:180)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.connect(DatabaseO
ptions.java:123)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getConnection(LoadJ
avaState.java:409)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getOldMD5(LoadJavaS
tate.java:696)
at oracle.aurora.server.tools.loadjava.ClientSchemaOb ject.getOldMD5(Clie
ntSchemaObject.java:52)
at oracle.aurora.server.tools.loadjava.SchemaObject.d oCreate(SchemaObjec
t.java:172)



D:\oracle\product\10.2.0\db_1\BIN>loadjava -user kwa/kwa Area.class

Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x807
7E76
Function=[Unknown.]
Library=D:\oracle\product\10.2.0\db_1\jdk\jre\bin\ client\jvm.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.


Current Java thread:
at oracle.jdbc.driver.T2CConnection.t2cCreateState(Na tive Method)
at oracle.jdbc.driver.T2CConnection.logon(T2CConnecti on.java:346)
at oracle.jdbc.driver.PhysicalConnection.<init>(Physi calConnection.java:
413)
at oracle.jdbc.driver.T2CConnection.<init>(T2CConnect ion.java:131)
at oracle.jdbc.driver.T2CDriverExtension.getConnectio n(T2CDriverExtensio
n.java:77)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriv er.java:752)
at java.sql.DriverManager.getConnection(DriverManager .java:512)
- locked <0x141ae178> (a java.lang.Class)
at java.sql.DriverManager.getConnection(DriverManager .java:140)
- locked <0x141ae178> (a java.lang.Class)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.getConnection(Dat
abaseOptions.java:180)
at oracle.aurora.server.tools.loadjava.DatabaseOption s.connect(DatabaseO
ptions.java:123)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getConnection(LoadJ
avaState.java:409)
at oracle.aurora.server.tools.loadjava.LoadJavaState. getOldMD5(LoadJavaS
tate.java:696)
at oracle.aurora.server.tools.loadjava.ClientSchemaOb ject.getOldMD5(Clie
ntSchemaObject.java:52)
at oracle.aurora.server.tools.loadjava.SchemaObject.d oCreate(SchemaObjec
t.java:172)
at oracle.aurora.server.tools.loadjava.SchemaObject.p rocess1(SchemaObjec
t.java:215)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:532)
at oracle.aurora.server.tools.loadjava.LoadJava.addCl ass(LoadJava.java:5
86)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:436)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:380)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:349)
at oracle.aurora.server.tools.loadjava.LoadJava.add(L oadJava.java:652)
at oracle.aurora.server.tools.loadjava.LoadJava.proce ssDeferredFiles(Loa
dJava.java:617)
at oracle.aurora.server.tools.loadjava.LoadJava.proce ss(LoadJava.java:81
8)
at oracle.aurora.server.tools.loadjava.LoadJava.comma nd(LoadJava.java:25
1)
at oracle.aurora.server.tools.loadjava.LoadJavaMain.r un(LoadJavaMain.jav
a:103)
at oracle.aurora.server.tools.loadjava.LoadJavaMain.m ain(LoadJavaMain.ja
va:28)

Dynamic libraries:
0x00400000 - 0x0040B000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\java.e
xe
0x7C900000 - 0x7C9B0000 C:\WINDOWS\system32\ntdll.dll
0x7C800000 - 0x7C8F5000 C:\WINDOWS\system32\kernel32.dll
0x77DD0000 - 0x77E6B000 C:\WINDOWS\system32\ADVAPI32.dll
0x77E70000 - 0x77F01000 C:\WINDOWS\system32\RPCRT4.dll
0x77C10000 - 0x77C68000 C:\WINDOWS\system32\MSVCRT.dll
0x08000000 - 0x08138000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\client
\jvm.dll
0x7E410000 - 0x7E4A0000 C:\WINDOWS\system32\USER32.dll
0x77F10000 - 0x77F57000 C:\WINDOWS\system32\GDI32.dll
0x76B40000 - 0x76B6D000 C:\WINDOWS\system32\WINMM.dll
0x76390000 - 0x763AD000 C:\WINDOWS\system32\IMM32.DLL
0x10000000 - 0x10007000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\hpi.dl
l
0x00390000 - 0x0039E000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\verify
.dll
0x003B0000 - 0x003C9000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\java.d
ll
0x003D0000 - 0x003DE000 D:\oracle\product\10.2.0\db_1\jdk\jre\bin\zip.dl
l
0x62F00000 - 0x62F13000 D:\oracle\product\10.2.0\db_1\BIN\ocijdbc10.dll
0x02E70000 - 0x02EC7000 D:\oracle\product\10.2.0\db_1\BIN\OCI.dll
0x7C340000 - 0x7C396000 D:\oracle\product\10.2.0\db_1\BIN\MSVCR71.dll
0x76C90000 - 0x76CB8000 C:\WINDOWS\system32\imagehlp.dll
0x59A60000 - 0x59B01000 C:\WINDOWS\system32\DBGHELP.dll
0x77C00000 - 0x77C08000 C:\WINDOWS\system32\VERSION.dll
0x76BF0000 - 0x76BFB000 C:\WINDOWS\system32\PSAPI.DLL

Heap at VM Abort:
Heap
def new generation total 576K, used 77K [0x10010000, 0x100b0000, 0x104f0000)
eden space 512K, 13% used [0x10010000, 0x10021b20, 0x10090000)
from space 64K, 11% used [0x10090000, 0x10091cd0, 0x100a0000)
to space 64K, 0% used [0x100a0000, 0x100a0000, 0x100b0000)
tenured generation total 1408K, used 243K [0x104f0000, 0x10650000, 0x14010000
)
the space 1408K, 17% used [0x104f0000, 0x1052cdd0, 0x1052ce00, 0x10650000)
compacting perm gen total 4096K, used 2414K [0x14010000, 0x14410000, 0x1801000
0)
the space 4096K, 58% used [0x14010000, 0x1426b810, 0x1426ba00, 0x14410000)

Local Time = Mon Aug 11 12:18:03 2008
Elapsed Time = 0
#
# HotSpot Virtual Machine Error : EXCEPTION_ACCESS_VIOLATION
# Error ID : 4F530E43505002EF
# Please report this error at
# http://java.sun.com/cgi-bin/bugreport.cgi
#
# Java VM: Java HotSpot(TM) Client VM (1.4.2_08-b03 interpreted mode)
#
# An error report file has been saved as hs_err_pid2940.log.
# Please refer to the file for further information.
#

D:\oracle\product\10.2.0\db_1\BIN>
If any one face this error, pl respond....
Aug 13 '08 #12

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Hubert Baumeister | last post by:
Fifth International Conference on eXtreme Programming and Agile Processes in Software Engineering XP2004 June 6-10, 2004,...
1
by: Marwan | last post by:
Hello I am using asynchronous delegates to make a call to a COM ActiveX object, but even though the call occurs on a separate thread, my UI is...
13
by: Bern McCarty | last post by:
I have run an experiment to try to learn some things about floating point performance in managed C++. I am using Visual Studio 2003. I was hoping...
4
by: John | last post by:
Hi all, This really is quite an urgent matter. I have a page with multiple, dynamically-loaded user controls and when a user clicks on a...
13
by: mitchellpal | last post by:
i am really having a hard time trying to differentiate the two..........i mean.....anyone got a better idea how each occurs?
13
by: shsingh | last post by:
I have a class A containing some map as data variables. I creat an object of class A on heap by allocatiing memory by using "malloc". This will...
3
by: cberthu | last post by:
Hi all, Is it possible to have two connects in the same rexx script to different DB's? I have to get data form on DB (with specifics selects and...
9
by: CryptiqueGuy | last post by:
Consider the variadic function with the following prototype: int foo(int num,...); Here 'num' specifies the number of arguments, and assume that...
12
by: Rahul | last post by:
Hi Everyone, I have the following code and i'm able to invoke the destructor explicitly but not the constructor. and i get a compile time error...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: CD Tom | last post by:
This happens in runtime 2013 and 2016. When a report is run and then closed a toolbar shows up and the only way to get it to go away is to right...
0
by: CD Tom | last post by:
This only shows up in access runtime. When a user select a report from my report menu when they close the report they get a menu I've called Add-ins...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.