Hi Prashanth,
You can fetch data from R/3 using JCO by opening an connection and calling a BAPI.
Please refer to the below documents for more details:
SAP JCo Client Programming - Components of SAP Communication Technology - SAP Library
Example Program Bapi2 - Components of SAP Communication Technology - SAP Library
https://scn.sap.com/thread/1580405
BAPI for user details: BAPI_USER_GET_DETAIL.
Best Regards,
Rohit