Re: Create new DB using JAVA
jlegeny <[email protected]>
| Newsgroups | gmane.comp.db.sapdb.general |
|---|---|
| Message-ID | <[email protected]> |
Hello Daniel,
thank you for your answer. I did it as you writ below, but now I have
an following error:
<DBMException -24965 ERR_SYSLOGON logon to system failed 1, Logon
failure: the user has not been granted the requested logon type at this
computer.>
I have write my administrator login/password to the winXP system. Is
it neccessary something to set up for correct grants?
j.
Dittmar, Daniel wrote:
>> DBM dbSession = DBM.dbDBM ("localhost", "my_new_db");
>> DBM.dbrootDBM("localhost", "c:\program files\sapdb\depend");
>> result = session.cmd ("db_create");
>>
>>
>
>Use the following instead:
>// DBM.dbDBM works only for an existing database
>// make sure that backslashes are properly escaped
>DBM dbSession = DBM.dbrootDBM("localhost", "c:\\program files\\sapdb\\depend");
>result = session.cmd ("db_create my_new_db dbm,dbm windowsuser,windowspassword);
>// my_new_db is the name of the new database
>// dbm,dbm is username and password of the dbm user
>// windowsuser,windowspassword is username and password of your Windows user
>// this is necessary bcause the Java interface connects through TCP/IP and
>// thus appears like a remote user
>
>Daniel Dittmar
>
>
>