Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Big company, little error

Re: Big company, little error

From: Mohamed Romdane <m_romdane_at_hotmail.com>
Date: Fri, 5 Nov 2004 07:18:39 +0100
Message-ID: <418b1b41$0$15271$79c14f64@nan-newsreader-05.noos.net>


Hi,

You have to grant the ROLE to the user after creating it, that contains the CREATE SESSION or the ALTER SESSION Privilege !

GRANT CONNECT, RESOURCE TO user;
or
GRANT DBA TO user;

Hope that helps ...

-- 
Best regards,

Mohamed ROMDANE
www.fastinternational.com
"Dan Ignat" <idan_at_core.ro> a écrit dans le message de news: 
c7a16134.0410130025.56fec2d4_at_posting.google.com...

> It's not a database error. It's just a example when unnx it's little
> confused.
> I forget "" --> "little error"
>
> Have a nice day,
> Dan
>
> Pete Finnigan <plsql_at_petefinnigan.com> wrote in message
> news:<AyxMmgB+JFbBRx9q_at_peterfinnigan.demon.co.uk>...
>> Hi,
>>
>> I would say that this is not an error. The error you get is because the
>> user unnx does not have the CREATE SESSION privilege. This means he
>> cannot connect. This is what the error message says. This is unconnected
>> to changing a users password. The same example could be done as follows:
>
> It's not a database error, it's just a intresting message.
>
>> Connected to:
>> Personal Oracle9i Release 9.2.0.1.0 - Production
>> With the Partitioning, OLAP and Oracle Data Mining options
>> JServer Release 9.2.0.1.0 - Production
>>
>> SQL> connect sys/a_at_sans as sysdba
>> Connected.
>> SQL> create user unnx identified by unnx password expire;
>>
>> User created.
>> SQL> alter user unnx identified by unnx2;
>>
>> User altered.
>>
>> SQL> connect unnx/unnx2
>> ERROR:
>> ORA-01045: user UNNX lacks CREATE SESSION privilege; logon denied
>>
>>
>> Warning: You are no longer connected to ORACLE.
>> SQL> connect sys/a_at_sans as sysdba
>> Connected.
>> SQL> grant create session to unnx;
>>
>> Grant succeeded.
>>
>> SQL> connect unnx/unnx2
>> Connected.
>> SQL>
>>
>> Instead here the user SYS changes the user UNNX's password and then the
>> user UNNX tries to connect (I realise this is concocted and the purpose
>> of expiring the password is to make the user change it on his next
>> connection) and receives the "LACK OF CREATE SESSION privilege" error.
>> This shows that changing the password is unconnected to the lack of
>> create session privilege.
>>
>> BUT, you are right to make people aware of this, some may assume that
>> the password change was rolled back (so to speak) when in fact it was
>> not. but not a bug in the database.
>>
>> kind regards
>>
>> Pete
Received on Fri Nov 05 2004 - 00:18:39 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US