SQL & PL/SQL :: Mail Sending In DAT Format Instead Of HTML?
Oct 14, 2010
I have learned procedure to send email with html attachment using UTL_SMTP protocol. But I could see the mailed attachment shows .Dat format. I need the attachment should go in .Html format.
find the below code which i am using:
CREATE OR REPLACE PROCEDURE send_email(
pi_from in Varchar,
pi_to in VARCHAR,
pi_subj in VARCHAR,
pi_msg CLOB
)
if i click the column it shows the text output(various tags ,symbols)
if i click the HTML it shows the correct format .,
i m sending the mail using that message column .,the mail Received with the text format ,actually i need it in the html format., How to send HTML output?
I have written a procedure to send a pdf file through mail. The directory was created and registered in SYS.DBA_DIRECTORIES with read,write grant access. But im getting the below error.
****** ORA-20014: Error in MAIL_FILES_PRO ORA-20012: Invalid Operation ORA-06512: at "ANAND.PRO_ICTPAYSLIPMAIL02", line 229 ORA-06512: at line 2 ******
We currently send mail via UTL_SMTP, we could easily switch to SMTP_MAIL but that is beside the point.
Our issue is that we have no way to find out what happens to mail we send to the MTA program, "smtpd". It is of my knowledge that the only information we can receive back from UTL_STMP is if the email address is invalid or if the email is going to be attempted to be forwarded by the MTA "smtpd".
We need the REAL data behind the scenes that "smtpd" is going to get after it attempts to forward an email from the database to GMail for example. We need "account does not exist" errors, and anything else that Google might have to say about us sending that address mail.
As far as I have researched there are no out of the box ways to send mail in this fashion.Could this be as simple as specifying the MX server for GMail? So for an email to a GMail account instead of connecting to localhost:25 for our SMTP server, we should connect to mx.googlemail.com:25?
how to setup receiving bounce messages through the database? We currently receive mail at the database box, and I think we can specify a special clob that will open one of the incoming mail files in RHEL to read for bounces.
BEGIN dbms_network_acl_admin.add_privilege (acl=> 'mails_senden.xml', principal=> 'USER2', is_grant=> true, privilege=> 'connect');
[code]....
USER1 sent a mail via UTL_SMTP successful whereas USER2 got the errors:
DECLARE * ERROR at line 1: ORA-24247: network access denied by access control list (ACL) ORA-06512: at "SYS.UTL_TCP", line 17 ORA-06512: at "SYS.UTL_TCP", line 267
[code]....
There is still the following fact:
USER1 has the role DBA, USER2 got the EXECUTE privilege to packages UTL_TCP, UTL_SMTP (GRANT from SYS).
IF the role DBA was granted to USER2 too then he couldt send emails just as well as USER1.
ERROR at line 1: ORA-29279: SMTP permanent error: 550 <account@test2.com[/email]> No such user here ORA-06512: at "SYS.UTL_SMTP", line 21 ORA-06512: at "SYS.UTL_SMTP", line 99 ORA-06512: at "SYS.UTL_SMTP", line 241 ORA-06512: at "SYS.UTL_MAIL", line 424 ORA-06512: at "SYS.UTL_MAIL", line 594 ORA-06512: at line 2
I have to embed a picture as a header with an e-mail content for my work, I google'd and tested with different options but I failed. (The JPG is stored in a table as a blog object) When I tried with the below code the JPG file is e-mailed as an attachment with an e-mail content, I want it to be displayed inside an e-mail.
I tried att_inline: TRUE option as well - still not working.
Here is my code I tested and worked as an attachment.
I need to create a forgot password page in which there will be two text box named user name and email id and user will provide his usename and email id in those text box. so apex will check that the provided name and email id are there in the data base and if email id corresponds to right user name then a mail will be send to that email Id containing auto generated password.
In Apex 4.2 Jquery mobile list view how can you apply html format for the phone# field to make it dial with a touch. For example, I see how to do a list view of the 'DEMO_CUSTOMER' sample data, but I cannot figure out how to format the phone # fields so that they will dial on touch. I know the HTML tags to use and I know how to use it in a standard report, but I can't figure out list view.
I m using UTL_SMTP to send mail using my mail server. could i check the availability of 1st mail server, if not available then could i set alternate mail server.
I have a Database of My all customers Mobile Nos I want to send SMS to all customer from Oracle Database using Pl/SQL or any inbuilt Oracle Package, if available or through Oracle forms
How i can send SMS to my Customers through Oracle PL/SQL or Oracle forms or any other front end and what are the additional requirement in sending SMS and what utilities are needed .
We are able to insert CLOB into database, Using oracle Text I'm able to search inside clob. [two questions solved ]. The question arise when we need to send this data to application either as file or as text(varchar2).
I'm able to generate file from CLOB using function,unfortunately it resides inside db and developer is not able to access it.
1)There is option to mount application partition inside db and export file over there but it is not viable option according to management.
2)I've Googled the solution to create JAVA API. Which will perform OS command like scp to send file from db to app(or any remote host). For security reason this option is also dropped.
3)I tried dbms_lob.substr but actual text inside clob is too long. File generated from CLOB sized around 5 MB.
So I guess it requires lot of effort if I wanted to convert into varchar2 as out parameter inside function.
So, to give CLOB data to developer as file or as varchar2. I'm not able to get any solution. Is there any other option using database to convert to string/varchar2 from CLOB ? Or do I need to drill down more into third option.
i am able to send text/ csv attachment thru oracle PL/Sql Procedure. But i am facing this for excel attachment, some junk character is coming while opening that attachment excel file.
i am attaching here with my coding for your view. Anything i have to configure at my SMTP server.