ABAP statement for converting UTC date/ time to local date/time
Hi
Is there any abap statement or any function module in BW which converts UTC date and UTC
time into local date and local time according to specific country.
Regards,
Kate
Hi,
and to convert the country to a timezone first use: TZ_LOCATION_TIMEZONE
/manfred
Similar Messages
-
GRR2- 4FM-RepPaint(put ABAP code for convert data in field)
Hi,
If somebody know how possible add ABAP code for convert data in some column-field of report (by RepWriter,UserExit,BADI)?
Thanks a lot.Elaborate your question. Not clear ??
-
Adobe offline form with capablity to read data from a local data base.
Hi ,
We have customer requirement for a offline Adobe form which will be used by Sales rep, this form when saved to the local hard disk is required to read data from another local data base available in the laptop and prefill a few fields in the form .
Is this requirement technically feasible using Adobe forms?
Thanks
Srikanth SWell may be it's possible because if you go to the Data View in ALD and create a new Data Connection --> OLEDB database --> Build --> It gives you various options for connecting to different DBs but frankly speaking I have never tried it.
Check the ALD help for more information on the topic.
Using LiveCycle Designer > Working with Data Sources > Connecting to a data source > To create a data connection to an OLE database
Chintan -
Same ABAP statements for SY-SUBRC 0 or 4
Hi,
I have a READ TABLE statement and if the SY-SUBRC is equal to 0 or 4, the same ABAP statements should be giving to both. What would be the most efficient way of writing this? Should I just not check for for the SY-SUBRC?
Thanks,
RTYou can simply check for 0 and 4, or if there is no chance of sy-subrc being anything other 0 or 4, simply don't check it..
clear itab.
read table itab with key....
check sy-subrc = 0
or sy-subrc = 4.
Regards,
Rich Heilman -
ABAP statement for JDBC connection to SQL server
Hi Gurus,
i need to connect a WebDynpro abap to a SQL server.
My OS is Unix so i cannot use a ODBC connection.
Can anyone help me to know if it's possible to write an abap statement to connect the SQL server by JDBC connection?
thanks a lot
Regards
Claudio.Hi,
ELSEIF SCREEN-GROUP2 = 'PRO'.
clear: list.
if screen-name = 'ZAVBAK-ZZPROMO_ID'.
exec sql.
commit
set connection :'CBREPOSITORYPRD'
endexec.
exec sql.
CONNECT TO :'CBREPOSITORYPRD'
endexec.
exec sql.
COMMIT
endexec
EXEC SQL.
OPEN C1 FOR
SELECT CutterRewardsUserListid,
SAPAccountNumber,
PromoID,
FirstName,
LastName
FROM CutterRewardsUserList
WHERE SAPAccountNumber = :XVBPA-KUNNR ORDER BY PromoID
ENDEXEC.
DO.
EXEC SQL.
FETCH NEXT C1 INTO :WA5
ENDEXEC.
IF SY-SUBRC = 0.
PERFORM UPDATE_LIST.
ELSE.
EXIT.
ENDIF.
ENDDO.
EXEC SQL.
CLOSE C1
ENDEXEC. -
ABAP statement for deleting the content of a infocube
Hello,
does someone know a abap statement or Babi to delete all data from a info cube?the abap statement how to delete all data from a specific cube.
There is a FM " RSDPW_INFOCUBE_DELETE_ALL_DATA". This will delete data in the cube. You need to put this in a program and run it process chain.
ALso, there is a process type to delete requests from info provider, and you can use appropriately.
The abap statement how i find out what the highest extraction point data is.
Define a variable like this:
DATA: HIGEXT_POINT like data_package_extrpoint (whatever the field name is )
HIGEXT_POINT = max(data_package_extrpoint).
Delete data_package where extrpoint < HIGHEXT_POINT.
Ravi Thothadri -
ISO date format to local date format
All
I have a requirement to convert the given ISO date format String to local date format String
Can someone give the the piece of code to do this
e.g I receive the following String "2003-03-15T09:00:00" and need to convert this to "03/15/2003 09:00:00"
ThanksCheck out java.text.SimpleDateFormat.
-
Gather shema stats for all objects in DB taking too much time
Dear ,
we schedule concurrent request " Gather Schema Statistics" to gather ALL schema on DB weekly . it takes on Test 4.5 hours to complete and 5 hours on Production system . we have only HR in Production and very soon it will start supply chain and Financial so I'm afraid from this time to increase in the near future . how could we reduce this time ? i tried to gather stats only with changed objects using " GATHER AUTO " option instead of " GATHER " but it gave me the following error
Cause: FDPSTP failed due to ORA-20001: NEW TABLE is an invalid identifier
ORA-06512: at "APPS.FND_STATS", line 799
ORA-06512: at line 1
The SQL statement being executed at the time of the error was: SELECT R.Conc_Login_Id,
Start of log messages from FND_FILE
In GATHER_SCHEMA_STATS , schema_name= ALL percent= 10 degree = 8 internal_flag= NOBACKUP
ORA-20001: NEW TABLE is an invalid identifier
End of log messages from FND_FILE
please if anyone knows how to reduce time for Gather stats or know how to solve this error he'll be much appreciatedHi,
i tried to gather stats only with changed objects using " GATHER AUTO " option instead of " GATHERYoudo not have to change this parameter, just schedule the concurrent program for HR (as suggested above), and you can schedule it for other schemas on regular basis (at the weeke ends) when there is no activity on the system -- Please see (Note: 168136.1 - How Often Should Gather Schema Statistics Program be Run?).
Regards,
Hussein -
I originally purchased a ringtone on Jan 10, 2013 and it is not longer on my i-phone 4s! I have another charge for the same song and there is still no way to set as ringtone!
Hello
Try restoring the device and setting up as new.
If it is still shows an iCloud activation lock, then it's on an iCloud account
The wrong device was removed from an iCloud account.
Check any other Apple IDs you might have at
iCloud.com
Get signed into them and remove that device.
I wish this was the first time I seen this.
Best of Luck -
How do I recover podcast stats for number of plays and last played date?
After accidental deletion of podcasts on iOS 7 phone, I recovered with Time Machine but stats are gone!
Do you have crossfade turned on? Several people have reported that it breaks play count updating.
-
Uploading credit card statement for USD which is not the local currency.
Hello Experts,
Please let me know is it possible to upload a credit card statement to showup in document buffer for USD, given that USD is not the local currency of the company code for which we are uploading the statement.
Regards,
VijayHi,
For uploading the credit card statement we will use std function module HR_TRV_CREDIT_CARD_CLEARING. This function module will not allow to upload the credit card expenses other than the company code currency (accounting currency). However you can modify the function module according to your requirement.
Thanks,
Nandagopal C -
ABAP routine for loading data of current month in InfoPackage
Hello experts,
I want to load data of current month. Therefore I implemented the following ABAP-Routine for field 0CALDAY in the InfoPackage's data selection:
data: lv_datum_l like sy-datum,
lv_datum_h like sy-datum.
concatenate sy-datum(6) '01' into lv_datum_l.
call function 'RP_LAST_DAY_OF_MONTHS'
exporting
day_in = sy-datum
importing
last_day_of_month = lv_datum_h.
l_t_range-sign = 'I'.
l_t_range-option = 'BT'.
l_t_range-low = lv_datum_l.
l_t_range-high = lv_datum_h.
But function 'RP_LAST_DAY_OF_MONTHS' cannot be found!
Any other suggestions for getting last day of current month?
regards
hizaHi,
Add this code. When u complete execution of this code, ZDATE will have ur month end date.
data : zdate_c(2) type c,
zyear_c(4) type c,
zmonth_c(2) type c.
data : zdate like sy-datum.
data : zday(2) type n.
zdate = sy-datum
zyear_c = zdate(4).
zmonth_c = zdate+4(2).
zdate_c = '01'.
concatenate zyear_c zmonth_c zdate_c into zdate.
CALL FUNCTION 'FIMA_END_OF_MONTH_DETERMINE'
EXPORTING
I_DATE = zdate
IMPORTING
E_DAYS_OF_MONTH = NO_OF_DAYS.
zday = NO_OF_DAYS.
concatenate zyear_c zmonth_c zday into zdate. -
Hi all,
does anyone know what the abap statement RSYN is for?
I haven't found anything about it in help docs.
:busHi,
I am getting dump call_function_format_not_sup which showing sapmssy1 program error. i am attaching the dump. plz check and kindly help me.
ABAP/4 runtime error CALL_FUNCTION_FORMAT_NOT_SUP
Occurred on 07.07.2009 at 15:15:18
RFC data format not supported.
What happened?
An error occurred when executing a Remote Function Call.
The current ABAP/4 program "SAPMSSY1" had to be terminated because
one of the statements could not be executed.
This is probably due to an error in the ABAP/4 program.
What can you do?
Print out the error message (using the "Print" function)
and make a note of the actions and input that caused the
error.
To resolve the problem, contact your
SAP system administrator.
Error analysis
A data error occurred when executing a Remote Function Call.
The data format used is not supported by the recipient.
How to correct the error
A 'Remote Function Call' passed data in the incorrect format or
length. If both the calling program and the called program are
ABAP/4 function modules, there is an error in the
SAP system.
If one of these programs is a CPI-C program which interprets the
RFC log itself, the error has probably occurred because the program
does not conform to the standards defined by SAP.
System environment
SAP Release.............. "31H"
Application server....... "PCPPROD1"
Network address.......... "10.106.128.71"
Operating system......... "SunOS"
Release.................. "5.6"
Hardware type............ "sun4u"
Database server.......... "PHYPLW02"
Database type............ "ORACLE"
Database name............ "ALP"
Database owner........... "SAPR3"
Character set............ "en"
SAP kernel............... "31I"
Created on............... "Jul 24 2001 05:20:53"
Created in............... "SunOS 5.5.1 Generic_103640-19 sun4u"
Database version......... "ora OCI_73400"
Patch level.............. "616"
Patch text............... " "
Supported environment....
Database................. "ORACLE 7.2..., ORACLE 7.3..., ORACLE
8.0...*"
SAP database version..... "31I"
Operating system......... "SunOS 5.5.1, SunOS 5.6, SunOS 5.7, SunOS 5.8"
User, transaction...
Client.............. 000
User................ "SAPSYS"
Language key........ "E"
Transaction......... " "
Program............. "SAPMSSY1"
Screen.............. "SAPMSSY13004"
Screen line......... 2
Information on where termination occurred
The termination occurred in the ABAP/4 program "SAPMSSY1" in
"REMOTE_FUNCTION_CALL".
The main program was "SAPMSSY1".
The termination occurred in line 67
of the source code of program "SAPMSSY1" (when calling the editor 670).
Source code extract
000370 ENDMODULE.
000380
000390 MODULE %_RFCDIA_CALL OUTPUT.
000400 "Do not display screen !
000410 CALL 'DY_INVISIBLE_SCREEN'.
000420 PERFORM REMOTE_FUNCTION_DIACALL.
000430 ENDMODULE.
000440
000450 MODULE %_CPIC_START.
000460 IF SY-XPROG(4) = '%RFC'.
000470 PERFORM REMOTE_FUNCTION_CALL USING RFCTYPE_EXTERNAL_CPIC.
000480 ELSE.
000490 CALL 'APPC_HD' ID 'HEADER' FIELD HEADER ID 'CONVID' FIELD CONVID.
000500 PERFORM CPIC_CALL USING CONVID.
000510 ENDIF.
000520 ENDMODULE.
000530
000540
000550 FORM CPIC_CALL USING CONVID.
000560 COMMUNICATION SEND ID CONVID BUFFER HEADER.
000570 IF SY-SUBRC EQ 0.
000580 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000590 ELSE.
000600 MESSAGE A800.
000610 ENDIF.
000620 ENDFORM.
000630
000640
000650 FORM REMOTE_FUNCTION_CALL USING VALUE(TYPE).
000660 DO.
CALL 'RfcImport' ID 'Type' FIELD TYPE.
000680 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000690 RSYN >SCONT SYSC 00011111 0.
000700 ENDDO.
000710 ENDFORM.
000720
000730 FORM REMOTE_FUNCTION_DIASTART.
000740 DO.
000750 CALL 'RfcImport' ID 'Type' FIELD RFCTYPE_RFCDIA.
000760 PERFORM (SY-XFORM) IN PROGRAM (SY-XPROG).
000770 "Parking position for next request
000780 RSYN >SCONT SYSC 00011111 10.
000790 "ALternativ : Free mode
000800 "COMMIT WORK.
000810 "SYSTEM-CALL FREE MODE 0.
000820 ENDDO.
000830 ENDFORM.
000840
000850 FORM REMOTE_FUNCTION_DIACALL.
000860 SY-XCODE = '%_@no@'.
Contents of system fields
SY field contents..................... SY field contents.....................
SY-SUBRC 0 SY-INDEX 1
SY-TABIX 0 SY-DBCNT 0
SY-FDPOS 0 SY-LSIND 0
SY-PAGNO 0 SY-LINNO 1
SY-COLNO 1
Chosen variables
Name.......................... Contents.1........2........3....+....4
SY-MSGV1
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV2
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV3
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
SY-MSGV4
2222222222222222222222222222222222222222
0000000000000000000000000000000000000000
... + 40
2222222222
0000000000
TYPE 3
0000
0003
SY-XPROG
22222222
00000000
SY-XFORM
222222222222222222222222222222
000000000000000000000000000000
Active calls / events
No.... Program INCLUDE Line Type.... Name.....................
1 SAPMSSY1 SAPMSSY1 67 FORM REMOTE_FUNCTION_CALL
2 SAPMSSY1 SAPMSSY1 30 MODULE %_RFC_START
Internal notes
The termination occurred in the function "ab_rfctinfo" of the SAP
Basis System, specifically in line 1178 of the module " ".
The internal operation just processed is "CALY".
List of ABAP/4 programs affected
Program
Load size
Roll size
Gen. date
/ time Changed by
SAPMSSY1
20480
83050
21.05.1997
16:27
21.05.1997
SAP
List of internal tables
No dump information available
Directory of application tables (contents)
Program name........... Contents.1........2........3....+....
SAPMSSY1 TCPIC
Directory of data areas (administration information)
No Program name........... Length Gen.date Gen.time Ofst Type Next
0 SAPMSSY1 /%_LISTTABLES 3128 -3 DATA
1 SAPMSSY1 stack area 65536 -2 DATA
2 SAPMSSY1 text pool 4064 -1 DATA
3 SAPMSSY1 global data 1136 0 DATA
4 SAPMSSY1 local data 0 1 STCK
5 SAPMSSY1 constant data 647 2 LITL
6 SAPMSSY1 not assigned 0 3 INVL
7 SAPMSSY1 SYST 2232 4 TABL
8 SAPMSSY1 SY 2232 5 TABL
9 SAPMSSY1 RSJOBINFO 84 6 TABL
10 SAPMSSY1 /%_SCREEN 56 7 DATA
11 SAPMSSY1 /%_SYS%% 480 8 DATA
12 SAPMSSY1 TCPIC 70 9 TABL
Directory of data areas (contents)
No Program name........... Contents.1........2........3....+....
0 SAPMSSY1 /%_LISTTABLES |00000x0C000000000x0C0
1 SAPMSSY1 stack area |000x030000ÿÿÿÿ00000000
2 SAPMSSY1 text pool |ÿÿ000006E000000x01R00000
3 SAPMSSY1 global data | 0 x04
4 SAPMSSY1 local data
ABAP/4 control blocks CONT
Index Name F1 Co Par01 Par2. Par3. Par4. Tabl Source Line Source code........
146 CLEA 00 83 SAPMSSY1 60 MESSAGE A800.
147 CLEA 00 84 SAPMSSY1 60
148 CLEA 00 85 SAPMSSY1 60
149 CLEA 00 86 SAPMSSY1 60
150 MESS 00 327 SAPMSSY1 60
151 ENDF 00 SAPMSSY1 62 ENDFORM.
156 PERP 02 SAPMSSY1 65 FORM REMOTE_FUNCTI
157 WHIL 00 2 SAPMSSY1 66 DO.
161 WHIL 00 3 SAPMSSY1 66
165 BRAN 05 Branch to 178 SAPMSSY1 66
166 CALY 00 3 87 72 73 73 SAPMSSY1 67 CALL 'RfcImport' I
>>>>> CALY 02 88 P0 SAPMSSY1 67
174 xper 02 22 23 SAPMSSY1 68 PERFORM (SY-XFORM)
176 SYSC 1F SAPMSSY1 69 RSYN >SCONT SYSC 0
177 BRAX 00 Branch to 161 SAPMSSY1 70 ENDDO.
178 WHIL 00 4 SAPMSSY1 70
182 ENDF 00 SAPMSSY1 71 ENDFORM.
187 WHIL 00 2 SAPMSSY1 74 DO.
End of runtime analysis -
Question about statement for all entries
Hi Abap experts,
I have a question concerning the ABAP statement for all entries.
Explanations:
Let’s say that my source package (Source table) contains 2 types of data:
-type1
-type2
I would like to use the statement select from table into internal table
For all entries in source package
But the where statement changes depending on the data type (2 keys when data type is 1 and only 1 key when data type is 2) .
So that would be:
Type1:
Select fields
From table into internal table
Where field1 = source_package-field1
And field2 = source_package-field2.
Type2:
Select fields
From table into internal table
Where field1 = source_package-field1
How can I merge them assming that the field od data type is ftype?
Thanks.
AmineHi amine,
i think this is helpful for you.
there are 2 ways to use the for all entries...
1. with header line: this method is old one. in this method the internal table (ITAB) is automatically create workarea (WA) with same name, this method 1 drawback is there where we can use WA and ITAB confused that's why this is come difficult.
2. without header line : this is nowadays we can use this method. in this method we create separate ITAb and WA. very clear this method.
EXAMPLES:
1.WITH HEADER LINE METHOD:
PARAMETERS p_kunnr TYPE kna1-kunnr.
DATA:it_kna1 LIKE kna1 OCCURS 0 WITH HEADER LINE,
it_adrc LIKE adrc OCCURS 0 WITH HEADER LINE,
it_adr2 LIKE adr2 OCCURS 0 WITH HEADER LINE,
it_adr6 LIKE adr6 OCCURS 0 WITH HEADER LINE.
START-OF-SELECTION.
SELECT * FROM kna1 INTO TABLE it_kna1
UP TO 100 ROWS.
IF NOT it_kna1[] IS INITIAL.
SELECT * FROM adrc INTO TABLE it_adrc
FOR ALL ENTRIES IN it_kna1
WHERE addrnumber = it_kna1-adrnr.
ENDIF.
IF NOT it_adrc[] IS INITIAL.
SELECT * FROM adr2 INTO TABLE it_adr2
FOR ALL ENTRIES IN it_adrc
WHERE addrnumber = it_adrc-addrnumber.
ENDIF.
IF NOT it_adr2[] IS INITIAL.
SELECT * FROM adr6 INTO TABLE it_adr6
FOR ALL ENTRIES IN it_adr2
WHERE addrnumber = it_adr2-addrnumber.
ENDIF.
LOOP AT it_kna1.
READ TABLE it_adrc WITH KEY addrnumber = it_kna1-adrnr.
IF sy-subrc = 0.
ENDIF.
READ TABLE it_adr2 WITH KEY addrnumber = it_kna1-adrnr.
IF sy-subrc = 0.
ENDIF.
READ TABLE it_adr6 WITH KEY addrnumber = it_kna1-adrnr.
IF sy-subrc = 0.
ENDIF.
WRITE : it_kna1-kunnr, it_kna1-name1, it_adrc-city1, it_adrc-street, it_adrc-po_box_reg,
it_adr2-telnr_long, it_adr6-smtp_addr.
ENDLOOP.
2. WITH OUT HEADER LINE:
TABLES: KNA1 , ADRC.
DATA : IT_KNA1 TYPE STANDARD TABLE OF KNA1,
IT_ADRC TYPE STANDARD TABLE OF ADRC,
WA_KNA1 TYPE KNA1,
WA_ADRC TYPE ADRC.
DATA: BEGIN OF STRTYPE ,
CUSTMERNO LIKE KNA1-KUNNR,
FIRSTNAME LIKE KNA1-NAME1,
LASTNAME TYPE NAME2,
CITY TYPE ORT01,
STATE TYPE REGIO,
COUNTRY TYPE LAND1,
ADDRESS LIKE ADRC-ADDRNUMBER,
END OF STRTYPE.
DATA : IT_1 LIKE TABLE OF STRTYPE.
SELECT-OPTIONS K_kunnr FOR kna1-kunnr NO-EXTENSION.
SELECT * FROM KNA1 INTO TABLE IT_KNA1 WHERE KUNNR IN K_KUNNR.
IF NOT IT_KNA1[] IS INITIAL.
SELECT * FROM ADRC INTO WA_ADRC FOR ALL ENTRIES IN IT_KNA1 WHERE ADDRNUMBER = IT_KNA1-ADRNR.
ENDSELECT.
ENDIF.
LOOP AT IT_KNA1 INTO WA_KNA1.
READ TABLE IT_ADRC INTO WA_ADRC WITH KEY ADDRNUMBER = WA_KNA1-ADRNR.
IF SY-SUBRC = 0.
STRTYPE-ADDRESS = WA_ADRC-ADDRNUMBER.
ENDIF.
APPEND STRTYPE TO IT_1.
WRITE : / WA_KNA1-KUNNR, WA_KNA1-NAME1, WA_KNA1-NAME2, WA_KNA1-ORT01, WA_KNA1-REGIO, WA_KNA1-LAND1, WA_ADRC-ADDRNUMBER.
ENDLOOP.
regards,
roopa.k -
Hi All,
Is there any possibility to disaplay Local Date & Time in script level.
our current system have time zone setting as German timimgs, but one of our client in china they want to display in all their labels with Local date & Time instead of German timings . They have thier own script but print program is common for all . is there any possiblity to change in script level without modifing the Print program.? pls let me know.....
Thanks & Regards,
sksk.these system fields will help i hope
you can get with sy- <field name>
these are from SYST structure.
DATLO SYSTDATLO DATS 8 0 Local Date for Current User
TIMLO SYSTTIMLO TIMS 6 0 Local Time of Current User
ZONLO SYSTZONLO CHAR 6 0 Time Zone of Current User
Maybe you are looking for
-
Spry menu bar not visible in live view
Hi everyone, I was just working on the css for my spry menu bar and went to check it out in the live view, but it is no longer visible. I checked it out in Safari and Firefox to no avail. It looks totally fine in the design view in Dreamweaver. I'm n
-
Report for field BSART (table MEPO_TOPLINE)?
Dear Gurus, how can I run a report on the following field? Field name: BSART Table name: MEPO_TOPLINE Thanks a lot
-
How to maintain muline header using webdynpro
Hi Friends, please let me know how shall i maintain muline header in a table ( eg: in a single colum i want to provide Qty,UOM,Price S.NO ITEM Desc Qty UOM Price
-
I choose to buy a SRW224G4P with this documentation: http://www.cisco.com/en/US/docs/switches/lan/csbms/srw248g4p/administration/guide/SRW224G4P-248G4P_User_Guide.pdf On this documentation, the switch is able to use IGMP v3 and IGMP querier: p99: IG
-
Photoshop Error 16 - Please reinstall the product
Hello - I manage a Mac lab for my school. We are running opendirectory on macs running 10.8.5. We have CS 5.5 that is fully updated. All the machines were imaged with deploy studio and have the exact same image on them. About 10% of our students