Home » Developer & Programmer » Reports & Discoverer » photo id (oracle 8i forms and reports 6i)
photo id [message #485001] Sat, 04 December 2010 23:07 Go to next message
lacchhii
Messages: 118
Registered: May 2009
Location: bangalore
Senior Member

hi,

we have a admin wizard where in there are 850 officials whose details are like

emp id
date of birth
date of joining
basic pay
photo
etc........

i have the photos of the officials out of the data base.

i have created a report to generate the details of the officials. what i would like to have is to get the photo of each official from the file which is not in the data base.

i have the command in pre_form
read_image_file('path where the photos are','msg.mcn');

this gives the same photo to all the officials.

how do i be able to link the photos to their emp id and get it


thanks in advance
Re: photo id [message #485008 is a reply to message #485001] Sun, 05 December 2010 00:38 Go to previous messageGo to next message
ranamirfan
Messages: 529
Registered: January 2006
Location: Pakistan / Saudi Arabia
Senior Member

Dear,

Set the Formula Column property as below.

./fa/8506/0/

Write code in a PL/SQL Formula.

function CF_1Formula return Char is
begin
  Return ('D:\'||:EmpNo||'.GIF');
end;



Hope It'll help you.


Regards,

Irfan
Re: photo id [message #485015 is a reply to message #485008] Sun, 05 December 2010 02:19 Go to previous messageGo to next message
lacchhii
Messages: 118
Registered: May 2009
Location: bangalore
Senior Member

./fa/8507/0/

hi irfan,

i did try out the same way as u mentioned. but i am getting this error

"REP-1517: COLUMN'CF_1' REFERENCES COLUMN 'EMP_ID', WHICH HAS INCOMPATIBLE FREQUENCY"

my settings for the formula column does not have the xml settings. it stops at pl/ sql formula. is the problem because of that. i have attached the screen shot of the formula column properties for your reference.


pl let me know necessary correction to be made
  • Attachment: REPORT.JPG
    (Size: 37.51KB, Downloaded 237 times)
Re: photo id [message #485016 is a reply to message #485015] Sun, 05 December 2010 02:40 Go to previous messageGo to next message
ranamirfan
Messages: 529
Registered: January 2006
Location: Pakistan / Saudi Arabia
Senior Member

Dear,

Quote:


"REP-1517: COLUMN'CF_1' REFERENCES COLUMN 'EMP_ID', WHICH HAS INCOMPATIBLE FREQUENCY"




You are trying to access EMP_ID column which is outside the query Group.

Please also read this post.

http://forums.oracle.com/forums/thread.jspa?threadID=1098995


Regards,

Irfan
Re: photo id [message #485778 is a reply to message #485015] Thu, 09 December 2010 19:07 Go to previous messageGo to next message
lacchhii
Messages: 118
Registered: May 2009
Location: bangalore
Senior Member

hi,

i tried the same way, now what happens is there are certain emp id where there are no photos received. so the report throws an error "no <emp_id>.jpg found. No photo found for that emp Id.

i tried giving exception
when NO_DATA_FOUND RETURN (NULL)it gives an error.

what is the exception to be used to make it work.

i even tried giving an exception to return any available jpg file,to check how the exception works ,but it doesnt accept.

thanks in advance
Re: photo id [message #485817 is a reply to message #485778] Fri, 10 December 2010 03:54 Go to previous message
cookiemonster
Messages: 11074
Registered: September 2008
Location: Rainy Manchester
Senior Member
The exception is coming outside the pl/sql function - hence no exception handler can catch it.
You should have the complete image path/name stored in a column (or 2 if you prefer) in the emp table. Those columns should be null if there is no image. Then you would just return that data. If it's null there won't be a problem.
Previous Topic: Report Server
Next Topic: Report not Print on Receipt Printer (CZERLOP) (merged)
Goto Forum:
  


Current Time: Thu Oct 23 16:02:24 CDT 2014

Total time taken to generate the page: 0.12251 seconds