Monday, October 17, 2011

Alter Session Parameter for Siebel Query

 

For Oracle 10g

alter session set optimizer_mode = first_rows_10
alter session set "_optimizer_sortmerge_join_enabled" = false
alter session set "_optimizer_join_sel_sanity_check" = true

Saturday, August 6, 2011

Siebel 8 Local DB Encryption & Backend Access

 

Anyone who has worked on the Siebel version 8 flavours is bound to have run into problems with its new local db encryption feature. As a default setting, Siebel encrypts the local db with an RSA encryption key, which means the local db thus extracted, cannot be accessed via the backend. Tools and the locally installed client will continue to work, but if you need to actually debug data entry issues in the database, the system will just respond saying incorrect password.

Traditionally, there is a tool called dbisqlc, an executable present in the Tool\Bin folder, which is mean to access Sybase databases. I have used this tool numerous times in the past to debug data entry issues and run spooled SQL statements. But if your localdb is encrypted, you will need to provide some more inputs to dbisqlc so that it can open up the dbf file.

Thankfully, there are helpful documents on suppportweb here and here which explains everything in detail.

 

    1. Determine the location of the local database that user wants to connect to and note down the full path of the database file for example %SIEBEL_CLIENT_ROOT%\local\sse_data.dbf.
    1. Launch dbisqlc.exe from the %SIEBEL_CLIENT_ROOT%\bin directory to bring up the Connect to Adaptive Server Anywhere dialog. On the Login tab fill out the following fields.NOTE: The values for the User ID and Password have to be in upper case:

Field

Value

User ID

DBA

Password

<Enterprise Name> in ALL CAPITALS

NOTE: The default DBA password value is the enterprise name. If the enterprise name has less than 8 characters, the name is padded with consecutive digits 1234. For example:

o If the Enterprise Name is Siebel2005, then the DBA password is SIEBEL2005.

o If the Enterprise Name is Siebel, then the DBA password is SIEBEL12.

o

On the Database tab fill out the following field:

Field

Value

Database File

C:\Sea\local\sse_data.dbf

NOTE: Starting in Siebel version 8.0, you will need to run the following query to retrieve the encrypted value for the local database owner and enter this value on the Encryption Key field. 

SELECT PREF_CD, VAL FROM S_NODE_PREF s1, S_NODE s2 WHERE s1.PREF_CD ='RemLocSec:PlainKey' AND s1.NODE_ID = s2.ROW_ID AND s2.NAME='<mobile client name of the local database';

    1. After clicking on the OK button, the user will connect to the local database. A message "Connected to database" should appear in the Statistics sub-window.

 

Knowing the DBA password for your local db can also be useful when the tables need to be extended.  Sometimes in Siebel tools, when you do an apply activate, the tools wizard goes into a hang and refuses to come out. I found that when I entered the userid as DBA and corresponding password generated as in the steps above, the tools system was able to complete the apply DDL step easily.

 

Also refer to this excellent post which explains how to reset forgotten passwords.