SQL & PL/SQL :: Image Save From Java GUI
Apr 5, 2011
I am currently working on project which is basically development is going on Java Spring and Oracle 10g
I have a problem when i am calling the procedure from Java GUI
I am created directory named IMAGE_DIR
CREATE OR REPLACE PROCEDURE u_rfnd_cnd_test
(ackno in varchar2, p_name IN u_rfnd_cnd_petition.URCP_IMAGE_NM%TYPE) IS
v_bfile BFILE;
v_blob BLOB;
BEGIN
INSERT INTO u_rfnd_cnd_petition (URCP_ACK_NO, URCP_IMAGE_NM, URCP_IMAGE)
VALUES ( ackno,p_name, empty_blob())
RETURN URCP_IMAGE INTO v_blob;
[Code]..
When i m calling this procedure from Oracle itself its working fine
But when calling this procedure from Java GUI with same parameter then i am getting error
But still i am getting an error saying.
Error :java.sql.SQLException: ORA-22288: file or LOB operation FILEOPEN failed The system cannot find the path specified. ORA-06512: at "WBCOMTAX.U_RFND_CND_TEST", line 18
View 5 Replies
ADVERTISEMENT
Jun 3, 2009
I create a simple table for image
CREATE TABLE image_table (
Design_no varchar2(10),
filename VARCHAR2(255) PRIMARY KEY,
image LONG RAW);
Then i create simple block of image_table
its show me in this website [URL] My question is i don't want to give my form path always.i want to save my picture path in my database and the name of my picture always same as my design_no column.
For example i want to save a picture in my database i will copy my picture in d:shahzaib1234.jpg now i want the path d:shahzaib save in database and when i copy my picture which path= d:shahzaib and file name = Design no its will automatically save in database.
View 4 Replies
View Related
Dec 18, 2008
i m getting some problam to display image in forms 6i.
i hv two tables
1st is empmst
emp_code number(5) not null (PK)
emp_name varchar2() not null
2nd is emppic
emp_code number(5) not null (FK of empmst)
emppic blob not null
i create a master detial form and save the data in tables
whn u execute query i m unable to get the pic..
View 5 Replies
View Related
Apr 14, 2010
I have a db field "image" of type BLOB and I save the contents to a file on a local folder c: example.bmp.
I found numerous examples
BEGIN -
Get LOB locator
SELECT image INTO l_blob pc_immagini_blob FROM WHERE code = WCI;
- Open the destination file.
l_file: UTL_FILE.fopen = ('C: Temp', 'EXAMPLE.BMP', 'w', 32767); -----> error
The db is not local but on an application server, the image must be saved to c: the client.
View 8 Replies
View Related
Oct 4, 2010
I want to store file from form to database:
1. what is the good way (best solution) to store file means into Database or folder on sever.
2. In either case how can we do it means i need in detail on both sides (means on form side and also on database side).
3. Every file related to a record and may contain 1 or more then 1 files and maybe update files for one record many time and we must keep track of each update.
View 8 Replies
View Related
Jul 13, 2012
Our system stores images on the unix filesystem. We scan full page images.
Our image specs are:
black and white: tiff, group4 compression, 300dpi. so files are about 40-80k compressed
photograpshs/gray scale: jpeg/jpeg compression 256 gray scale. Some images can be 2megs...but most of them are about 400-700k
We build a demo with forms10G/application server 1 year ago and performance was really bad. Took about 10-15 seconds to generate a report with 1 image of it...compared to about 1-2 secs using forms 6i. We just installed weblogic 11G (10.3.5) with forms 11gr2. I'm guessing performance will still be an issue but we will still be testing it.
Our users currently use nfs to access images on the unix server. So that would not changed.
- read_image from filesystem (c: unc path //server/images/.../1.jpeg)
- zoom in, zoom out (having vertical/hori scroll bars to move around...or best would be panning)
- save_image on filesystem
- fit to window/cancas
- always keeping aspect ratio
nice to have options, but not needed at this time
- save in blobs
- editing capabilities (mostly just select an area to delete, like black borders...some speckles here and there)
View 1 Replies
View Related
Sep 26, 2010
i want to create a simple form in this form i want to upload the image on the image item with browse button that open a diaglog box that go to the image i select the image and this image is display on image item on the form.
View 1 Replies
View Related
Apr 26, 2013
I am trying to execute an xslt (for XML transformation) using xmltype.transform function.
I can't paste XSLT code here, but below is similar what I am doing.
[URL]
I have used a reference of random() method of java.lang.Math in xslt file, and it's giving me below error.
ORA-31011: XML parsing failed
ORA-19202: Error occurred in XML processing
LPX-00607: Invalid reference: 'random'.
I doubt, it's because of "Math" class, which is not present in Oracle, how to load standard java classes.
View 1 Replies
View Related
May 22, 2012
I am trying to invoke program from my local Windows machine (exactly java executor, which is in my environment on c:javajdkinjava) using database package with Java stored procedure.
Everything is fired by SQLPLUS script, this script invokes package with Java stored procedure (jar loaded into Oracle) and that procedure is trying to invoke runtime process (syntax:
c:javajdkinjava -cp
and here ara my classes and main jar) using my local java executor. I added all permissions using dbms_java.grant_permisions (execution forced me to give permissions java.io.FilePermission to <<ALL_FILES>> for execute), moreover I added to my database user JAVASYSPRIV and JAVAUSERPRIV role. Unfortunately, beside this I am still getting error:
C:javajdkinjava not found (Note that lookup with PATH isn't done due to the oracle executable being setuid.)
View 8 Replies
View Related
Jul 14, 2011
I was getting java.sql.SQLException: executeBatch, Exception = 1when i tried to use executeBatch().could not understand why i am getting it.
View 1 Replies
View Related
Jun 20, 2011
I am writing a java stored procedure in my package. In the java procedure I want to issue a query to be fired on the user table from which I am calling the java procedure.
Some thing like following:
I am logged in to USER1 and my package is inside USER1. From this package I am calling the Java Stored Procedure. In java procedure I want to make a jdbc connection to USER2. The details of USER2(password, hostname,portno) are stored in a table called 'connection_details' and this table is in the USER1.
My problem is how can I issue the
SELECT details FROM CONNECTION_DETAILS for USER2
so that i can get the details..?
Do i need to first make jdbc connection to USER1 and then execute the above query for which i need similar details of USER1. How can i obtain the details of USER1 here.
I am thinking if I am already in USER1 then do I need to make the jdbc connection to USER1 and then execute the query?
View 1 Replies
View Related
Dec 21, 2011
I've this java source create or replace and compile java source named "Decodificador" as
public class Decodificador {
public static String decodifica(String codigo)
return codigo;
and this function
create or replace function F_Decodificador(codigo varchar2) RETURN VARCHAR2 IS
LANGUAGE java NAME 'Decodificador.decodifica(String) return String';
when I execute the function the result is:
ORA-29531: no method decodifica in class Decodificador
View 8 Replies
View Related
Jul 30, 2012
Which is the best driver for java to Oracle database connection ?
View 1 Replies
View Related
Feb 10, 2011
I need to call DB function through Java Hibernate.
My Sample XML File looks like.
---------------------------------------------------------------
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping>
<sql-query name="getchequeno" callable="true">
?:=call cz_nab_mw_fn_gen_ol_chq_no()
</sql-query>
</hibernate-mapping>
---------------------------------------------------------------
I am getting below error while reading the file
"java.lang.RuntimeException: org.hibernate.HibernateException: Errors in named queries: getchequeno"
View 1 Replies
View Related
Feb 4, 2005
Here is a problem. I have to pass an array e.g ('Account','Marketing',Computer' ) from java to Oracle 9i.
Would I be able to do in Oracle, if yes then how ?
View 11 Replies
View Related
Aug 26, 2011
we can you java code natively with Oracle. But I didn't get how to decide when to use native java in oracle and when to use pl/sql.
View 5 Replies
View Related
May 20, 2013
i`m trying to use pl/sql function to execute java class. I created 2 tables with around 100 values and java class with simple functionality. I need to create function to loop through my table1 and get with each iteration one value from table and pass that value as parameter to java class.
table1 is something like this:
ID NAME
1 name1
2 name2
3 name3
. .
. .
100 name100
table2 is empty with same columns as table1 ( table2 is for data obtained from java returns ) I created in sql+ java class.
CREATE OR REPLACE AND RESOLVE JAVA SOURCE NAMED "myClass" AS
import java.io.*;
import java.util.*
public class myClass {
public static String fun(String strName)
[code]....
Then i wanna make a pl/sql function for:
1)For i = 1 Obtain first value from table1 (column name) and pass it throught java class then return value and save it in table2 with the same id as id from table1
2) change i=1 to i=2 and do that same
3) end if i=101
View 1 Replies
View Related
Nov 26, 2012
I Program with Java . when we connect oracle by program ,
Get the following error :
'No suitable driver found for jdbc:orcl:thin:@localhost:1521 '
View 3 Replies
View Related
Aug 22, 2005
I have created a form which as two block as master and detail.I am facing two problem in my detail block.
First: When I populate records in detail block, it prompt a message 'Do you want to save record ?'.
Second : When I alter any value in detail block and move to next record, it prompt a message 'Do you want to save record ?'
Is there any way where, system don't prompt me a message for saving record and user can continue with changes and save the records when he desire.
View 16 Replies
View Related
Dec 20, 2011
In oracle 9i, I have a table and i inserted the more then 3 records and while inserting each records i have created the save point. But, now i rollback to that particular save point, the whole transaction get roll backed.
Here the similar example what i have tried using SQL Developer Eg:
insert into dept (deptid,dept_name) values (3,'Purchase');
savepoint aa;
insert into dept (deptid,dept_name) values (4,'IT');
savepoint bb;
insert into dept (deptid,dept_name) values (5,'System');
savepoint cc;
rollback to bb;
View 10 Replies
View Related
May 13, 2009
I work with several tables at a time in SQL Developer and I find myself having to reopen and freeze every table everytime I start the application. Is there a way to save all those frozen views for next time?
View 4 Replies
View Related
Jan 22, 2013
When a user clicks on Save Button on a form, can we know from sql plus (Oracle) all the related queries (insert/Update etc) for that transaction ??
View 1 Replies
View Related
Oct 21, 2010
the data not save the record the item CMPID not generate a number or id to press button NEW
secondly to click the button SAVE they not save the partcular transaction.
View 12 Replies
View Related
Jun 21, 2011
Can we save the Microsoft outlook incoming and outgoing mails parameters(to,from,cc, subject,desc) in oracle database table online.
View 5 Replies
View Related
May 16, 2010
I have a block based on a table and display a few records on the form after retrieving records from the table behind. Now I should be able to edit a record or add a new record to the existing records on the screen. So when i click the save button I only want the rows which are new or have been edited to go back into the db. This is the piece of code I was using for the save button in the on-button-clicked action.
IF alert_button=alert_button1 THEN
GO_BLOCK('my_block');
IF NOT Form_Success THEN RAISE Form_Trigger_Failure;
END IF;
/* ** Commit if anything is changed */
IF :System.record_Status IN ('CHANGED','NEW') THEN Commit_Form;
END IF;
msg_info('Your changes have been saved.');
END IF;
When I do this all the records on the screen gets inserted into the table instead of only the one's I have edited or newly inserted. I only want to insert rows which are new or edited into the table after I click the save button.
View 5 Replies
View Related
Jul 22, 2011
I am working on form 6i. I want to disable the 'SAVE' button which can be seen in the menu (front end).
View 2 Replies
View Related
Jun 26, 2012
declare
blk_name varchar2(60);
form_name varchar2(60);
[Code].....
this is my coding on save button. this is working fine but only once. when i enter the data second time and try to save, it didn't do anything. what should i do?
View 5 Replies
View Related
Apr 25, 2012
I make button in detail section using this location button call another forms, I want first update the location entry then save our main forms.
View 3 Replies
View Related
Mar 16, 2006
I have seen many times that people are confused for how to save and retrieve images in Oracle Database from forms. Here I have created a sample form. All the coding is there. And also required scripts are also written in this post. Please download the form create the scripts and run the form.
Here we go:
Database : 9i
Forms : 6i
Create Scripts:
CREATE TABLE DOCS_COMP_DOCUMENTS
(
DOC_ID VARCHAR2(10),
DOC_NAME VARCHAR2(100),
DOC_SCANNED_COPY LONG RAW,
FILE_NAME VARCHAR2(50),
FILE_EXTENSION VARCHAR2(3)
)
[code].......
Note: This Procedure is to find the file name and extension and store it as well in database. Create this procedure in database.
To retrieve images just press F7 & F8 in forms
Download the attached .fmb module and run it.
View 39 Replies
View Related
Jun 3, 2013
how to save multiple records at once i did coding like this:
declare
cnt number;
l_rec number;
f_rec number;
begin
cnt := 0;
go_block('aan');
last_record;
l_rec := :system.cursor_record;
first_record;
[code]....
but this works as saving the last record only, not saving the all records.
View 4 Replies
View Related