Hi all!
I cant seem to connect using jdbc.
I created a database by modifying the script that creates the test
database. I also created the user bcuser using this sql statement:
sql_execute CREATE USER bcuser PASSWORD bcpass RESOURCE NOT EXCLUSIVE
DEFAULTCODE UNICODE
This seems to have worked. I installed websql/webdbm and I can log on to
websql using my bcuser. I can also execute a query successfully (select *
from tables) using websql.
When using the dbmcli user_getall I dont see bcuser listed - am I right in
thinking that user_getall only lists administrative accounts known to the
database?
Anyway, when using the HelloSapDB test util distributed with sapdb, I get
this:
[sapdb@nerdling sapdb]$ java -classpath lib/sapdbc.jar:. HelloSapDB -u bcuser,bcpass
-d soprano
Exception in thread "main" com.sap.dbtech.jdbc.exceptions.JDBCDriverException: SAP
DBTech JDBC: Cannot connect to jdbc:sapdb://nerdling/null [Restart required].
at com.sap.dbtech.jdbc.DriverSapDB.connect(DriverSapDB.java:193)
at java.sql.DriverManager.getConnection(DriverManager.java:512)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at HelloSapDB.main(HelloSapDB.java:26)
I tried running it as user dbm as well but I get exactly the same
response. When issuing "dbmcli -u dbm,dbm -d soprano user_get dbm" I get
this:
OK
SERVERRIGHTS=DBInfoRead,ExecLoad,UserMgm,DBFileRead,Backup,InstallMgm,LoadSysTab,ParamCheckWrite,ParamFull,ParamRead,DBStart,DBStop,Recovery,AccessSQL,AccessUtility
GUIRIGHTS=
SECONDPASSWORD=NO
DISABLED=NO
COMMENT=
- Im running RedHat 8 and sapdb: "7.4.3","UNIX","/opt/sapdb/depend",False,ASCII,2
Does anyone have any clues as to why I cant connect using jdbc?
Cheers,
/m
On Thu, 13 Feb 2003 17:51:57 +0100, Marcus Berglund wrote:
> Thanks for the quick response!
> I managed to create a user using the dbmcli command (create_user
> user,password). However, from your response I noticed that this was not
> the way I should have done (thanks again) it as I just want to create a regular user
>that
> can connect to the db (the goal is for that user to be able to use jdbc to
> access the database).
> So trying out the second alternative:
>
> [sapdb@nerdling sapdb]$ dbmcli -u dbm,dbm -d soprano
> dbmcli on soprano>sql_execute CREATE USER bcuser PASSWORD bcpass
> ERR
> -24988,ERR_SQL: sql error
> -5001,Missing privilege:DBA
>
> Ok - to minimize the risk of idiot-errors:
> - Am I wrong in thinking that the user dbm really is a dbm?
> How do I get sql access ?
> what username should I use with the dbmcli ?
> Should I use the username,password I used when installing sapdb?
> I used uid:sapdb,gid:sapsys but I get a user authorization failure when trying to
> run dbmcli using it).
>
> I tried finding some relevant information here (couldnt find the relevant
> info in the official online docs) :
>
>http://www.rst-consult.com/database/sapdb/dbmcli_us_html.html#0.2.3.3.3CreatingandchangingdatabaseusersinTST|outline
> but the output from the "dbmcli -n localhost -d soprano -u dbm,dbm
> user_get dbm"-command does not look the output I'm getting. This is what I
> get:
> dbmcli on localhost : soprano>user_get dbm
> OK
>
>SERVERRIGHTS=DBInfoRead,ExecLoad,UserMgm,DBFileRead,Backup,InstallMgm,LoadSysTab,ParamCheckWrite,ParamFull,ParamRead,DBStart,DBStop,Recovery,AccessSQL,AccessUtility
> GUIRIGHTS=
> SECONDPASSWORD=NO
> DISABLED=NO
> COMMENT=
>
> I use Linux and as far as I can tell there is no "SQLStudio" available for
> download.
>
> I feel that these are extremely basic questions but I just cant seem to
> find any relevant information that works for me (the commands I try from
> the docs on the rst-consult website just gives me errors and I just cant
> seem to find any relevant info in the sapdb online docs.).
>
> Have I missed some basic howto that deals with this?
> I've sofar checked out these links (apart from the sap online docs):
> http://www.mybytes.de/sapdb/
> http://www.rst-consult.com/database/sapdb/odbc_us/index.html
>
> I would really appreciate a pointer in the right direction..
> Cheers,
> /m
>
>
> On Thu, 13 Feb 2003 15:31:23 +0100, Schroeder, Alexander wrote:
>
>> Hi all,
>>
>> again to remember:
>>
>> There are dbm operators and there are database users. Apparently Zsolt and Marcus
>> wanted to create the second one (a database user)-
>>
>> A dbm operator (generally, one who can execute all these fine dbmcli command,
>> and utilise DBMGUI to monitor the database, make backups, etc.
>> can be create with that user_create command:
>>
>> http://www.sapdb.org/7.4/htmhelp/29/4e6939474e11d4aa1100a0c9430730/content.htm
>>
>> In contrast, a database user is create using the SQL statement CREATE USER:
>>
>> http://www.sapdb.org/7.4/htmhelp/48/f0daa5225811d3a97d00a0c9449261/content.htm
>>
>> If you want to execute a SQL command from dbmcli, you have to prefix it with
>> sql_execute:
>>
>> http://www.sapdb.org/7.4/htmhelp/fd/9a05e4613411d4aa1500a0c9430730/content.htm
>>
>> You can of course issue the CREATE USER statement not only from dbmcli, but also
>> from SQL Studio, for instance.
>>
>> Regards
>> Alexander Schr�der
>> SAP Labs Berlin
>>
>>> -----Original Message-----
>>> From: Andreas Ernst [mailto:[EMAIL PROTECTED]]
>>> Sent: Thursday, February 13, 2003 3:13 PM
>>> To: Marcus Berglund <[EMAIL PROTECTED]>; SAPDB
>>> Subject: Re: Newbie question: creating a user
>>>
>>>
>>> Hi,
>>>
>>> try:
>>>
>>> [sapdb@nerdling sapdb]$ dbmcli -u dbm,dbm -d soprano
>>>
>>> > help
>>>
>>> and you get all commands....
>>>
>>> and at the end ot the list
>>>
>>> user_create
>>>
>>> HTH
>>> Andreas
>>>
>>> Marcus Berglund schrieb:
>>>
>>> >I have the same problem. The problem for me is not the syntax of the
>>> >command but how to execute it. When using the dbmcli I get this:
>>> >
>>> >[sapdb@nerdling sapdb]$ dbmcli -u dbm,dbm -d soprano
>>> >dbmcli on soprano>create user testuser password pwd not exclusive
>>> >ERR
>>> >-24977,ERR_COMMAND: unknown command "create"
>>> >
>>> >I guess Im not supposed to use the dbmcli for this - but what am I
>>> >supposed to use to get a regular SQL session going with my db??
>>> >Would appreciate some help..
>>> >
>>> >
>>> >---
>>> >
>>> >--- In [EMAIL PROTECTED], "Zabach, Elke"
>>> ><[EMAIL PROTECTED]> wrote:
>>> >
>>> >
>>> >>Zsolt Almasi wrote:
>>> >>
>>> >>
>>> >>
>>> >>>Can you tell me , how can I create a Standard user ? I will
>>> >>>apreciate if you
>>> >>>can show me some examples !
>>> >>>
>>> >>>
>>> >>the reference-manual is too complicate to understand this?
>>> >>(see chapter Authorization --> create user )
>>> >>
>>> >>
>>> >>
>>> >http://www.sapdb.org/htmhelp/48/f0daa5225811d3a97d00a0c944926
>> 1/frameset.htm
>>>
>>>
>>>>example
>>>>create user xyz password abc
>>>>
>>>>Elke
>>>>SAP Labs Berlin
>>>>_______________________________________________
>>>>sapdb.general mailing list
>>>>[EMAIL PROTECTED]
>>>>http://listserv.sap.com/mailman/listinfo/sapdb.general
>>>>
>>>>
>>>
>>>_______________________________________________
>>>sapdb.general mailing list
>>>[EMAIL PROTECTED]
>>>http://listserv.sap.com/mailman/listinfo/sapdb.general
>>>
>>>
>>>
>>
>>
>>
>>
>> _______________________________________________
>> sapdb.general mailing list
>> [EMAIL PROTECTED]
>> http://listserv.sap.com/mailman/listinfo/sapdb.general
_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general