Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

fix E-MAIL data (table ADRP or ADR6)

Former Member
0 Kudos

Hello all,

We work with a Z transaction called ZSOST (copy from SOST) which sends e-mail via internet for a user e-mail address.

The ZOST is not sending the e-mail for one specific user because the user e-mail address is not correct. We need to find where E-MAIL data was registered (the transaction) and then modify for the right address.

It was verified that ZSOST is picking up the e-mail address data from one of tables bellow:

- <b>table ADRP</b> (field NAME_LAST or field NAME_TEXT)

or

- <b>table ADR6</b> (field SMTP_ADDR).

I have to find out from which transaction (probably any transaction that holds master record) is being registered the e-mail address information.

I have searched but I have not gotten any success. Please, can anyone help me?

Many Thanks and Rgds,

Barbara

1 ACCEPTED SOLUTION

former_member235056
Active Contributor
0 Kudos

Hi,

Steps to perform in SAP:

1. Transaction SM59 – Setup an RFC Destination for the execution of the email transfer

a. Name: Internet Mail Gateway

b. Connection Type: T

c. Description: Internet Mail Gateway

d. Activation Type: Start

e. Explicit host:

i. Program: c:\<dir>\mlunxsnd (I used c:\sapmail)

ii. Target Host: <Server_Name>

f. (MENU) Destination -> Gateway Options

i. Gateway Host: < Server_Name>

ii. Gateway Service: sapgw00

iii.<OK>

g. SAVE

2. Transaction SCOT – Setup a default domain for your system

a. (MENU) Settings -> Default Domain

i. <Default_domain> (i.e. John.Doe@company.com, Domain – company.com)

ii. This setting gives a default to any user who does not have their email address maintained in the system. <user_name>@<default_domain>

3. Transaction SCOT – Setup of the Node for queuing the emails before transfer to Exchange

a. Click on “INT” -> Create button

b. Give Default name (I choose EXCHG, as this was the node type for the Exchange Connector)

c. Give Description

d. Assign the RFC Destination previously created (Internet Mail Gateway)

e. Node: “Internet”

f. Address area: *

g. Supported address Types:

i. All formats except the fllw

ii. ALI, OBJ, OTF, SCR, URL

h. Choose Ok and Save

4. Transaction SCOT – Setup a job to execute the send process on the queue.

a. (MENU) View -> Jobs

i. Select the Create Button

ii. Job Name: SAPConnect

iii. Put Cursor on Variant: SAP&CONNECTINT *As you created an INT Node, you need to run the variant for all of the INT sending. You can select SAP&CONNECTALL, but if you are not using any other node types, you can run with SAP&CONNECTINT.

iv. Select: Schedule Job Button

v. Schedule job for a periodic run – approx. every 15 minutes

vi. Save

<b>5. Transaction SU01 – Maintain each user’s email address</b>

a. Select users who require the ability to email from SAP

b. Under the address tab, in SU01, maintain their email address.

Steps to perform on the SAP system (operating System):

1. Create a directory for the SAP programs.

a. Create directory c:\sapmail (Directory can be anything)

b. Unpack the ML*.CAR file from SAP’s website

c. Alternatively, copy the ML* files from /usr/sap/../run/ directory. This ensures version compatibility with your SAP instance.

2. Create the directories for your “sendmail” program

a. http://emailrelay.sourceforge.net/

i. Download the emailrelay program

b. Create directory c:\winnt\spool\emailrelay

i. Unpack the contents of the emailrelay zip into this directory

