select 'alter user '||a.name||' identified by values '''||
       decode(b.password_versions,'10G ',a.password,
                                  '11G ',a.spare4,
                                  '10G 11G ',spare4||';'||a.password)
       ||''';' from sys.user$ a, dba_users b
where b.user_id = a.user# order by 1;
