PDA

View Full Version : Snddst (*doc) .csv wird nicht als Anhang verschickt



DLCELLE
31-07-07, 09:18
Hallo. Ich generiere per CPYTOIMPF eine .csv Datei und möchte diese anschließend per SNDDST (*DOC) als Anhang verschicken.

Die CSV-Datei wird aber nicht als Anhang verschickt, sondern direkt in die Mail integriert.

Mit einer per Excel erzeugten .csv funktioniert es allerdings problemlos.

Im Forum gibt es zwar eine Menge Beiträge zum Thema SNDDST, hierzu habe ich allerdings nichts gefunden.

Vielen Dank schon mal im Voraus.

TARASIK
31-07-07, 09:43
Hallo,
kommt denn eine Fehlermeldung, so z. B. die CPI9046 ?

DLCELLE
31-07-07, 10:00
Ich bekomme weder bei CPYTOIMPF noch beim SNDDST eine Fehlermeldung.

Der Code schaut folgendermaßen aus:

CPYTOIMPF FROMFILE(file) +
TOSTMF('QDLS/TEST/TEST.CSV') +
MBROPT(*REPLACE) STMFCODPAG(*PCASCII) +
RCDDLM(*CRLF) FLDDLM(';') DECPNT(*COMMA)


SNDDST TYPE(*DOC) TOINTNET((email@adresse.de)) DSTD(TET) MSG(TEST) DOC(test.CSV) FLR(TEST)

TARASIK
31-07-07, 10:04
Hallo,
ich denke das geht gar nicht, denn:

Using the Send Distribution ( SNDDST *DOC ) command to send a document to a user ID and address that will route it through the QSMTPQ distribution queue is not supported. Message CPI9046 with RC0401 (invalid document) results.

The QSMTPQ uses the previous Bridge Client to send simple SMTP messages. It does not support MIME and sends only FFT-type documents. This is a permanent restriction for SNDDST .

TARASIK
31-07-07, 10:27
Hallo,
es gibt da noch einen Parameter im snddst:

If you issue a SNDDST command of a *DOC and the document is in an RFTDCA or RFTAS400 format, there is a parameter on the SNDDST command which determines if the document is sent as an attachment or copied into the message itself.

The parameter that controls this is the SNDFMT (Send Format) parameter (see example below).

If the value of this parameter is *NOTE, the document is copied into the e-mail message. If the value is *NOCHG, the document is sent as an attachment to the e-mail.

Send Distribution (SNDDST)

Type choices, press Enter.

Message . . . . . . . . . . . . *NONE



Confirmation of delivery . . . . *YES *NO, *YES
Sensitivity . . . . . . . . . . *NONE
Content importance . . . . . . . *NORMAL *NORMAL, *LOW, *HIGH
Priority . . . . . . . . . . . . *NORMAL *NORMAL, *HIGH, *LOW
User identifier:
User ID . . . . . . . . . . . *CURRENT Character value, *CURRENT
Address . . . . . . . . . . . Character value
Send format . . . . . . . . . . > *NOTE *NOCHG, *NOTE, *FINALFORM
Document . . . . . . . . . . . . > DICTADD Name, *DOCID
In folder . . . . . . . . . . . > HADLEY

DLCELLE
31-07-07, 10:58
Sobald man einen Dateinamen und Pfad für einen Anhang hinterlegt bekommt man eine Fehlermeldung bei einer anderen Auswahl als *NOCHG.

Der Versand klappt ja auch, sobald ich eine per Excel generierte CSV Datei verschicke. Ich nehme also mal an, dass es irgendwo bei der Erstellung einen Fehler gibt.

Aber schon mal schöne Dank für die schnellen Anworten!

kuempi von stein
31-07-07, 11:20
mh...
Das Problem muss im CPYTOIMPF liegen.
Wir versenden diverse Files per SNDDST *DOC und das klappt.

Mach doch mal den CPYTOIMPF in ein anderes Verzeichnis.
Dann hole die Datei von da mit MOV raus und stelle sie in das zu versendende Verzeichnis

MOV OBJ('/HOME/VZ1/VZ2/TEST.CSV') TODIR('/QDLS/VZ3')
Dann mal ein

CHGDOCD DOC(TEST.CSV) FLR('VZ3') DOCD('TEST')
und dann ein

SNDDST TYPE(*DOC) TOINTNET(('email@adresse.de')) DSTD('TEST') MSG('TEST') USRID(QPGMR MEINEAS400) DOC(TEST.CSV) FLR('VZ3')

Und zwischen den Befehlen immer ein Delay 1

Versuchs mal so bitte.

kuempi

DLCELLE
31-07-07, 11:59
Hat funktioniert, super!!!

Nochmal schönen Dank und euch noch einen schönen Tag!