c. create Directory c:\reskit (Used to make the emailrelay program run as a service

i. http://www.tacktech.com/display.cfm?ttid=197

1. www.tacktech.com had some great instructions for creating a service on the NT side. (Thank you Tacktech)

2. Use SRVANY to create the services, as documented below.

d. Open command prompt

e. Follow instructions for creating a service

i. cd \reskit

ii. execute c:\reskit\instsrv.exe "<SERVICE_NAME_Engine>" c:\reskit\srvany.exe

1. This service is the “engine”

iii. execute c:\reskit\instsrv.exe "<SERVICE_NAME_Send_Process>" c:\reskit\srvany.exe

1. This service is the “send process”

iv. Modify the registry to represent the two new services

v. View instructions for Parameters and Application Creation under the services in the registry

vi. Command lines should be as follows:

1. <SERVICE_NAME_Engine> - c:\winnt\spool\emailrelay\emailrelay.exe --as-server --no-daemon

2. <SERVICE_NAME_Send_Process> - c:\winnt\spool\emailrelay\emailrelay.exe --no-daemon –-hidden --forward-to (your_mailhost):SMTP --poll 5

vii. Start the services using service mgr.

f. cmd prompt cd \sapmail

g. mlsomadm c:\sapmail\mailgw.ini (see below)

3. Create a mailgw.ini file (This file is used by the mlunxsnd program)

a. Open a command prompt

b. Change to the directory c:\sapmail

c. Run command mlsomadm c:\sapmail\mailgw.ini

i. This creates the parameter file for the send process.

d. MAILGW.INI entries

i. System Name: [SID]

ii. Client: [000]

iii. Username: [MAILADM] – no user required, as this is not being used for your connection

iv. Password: [*******] – leave empty

v. Language: [E]

vi. Load Balancing: [N]

vii. Hostname: [app_server_name]

viii. System Number: [00]

ix. Gateway Hostname: [ ] – you do not have to specify, it will use the default

x. Gateway Service: [ ] – default will be used

xi. Use SAP Router: [N]

xii. Set Bcc Flag on Env..: [N]

xiii. Trace Level <In..>: 1

xiv. Trace file <In..> c:\sapmail\tracein.txt - Can be where ever you want

xv. Sendmail Command: c:\winnt\spool\emailrelay\submit -–from <SENDER_ADDRESS>

xvi. A warning may come up that says to not use the “–t” flag. IGNORE

xvii. Codepage: [ISO-8859-1]

xviii. Generate Notificat..: [N]

xix. Trace Level <Out..: [1]

xx. Trace File <Out..>: c:\sapmail\traceout.txt - Can be where ever you want

xxi. Update File c:\sapmail\mailgw.ini [Y]

Steps to perform on the Microsoft Exchange System

1. Allow the SAP systems to enter on port 25 to send mails using Microsoft Exchange (SMTP Communication)

[Edit section] Examples

[Edit section] Conclusion

The setup is pretty easy, and hopefully, the steps provided above will get you going quickly. Be sure to get your Email admins to allow you to enter the exchange system via port 25(normally) from your SAP system. Without this piece, your emails will just queue with nowhere to go.

I want to thank Jeff Spray for his ideas, and assistance in setting this up.

Pls reward points.

Regards,

Ameet.

1 REPLY 1

former_member235056
Active Contributor
0 Kudos

Hi,

Steps to perform in SAP:

1. Transaction SM59 – Setup an RFC Destination for the execution of the email transfer

a. Name: Internet Mail Gateway

b. Connection Type: T

c. Description: Internet Mail Gateway

d. Activation Type: Start

e. Explicit host:

i. Program: c:\<dir>\mlunxsnd (I used c:\sapmail)

ii. Target Host: <Server_Name>

f. (MENU) Destination -> Gateway Options

i. Gateway Host: < Server_Name>

ii. Gateway Service: sapgw00

iii.<OK>

g. SAVE

2. Transaction SCOT – Setup a default domain for your system

a. (MENU) Settings -> Default Domain

i. <Default_domain> (i.e. John.Doe@company.com, Domain – company.com)

ii. This setting gives a default to any user who does not have their email address maintained in the system. <user_name>@<default_domain>

3. Transaction SCOT – Setup of the Node for queuing the emails before transfer to Exchange

a. Click on “INT” -> Create button

b. Give Default name (I choose EXCHG, as this was the node type for the Exchange Connector)

c. Give Description

d. Assign the RFC Destination previously created (Internet Mail Gateway)

e. Node: “Internet”

f. Address area: *

g. Supported address Types:

i. All formats except the fllw

ii. ALI, OBJ, OTF, SCR, URL

h. Choose Ok and Save

4. Transaction SCOT – Setup a job to execute the send process on the queue.

a. (MENU) View -> Jobs

i. Select the Create Button

ii. Job Name: SAPConnect

iii. Put Cursor on Variant: SAP&CONNECTINT *As you created an INT Node, you need to run the variant for all of the INT sending. You can select SAP&CONNECTALL, but if you are not using any other node types, you can run with SAP&CONNECTINT.

iv. Select: Schedule Job Button

v. Schedule job for a periodic run – approx. every 15 minutes

vi. Save

<b>5. Transaction SU01 – Maintain each user’s email address</b>

a. Select users who require the ability to email from SAP

b. Under the address tab, in SU01, maintain their email address.

Steps to perform on the SAP system (operating System):

1. Create a directory for the SAP programs.

a. Create directory c:\sapmail (Directory can be anything)

b. Unpack the ML*.CAR file from SAP’s website

c. Alternatively, copy the ML* files from /usr/sap/../run/ directory. This ensures version compatibility with your SAP instance.

2. Create the directories for your “sendmail” program

a. http://emailrelay.sourceforge.net/

i. Download the emailrelay program

b. Create directory c:\winnt\spool\emailrelay

i. Unpack the contents of the emailrelay zip into this directory

c. create Directory c:\reskit (Used to make the emailrelay program run as a service

i. http://www.tacktech.com/display.cfm?ttid=197

1. www.tacktech.com had some great instructions for creating a service on the NT side. (Thank you Tacktech)

2. Use SRVANY to create the services, as documented below.

d. Open command prompt

e. Follow instructions for creating a service

i. cd \reskit

ii. execute c:\reskit\instsrv.exe "<SERVICE_NAME_Engine>" c:\reskit\srvany.exe

1. This service is the “engine”

iii. execute c:\reskit\instsrv.exe "<SERVICE_NAME_Send_Process>" c:\reskit\srvany.exe

1. This service is the “send process”

iv. Modify the registry to represent the two new services

v. View instructions for Parameters and Application Creation under the services in the registry

vi. Command lines should be as follows:

1. <SERVICE_NAME_Engine> - c:\winnt\spool\emailrelay\emailrelay.exe --as-server --no-daemon

2. <SERVICE_NAME_Send_Process> - c:\winnt\spool\emailrelay\emailrelay.exe --no-daemon –-hidden --forward-to (your_mailhost):SMTP --poll 5

vii. Start the services using service mgr.

f. cmd prompt cd \sapmail

g. mlsomadm c:\sapmail\mailgw.ini (see below)

3. Create a mailgw.ini file (This file is used by the mlunxsnd program)

a. Open a command prompt

b. Change to the directory c:\sapmail

c. Run command mlsomadm c:\sapmail\mailgw.ini

i. This creates the parameter file for the send process.

d. MAILGW.INI entries

i. System Name: [SID]

ii. Client: [000]

iii. Username: [MAILADM] – no user required, as this is not being used for your connection

iv. Password: [*******] – leave empty

v. Language: [E]

vi. Load Balancing: [N]

vii. Hostname: [app_server_name]

viii. System Number: [00]

ix. Gateway Hostname: [ ] – you do not have to specify, it will use the default

x. Gateway Service: [ ] – default will be used

xi. Use SAP Router: [N]

xii. Set Bcc Flag on Env..: [N]

xiii. Trace Level <In..>: 1

xiv. Trace file <In..> c:\sapmail\tracein.txt - Can be where ever you want

xv. Sendmail Command: c:\winnt\spool\emailrelay\submit -–from <SENDER_ADDRESS>

xvi. A warning may come up that says to not use the “–t” flag. IGNORE

xvii. Codepage: [ISO-8859-1]

xviii. Generate Notificat..: [N]

xix. Trace Level <Out..: [1]

xx. Trace File <Out..>: c:\sapmail\traceout.txt - Can be where ever you want

xxi. Update File c:\sapmail\mailgw.ini [Y]

Steps to perform on the Microsoft Exchange System

1. Allow the SAP systems to enter on port 25 to send mails using Microsoft Exchange (SMTP Communication)

[Edit section] Examples

[Edit section] Conclusion

The setup is pretty easy, and hopefully, the steps provided above will get you going quickly. Be sure to get your Email admins to allow you to enter the exchange system via port 25(normally) from your SAP system. Without this piece, your emails will just queue with nowhere to go.

I want to thank Jeff Spray for his ideas, and assistance in setting this up.

Pls reward points.

Regards,

Ameet.