Oracle EBS code should only be run under APPS schema. I think that this applies to Java classes as well.
How To Run FND_GLOBAL.APPS_INITIALIZE (or any other API) Using A User Other Than APPS (Doc ID 822225.1)
Thanks for the response..
Actually the plsql code i am using is the below one..
SELECT FSMOB_GET_PASSWORD.decrypt (
(SELECT FSMOB_GET_PASSWORD.decrypt (fnd_web_sec.get_guest_username_pwd, usertable.encrypted_foundation_password )
) AS apps_password
FROM fnd_user usertable
WHERE usertable.user_name =
(SELECT SUBSTR (fnd_web_sec.get_guest_username_pwd, 1, INSTR (fnd_web_sec.get_guest_username_pwd, '/' ) - 1 )
), fu.encrypted_user_password ) PASSWORD
FROM fnd_user fu
WHERE UPPER(fu.user_name) = upper(p_username);
the java code is given inside FSMOB_GET_PASSWORD API..
if this is possible only in APPS schema , how can the passwords be retrieved in other schema?
you should run that as apps user. As you don't know which all internal tables/view/objects are being referred