‎2006 Mar 08 1:22 PM
Hi,
I would like to know if there are standard function modules to get Protocols available on the ABAP R/3 System, The port on which its running, Host Name etc..
With Regards
Murali
‎2006 Mar 08 1:33 PM
Hi Murali,
Pl take a look at the methods available in the class CL_GUI_FRONTEND_SERVICES in SE24.
regards,
Suresh Datti
‎2006 Mar 08 1:35 PM
Hi,
use this FM <b>SYSTEM_INFO</b>
this works in program, directly you can't run it.
if you see this FM you can understand how to pass get the parameters which you need..
if you want version then you need to pass 'SAP_VERSION' to key, you will get the value. like that all the data....
function SYSTEM_INFO.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*" IMPORTING
*" VALUE(KEY) TYPE CLIKE
*" EXPORTING
*" VALUE(VALUE) TYPE SIMPLE
*"----------------------------------------------------------------------
data : begin of TAB occurs 20,
KEY(21),
VALUE(69),
end of TAB.
case KEY.
when 'SAP_VERSION'.
TAB-KEY = 'SAP version'. "#EC NOTEXT
when 'SAP_SYSTEM_ID'.
TAB-KEY = 'SAP system id'. "#EC NOTEXT
when 'OPSYS'.
TAB-KEY = 'operating system'. "#EC NOTEXT
when 'MACHINE_TYPE'.
TAB-KEY = 'machine type'. "#EC NOTEXT
when 'DBSYS'.
TAB-KEY = 'database system'. "#EC NOTEXT
when 'DBNAME'.
TAB-KEY = 'database name'. "#EC NOTEXT
when 'DBUSER'.
TAB-KEY = 'database owner'. "#EC NOTEXT
when 'DBHOST'.
TAB-KEY = 'database host'. "#EC NOTEXT
when 'CTYPE'.
TAB-KEY = 'LC_CTYPE'. "#EC NOTEXT
when 'OPSYS_VERSION'.
TAB-KEY = 'OP system release'. "#EC NOTEXT
when 'KERNEL_KIND'.
TAB-KEY = 'kernel kind'. "#EC NOTEXT
when others.
VALUE = SPACE.
endcase.
if TAB-KEY <> SPACE.
call 'SAPCORE' id 'ID' field 'VERSION'
id 'TABLE' field TAB-*SYS*.
read table TAB with key KEY = TAB-KEY.
if SY-SUBRC = 0.
VALUE = TAB-VALUE.
endif.
endif.
endfunction.regards
vijay
‎2006 Mar 08 1:40 PM
Hi Murlai,
there is another FM <b>/SDF/SYSTEM_INFO</b>, that gives all the info. run it and check.
for this you need not to pass any thing..., you should get all info one shot.
for the <b>system_info</b> you need to call so many times..
Regards
vijay
‎2006 Mar 08 1:49 PM
Hi,
The FM doesnot work when I execute, it gives message saying error generating the test frame.
With Regards
Murali
‎2006 Mar 08 1:53 PM
Hi Murali,
i already informed you, it won't work in direct run, you need to call it in your program then only it will work.
any way there is another FM which does the same Job.
check this FM <b>/SDF/SYSTEM_INFO</b>
run it directly...
Regards
vijay
‎2006 Mar 08 2:15 PM
Hi,
I have already tried this /SDF/SYSTEM_INFO in se37 but I dont find the function module.
With Regards
Murali
‎2006 Mar 08 2:23 PM
Hi Murali,
In SE 37 , you can use RFC_GET_SYSTEM_INFO & give DESTINATION = 'NONE'.
Regartds,
Suresh Datti
‎2006 Mar 08 2:28 PM
Hi,
Thanks this does work, but it doesn't give me the information that I need, If you use the transaction sicf, you can see the HTTP protocol runs on a particular port, the host name and so on. So can I get this information progrmatically.
With Regards
Murali
‎2006 Mar 08 2:29 PM
Hi Murali,
check this code..
report zsys_info .
data: value(69).
call function 'SYSTEM_INFO'
exporting
key = 'SAP_VERSION'
importing
value = value.
.
write: 'Version ' , value.
call function 'SYSTEM_INFO'
exporting
key = 'SAP_SYSTEM_ID'
importing
value = value.
.
write:/ 'system id' , value.
call function 'SYSTEM_INFO'
exporting
key = 'MACHINE_TYPE'
importing
value = value.
.
write:/ 'Machine type ' , value.
call function 'SYSTEM_INFO'
exporting
key = 'DBNAME'
importing
value = value.
.
write:/ 'DB name' , value.
call function 'SYSTEM_INFO'
exporting
key = 'DBUSER'
importing
value = value.
.
write:/ 'DB user' , value.
call function 'SYSTEM_INFO'
exporting
key = 'DBUSER'
importing
value = value.
.
write:/ 'DB Host' , value.
call function 'SYSTEM_INFO'
exporting
key = 'CTYPE'
importing
value = value.
.
write:/ 'CTYPE' , value.
call function 'SYSTEM_INFO'
exporting
key = 'OPSYS_VERSION'
importing
value = value.
.
write:/ 'OPSYS_VERSION' , value.
call function 'SYSTEM_INFO'
exporting
key = 'KERNEL_KIND'
importing
value = value.
.
write:/ 'KERNEL_KIND' , value.regards
vijay
‎2006 Mar 08 2:36 PM
Hi,
in that case you can try this FM' <b>ICF_SYSTEM_INFO</b>
regards
vijay
‎2006 Mar 08 2:46 PM
try ICF_SHOW_PROXY_CONFIGURATION or look at its source code.. you might get some hints on the Tables where the info is stored..
regards,
Suresh Datti
‎2006 Mar 08 1:46 PM
Hi,
try
/SDF/SCSI_GET_SYSTEM_INFO
Hope this helps.
Regards,
Shashank