Home » Developer & Programmer » Reports & Discoverer » button in reports (report 6i)
button in reports [message #624219] Fri, 19 September 2014 03:57 Go to next message
shahzad-ul-hasan
Messages: 566
Registered: August 2002
Senior Member
i have create a button in report. with following code:
procedure U_1ButtonAction is
begin
  insert into msgout (id,msgto,msg)
  values
  (:stuid,'+923216644029','Respected parents your child got' || :obt ||'/' || :tot || 'in ' ||:ty);
end;

but when i run the report it gives me the following error:
/forum/fa/12175/0/
  • Attachment: 33.JPG
    (Size: 9.27KB, Downloaded 623 times)
Re: button in reports [message #624220 is a reply to message #624219] Fri, 19 September 2014 04:04 Go to previous messageGo to next message
Littlefoot
Messages: 21612
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Open Reports' Help and search for REP-1344; its cause and action are described in there.

However, why would you want to do such a job using a report? A standalone procedure seems to be a better choice.
Re: button in reports [message #624247 is a reply to message #624220] Fri, 19 September 2014 08:14 Go to previous messageGo to next message
shahzad-ul-hasan
Messages: 566
Registered: August 2002
Senior Member
Tell me the procedure .a database level or report level.
Re: button in reports [message #624254 is a reply to message #624247] Fri, 19 September 2014 10:21 Go to previous messageGo to next message
shahzad-ul-hasan
Messages: 566
Registered: August 2002
Senior Member
i have checked through help file.now the button is not showing on report. but report compile correctly.
Re: button in reports [message #624266 is a reply to message #624247] Fri, 19 September 2014 14:27 Go to previous messageGo to next message
Littlefoot
Messages: 21612
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
shahzad-ul-hasan wrote on Fri, 19 September 2014 15:14

Tell me the procedure


I don't know it, I don't have enough information (tables' description and stuff).

I think that it is "stupid" to run a report, have a list of tens or hundreds of students, and then clicking that button of yours tens or hundreds of times in order to insert values into a certain table (which would be used for ... what? Sending an e-mail to parents?). A procedure would
insert into msgout (id,msgto,msg)
  select 
    stuid, 
    '<is it a hardcoded telephone number? Wrong! That information should be stored somewhere>',
    'Respected parents your child got' || obt ||'/' || tot || 'in ' ||ty
  from <a table you use in that report>
  where <condition here, if necessary>;

No clicking, no nothing. Let Oracle do the dirty job.
Re: button in reports [message #624326 is a reply to message #624266] Sun, 21 September 2014 12:57 Go to previous message
shahzad-ul-hasan
Messages: 566
Registered: August 2002
Senior Member
I have done my report to work before that procedure...thanks for your help.
Previous Topic: Rep-1401: '' Fatal PL/sql error, issue with Clob and varchar2 in Oracle 11.2.0.4.0
Next Topic: Temporary table in report
Goto Forum:
  


Current Time: Sun Oct 25 23:19:39 CDT 2020