[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1881
  • Last Modified:

Alter user password with FORMS_DDL in Forms6i

Ca anybody tell me why the following statement does not work.

FORMS_DDL(' ALTER USER '||:Block.Username||' identified by '||:block.newpassword)

I keep getting a 28001 password expire message.
0
timjshields
Asked:
timjshields
  • 2
  • 2
1 Solution
 
schwertnerCommented:
Seem the user you use has not CREATE USER privelege.
To issue this DDL you have to be connected under SYS schema.
If this is not the case the user you use with this Form
should be granted some rights from the SYS user.
I just show in OEm for 10g.
This is the under " Modify System Privileges "
and the privelege is
"CREATE USER"

SQL>connect sys/passw@alias as sysdba
SQL>grant create user to your_user;
0
 
jwahlCommented:
the statement is o.k. and should work.

the problem in your case is that the password of the user had expired.  you can only change the password with ALTER USER ... if you're connected to the database with a valid (not expired) password.

0
 
jwahlCommented:
> the statement is o.k. and should work.
... assuming that the user has priveleges as schwertner described ...
0
 
timjshieldsAuthor Commented:
Thanks for the reply.
The user  is me and I have dba rights. I expired the password on purpose to test the statement -> FORMS_DDL(' ALTER USER '||:Block.Username||' identified by '||:block.newpassword)!.
What you are telling me is that I should is
1) creat a logon statement  as sys
2) do the alter statment?
3) logon statment with the expired user.

By the is to be done in a login screen I created.

0
 
schwertnerCommented:
According
http://forum.java.sun.com/thread.jspa?threadID=455430&tstart=0
ALTER USER '||:Block.Username||' identified by '||:block.newpassword
will do the job!
Give a try.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now