Error... trying to backup files from remote server
I've tried to backup files from one server (client installed) to tape drive on the administrative server (administrative, media, client) but get an error.
Backup of administrative server to the same media family was successful. What can be wrong?
2014/09/29.12:41:47 Transcript for job admin/14.1 running on 1-prim
2014/09/29.12:41:47
Backup started on Mon Sep 29 2014 at 12:43:24
Volume label:
Volume tag: ABC028
Volume UUID: da584616-2537-1032-990c-ae2b164578ea
Volume ID: test_media-000001
Volume sequence: 1
Volume set owner: root
Volume set created: Tue Sep 23 18:10:59 2014
Volume set expires: Tue Oct 07 18:10:59 2014
Media family: test_media
Original UUID: da584616-2537-1032-990c-ae2b164578ea
Archive label:
File number: 3
File section: 1
Owner: root
Client host: prgrc01
Backup level: 0
S/w compression: no
Archive created: Mon Sep 29 12:43:24 2014
Encryption: off
NDMP_MOVER_LISTEN failed because a listen socket couldn't be created.
The error reported was "host not found (FSP network database manager)".
Error: can't tell NDMP mover on 1-prim to listen - I/O error (NDMP client)
Backup statistics:
status 23
devices Drive1
devices 1
volumes test_media-000001
voltags ABC028
file 3
host prgrc01
encryption off
start_time Mon Sep 29 2014 at 12:43:24 (1411980204)
end_time Mon Sep 29 2014 at 12:43:32 (1411980212)
backup_time Mon Sep 29 2014 at 12:43:24 (1411980204)
entries_scanned 0
kbytes_scanned 0
entries_excluded 0
entries_skipped 0
mount_points_skipped 0
files 0
directories 0
hardlinks 0
symlinks 0
sparse_files 0
filesys_errors 0
unknown_type 0
file_kbytes 0
dev_kbytes 6
dev_iosecs 0
dev_iorate 7.2 KB/S
wrt_iosecs 8
wrt_iorate 896.0 B/S
physical_blks_written 0
write_errors 0
physical_blks_read 0
read_errors 0
error_rate 0%
path / incomplete
I've resolved the problem. There was a mystake in client host name.
Similar Messages
-
Error occurred while downloading files from Administration Server...
Hi guys,
If i already have my application deployed and exploded in ../tmp/_WL_user , when I restart the managed server it will try to download again the files from the upload directory in the Administration Servers? (I'm using stage mode).
Sometimes I got the following error:
Caused By: java.io.IOException: [DeploymentService:290066]Error occurred while downloading files from Administration Server for deployment request "0". Underlying error is: "null"
and I already have the war exploded in /tmp/_WL_user
the staging mode is not only for the first deployment? when i don't have the war exploded in /tmp/_WL_user?
I've some confusion related to the process or deployment/startup of the managed servers.
ThanksHi,
when you get following error * DeploymentService:290066 * then that means
A service on the machine is preventing the WebLogic Server remote instance from downloading the configuration file. This can be Hosts Intrusion Prevention (HIPS) agents or any other agent causing this issue.
Disable the agent interfering with the download process to fix this issue.
Regards,
Kal -
HOw to delete files from remote server?
Hi,
I want to delete files from a directory on remote server.
I use the following command to delete on current server:
find $srcdir -mtime +90 -name "COR*.txt" -exec rm -f {} \;
Now, how can I delete files from remote server ?
Thanks!
YoginiSome possible options:
1. There exists SSH implementation for Windows.
2. You can make a workaround. You can setup share for specific/wanted directory.
Then you can mount it on Linux machine and execute command localy and delete files "localy" in mounted directory.
3. You can setup FTP server on Windows machine and do that remotely via FTP commands. -
Using scp to copy files from remote server to mac from a newbie
Hi am a new poster to this forum and getting (re)acquainted with the unix world using terminal on the Mac. I am part of webteam for a large website run by a nonprofit where I have administrative access. I hope that this forum is the correct venue for my question.
The other day I used terminal tsch to logg onto a remote server where I have admin privaleges. One of the other admins and I were in the process of experimenting with using either rsync or scp to "backup" the server. We are experimenting with different backup strategies over and above those supplied by our web host. After finding out how to open port 22 on my modem and setting services in sharing to allow for remote log on, I logged on to the remote server and ran this command (suggested by another admin):
scp -r -p -v /remotefolder [email protected]:/Users/drktyler/Documents/serverBU/
Unfortunately I had severely underestimated the amount of time it would take to perform scp and needed to terminate the scp job. For example, I only got 100 MB onto my Mac in one hour (normally takes about 6 mintues to download a 100 MB file from the internet) I tried to kill the job by doing:
ctrl -z
ls ps
kill (scp pid #)
This did not work. And I forgot about trying ctrl-c <blush>
I was able to exit my session on the remote server which "exited" the scp job.
Oh, before running scp, I did try rsync and it did not work. Unfortunately, I had not set my terminal session to an unlimited buffer size, so the early part of my session rolled off the terminal screen. This means I have no idea what the error was.
This morning the other admin was performing some backups on the remote server and noticed that there was a an unexplained directory on the remote server named:
mymacuserid
It had what he called some rpms. I am not exactly sure what a rpms cache files are, but I think that rpms has some relatationship to the RPM package manager used by many linux systems. I could not account for how the mymacuserid directory got on the remote server because I did not put it there and my log in id to the remote server bears no resemblance to my Mac user id.
We don't believe that this directory did any harm to the remote server, but I sure as heck would like to know how it got there.
My question is if there was something about my scp command that
(1) created this "temporary" mymacuserid directory on the remote server
(2) did the way I ended the scp job by exiting the terminal mean that this temporary directory was not "cleaned up."?
(3) what other options might have been available to me to kill the job and clean up after the job? ctrl-c while logged onto the remote server? opening up a second terminal window and killing the ssh job?
(4) is scp normally that slow?
My Mac: Mac Mini, 1.66 GHz Intel Core Duo, Memory: 1.5 GB 667 MHz DDR2 SDRAM, Mac OS 10.4.8
Remote server: CPU AuthenticAMD, AMD Athlon(TM) XP 2600+
Version psa v8.1.1_build81070716.12 os_CentOS 4.2
OS Linux 2.6.9-55.0.2.EL {CentOS is built from Red Hat Enterprise Linux}
Respectfully yours,
treehugger from njJ.V. Thanks so much for your very helpful response!
The other admin who was trying scp over the weekend also reported that the job ran very slowly, so I suspect the slow response time may be on the remote server end. I do appreciate knowing that you have gotten 80% of your advertised DSL speed with scp.
Thank-you for being so polite and gentle in your response. No I did not know that if the remote patname has white space in it, that I need to quote the whole path and escape any white space with preceding backslashes as you showed in your rsync example.
Finally, as for the rogue elements being left on the server, I figured out that these rogue elements were left on the server the day before I did the aborted scp job because I had to quit the terminal in the middle of an active rsync job while logged onto the remote terminal. When I went onto the server this morning, I checked the timestamps on the rogue files and the timestamps match up.
The other admin has finally succeeded in doing a full server back-up (in addition to the back-up using the back-up utility provided by our web host). So, for the moment we are in pretty good shape. Of course, I'm not sure that I could replicate what he did. <shrug>
Thanks again. I'm glad I posted on this forum as I have always learned a lot by reading the apple forums I suspect that I will be posting again.
T.H.
P.S. Please forgive me for not including copies of your original message in my reply. There is probably a setting that I need to change. -
Error while reading excel file from application server into internal table.
Hi experts,
My requirement is to read an excel file from application server into internal table.
Hence I have created an excel file fm_test_excel.xls in desktop and uploaded to app server using CG3Z tcode (as BIN file type).
Now in my program I have used :
OPEN DATASET v_filename FOR INPUT IN text mode encoding default.
DO.
READ DATASET v_filename INTO wa_tab.
The statement OPEN DATASET works fine but I get a dump (conversion code page error) at READ DATASET statement.
Error details:
A character set conversion is not possible.
At the conversion of a text from codepage '4110' to codepage '4103':
- a character was found that cannot be displayed in one of the two
codepages;
- or it was detected that this conversion is not supported
The running ABAP program 'Y_READ_FILE' had to be terminated as the conversion
would have produced incorrect data.
The number of characters that could not be displayed (and therefore not
be converted), is 445. If this number is 0, the second error case, as
mentioned above, has occurred.
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_CONVERSION_CODEPAGE', was not
caught and
therefore caused a runtime error.
The reason for the exception is:
Characters are always displayed in only a certain codepage. Many
codepages only define a limited set of characters. If a text from a
codepage should be converted into another codepage, and if this text
contains characters that are not defined in one of the two codepages, a
conversion error occurs.
Moreover, a conversion error can occur if one of the needed codepages
'4110' or '4103' is not known to the system.
If the conversion error occurred at read or write of screen, the file
name was '/usr/sap/read_files/fm_test_excel.xls'. (further information about
the file: "X 549 16896rw-rw----201105170908082011051707480320110517074803")
Also let me know whether this is the proper way of reading excel file from app server, if not please suggest an alternative .
Regards,
KarthikHi,
Try to use OPEN DATASET v_filename FOR INPUT IN BINARY mode encoding default. instead of OPEN DATASET v_filename FOR INPUT IN text mode encoding default.
As I think you are uploading the file in BIN format to Application server and trying to open text file.
Regards,
Umang Mehta -
Error in Reading the file from Application Server
Hi,
This Error is regarding one of my interface, the issue is that , the interface reads data from file in bunch suppose 100 records at a time , then processes those records and once finished go for next 100 records .
Noe the error is that , the process takes place till 500 records correctly but when it went to fetch for next 100 i.e fom 501 to 600 it selects only 501 to 583 .
this records has been processed successfully but the job finished there only
but the file contains 788 records
When the same file has been run in other server it ran successfully without such error .
Can you please suggest how to resolve the issueHi,
Try to manually download the file from application server using standard transactions, and than check how many records are you able to download from app. server.
I guess there might be something wrong with the format of 583rd record, which makes sap assume that the file has come to an end.
Hope this will help you.
Regards,
Vinit... -
Error while uploading the file from Allpcation server in LSMW-7th step
Hi Experts,
what should be the specific CODE PAGE should be maintained while uploading the file from application server in LSMW-7th Step
Thanks in advance,
KSRHi
I mean that there is any seperate CODE PAGE which comes at the bottom of screen while uploading the file from the application server in 7th step.
Is there any specific CODE PAGE to be maintained...
Thanks in advance
Oarsk -
Error while downloading PDF file from FTP Server
Hi Friends,
I have sent a PDF file with data to FTP , Then i want to check that uploaded pdf file , whether that is correct or not?
for that , i have downloaded that file from FTP and i am trying to open the file . but it is giving this problem .
"There was an error opening the document . The file is damaged and could not be repaired."
will you suggest me regarding this.
thanks in advance.
balaji.T.CALL FUNCTION 'CONVERT_OTFSPOOLJOB_2_PDF'
EXPORTING
SRC_SPOOLID = spoolno
src_spoolid = wa_file-rqident
no_dialog = ' '
DST_DEVICE =
PDF_DESTINATION =
IMPORTING
pdf_bytecount = numbytes
pdf_spoolid = pdfspoolid
OTF_PAGECOUNT =
btc_jobname = jobname
btc_jobcount = jobcount
TABLES
pdf = pdf
EXCEPTIONS
err_no_otf_spooljob = 1
err_no_spooljob = 2
err_no_permission = 3
err_conv_not_possible = 4
err_bad_dstdevice = 5
user_cancelled = 6
err_spoolerror = 7
err_temseerror = 8
err_btcjob_open_failed = 9
err_btcjob_submit_failed = 10
err_btcjob_close_failed = 11.
because of this one PDF internal table is obtained.
OPEN DATASET L_FILENAME FOR OUTPUT in text mode MESSAGE MSG.
LOOP AT pdf.
CONCATENATE pdf-tdformat "Material group
pdf-TDLINE "Basic Material
INTO ITEXT-TLINE ..
APPEND ITEXT.
TRANSFER ITEXT TO L_FILENAME.
ENDLOOP. -
Help! Downloading a file from remote Server
I am currently doing a program for downloading a specified file from the remote server i.e from any website. If the downloading process stops in between due to some problem in the internet connection, then my program needs to start the downloading the file again to the local directory from where it was left.
My idea is that, getting the size of the remote file initially when the downloading process starts and if the connection is interrupted, i will check the size of the downloaded file in the local directory with the remote file size. If the remote file size is greater than the localfile size, i need to start downloading the file where it was left i.e start downloading the next bit from the remote file.
Is there any way to get the contents of the remote file from the specified point say 50th byte from a total file size of 100 kb using java?
which concept to use FtpClient or sockets?
iam a little bit confused!!!!
Please help me.
Thanks in advance.For HTTP you can use this function to open the stream with offset:
InputStream openStream(URL url, long offset) {
try {
URLConnection uc = url.openConnection();
uc.setRequestProperty("Authorization", "Basic " + (new BASE64Encoder()).encode("username:password".getBytes()));
if (offset != 0 && url.openConnection().getHeaderField(0).toUpperCase().startsWith("HTTP/1.1"))
uc.setRequestProperty("Range", "bytes=" + offset + "-");
return new BufferedInputStream(uc.getInputStream());
} catch (MalformedURLException mfURLe) {
System.err.println("Malformed URL in Client Updater. Unable to receive update list: " + mfURLe.getMessage());
} catch (IOException ioe) {
System.err.println("Unable to open input stream: " + ioe.getMessage());
return null;
} -
Read XML files from remote server
Post Author: TomDegetel
CA Forum: Data Integration
This question may look simple to you but I don't see directly how to do this.The idea is to read data from an XML file which is sent to a UNIX directory on a server.When the JobServer is running on my local PC I can configure a flow that reads the file from the local harddisk but if the JobServer is running on another server I don't know how to reach this file.How can I connect from the jobserver to a remote server in order to read an xml file and read its contents into a query ? Thanks, TomPost Author: bhofmans
CA Forum: Data Integration
you have several options :
1) Make sure the directory is accessible to your jobserver via shares. This can even be done between Windows and UNIX using SAMBA or related software.
2) Use ftp to get the file from the remote location and ftp it to a local drive (DI had built-in options to do ftp)
3) In 11.7 we added the possibility to specify an URL for the XML file in stead of a file name. So if you can make the XML file available via a web server on the UNIX machine, this would be another way to access the file. -
Error while compiling JSP file from glassfish server
Hello, I have created a single page with only one text box using Netbeans and Visual Web Pack and deployed it on to Glassfish Build44 server. Deployed okay. But when I try to open the page I get the following error. But the same project when I create on studio creator and deploy to Sun java App Server that comes with creator, it works fine. Any help would be really useful.
Error:
ApplicationDispatcher[MAReports] PWC1231: Servlet.service() for servlet jsp threw exception
org.apache.jasper.JasperException: /Page1.jsp(5,60) PWC6341: According to the TLD, deferred-value is specified for the attribute id of the tag handler com.sun.webui.jsf.component.PageTag, but the argument for the setter method is not a javax.el.ValueExpression.
I have tried 2 diff version of jdk1.5.0_06 and jdk1.5.0_12. No use. It is all running under win env. I saw couple google hits on this error. But no real solution that I could see.
Thanks in Advance.Hi,
I had the same problem i think:
PWC1406: Servlet.service() for servlet Faces Servlet threw exception com.sun.rave.web.ui.appbase.ApplicationException: org.apache.jasper.JasperException: /login.jsp(5,60) PWC6341: According to the TLD, deferred-value is specified for the attribute id of the tag handler com.sun.webui.jsf.component.PageTag, but the argument for the setter method is not a javax.el.ValueExpression at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.cleanup(ViewHandlerImpl.java:559) at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:290) at .............
I work on GlassFish v2 running on ubuntu server, I develop from netbeans 5.5.1 on windows xp.
I resolved the problems in the war file of my application, the lib directory as some library missing, and some seem do not work correctely. I dont know precicely the problemes. but i resolve it copynig and past lib directory from another working project.
The problemes seem to be in the war lib this what i can tell.
sorry for my english
Regards, and good job!!! -
Category ABAP Programming Error
Runtime Errors CONVT_NO_NUMBER
Except. CX_SY_CONVERSION_NO_NUMBER
ABAP Program ZMM_MIGO_GOODS_ISSUE
Application Component Not assigned
Date and Time 26.05.2014 14:28:30
Short Text
"C:\Users\SAP\Desktop\MIGO\MIGO.xlsx" cannot be interpreted as a number
What happened?
Error in the ABAP Application Program
The current ABAP program "ZMM_MIGO_GOODS_ISSUE" had to be terminated because
it has
come across a statement that unfortunately cannot be executed.
Error analysis
An exception has occurred which is explained in more detail below. The
exception is assigned to class 'CX_SY_CONVERSION_NO_NUMBER' and was not caught
in procedure
"%_SEL_SCREEN_P_FNAME_V" "(FORM)", nor was it propagated by a RAISING clause.
Since the caller of the procedure could not have anticipated thisHI CHIRUI,
I have changed and tried but still i a getting the same thing..
otherwise please check this i am using some class method i am not getting short dump,but excel file is not getting uploaded.
REPORT ZMM_MIGO_GOODS_ISSUE NO STANDARD PAGE HEADING.
DATA : BEGIN OF IT_DATA OCCURS 0,
ID(10),
BLDAT(10), " Document Date
BUDAT(10), " Posting Date
REF_DOC_NO(16), " Material Slip No
DEL_NOTE(16), " delivery note
MATNR TYPE MSEG-MATNR, " Material Number
ERFMG(13) TYPE C, " Quantity
BWART TYPE RM07M-BWARTWA, " Movement Type
SOBKZ(1), " Special Stock
WERKS TYPE RM07M-WERKS, " Plant
LGORT TYPE RM07M-LGORT, " Storage Location
PS_POSID TYPE PS_POSID, " WBS Element
COST_CENTER TYPE KOSTL, " cost center
ORDER TYPE AUFNR, " order number
SERNR TYPE RIPW0-SERNR, " Serial Number
END OF IT_DATA,
BEGIN OF IT_HEAD OCCURS 0,
ID(10),
BLDAT(10), " Document Date
BUDAT(10), " Posting Date
REF_DOC_NO(16), " Reference document number
"HEADER_TXT(25), " Header Text
BWART TYPE RM07M-BWARTWA, " Movement Type
END OF IT_HEAD,
BEGIN OF IT_ITEM OCCURS 0,
ID(10),
"ID1(10),
WERKS TYPE RM07M-WERKS, " Plant
LGORT TYPE RM07M-LGORT, " Storage Location
VAL_TYPE TYPE BWTAR_D,
MATNR TYPE MSEG-MATNR, " Material Number
ERFMG(13) TYPE C, " Quantity
CHARG TYPE MSEG-CHARG, " Batch
BWTAR TYPE BWTAR_D,
PS_POSID TYPE PS_POSID, " WBS Element
ERFME TYPE MSEG-ERFME, " Unit
COST_CENTER TYPE KOSTL, " cost center
ORDER TYPE AUFNR, " order number
CUSTOMER TYPE EKUNN, " Account Number of Customer
SERNR TYPE RIPW0-SERNR, " Serial Number
AMOUNT_LC TYPE BAPI_EXBWR,
SOBKZ(1),
END OF IT_ITEM,
HEADER LIKE BAPI2017_GM_HEAD_01,
CODE LIKE BAPI2017_GM_CODE,
ITEMS LIKE BAPI2017_GM_ITEM_CREATE OCCURS 0 WITH HEADER LINE,
SERIAL LIKE BAPI2017_GM_SERIALNUMBER OCCURS 0 WITH HEADER LINE,
RETURN LIKE BAPI2017_GM_HEAD_RET,
RET LIKE BAPIRET2 OCCURS 0 WITH HEADER LINE,
TESTRUN LIKE BAPI2017_GM_GEN-TESTRUN,
IT_TAB TYPE FILETABLE,
GD_SUBRC TYPE I,
L_FILE TYPE RLGRAP-FILENAME,
IT_RAW TYPE TRUXS_T_TEXT_DATA,
COUNT(2) TYPE N,
TEXT_C(30).
DATA: DATA LIKE TABLE OF IT_ITEM WITH HEADER LINE.
DATA: IT_TEMP LIKE TABLE OF IT_ITEM WITH HEADER LINE.
DATA: IT_TEMP1 LIKE TABLE OF IT_ITEM WITH HEADER LINE.
DATA: IT_ITEM1 LIKE TABLE OF IT_ITEM WITH HEADER LINE.
SELECTION-SCREEN: BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
PARAMETERS : P_FILE TYPE RLGRAP-FILENAME.
* p_test AS CHECKBOX.
SELECTION-SCREEN: END OF BLOCK B1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG
EXPORTING
WINDOW_TITLE = 'SELECT FILE'
CHANGING
FILE_TABLE = IT_TAB
RC = GD_SUBRC.
READ TABLE IT_TAB INTO P_FILE INDEX 1.
START-OF-SELECTION.
PERFORM GET_EXCEL_DATA.
PERFORM GET_HEADER_ITEM.
PERFORM UPDATE_DATA.
*& Form GET_EXCEL_DATA
* text
* --> p1 text
* <-- p2 text
FORM GET_EXCEL_DATA .
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
INPUT = P_FILE
IMPORTING
OUTPUT = L_FILE.
CALL FUNCTION 'TEXT_CONVERT_XLS_TO_SAP'
EXPORTING
I_LINE_HEADER = 'X'
I_TAB_RAW_DATA = IT_RAW
I_FILENAME = L_FILE
TABLES
I_TAB_CONVERTED_DATA = IT_DATA
EXCEPTIONS
CONVERSION_FAILED = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM. " GET_EXCEL_DATA
*& Form GET_HEADER_ITEM
* text
* --> p1 text
* <-- p2 text
FORM GET_HEADER_ITEM .
DATA : FLAG(1).
LOOP AT IT_DATA.
CLEAR FLAG.
IF IT_DATA-ID IS NOT INITIAL.
AT NEW ID.
FLAG = 'X'.
ENDAT.
ENDIF.
IF FLAG = 'X'.
MOVE-CORRESPONDING IT_DATA TO IT_HEAD.
APPEND IT_HEAD.
ENDIF.
MOVE-CORRESPONDING IT_DATA TO IT_ITEM.
APPEND IT_ITEM.
ENDLOOP.
DATA[] = IT_ITEM[].
IT_TEMP[] = IT_ITEM[].
IT_TEMP1[] = IT_ITEM[].
ENDFORM. " GET_HEADER_ITEM
*& Form UPDATE_DATA
* text
* --> p1 text
* <-- p2 text
FORM UPDATE_DATA .
DATA : COUNT1(10),
L_QTY TYPE I,
DAT(10).
CONCATENATE SY-DATUM+6(2) '.' SY-DATUM+4(2) '.' SY-DATUM(4) INTO DAT.
LOOP AT IT_HEAD.
ON CHANGE OF IT_HEAD-ID.
CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'
EXPORTING
DATE_EXTERNAL = IT_HEAD-BUDAT
ACCEPT_INITIAL_DATE = 'X'
IMPORTING
DATE_INTERNAL = HEADER-PSTNG_DATE.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'
EXPORTING
DATE_EXTERNAL = IT_HEAD-BLDAT
ACCEPT_INITIAL_DATE = 'X'
IMPORTING
DATE_INTERNAL = HEADER-DOC_DATE.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
MOVE : '2' TO HEADER-VER_GR_GI_SLIP,
'X' TO HEADER-VER_GR_GI_SLIPX.
* IF r1 EQ 'X'.
MOVE '05' TO CODE-GM_CODE.
HEADER-REF_DOC_NO = IT_HEAD-REF_DOC_NO.
"HEADER-HEADER_TXT = IT_HEAD-HEADER_TXT.
* ELSEIF r2 EQ 'X'.
* MOVE '04' TO code-gm_code.
* ELSEIF r3 EQ 'X'.
* MOVE '04' TO code-gm_code.
* ENDIF.
* IF p_test = 'X'.
* MOVE 'X' TO testrun.
* ENDIF.
ENDON.
IT_ITEM1[] = IT_ITEM[].
*delete it_item[] where werks = '' and id = it_head-id.
DELETE ADJACENT DUPLICATES FROM IT_ITEM COMPARING ID MATNR.
LOOP AT IT_ITEM WHERE ID = IT_HEAD-ID.
* ON CHANGE OF it_item-id1.
COUNT1 = COUNT1 + 1.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
INPUT = IT_ITEM-MATNR
IMPORTING
OUTPUT = ITEMS-MATERIAL.
MOVE : IT_ITEM-WERKS TO ITEMS-PLANT,
IT_ITEM-LGORT TO ITEMS-STGE_LOC,
* it_item-lgort1 TO items-move_stloc,
IT_ITEM-CHARG TO ITEMS-BATCH,
* IT_ITEM-VAL_TYPE TO ITEMS-VAL_TYPE,
'FRESH' TO ITEMS-VAL_TYPE,
IT_HEAD-BWART TO ITEMS-MOVE_TYPE,
IT_ITEM-SOBKZ TO ITEMS-SPEC_STOCK,
IT_ITEM-ERFMG TO ITEMS-ENTRY_QNT,
IT_ITEM-ERFMG TO ITEMS-ENTRY_QNT,
* it_item-erfme TO items-entry_uom,
* it_item-sgtxt TO items-item_text,
* it_item-exbwr TO items-amount_lc,
IT_ITEM-PS_POSID TO ITEMS-WBS_ELEM,
IT_ITEM-PS_POSID TO ITEMS-VAL_WBS_ELEM,
"IT_ITEM-CUSTOMER TO ITEMS-CUSTOMER,
IT_ITEM-ERFMG TO L_QTY,
IT_ITEM-AMOUNT_LC TO ITEMS-AMOUNT_LC,
IT_ITEM-COST_CENTER TO ITEMS-COSTCENTER,
IT_ITEM-ORDER TO ITEMS-ORDERID.
* items-SPEC_MVMT = 'R'.
CALL FUNCTION 'CONVERSION_EXIT_ABPSN_INPUT'
EXPORTING
INPUT = ITEMS-WBS_ELEM
IMPORTING
OUTPUT = ITEMS-WBS_ELEM.
CALL FUNCTION 'CONVERSION_EXIT_ABPSN_INPUT'
EXPORTING
INPUT = ITEMS-VAL_WBS_ELEM
IMPORTING
OUTPUT = ITEMS-VAL_WBS_ELEM.
* CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
* EXPORTING
* input = it_item-lifnr
* IMPORTING
* output = items-vendor.
APPEND ITEMS.
* ENDON.
ENDLOOP.
DELETE ADJACENT DUPLICATES FROM IT_TEMP COMPARING ID MATNR.
DELETE IT_TEMP1 WHERE ID <> IT_HEAD-ID.
DELETE IT_TEMP WHERE ID <> IT_HEAD-ID.
DATA: MAT_ITM TYPE MBLPO,
SERNP TYPE SERAIL.
MAT_ITM = '0001'.
LOOP AT IT_TEMP.
SELECT SINGLE SERNP FROM MARC INTO SERNP WHERE MATNR = IT_TEMP-MATNR.
IF SERNP IS NOT INITIAL.
LOOP AT IT_TEMP1 WHERE ID = IT_TEMP-ID AND MATNR = IT_TEMP-MATNR.
* MOVE : it_item1-id TO serial-matdoc_itm,
* MOVE : mat_itm TO serial-matdoc_itm,
SERIAL-MATDOC_ITM = MAT_ITM .
SERIAL-SERIALNO = IT_TEMP1-SERNR.
APPEND SERIAL.
CLEAR IT_ITEM1.
ENDLOOP.
MAT_ITM = MAT_ITM + 1.
ENDIF.
CLEAR IT_TEMP.
ENDLOOP.
CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
EXPORTING
GOODSMVT_HEADER = HEADER
GOODSMVT_CODE = CODE
TESTRUN = TESTRUN
* GOODSMVT_REF_EWM =
IMPORTING
GOODSMVT_HEADRET = RETURN
* MATERIALDOCUMENT =
* MATDOCUMENTYEAR =
TABLES
GOODSMVT_ITEM = ITEMS
GOODSMVT_SERIALNUMBER = SERIAL
RETURN = RET
* GOODSMVT_SERV_PART_DATA =
* EXTENSIONIN =
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
EXPORTING
WAIT = 'X'
* IMPORTING
* RETURN =
IF NOT RETURN IS INITIAL.
WRITE :/ 'Material Document Number Generated: ' ,RETURN-MAT_DOC,RETURN-DOC_YEAR.
ELSE.
LOOP AT RET.
WRITE : RET-TYPE, RET-MESSAGE.
* log-index = sy-index.
* log-matnr = header-material.
* log-message = ret1-message.
* APPEND log.
ENDLOOP.
ENDIF.
REFRESH : ITEMS,RET.
CLEAR : HEADER,RETURN.
CLEAR: TESTRUN ,
RETURN,
ITEMS[],
SERIAL[],
RET[],
HEADER,
IT_TEMP[] ,
IT_TEMP1[].
IT_TEMP[] = DATA[].
IT_TEMP1[] = DATA[].
ENDLOOP.
ENDFORM. " UPDATE_DATA
Regards,
Suresh bheema -
How to download files from Application Server of Unix o.s to local director
Hi All,
I am trying to download files from Apllication server of Unix operating Systems to local file in excel sheet format using a z-program.but whenever I am trying to use OPEN dataset ........
it is showing sy-subrc = 8.
Can I have any clew please.
Thanks in advance,
Regards,
AMEER.Hi Sreekanth,
Thanks a lot for quick reply.I have to download that files from z-program only. I am giving you my code below.
*& Report ZTRAK_DOWNLOAD *
REPORT ZTRAK_DOWNLOAD MESSAGE-ID ZCT .
SELECTION-SCREEN BEGIN OF BLOCK DOWNLOAD WITH FRAME TITLE TEXT1.
PARAMETERS :
SERDIR LIKE RLGRAP-FILENAME DEFAULT '/usr/trak',
LOCDIR LIKE RLGRAP-FILENAME DEFAULT 'C:\Trak'.
SELECTION-SCREEN END OF BLOCK DOWNLOAD .
SELECTION-SCREEN BEGIN OF BLOCK INFO2 WITH FRAME.
SELECTION-SCREEN COMMENT 1(79) TEXT2.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN COMMENT 1(79) TEXT3.
SELECTION-SCREEN END OF BLOCK INFO2 .
SELECTION-SCREEN BEGIN OF BLOCK INFO3 WITH FRAME.
SELECTION-SCREEN COMMENT 1(79) TEXT4.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN COMMENT 1(79) TEXT5.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN COMMENT 1(79) TEXT6.
SELECTION-SCREEN SKIP 1.
SELECTION-SCREEN COMMENT 1(79) TEXT7.
SELECTION-SCREEN SKIP 2.
SELECTION-SCREEN COMMENT 1(79) TEXT8.
SELECTION-SCREEN SKIP 1.
SELECTION-SCREEN COMMENT 1(79) TEXT9.
SELECTION-SCREEN END OF BLOCK INFO3.
*- Internal Table to output data in Excel
DATA: BEGIN OF tab_excel OCCURS 0,
col1(50),
col2(132),
col3(255),
col4(100),
col5(100),
col6(50),
COL7(60),
col8(30),
col9(30),
col10(30),
col11(20),
col12(15),
col13(15),
END OF tab_excel.
DATA: FILE LIKE RLGRAP-FILENAME .
DATA: W_DATASET(80).
INITIALIZATION.
TEXT1 = 'Download Reports'.
TEXT2 = 'The Program downloads the reports generated by Trak'.
TEXT3 = 'Utility from Server to Local PC.'.
TEXT4 = 'Check the following before executing the Program.'.
TEXT5 = ' 1. A valid Server path is provided.'.
TEXT6 = ' 2. A valid Local PC path is provided.'.
TEXT7 = ' 3. Local PC has 10 MB free space.'.
TEXT8 = 'The report can be executed in the forground.'.
TEXT9 =
'The report should be executed after execution of Transaction TRAK'.
AT SELECTION-SCREEN.
IF SERDIR EQ ''.
MESSAGE E001(ZCT).
ENDIF.
IF LOCDIR EQ ''.
MESSAGE E002(ZCT).
ENDIF.
START-OF-SELECTION.
Download ABAP Development Summary Report
FILE = '\ABAP_Report_Developments.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/ABAP_Report_Developments.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download BDC Development Report
FILE = '\BDC_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/BDC_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Development Summary Report
FILE = '\Developments_Summary_Report.XLS' .
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Developments_Summary_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Enhancement Development Report
FILE = '\Enhancement_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Enhancement_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download field exit Development Report
FILE = '\Field_Exit_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Field_Exit_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Frequency & Purpose Report
FILE = '\Frequency_And_Purpose_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Frequency_And_Purpose_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Function Group Developments Report
FILE = '\FunctionGroup_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/FunctionGroup_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Function Module Developments Report
FILE = '\FunctionModule_Developments_Report.XLS' .
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/FunctionModule_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Include Developments Report
FILE = '\Include_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Include_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download UserGroup Developments Report
FILE = '\UserGroup_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/UserGroup_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Modified_Standard_SAP_Objects_Report
FILE = '\Modified_Standard_SAP_Objects_Report.XLS' .
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Modified_Standard_SAP_Objects_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Include Developments Report
*FILE = '\Include_Developments_Report.XLS'.
*CONCATENATE LOCDIR FILE INTO FILE.
*W_DATASET = '/Include_Developments_Report.dat'.
*CONCATENATE SERDIR W_DATASET INTO W_DATASET.
*PERFORM INIT.
Download SAP Script Developments Report
FILE = '\SAP_Scipt_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/SAP_Scipt_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Transaction Developments Report
FILE = '\Transaction_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/Transaction_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download User Exits Developments Report
FILE = '\UserExits_Reports.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/UserExits_Reports.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download ABAP Query Developments Report
FILE = '\ABAPQuery_Developments_Reports.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/ABAPQuery_Developments_Reports.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
Download Functional Area Developments Report
FILE = '\FunctionalArea_Developments_Report.XLS'.
CONCATENATE LOCDIR FILE INTO FILE.
W_DATASET = '/FunctionalArea_Developments_Report.dat'.
CONCATENATE SERDIR W_DATASET INTO W_DATASET.
PERFORM INIT.
MESSAGE S003(ZCT) WITH LOCDIR.
END-OF-SELECTION.
This routine checks whether file exists if yes downloads it to
the Local PC
FORM INIT.
OPEN DATASET W_DATASET FOR INPUT IN TEXT MODE ENCODING DEFAULT.
DO.
IF SY-SUBRC <> 0.
EXIT.
ENDIF.
READ DATASET W_DATASET INTO tab_excel.
APPEND tab_excel.
CLEAR tab_excel.
ENDDO.
PERFORM DOWNLOAD_FILE.
ENDFORM.
This routine downloads the data in an XL format on local PC
FORM Download_File .
CALL FUNCTION 'WS_DOWNLOAD'
EXPORTING
FILENAME = FILE
FILETYPE = 'DAT'
TABLES
DATA_TAB = tab_excel
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_WRITE_ERROR = 2
INVALID_FILESIZE = 3
INVALID_TYPE = 4
NO_BATCH = 5
UNKNOWN_ERROR = 6
INVALID_TABLE_WIDTH = 7
GUI_REFUSE_FILETRANSFER = 8
CUSTOMER_ERROR = 9
OTHERS = 10.
IF sy-subrc <> 0.
message ''. " Error in file transfer
ELSE.
CLEAR TAB_EXCEL.
REFRESH TAB_EXCEL.
FILE = ''.
W_DATASET = ''.
ENDIF.
ENDFORM.
I have created those files in Application Server running in another z-program in background mode.Then I am trying to download those files using above the program.I am creating those trak/Trak files manually and I can able to see those files in A.S level.But when downloading the same files I am facing the problem.
regards,
Ameer -
Reading .txt file from remote using abap?
Hi,
I must read a .txt file from remote server automatically.
I have path and name of .txt file. Remote system asks username and password.
In abap is it possible to give username and password for reading .txt from remote server?
Remote server and sap server are not in same domain.
How can i do that?
Thanks.Hi Cemil ,
You can try using the FM RZL_READ_FILE_REMOTE_SH.
This is an option i found , but i have really not tried it out .
Regadrs
Arun -
How to load jar files from remote location
Hi all,
I am trying to load jar files from remote server, from a servlet which is running on OC4j.
For doing this,First I am getting ClassLoader by using ClassLoader.getSystemClassLoader() and then type casting it to URLClassLoader.
But by doing it I am getting ClassCastException,because oc4j returns oracle.classloader.PolicyClassLoader instead of java.net.ClassLoader.
Appreciate if anyone can tell me how to load remote jar files using oracle.classloader.PolicyClassLoader .
Thanks
HarishHi,
I suppose you know about this, but just in case.
I have used jnpl to load jar files from remote location.
Rowan
Maybe you are looking for
-
Problem after updating to iOS 8.1 on my iPod touch 5th gen
I just want to report to Apple that after updating my iPod Touch 5th Generation to iOS 8.1, my iPod just shuts down by itself from time to time. The only way you can turn it on is by pressing the top right button and the home button at the same time
-
Sort an element out of 2-D array
Hi guys, how to sort an element out of a 2-D array. For example I like to know the value of element in array[0][1]. Solved! Go to Solution.
-
Change where clause filter based on prompt?
Hi, I am trying to change my where clause filter based on a prompt selected. What I want to do logically looks like this - although it doesn't work as it is not valid case statement syntax: select * from table t where t.calc_result_info_key in (case
-
Variables Vs. Parameters
Hello, I'm attempting to call a method (with several parameters) from another class. I've instantiated a new instance of said class, but passing the parameters is something which is posing a bit of difficulty...as the parameter values are determined
-
Using my 160Gb iPod Classic as ext back-up drive
I'm wanting to use my ipod classic as my external back-up since I have 100Gbs of space remaining after sync of my 33 Gb of music/video/audiobook/photos.