ORA-29279: SMTP permanent error: 550 5.7.1
Dear All,
I am trying to send a mail from my database server but getting this following error:
ORA-29279: SMTP permanent error: 550 5.7.1
My database server IP is :192.168.10.242
And I set the SMTP_OUT_SERVER parameter : 192.168.10.242.
Please help me, how can I solve this problem?
mwz wrote:
Dear All,
I am trying to send a mail from my database server but getting this following error:
ORA-29279: SMTP permanent error: 550 5.7.1
My database server IP is :192.168.10.242
And I set the SMTP_OUT_SERVER parameter : 192.168.10.242.
Please help me, how can I solve this problem?I wonder if this error message was followed by "554 5.0.0 Service unavailable"? Do you have an email server with a SMTP receive connector on the same server as the Oracle instance? SMTP_OUT_SERVER should point to the remote SMTP (email) server which will receive and route the email message. The documentation could have made that point a little more clear, see:
http://download.oracle.com/docs/cd/B14117_01/server.101/b10755/initparams198.htm
If you are able to resolve the above configuration problem, and are still having trouble, you may need to talk with the person responsible for the SMTP (email) server. That person may need to review the SMTP logging (if enabled) to determine the exact problem, and offer suggestions to you and/or modify the configuration of the SMTP server to permit delivery of email messages from the Oracle server. The SMTP log might look something like this one:
http://playground.sun.com/mobile-ip/WG-archive/current/msg01660.html
Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc.
Similar Messages
-
ORA-29279: SMTP permanent error: 550 5.0.0 Command rejected
Hi All,
I wrote a procedure to send mails. It is working fine in one Environment and not working in another Environment even I am passing same values to this procedure.
Please help me to fix this.
Error:
ORA-29279: SMTP permanent error: 550 5.0.0 Command rejected
ORA-06512: at "SYS.UTL_SMTP", line 21
ORA-06512: at "SYS.UTL_SMTP", line 99
ORA-06512: at "SYS.UTL_SMTP", line 222
ORA-06512: at "NIKU.Z_PRO_TEST_MAIL", line 14
ORA-06512: at line 15
The Procedure is :
CREATE OR REPLACE PROCEDURE Z_Pro_Test_Mail(
pInSender IN VARCHAR2,
pInRecipient IN VARCHAR2,
pInSubject IN VARCHAR2,
pInBody IN VARCHAR2,
pInMailhost IN VARCHAR2)
IS
c utl_smtp.connection;
BEGIN
c := utl_smtp.open_connection(pInMailhost, 25); -- SMTP on port 25
utl_smtp.helo(c, pInMailhost);
utl_smtp.mail(c, pInSender);
utl_smtp.rcpt(c, pInRecipient);
utl_smtp.data(c,'From: '||pInSender || utl_tcp.crlf ||
'To: ' || pInRecipient || utl_tcp.crlf ||
'Subject: ' || pInSubject ||
utl_tcp.crlf || pInBody);
utl_smtp.quit(c);
END Z_Pro_Test_Mail;
/Hi,
I think you can check your SMTP server with your system administrator firstly. does it work normally?
And if you are using a Windows PC for APEX, you can check you SMTP server in your IIS administration.
From your error info : Unable to relay, you can follow below to have a check, if you are working on MS Window
IIS -> Default SMTP Virtual Server -> Properties -> Access -> Relay resitrictions -> Relay -> All except the list below.
Hope this helpfull.
PPMonkey. -
i got this problem ,when i try to send mail from mail Queue.
ORA-29279: SMTP permanent error: 550 5.7.1 Unable to relay for [email protected]
Edited by: Alekh on Aug 7, 2009 10:13 AM
Edited by: Alekh on Aug 7, 2009 11:52 AMHi,
I think you can check your SMTP server with your system administrator firstly. does it work normally?
And if you are using a Windows PC for APEX, you can check you SMTP server in your IIS administration.
From your error info : Unable to relay, you can follow below to have a check, if you are working on MS Window
IIS -> Default SMTP Virtual Server -> Properties -> Access -> Relay resitrictions -> Relay -> All except the list below.
Hope this helpfull.
PPMonkey. -
ORA-29279: SMTP Permanet error: 550 5.2.1
I am recieving the error message ORA-29279SMTP Permanet error: 550 5.2.1 .... Mailbox disabled for this recipient.
I am using the utl_smtp function to send from the DB.
I can send to the email address through normal email clients but not from the DB.
Does anyone have any ideas?
Thanks,
Hymanmwz wrote:
Dear All,
I am trying to send a mail from my database server but getting this following error:
ORA-29279: SMTP permanent error: 550 5.7.1
My database server IP is :192.168.10.242
And I set the SMTP_OUT_SERVER parameter : 192.168.10.242.
Please help me, how can I solve this problem?I wonder if this error message was followed by "554 5.0.0 Service unavailable"? Do you have an email server with a SMTP receive connector on the same server as the Oracle instance? SMTP_OUT_SERVER should point to the remote SMTP (email) server which will receive and route the email message. The documentation could have made that point a little more clear, see:
http://download.oracle.com/docs/cd/B14117_01/server.101/b10755/initparams198.htm
If you are able to resolve the above configuration problem, and are still having trouble, you may need to talk with the person responsible for the SMTP (email) server. That person may need to review the SMTP logging (if enabled) to determine the exact problem, and offer suggestions to you and/or modify the configuration of the SMTP server to permit delivery of email messages from the Oracle server. The SMTP log might look something like this one:
http://playground.sun.com/mobile-ip/WG-archive/current/msg01660.html
Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc. -
I have installed Oracle 10g (10.2.0.1) on Windows XP (SP2) machine at my home PC.There is a broadband connection on my home PC.I have installed UTL_MAIL package and then set SMTP_OUT_PARAMETER by the following SQL Statement.
My machine IP address is 192.168.0.3
SQl> alter system set smtp_out_server = 'smtp.bsnl.in:25' scope = 25;
Then we run the following script.
BEGIN
UTL_MAIL.SEND(
SENDER => '[email protected]',
RECIPIENTS => '[email protected]',
SUBJECT => 'Testing UTL_MAIL',
MESSAGE => 'The receipt of this email means'||
'that it works for UTL_MAIL'
END;
Then following error message comes.
BEGIN
ERROR at line 1:
ORA-29279: SMTP permanent error: 553 Authentication is required to send mail as
<[email protected]>
ORA-06512: at "SYS.UTL_SMTP", line 21
ORA-06512: at "SYS.UTL_SMTP", line 99
ORA-06512: at "SYS.UTL_SMTP", line 222
ORA-06512: at "SYS.UTL_MAIL", line 407
ORA-06512: at "SYS.UTL_MAIL", line 594
ORA-06512: at line 2
Can anybody suggest the solution of the above problem.Hi,
is your smtp server configured to use anonymous connection?
Attackwave
Reply Code Description
211 System status, or system help reply
214 Help message [Information on how to use the receiver or the meaning of a particular non-standard command; this reply is useful only to the human user]
220 <domain> Service ready
221 <domain> Service closing transmission channel
250 Requested mail action okay, completed
251 User not local; will forward to <forward-path>
252 OK, pending messages for node <node> started. Cannot VRFY user (for example, info is not local), but will take message for this user and attempt delivery.
253 OK, <messages> pending messages for node <node> started
354 Start mail input; end with <CRLF>.<CRLF>
355 Octet-offset is the transaction offset
421 <domain> Service not available, closing transmission channel (This may be a reply to any command if the service knows it must shut down.)
450 Requested mail action not taken: mailbox unavailable [for example, mailbox busy]
451 Requested action terminated: local error in processing
452 Requested action not taken: insufficient system storage
453 You have no mail.
454 TLS not available due to temporary reason. Encryption required for requested authentication mechanism.
458 Unable to queue messages for node <node>
459 Node <node> not allowed: reason
500 Syntax error, command unrecognized (This may include errors such as command line too long.)
501 Syntax error in parameters or arguments
502 Command not implemented
503 Bad sequence of commands
504 Command parameter not implemented
521 <Machine> does not accept mail.
530 Must issue a STARTTLS command first. Encryption required for requested authentication.
534 Authentication mechanism is too weak.
538 Encryption required for requested authentication mechanism.
550 Requested action not taken: mailbox unavailable [for , mailbox not found, no access]
551 User not local; please try <forward-path>
552 Requested mail action terminated: exceeded storage allocation
*553 Requested action not taken: mailbox name not allowed [for example, mailbox syntax incorrect]*
554 Transaction failed -
ORA-29279: SMTP permanent error: 501 5.5.2
im getting the error
ORA-29279: SMTP permanent error: 501 5.5.2 Syntax error in parameters scanning "FROM"
kindly help . What is the problem exactly?I'm having this same issue now.
This doesn't happen to my other databases on another server.
Basically, I have a startup trigger that sends out mail, and I'm finding on database on a particular (new) server, UTL_SMTP is getting this error.
Have you figured out your root cause? -
Hi ,
Following error msg coming when notification was sending to mail .
ORA-29279: SMTP permanent error: 554 5.5.1 Error: no valid recipients
Please advise how to clear this error.
Thanks&Regards
Ranganath KonikineniIt's not related to oracle. Check How you made the connection with SMTP server and to whom you are sending the mail.
Post your code with tag like {noformat} Your lines of code {noformat} -
Hello friend,
I have changed my smtp server to send email but now i am getting a different error like given below
ORA-29279: SMTP permanent error: 530 5.7.0 Must issue a STARTTLS command first. 2sm141783tif.39
I dont know what is this STARTTLS command.
Pls help me ;
Thanks,
Uttam SInghIt is NOT obvious to someone experiencing a ORA-29279: SMTP permanent error: messages that the root cause is in the SMPT server, it is still an ORA error code. It is especially NOT OBVIOUS, if that person is OBVIOUSLY a newbie. It is OBVIOUS that when you essentially flame people for asking such questions you discourage them from ever asking questions on your forum.
Could you PLEASE, PLEASE, PLEASE be a little less arrogant and stop cluttering up this forum with over-the-top and OFF responses????
Thank You in Advance Mr. Expert. -
Hi ,
I am getting below error frequently in alert log of database.
ORA-12012: error on auto execute of job 754461
ORA-29279: SMTP permanent error: ORA-29279: SMTP permanent error: 501 Syntax error, parameters in command "RCPT TO:" unrecognized or missing
ORA-06512: at "SYS.UTL_SMTP", line 20
ORA-06512: at "SYS.UTL_SMTP", line 98
ORA-06512: at "SYS.UTL_SMTP", line 240
ORA-06512: at "APPS.EIS_UTIL_PKG", line 94
ORA-06512: at "APPS.HKD_PO_ADDON_PKG", line 110
ORA-06512: at line 1You have a job running in the database. Its job ID is 754461
It looks as if that job runs APPS.HKD_PO_ADDON_PKG
That job is attempting to send mail using UTL_SMTP and apparently passing some strange value to SMTP server for the RCPT TO: parameter. -
UTL.MAIL error ORA-29279: SMTP permanent error: 501 Address Syntax Error in
Hi,
I am new to the forum so please excuse if I post incorrectly without conforming to the standards.
We need to send mails using the UTL.MAIL package and have installed them on the database.
Whenever I am trying to send an email I am getting the following error:
ERROR at line 1:
ORA-29279: SMTP permanent error: 501 Address Syntax Error in
[email protected]
ORA-06512: at "SYS.UTL_MAIL", line 654
ORA-06512: at "SYS.UTL_MAIL", line 671
ORA-06512: at line 2
The test code which I am running is as follows:
BEGIN
UTL_MAIL.send(sender => 'test <[email protected]>',
recipients => '[email protected]',
subject => 'UTL_MAIL test subject',
message => 'UTL_MAIL test body');
END;
I have tried different combinations:
BEGIN
UTL_MAIL.send(sender => 'test "<[email protected]>"',
recipients => '[email protected]',
subject => 'UTL_MAIL test subject',
message => 'UTL_MAIL test body');
END;
even tried
BEGIN
UTL_MAIL.send(sender => '[email protected]',
recipients => '[email protected]',
subject => 'UTL_MAIL test subject',
message => 'UTL_MAIL test body');
END;
Everytime I am getting the same error.
This seems to be working with an exchange mail server but never on the SMTP server.
In the SMTP server logs the sender address is not having the angular brackets <> unlike the other mails which are being sent over.
It seems that the SMTP server is pretty strict and the SMTP admin will not change any settings on the server.
The oracle version is as follows
Oracle Database 11g Release 11.2.0.1.0 - 64bit Production
Could you please help me out with a solution.
Some how the angular brackets are geting stripped off (which UTL MAIL package generally does), Is there any way in which I can include the angular brackets.
Edited by: 984757 on 29-Jan-2013 02:56
Edited by: 984757 on 29-Jan-2013 02:57I dislike UTL_MAIL - clunky and poor abstraction interface, and not well written.
Had a look at the code. It does this:
WHILE (ALL_RCPTS IS NOT NULL) LOOP
UTL_SMTP.RCPT(MAIL_CONN,'<' || GET_ADDRESS(ALL_RCPTS) || '>');
END LOOP;The GET_ADDRESS() function process the ALL_RCPTS parameter, returns the 1st address from it, and updates the (in/out) parameter with the remaining string.
SQL> var address varchar2(200);
SQL> exec :address := '<[email protected]>,[email protected]';
PL/SQL procedure successfully completed.
SQL> exec dbms_output.put_line( 'get_address='||UTL_MAIL.GET_ADDRESS(:address)||' address='||:address );
get_address=[email protected] address=[email protected]
PL/SQL procedure successfully completed.
SQL> exec dbms_output.put_line( 'get_address='||UTL_MAIL.GET_ADDRESS(:address)||' address='||:address );
get_address=[email protected] address=
PL/SQL procedure successfully completed.
SQL> The address is explicitly surrounded by brackets as per the RFC. So that is what your SMTP server should see.
If not - perhaps then our UTL_MAIL versions do not match. Cannot recall from what version I pulled and unwrapped the UTL_MAIL package code I have.
Personally though, I've ceased using UTL_MAIL a while back. It lacks in may respects. I have written my own mail package that supports multiple attachment, complex Mime formatting, attachments of 20+ MB in size, and so on - running on the UTL_SMTP interface (that provides the transport layer for sending mail). And for issues like you are facing, I suggest considering using UTL_SMTP directly.
Edited by: Billy Verreynne on Jan 29, 2013 12:52 PM
(Updated the code with HTML entity names to get the code snippet to render correctly) -
Unable to send Email: ORA-29279: SMTP permanent error: 501 Syntax error in
We have a procedure use utl_smtp in 10g (10.0.4). we got this msg (Unable to send Email: ORA-29279: SMTP permanent error: 501 Syntax error in arguments) when send e-mail to another mail box (internal),
but we use the same procedure running in 10g(10.03) it works perfectly. Is Oracle 10g(10.0.4 vs. 10.0.3) causing this issue ? Can someone shed some lights on my head ? Thx.We found what is wrong about this.
The problem is in CC we had a e-mail address has one space like this test [email protected] so UTL_smtp doesn't like this kind format then we recreated a new e-mail address without space and it works fine. -
Getting ORA-29279: SMTP permanent error: 553
Error report:
ORA-29279: SMTP permanent error: 553 Requested action not taken: mailbox name not allowed
ORA-06512: at "SYS.UTL_SMTP", line 20
ORA-06512: at "SYS.UTL_SMTP", line 98
ORA-06512: at "SYS.UTL_SMTP", line 221
ORA-06512: at "SYS.UTL_MAIL", line 397
ORA-06512: at "SYS.UTL_MAIL", line 608
ORA-06512: at line 2
29279. 00000 - "SMTP permanent error: %s"*Cause: A SMTP permanent error occurred.
*Action: Correct the error and retry the SMTP operation..
The mail server changed in our company and i have updated the smtp_out_server parameter in system to reflect the new ip with the port.
But when i try testing the utl_mail package, i get this error message. It used to work fine with the old mail server. Nothing else has changed.
Please advice.
Thanks
Kavita994008 wrote:
Error report:
ORA-29279: SMTP permanent error: 553 Requested action not taken: mailbox name not allowed
ORA-06512: at "SYS.UTL_SMTP", line 20
ORA-06512: at "SYS.UTL_SMTP", line 98
ORA-06512: at "SYS.UTL_SMTP", line 221
ORA-06512: at "SYS.UTL_MAIL", line 397
ORA-06512: at "SYS.UTL_MAIL", line 608
ORA-06512: at line 2
29279. 00000 - "SMTP permanent error: %s"*Cause: A SMTP permanent error occurred.
*Action: Correct the error and retry the SMTP operation..
The mail server changed in our company and i have updated the smtp_out_server parameter in system to reflect the new ip with the port.
But when i try testing the utl_mail package, i get this error message. It used to work fine with the old mail server. Nothing else has changed.
Please advice.
Thanks
Kavitawhile logged onto the DB then do as below
telnet <new_mail_server> 25
post results back here -
ORA-29279: SMTP permanent error: 530 5.7.0 Must issue a STARTTLS command
Hi,
When am sending mail through apex_mail it getting an error { " ORA-29279: SMTP permanent error: 530 5.7.0 Must issue a STARTTLS "}
ACL Package
{{{{ " DECLARE
ACL_PATH VARCHAR2(4000);
ACL_ID RAW(16);
BEGIN
-- Look for the ACL currently assigned to '*' and give APEX_040100
-- the "connect" privilege if APEX_040000 does not have the privilege yet.
SELECT ACL INTO ACL_PATH FROM DBA_NETWORK_ACLS
WHERE HOST = '*' AND LOWER_PORT IS NULL AND UPPER_PORT IS NULL;
-- Before checking the privilege, make sure that the ACL is valid
-- (for example, does not contain stale references to dropped users).
-- If it does, the following exception will be raised:
-- ORA-44416: Invalid ACL: Unresolved principal 'APEX_040100'
-- ORA-06512: at "XDB.DBMS_XDBZ", line ...
SELECT SYS_OP_R2O(extractValue(P.RES, '/Resource/XMLRef')) INTO ACL_ID
FROM XDB.XDB$ACL A, PATH_VIEW P
WHERE extractValue(P.RES, '/Resource/XMLRef') = REF(A) AND
EQUALS_PATH(P.RES, ACL_PATH) = 1;
DBMS_XDBZ.ValidateACL(ACL_ID);
IF DBMS_NETWORK_ACL_ADMIN.CHECK_PRIVILEGE(ACL_PATH, 'APEX_040100',
'connect') IS NULL THEN
DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH,
'APEX_040100', TRUE, 'connect');
END IF;
EXCEPTION
-- When no ACL has been assigned to '*'.
WHEN NO_DATA_FOUND THEN
DBMS_NETWORK_ACL_ADMIN.CREATE_ACL('power_users.xml',
'ACL that lets power users to connect to everywhere',
'APEX_040100', TRUE, 'connect');
DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('power_users.xml','*');
END;
COMMIT;
And i changed in the instance settings under email to smtp credentials.
can anyone tel me about this error.??
My apex version - 4.1.1
database version - 11gr2
Edited by: Tulasi 1243 on Aug 17, 2012 4:27 PMHi,
Many mail server provides like gmail use TLS/SSL for mail transmission. The error suggest your mail server is expecting a TLS/SSL connection.
The TLS/SSL connection is not part of the UTL_SMTP and UTL_MAIL API. You have to either use Wallet as described here http://oracleblues.blogspot.in/2010/09/11g-release-2-11202-new-utlsmtp.html or use a third party tunneler like stunnel as described here http://monkeyonoracle.blogspot.in/2009/11/plsql-and-gmail-or-utlsmtp-with-ssl.html
Cheers, -
Ora-29279: SMTP permanent error Unbalanced ' ' XE
Dear Sirs
Sorry for my bad english, I'm not from USA; I have a problem when I send email in Oracle Express Aplication Release 11.2.0.2.0, I get this mistake ora-29279: SMTP permanent error <[email protected].. Unbalanced '>' and I don`t know what happen. I configure UTL_MAIL in this way:
[host@oracle]$ cd $ORACLE_HOME/rdbms/admin
[host@oracle]$sqlplus / as sysdba
SQL> @utlmail
SQL> @utlsmtp
SQL> @prvtmail.plb
SQL> GRANT EXECUTE ON utl_mail TO PUBLIC;
SQL> GRANT EXECUTE ON utl_smtp TO PUBLIC;
SQL> alter system set smtp_out_server='192.168.170.10' scope=both;
ACL: Access Control List
in White Horses Blog
Create ACL and privileges
Now first create an ACL as SYS (or any other user with DBMS_NETWORK_ACL_ADMIN execute granted), this will hold the privileges. You can add as many privileges as you like to this file, but I would recommend to split privileges in the ACL to specific tasks or users. You must create an ACL with at least one privilege, so lets start with the ‘connect’ privilege for user ASSA, (also a role can be added as principal):
begin
dbms_network_acl_admin.create_acl (
acl => 'utl_mail.xml',
description => 'Allow mail to be send',
principal => 'ASSA',
is_grant => TRUE,
privilege => 'connect'
commit;
end;
Add Privilege
Great, now that the ACL is created, you can add more privileges like the ‘resolve’ privilege:
begin
dbms_network_acl_admin.add_privilege (
acl => 'utl_mail.xml',
principal => 'ASSA',
is_grant => TRUE,
privilege => 'resolve'
commit;
end;
Assign ACL
Cool, you granted ASSA to connect and resolve, but you have not defined to which resources he is allowed to connect:
begin
dbms_network_acl_admin.assign_acl(
acl => 'utl_mail.xml',
host => '192.160.170.10'
commit;
end;
I configured utl_mail in other computer at the first time, in virtual machine, in a server, with windows server 2000 and it's working without problems.
The problem is in this computer, with windows xp. I can`t send emails despite configuring UTL_MAIL.
Danny Lima
EcuadorDear UDO
i dont think that the code is bad, i have the same code in my virtual machine in PC server with Windows server 2003 and that's works.
In my pc Server:
create or replace TRIGGER "AUTO"
after insert on qr
for each row
declare
/* auto_Nivel Variable que tomará el campo nivel del Empleado que Administre el Reclamo*/
auto_nivel number;
/*auto_mail_e y auto_mail_s Variable que tomará el campo del correo del Empleado que Administre el Reclamo y de
su superior respectivamente*/
auto_mail_e varchar2(30);
auto_mail_s varchar(30);
/*auto_responsable variable que tomará el campo cedula_empleado de la tabla QR*/
auto_responsable varchar2(30):=:new.cedula_empleado;
/*auto_n_empleado variable que tomará el nombre y apellido del empleado que Administre el Reclamo*/
auto_n_empleado varchar2(60);
/*auto_n_cliente variable que tomará el nombre y apellido del Cliente que solicitó la hoja de servicio*/
auto_n_cliente varchar2(60);
/*auto_CRM variable que tomará el correo electrónico de CRM*/
auto_CRM varchar2(30);
/*a variable que almacenará correo electrónicos*/
a varchar2(120);
/*a variable que almacenará el ID del empleado causante del reclamo*/
auto_causante varchar2(30):=:new.empleado_causante;
/*a variable que almacenará el correo electrónico del empleado causante del reclamo*/
auto_causante_mail varchar2(30);
/*ori_aux variable que almacenará el origen perteneciente a talleres, cuya recepción de Reclamos tiene
una condición especial*/
ori_aux number;
ori number:=:new.origen;
begin
select c.nombre||' '||c.apellido into auto_n_cliente
from cliente c where c.id=:new.cedula_cliente;
IF :new.QUEJA_RECLAMO='QUEJA' THEN
select e.email into auto_crm
from empleados e where e.perfil='CRM';
utl_mail.send(sender => '[email protected]',
recipients => auto_crm,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' queja por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
ELSE
Select e.nivel into auto_nivel
from empleados e where e.id=auto_responsable;
select e.nombre||' '||e.apellido into auto_n_empleado
from empleados e where e.id=auto_responsable;
SELECT O.ORIGEN_MAYOR INTO ORI_AUX
FROM ORIGEN O WHERE :NEW.ORIGEN=O.ID;
/*Inserción de Datos en la tabla Seguimiento*/
insert into seguimiento
(id_ss,fecha_seguimiento,escalado_a,estado)
values
(:new.ss,:new.fecha,auto_responsable,'CASO ABIERTO');
/*Proceso si el Origen del reclamo pertenece a Talleres*/
if ori_aux=22 THEN
select e.email into auto_causante_mail
from empleados e where e.id=auto_causante;
select e.email into auto_crm
from empleados e where e.perfil='CRM';
a:=auto_causante_mail||',[email protected],'||auto_crm;
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.empleado_causante||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
select e.email into auto_mail_e
from empleados e where e.id=auto_responsable;
a:=auto_mail_e;
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
if ori=2 then
utl_mail.send(sender => '[email protected]',
recipients => '[email protected],[email protected],[email protected]',
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.empleado_causante||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
end if;
else
/*Proceso si empleado que administrará el reclamo es de nivel diferente de 1*/
if auto_nivel <> 1 then
/*Asignacióna del correo del Empleado que Administre el Reclamo y de su superior respectivamente
a las variables auto_mail_e y auto_mail_s también respectivamente*/
select e.email, x.email into auto_mail_e, auto_mail_s
from empleados e, empleados x
where e.id=auto_responsable and e.dependencia=x.id;
/*Asignación de los correos Empleado que Administre el Reclamo, de su superior
y de [email protected] respectivamente*/
a:=auto_mail_e||','||auto_mail_s||',[email protected]';
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
else
/*Proceso si empleado que administrará el reclamo es de nivel 1*/
/*Asignación del correo del empleado que administrará el reclamo*/
select e.email into auto_mail_e
from empleados e where e.id=auto_responsable;
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
a:=auto_mail_e||',[email protected]';
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
end if;
end if;
end if;
end auto;
I can send emails with this code without problems
, but just in my virtual machine.
I compare the code that is in my pc with Windows xp where I have the problem and its the same code, but that code doesn`t work and I get
problems when I send the email.
In my pc with windows XP
create or replace trigger "AUTO"
after insert on qr
for each row
declare
/* auto_Nivel Variable que tomará el campo nivel del Empleado que Administre el Reclamo*/
auto_nivel number;
/*auto_mail_e y auto_mail_s Variable que tomará el campo del correo del Empleado que Administre el Reclamo y de
su superior respectivamente*/
auto_mail_e varchar2(30);
auto_mail_s varchar(30);
/*auto_responsable variable que tomará el campo cedula_empleado de la tabla QR*/
auto_responsable varchar2(30):=:new.cedula_empleado;
/*auto_n_empleado variable que tomará el nombre y apellido del empleado que Administre el Reclamo*/
auto_n_empleado varchar2(60);
/*auto_n_cliente variable que tomará el nombre y apellido del Cliente que solicitó la hoja de servicio*/
auto_n_cliente varchar2(60);
/*auto_CRM variable que tomará el correo electrónico de CRM*/
auto_CRM varchar2(40);
/*a variable que almacenará correo electrónicos*/
a varchar2(120);
/*a variable que almacenará el ID del empleado causante del reclamo*/
auto_causante varchar2(30):=:new.empleado_causante;
/*a variable que almacenará el correo electrónico del empleado causante del reclamo*/
auto_causante_mail varchar2(40);
/*ori_aux variable que almacenará el origen perteneciente a talleres, cuya recepción de Reclamos tiene
una condición especial*/
ori_aux number;
ori number:=:new.origen;
begin
select c.nombre||' '||c.apellido into auto_n_cliente
from cliente c where c.id=:new.cedula_cliente;
IF :new.QUEJA_RECLAMO='QUEJA' THEN
select e.email into auto_crm
from empleados e where e.perfil='CRM';
utl_mail.send(sender => '[email protected]',
recipients => auto_crm,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' queja por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
ELSE
Select e.nivel into auto_nivel
from empleados e where e.id=auto_responsable;
select e.nombre||' '||e.apellido into auto_n_empleado
from empleados e where e.id=auto_responsable;
SELECT O.ORIGEN_MAYOR INTO ORI_AUX
FROM ORIGEN O WHERE :NEW.ORIGEN=O.ID;
/*Inserción de Datos en la tabla Seguimiento*/
insert into seguimiento
(id_ss,fecha_seguimiento,escalado_a,estado)
values
(:new.ss,:new.fecha,auto_responsable,'CASO ABIERTO');
/*Proceso si el Origen del reclamo pertenece a Talleres*/
if ori_aux=22 THEN
select e.email into auto_causante_mail
from empleados e where e.id=auto_causante;
select e.email into auto_crm
from empleados e where e.perfil='CRM';
a:=auto_causante_mail||',[email protected],'||auto_crm;
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.empleado_causante||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
select e.email into auto_mail_e
from empleados e where e.id=auto_responsable;
a:=auto_mail_e;
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
if ori=2 then
utl_mail.send(sender => '[email protected]',
recipients => '[email protected],[email protected],[email protected]',
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.empleado_causante||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
end if;
else
/*Proceso si empleado que administrará el reclamo es de nivel diferente de 1*/
if auto_nivel <> 1 then
/*Asignacióna del correo del Empleado que Administre el Reclamo y de su superior respectivamente
a las variables auto_mail_e y auto_mail_s también respectivamente*/
select e.email, x.email into auto_mail_e, auto_mail_s
from empleados e, empleados x
where e.id=auto_responsable and e.dependencia=x.id;
/*Asignación de los correos Empleado que Administre el Reclamo, de su superior
y de [email protected] respectivamente*/
a:=auto_mail_e||','||auto_mail_s||',[email protected]';
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
else
/*Proceso si empleado que administrará el reclamo es de nivel 1*/
/*Asignación del correo del empleado que administrará el reclamo*/
select e.email into auto_mail_e
from empleados e where e.id=auto_responsable;
/*Proceso de Envío de Correo a los destinatarios almacenados en la variable a*/
a:=auto_mail_e||',[email protected]';
utl_mail.send(sender => '[email protected]',
recipients => a,
subject => 'DATASIERRA PQR-CRM',
message => 'DATASIERRA PQR-CRM'||CHR(10)||'Reclamo '||:new.ss||CHR(10)||:new.cedula_empleado||CHR(10)||auto_n_empleado||CHR(10)||''||CHR(10)||auto_n_cliente||' Numero de Cedula: '||:new.cedula_cliente||' reclamo por: '||CHR(10)||''||CHR(10)||:new.descripcion||CHR(10)||''||CHR(10)||SYSDATE);
end if;
end if;
end if;
end auto;
Both of them are the same, I dont know what happen.! -
Ora-29279: SMTP permanent error Unbalanced ' '
Dear Sirs
Sorry for my bad english; I have a problem when I send email in Oracle Express Aplication Release 11.2.0.2.0, I get this mistake ora-29279: SMTP permanent error <[email protected].. Unbalanced '>' and I don`t know what happen. I configure UTL_MAIL in this way:
[host@oracle]$ cd $ORACLE_HOME/rdbms/admin
[host@oracle]$sqlplus / as sysdba
SQL> @utlmail
SQL> @utlsmtp
SQL> @prvtmail.plb
SQL> GRANT EXECUTE ON utl_mail TO PUBLIC;
SQL> GRANT EXECUTE ON utl_smtp TO PUBLIC;
SQL> alter system set smtp_out_server='192.168.170.10' scope=both;
ACL: Access Control List
in White Horses Blog
Create ACL and privileges
Now first create an ACL as SYS (or any other user with DBMS_NETWORK_ACL_ADMIN execute granted), this will hold the privileges. You can add as many privileges as you like to this file, but I would recommend to split privileges in the ACL to specific tasks or users. You must create an ACL with at least one privilege, so lets start with the ‘connect’ privilege for user ASSA, (also a role can be added as principal):
begin
dbms_network_acl_admin.create_acl (
acl => 'utl_mail.xml',
description => 'Allow mail to be send',
principal => 'ASSA',
is_grant => TRUE,
privilege => 'connect'
commit;
end;
Add Privilege
Great, now that the ACL is created, you can add more privileges like the ‘resolve’ privilege:
begin
dbms_network_acl_admin.add_privilege (
acl => 'utl_mail.xml',
principal => 'ASSA',
is_grant => TRUE,
privilege => 'resolve'
commit;
end;
Assign ACL
Cool, you granted ASSA to connect and resolve, but you have not defined to which resources he is allowed to connect:
begin
dbms_network_acl_admin.assign_acl(
acl => 'utl_mail.xml',
host => '192.160.170.10'
commit;
end;
I configured utl_mail in other computer at the first time, in virtual machine, in a server, with windows server 2000 and it's working without problems.
The problem is in this computer, with windows xp. I can`t send emails despite configuring UTL_MAIL.
Danny Lima
EcuadorIt is a mail server error, telling you it does not like the data your code is passing to it. Nothing to do with Oracle, ACLs or configuration settings.
Everything to do with your code passing incorrectly formatted data to the mail server - and the mail server throwing an error back at your code.
Maybe you are looking for
-
Hi I'm recently having a problem when opening a workbook in BEx Analyzer. This never used to be a problem, however when opneing it now I get following error message: Program error in class SAPMSSY1 method : UNCAUGHT_EXCEPTION System error in program
-
How to post idoc from r/3 to xi
hi experts i have one doubt abt posting idoc from r/3 to xi how to post for vendor master idoc for sales order idoc for purchase order idoc for delivery idoc is there any inbuilt posting prgms r there or we have to write the prms. please cle
-
My Maps in Iphone 4 IOS 6 are not working It just gives an error message when I try to search the route . In IOS 5,its working fine,
-
ITunes running set up multiple times
Hi, Does anyone know why iTunes would run through set up without a downloaded update? My iTunes runs though the set up process many, many times. Since I've been keeping track of the set ups, it has run 11 times with only one of those times being with
-
HT204088 Unable to redeem my card or acces my account.
Unable to redeem card or access my iTunes account... Just downloaded the newest version of iTunes and now I cannot do these things...