Skip to main content

Posts

Showing posts with the label Siebel DB

How to create SQL DB Views in MS SQL Server

This Article will cover below points: How to create DB View in Microsoft SQL Server. How to provide permissions to DB View. How to export DB View to .sql file. How to create DB View in Microsoft SQL Server: Connect MS SQL Server to Siebel DB. Expand the Siebel DB and navigate to Views Right click on Views and Select New View.. This might take few minutes on first use and it will open below new window from where you can create db view by selecting Table, Views etc. But I prefer to write query and directly use.Click on Close button. On Close you can see a new query window with three sections.  1st section will show the table/ view relational diagram. 2nd section will show the Columns and their details. 3rd window will have the SQL query. Copy and Paste the SQL query in 3rd section and click on other section, MS SQL Server will auto create the relation diagram and populate the Column details. From the top tool bar click on Save button and MS SQL Server will ask for DB View name, pr...

How to create external table in Siebel Tools through Siebel Wizard

  What is external table in Siebel: "External Table" in the Siebel is used by " External Business Component (EBC)". EBC is used to access data in a database tables that does not belong Siebel schema or a different database or same database with different tables (using joins) or manipulation data using sql functions. Create External Table: You use Siebel Tools and the External Table Schema Import Wizard to import your external table definition into the Siebel Repository. Start Siebel Tools. Select File > New Object.... In the New Object Wizards applet, on the General tab, double-click External Table Schema Import. The External Table Schema Import Wizard appears, as shown in the following figure. Provide the appropriate project which new external table will belong to then select the type of schema source to "DDL/ Analyics" and 3 characters for the table name and click Next button. Now on next window select the database where you have created your DB view...

How to create SQL Views in SQL Developer from UI

 About DB Views: Views are customized presentations of data in one or more tables or other views. You can think of them as stored queries. Views do not actually contain data, but instead derive their data from the tables upon which they are based. These tables are referred to as the base tables of the view. Similar to tables, views can be queried, updated, inserted into, and deleted from, with some restrictions. All operations performed on a view actually affect the base tables of the view. Views can provide an additional level of security by restricting access to a predetermined set of rows and columns of a table. They can also hide data complexity and store complex queries. Create Views: Open SQL Developer and connect the connection (DEV, UAT, Prod), Write the desired query. Now expand the db and find the Views and right click and select the "New View" A new window will appear. Paste the query your have prepared before and provide the appropriate new and click on OK button....

Siebel DB Backup through SQL Query

Replace values in highlighted with lime color according to your configuration. BACKUP DATABASE [SiebelDB] TO DISK = N' E :\\ FolderName \\ MSSQL11.MSSQLSERVER \\ MSSQL \\ Backup \\SiebelDB- bk-date .bak' WITH NOFORMAT, NOINIT, NAME = N'SiebelDB-Full Database Backup- Date ', SKIP, NOREWIND, NOUNLOAD,  STATS = 10 GO

How to unlock Workflow in Siebel Tools from Database Table through SQL query

Background: For working on an object in Siebel tools you need to lock it and usually developer forget to unlock after working on the object. So you need to ask and wait for current lock owner to unlock. There is simple way to unlock any object in Siebel, use SQL Query. Below are the simple steps to achieve this. Process: Get Row Id of Workflow from Siebel Tools and replace below and run the query:   Open tools select the workflow and from top menu bar go to "Help" and click on "About Record"   A new window will open click on "Details>>" button. Copy the Row# and replace in where clause. UPDATE S_WFR_PROC SET OBJ_LOCKED_FLG='N' WHERE ROW_ID=' 1-OOYOU ' If you using Oracle SQL Developer make sure to commit. In tools query the workflow and lock. Now query the workflow again in Siebel Tools and lock it by right click menu.

How to get Siebel Workflow Instance Monitor values from Database through SQL query

Below is the query for getting workflow instance monitor values from table: select wfdl.NAME as 'WF Name' ,wfdl.DEPLOY_STATUS_CD as 'Status' ,wfdl.VERSION as 'WF Version' ,wfil.END_TS as 'Instance EndDate' ,wfil.STATUS_CD as 'Instance Status' ,wfsil.STEP_NAME as 'Step Name' ,wfsil.STATUS_CD as 'Step Status' ,wfsl.NAME as 'Process Name' ,wfsl.PROP_VAL as 'Process Value' from S_WFA_DEFN_LOG wfdl join S_WFA_INST_LOG wfil on wfdl.ROW_ID = wfil.DEFINITION_ID  --Process Instance join S_WFA_INSTP_LOG wfsil on wfil.ROW_ID = wfsil.INST_LOG_ID --Step Instance join S_WFA_STPRP_LOG wfsl on wfsil.ROW_ID = wfsl.STEP_LOG_ID  --Process Properties where wfdl.NAME = 'Workflow name with instance monitor level 3' --and wfil.STATUS_CD = 'COMPLETED' --and wfsil.STEP_NAME = 'step name' --and wfsl.NAME <> 'Error Message'

How to get Email profile parameters (like password) from Siebel DB using sql query

1. Open MS SQL Management Studio copy paste below query in query window. SELECT Prof.NAME AS 'Profile Name' ,ParNam.NAME AS 'Parameter Name' ,Par.VALUE AS 'Parameter Value' FROM S_CM_PROF Prof LEFT JOIN S_CM_PROF_PARM Par ON Par.CM_PROF_ID = Prof.ROW_ID LEFT JOIN S_CM_CNCTR_PARM ParNam ON ParNam.ROW_ID = Par.CM_CNCTR_PARM_ID WHERE 1=1 AND Prof.NAME = 'Email  Profile Name' 2. Go to site map in Siebel Client search for Communication Drivers and Profile, copy the name of desired Email profile and add it in above query. Run the query and you will have all parameters and their values of that profile.

Find SQL Table Fragmentation

For checking table fragmentation use below: DBCC SHOWCONTIG ('S_CONTACT') DBCC SHOWCONTIG (tablename) DBCC SHOWCONTIG (tablename, indexname) Response: DBCC SHOWCONTIG scanning 'S_CONTACT' table... Table: 'S_CONTACT' (1353212021); index ID: 1, database ID: 6 TABLE level scan performed. - Pages Scanned................................: 13919 - Extents Scanned..............................: 1742 - Extent Switches..............................: 1742 - Avg. Pages per Extent........................: 8.0 - Scan Density [Best Count:Actual Count].......: 99.83% [1740:1743] - Logical Scan Fragmentation ..................: 0.02% - Extent Scan Fragmentation ...................: 6.89% - Avg. Bytes Free per Page.....................: 956.4 - Avg. Page Density (full).....................: 88.18% DBCC execution completed. If DBCC printed error messages, contact your system administrator. ----- For fragmentation use below: DBCC DBREINDEX ('S_CONTAC...