What are the scripts do you use while Apps Cloning?

adpreclone.pl prepares the source system to be cloned by collecting information about the database and creating generic templates of files containing source specific hardcoded values. Its location is $COMMON_TOP/ admin/scripts/contextname/ adcfgclone.pl creates the new context file used to configure the target system. 2. 3. What is Patch? Patch is a program which fixes the bug. Apps11i Post-Installation steps? 1) Shutdown all Oracle Application Processes 2) Apply Inter-Operability Patch(3830807) 3) Apply Discoverer Patch(3170128) 4) Relink all Oracle Appications executables 5) Restart Oracle Application Processes Apps11i Post Cloning steps? 1)Update the profile options 2)Update the printer settings 3)Update workflow configuration settings 4)Verify APPLCSF variable 5)Update session_cookie_ domain in icx_parameter table Types of Patches?  One-off patch: This is the simplest type of patch. It is created to resolve a specific bug.  Minipack patch: This is a collection of one-off patches and enhancements related to a particular module. Alphabetic characters denote the Minipack version for the module; for example, the product code for the Application DBA utilities is AD, and version Minipack I of this product would be called AD.I  Family Pack patch: This is a collection of Minipack patches for a particular family group of application modules. Alphabetic characters denote the Family Pack version; for example, the J version of the Human Resources Suite Product Family would be HR_PF.J  Maintenance Pack patch: This is a collection of Family Packs that serves as a point-level release upgrade; Oracle Applications Release 11.5.10 is an example of a Maintenance Pack. Contents of a Patch? Readme files Driver files Metadata files Replacement files Modes of Patching? Test mode (apply=n), With the Test mode, we can see the effects applying the patch will have on your system before applying the patch. Pre-install mode (preinstall= y), Pre-install mode of Autopatch is used when the version of Oracle Applications AutoPatch works with is different than the version of Oracle Applications in the database. We use this mode during upgrade process. Non-interactive mode (adpatch defaultsfile= $APPL_TOP/ admin/<SID>/log) What are the drivers present in patching? C driver copies the files and links executables D driver runs the SQL scripts and programs that updates the database G driver generates the forms, reports and message files U driver is a consolidated driver containing all copy, database, and generate actions Options of adpatch?







Novalidate Noprereq Nocompiledb Nocompilejsp Noautoconfig

Prevents adpatch from validating all schema connections Prevents adpatch from checking the existence of prerequisite patches Prevents adpatch from compiling database objects Prevents adpatch from compiling JSP objects Prevents adpatch from running autoconfig after the patch has been completed NogenerateportionPrevents adpatch from compiling forms, menus, and plls Hidepw Prevents passwords from being displayed in log files Hotpatch Allows adpatch to be run when the instance is not in maintenance mode 10. Minipack naming convention? 11i.<prod>.A, 11i.<prod>.B For example: 11i.AD.G, 11i.AD.H 11. Maintenance pack naming convention? 11.5.1, 11.5.2, 11.5.3 12. Family pack naming convention? 11i.<prod family name>.<letter> For example: 11i.HR_PF.C 13. Difference between adpatch and Opatch? adpatch is utility to apply Oracle Application Patches opatch is utility to apply Database Patches 14. What is the prerequisite to apply Opatch? Database should be down 15. What do you do if patch fails? Review log file(s) to determine the cause of the error Fix the cause of the error Restart adpatch Answer 'Yes' when adpatch asks if you want to continue the previous session Adpatch will skip already completed jobs, and pick up from where it left off. 16. How to apply a pre-requisite patch when adpatch is running? Shut down the workers using adctrl Backup FND_INSTALL_ PROCESSES, AD_DEFERRED_ JOBS, restart files(.rf9) Then, drop the above tables, restart files and apply the pre-requisite patch. Restore the two tables and restart files from backup & run the adpatch. 17. If you know that the patch has been applied previously but patch is asking you to apply the existing patch as a pre-requisite? adpatch options=noprereq 18. While applying Apps patch using adpatch, if you want to hide the apps password, how will that be possible ? Use adpatch flags=hidepw while applying patches in apps to hide apps or system password being displayed on Users Screen. 19. How do you reduce patch timings? Merging patches via admrgpch Use various adpatch options like nocompiledb or nocompilejsp Use defaults file 20. How you put Applications 11i in Maintenance mode ? Use adadmin to change Maintenance mode in Oracle Apps. With AD.I you need to enable maintenance mode in order to apply apps patch via adpatch utility. If you don't want to put apps in maintenance mode you can use adpatch options=hotpatch feature. 21. How do you know that a patch has been applied? Navigate to sitemap > patches patchhistory (or) Query AD_BUGS or AD_APPLIED_PATCHES 22. How do you find out which drivers have been applied? Query the ad_patch_drivers; 23. How do you find out what patches have been applied on database? $ opatch lsinventory

24. How to rollback the opatch? opatch rollback 25. How to apply the patch? opatch apply 26. How to go for the help on Opatch? opatch help 27. Location of Patch History files? $APPL_TOP/admin/ SID/javaupdates<timestamp>.txt(for java related files) $APPL_TOP/admin/ SID/adpsv<timestamp>.txt(non-java related files ) 28. Where do you find adpatch log files ? Patch log files will be in directory $APPL_TOP/admin/ SID/log like adpatchXXX.log ( file name you mentioned while patching ), adworkXXX.log for worker log files 29. Location of Adpatch default logfile location? $APPL_TOP/install/ log 30. Location of APPS password? $IAS_ORACLE_ HOME/Apache/ modplsql/ cfg/wdbsvr. app (or) $8.0.6 ORACLE_HOME/ report60/ server/CGIcmd. dat 31. How do you know whether ur system is autoconfing enabled or not? Run adcfginfo.sh contextfile= $APPL_TOP/ admin/contextnam e.xml 32. How do you determine whether your system is Rapid Clone enabled? First, verify that your system is AutoConfig enabled. Then, Verify that the latest Rapid Clone Patch has been applied or not 33. If I have 5 databases, is it possible to point only to 1 bdump? Keep the same location in 'background_ dump_dest' parameter for 5 databases in pfiles 34. How to retrieve recent files? ls -ltr 35. How do you know the kernel version? uname -r 36. Contents of pfile? db_name background_dump_ dest user_dump_dest core_dump_dest control_files undo_management compatible db_block_size db_cache_size db_domain global_names instance_name max_dump_file_ size remote_login_ passwordfile service_names shared_pool_ size 37. Contents of controlfile? Database name & Identifier Timestamp of database creation Tablespace names Names & locations of datafiles and redolog files Current redolog file sequence number Checkpoint information Begin & end of undo segments

52. 49. 39. 45. If your Kernel parameter settings are insufficient for Oracle. 48. However. 46.---for FORM version How do you find out if Form Server is running or not? ps -ef |grep f60webmx What is the Forms Server executable name? f60srvm What if the Form Server is slow? Bounce the server How to confirm if Report Server is Up & Running ? ps -ef | grep rwmts60 What are Materialized views? Materialized views are schema objects that can be used to summarize and distribute data.-name<filename> if you are not in present directory. Redo log archive information Backup information Why do you set Kernel parameters? Oracle uses UNIX resources such as shared memory. 50. The only thing to do is to invalidate the user by assigning an end date to the effective period for the user. 53. 41. 54.38. So we modify the Kernel parameters in /proc/sys/kernel. 51. 44. What is deadlock? When two processes waiting to update the rows of a table which are locked by an other process. What is the purpose of find? if you are in present directory. then deadlock arises. 40.--------. How to find out the version of a FORM? f60gen-----. 43. how do you find? find -name<filename> How to enable a new language? Through License Manager How do you take backup in LINUX? By using tar or cp or cpio What is Generic Service Management(GSM) ? GSM is an extension of concurrent processing which provides a powerful framework for managing processes on multiple host machines. Navigating path: Security -> User -> Define How do you delete a responsibility from Oracle Applications? Responsibilities cannot be deleted since those records are kept for security and monitoring purposes. how do you find? f ind . . 55. swap space and semaphores for interprocess communication. What is Standard manager? Standard manager is the default manager which accepts all kinds of requests. 42. conf file. 47. How do you create the user? Navigate to Security-->user-->define How do you delete an existing user in the applications? Applications users cannot be deleted since records belonging to users are kept for security and monitoring purposes. responsibilities can be disabled by assigning an end date to the effective period How do you tell what products are installed within Applications? This information can be accessed within Applications from the Alert Manager Responsibility. It has no predefined specialization rules and is active all the time. To setup these parameters permanently is use /etc/sysctl. that coordinates the concurrent processes generated by user’s concurrent requests. you will experience problems during installation and/or instance startup. Navigation Path: System--> Installations What is Concurrent Manager? Concurrent Manager is a program or process manager on application db server.

74. there is an incompatability with concurrent request and is resolved by Conflict Resolution Manager. If it finds other managers down . What is incompatability with Concurrent request? When a concurrent request is being processed and another concurrent manager is trying to process same type of request. It occurs only in 11i RAC configuration. it checks & try to restart them. What happens. You should change the PMON cycle to a number lower than 20 if your concurrent managers are having problems with abnormal terminations. The default for queue size of one PMON cycle should be used. sql 68.sh start/stop (or) $FND_TOP/bin/ startmgr 61. 70. What is Auto Config? How does AutoConfig know which value from the XML file needs to be put in which file? . What is Queue Size? The queue size is the number of PMON cycles that the ICM waits between checking= for disabled or new concurrent managers. How do you define a Concurrent Manager? Navigate to Manager --> Define 62. What happens if user kills ICM? Applications will be down 71.56. Its location is prod_top/admin/ template 75. if Conflict Resolution Manager is down? ICM will take over the jobs of CRM 69. what might be the problem? Apps Listener is not up 67. How do you check the current status of manager processes at OS level? $FND_TOP/sql/ afcmstat. What is Confict Resolution Manager? CRM resolves conflicts such as request incompatabilities. 73. 60. If ICM is down. How do you know whether Concurrent Manager is running or not? ps -ef |grep FNDLIBR 64. How do you know whether Listener is up or not? ps -ef |grep FNDFS 66. ICM takes care of the queue control requests. What is ICM? ICM is the manager which controls other managers. Location of AutoConfig template files and its use? AutoConfig uses template files to determine the basic settings that are needed. The default sleep time is 60. How do you determine whether the standard managers are up? ps -ef |grep FNDLIBR (or)$FND_TOP/ sql/afimchk. 57. reducing this number to a very low value many cause excessive cpu utilization. 58. Where do you see the requests? Query the FND_CONCURRENT_ REQUESTS 65. sql 63. What is PMON cycle? This is the number of sleep cycles that the ICM waits between the time it checks for concurrent managers failures. What is Transaction manager? A Transaction manager is started on concurrent processing server and periodically reads the pipe (concatenation of Application tier and Database tier) for incoming transactions. what happens? All the other managers will keep working. which means starting up and shutting down other concurrent managers. which defaults to 20. 72. 59. However. but you can lower this number if you see you have a lot of request waiting (Pending/Normal) . What is Sleep Time? The sleep time parameter indicates the seconds that the ICM should wait between checking for requests that are waiting to run. How to start/stop the Concurrent Manager? adcmctl. If Concurrent manager is not getting up.

83. 82. 80.sql? catalog. there is one Applications Context for each application tier. How do you know that you are in DbTier or AppsTier? Through XML file. 77. How do you know the database growth? Query dba_free_space dba_segments dba_extents 89. pupbld.sql. catproc. If DbTier=yes. 78. called the Applications Context. What is dbclone? Creating same structure of existing database. 79. AD_SNAPSHOT_ BUGFIXES What is the runaway process in CPU? The process to which the memory assigned is not released is known as runaway process.sql.txt AD_SNAPSHOT. How do you change the port values? Port values can be changed in the context file with the help of ContextEditor and running AutoConfig. How do you compile invalid objects? By running 'Validate APPS Schema' task in adadmin (or) Run utlrp. it reads the XML files and creates all the AutoConfig managed configuration files. 91. and one for the database tier.sql creates the product and user profile tables Its location is $ORACLE_HOME/ sqlplus/admin How do you drop the user including contents? Drop user XXX cascade. you are in DbTier How do you know the database has invalid objects? Select * from dba_objects where status like 'invalid'.76.sql creates views and synonyms on data dictionary Its location is $ORACLE_HOME/ rdbms/admin catproc. For each configuration file maintained by AutoConfig. 84. What if the database got crashed after giving ALTER tablespace xxx begin backup? Startup the database in mount mode and give the command ALTER tablespace xxx end backup . there exists a template file which determines which values to pick from the XML file. 81. Undo information will be written into redo log files. What happens when you give ALTER tablespace begin backup? Datafile headers will be freezed. In which mode do you up the database after creating control file? startup mount 90. AD_SNAPSHOT_ FILES. Its location is $ORACLE_HOME/ rdbms/admin Location of Apache logs? $IAS_ORACLE_ HOME/Apache/ Apache/log Why do you run catalog. 86. When you run AutoConfig. Auto Config is a configuration tool that supports automated configuration of an Oracle Application file system. 85. Navigate to Sitemap > Context Editor What is Snapshot? Snapshot gives a picture of selected Application related files in a given APPL_TOP Location of Snapshot Information? $APPL_TOP/admin/ SID/out/snapdnld . 87.sql creates the PL/SQL procedures and packages Its location is $ORACLE_HOME/ rdbms/admin pupbld. All of the information required for configuring an Applications file system is collected into a central repository.sql. What is use InterOperability Patch? We apply this patch for the compatability between OS and Oracle 88.

lst admanifest_lossy.----Database Tier .How do you know the OUI version? $IAS_ORACLE_ HOME/appsoui/ oui/oraparam.--------.92. Location of HTML Cache in Oracle Applications? $OA_HTML/_pages 97. Location of audit traces? $ORACLE_HOME/ rdbms/audit 100.sql reports standard information about the installed configuration of Oracle Applications 101. search for entry like jinit_ver_name 102.How do you connect to RMAN? rman target system/manager@ SID-----To connect remotely rman target / -----------.How do you find out the status and process id of the adworkers? ps –ef | grep adworker 107. sh 99.When you run the convert character set. If Apache is getting problems.ini 105.properties 96.--------. lst 109.How to find out database version? select * from v$version.sql? adutconf.How do you the Apache version? Type sqlplus after connecting to $IAS_ORACLE_ HOME 106.How to find opatch Version ? $ORACLE_HOME/ OPatch/opatch version 103. What are they? admanifest_excp.txt.Location of Non-OAM context editor wizard? COMMON_TOP/util/ editcontext. How to find Apache (web server) is running or not? ps -ef | grep httpd.--------. 104.How do you know the Jinitiator version? Under $COMMON_TOP/ html/bin/ appsweb_SID_ HOSTNAME.sh start (or) $ORACLE_HOME/ discwb4/util/ startall. How do you restart the Discoverer in Oracle Applications 11i? addisctl.--------. it is again restarted. How do you findout the installation is single-node or multi-node? adconfig.conf $ IAS_ORACLE_HOME/ Apache/Jserv/ etc/jserv.conf 95. How to solve it? Kill the parent process by this command pkill pid 93.What is the use of adutconf.-------To connect globally 108.->$APPL_TOP/admin (or) Query FND_NODES 94. Location of PL/SQL Cache in Oracle Applications? $IAS_ORACLE_ HOME/Apache/ modplsql/ cache 98. search for entry like jinit_ver_name (or) Under $FND-TOP/resource/ appsweb_SID_ HOSTNAME. ini (or) grep -i version oraparam. adadmin creates 3 files in the APPL_TOP/admin/ SID/out. lst admanifest.-----Application Tier RDBMS_ORACLE_ HOME/appsutil/ editcontext. which files do you look for to trouble shoot? $IAS_ORACLE_ HOME/Apache/ Apache/conf/httpd. cfg. When you kill a particular process id. cfg.--------.

What are the storage clauses do you specify? local.How do you maintain multiple databases with single instance? By sourcing the environment variables 116.What happens when you give commit statement? Server process records the SCN & commit record in the redo log buffer LGWR writes the redo log buffer entries & the SCN to redo log files Oracle notifies the user that the commit is completed Server process records that the transaction is completed & that the resource lock can be released 117. . Syntax: ln -s filename linkname A hardlink is a pathname that references an inode Syntax: ln filename linkname 115. 120.Multiplexing the controlfile using SPfile Alter system set control_files= location Shutdown the database Create additional controlfiles Startup the database 118.Contents of APPL_TOP? environment files and products 126.How do you mount the directories through NFS? mount -t nfs hostname:source destination 123. dictionary 121.How to change the APPLTMP.How to recover clone data? Recover database until cancel 124.How do you know the product versions.What does APPLCSF mean? $COMMON_TOP/ admin 127.How to find out the file version? adident Header <filename> 122. uniform. autoextend.What is softlink or hardlink? A softlink is a file that points to another file. APPLPTMP? utl_file_dir should be edited in pfile 128.Multiplexing the controlfile using Pfile Shutdown the database Copy the existing controlfiles to a newname and location Add the new controlfile name to pfile Startup the database 119.Diff.Multiplexing the Redo log files? If the log file is current.How to lock/unlock the scott/tiger account? alter user scott account lock/unlock 111.Diff. between sys and sysoper? Sysoper can take backup of controlfile Sys can take full backup of database 113. patchset levels? $AD_TOP/sql/ adutconf. lst (or) Query PRODUCT_COMPONENT_ VERSION table.110. between sys and system? Sys owns data dictionary views System owns the objects owned by oracle utilities 112. perform logswitch by using ALTER SYSTEM SWITCH LOGFILE Copy the redolog file to the new location Use ALTER DATABASE RENAME FILE xxx TO xxx to make the change in control files.How to create a user through command prompt? useradd -g groupname -d directory -p password username 114.What is the utility to upgrade from one version to another version? dbua 125.

3.5. you should always do it through the OUI deinstaller in order to keep the Global Inventory synchronized.8.Location of US directory? $APPL_TOP/au/ 11. They allow AutoPatch.0/reports/ us 131.xml Unlike the binary OraInventory. v$datafile 133.--------. What is Global Inventory? The Global Inventory is the part of the XML inventory that contains the high level list of all Oracle products installed on a machine.dbc file is corrupted. Then.129. Note: If you need to delete and ORACLE_HOME. such as ORACLE_HOME( RDBMS and IAS) or JRE.What happens when you give open resetlogs? log sequence no.1 installation 138. the informatio in the inventory is stored in Extensible Markup Language(XML) format. The Global Inventory records the physical location of Oracle products installed on the machine. will be reset 132. the XML inventory is divided into 2 distinct components. What is OraInventory? The OraInventory stores information about all oracle software products installed in all ORACLE_HOMES and other non-oracle products such as the Java Runtime Environment( JRE).-JAVA_TOP 130. The XML format allows for easier diagnosis of problems and faster loading of data.What are AutoPatch Restart files? Restart files store information about completed processing in the event of a patch or system failure.5.How do you create Applications Context file? Run $AD_TOP/bin/ adbldxml.--------. Its location is $APPL_TOP/admin/<SID>/restart 135. sh.How to check whether all the processes are running or not? ps -ef |grep smon 136. 141. what happens? and What should you do? autoconfig should be run 134. and AD Administration to continue processing at the point where they stopped. 139. The Global Inventory gets updated everytime you install or de-install an ORACLE_HOME. The inventory is XML if the following file exists $ORACLE_HOME/ inventory/ ContextXML/ comps.----APPL_ TOP $JAVA_TOP/oracle/ apps/<prod>/jar-------.What is Local Inventory? There is one Local Inventory per ORACLE_HOME.How do you know which user has which privileges? $DBA_SYS_PRIVS 137.--------.Location of JAR files? $PROD_TOP/java/ jar-----.If .--------.What is XML oraInventory? Starting with OUI 2. the following values will be prompted for ORACLE_SID used to connect to database Full path to the Rapid Install Configuration file Full path to the JDK 1.x and 11. loc which points the location of Global Inventory. It is physically located inside the ORACLE_HOME at . after sourcing APPL_TOP & ORACLE_HOME environment files. It does not have any information about the detail of patches applied to each ORACLE_HOMEs. Global Inventory or Central Inventory Local Inventory or Home Inventory 140.How do you know that the particular datafile belongs to particular tablespace? Query v$tablespace. AutoUpgrade. The location of the OraInventory is /etc/oraInst.

What does OUISetup. 145. The Local Inventory gets updated whenever a patch is applied to the ORACLE_HOME. What is Port Pool? The Port Pool provides a way to use a set of predefined server ports.$ORACLE_HOME/ inventory and contains the detail of the patch level for that ORACLE_HOME.6 ORACLE_HOME directory IAS ORACLE HOME directory Location of JDK1.How do you determine if your system is autoconfig enabled or not? Run adcfginfo. Port Name Default port numubers Web Listener Port 8000 Database Port 1521 RPC Port 1626 Reports Port 7000 Metric Server Data Port 9100 JTF Fulfillment Server Port 9300 148.1 Prompts common to DB and AppsTier Port Pool Number [0-99] 147. The application knows the name of the DBC file by using profile option "Applications Database Id" Contents of dbc file: .pl will prompt for the values required to create the new context file used to configure the target system.How do you determine if your system is Rapid Clone enabled or not? First. 143.3. It should be run as part of the OUI Patch installation and performs the following tasks: Register the OUI program in the Global Inventory Register the JRE in the Global Inventory Ensures that the ORACLE_HOME in which the patch is installed is properly registered in the Global Inventory.pl do? OUISetup.Can you clone a multinode system to a singlenode system? You can use Rapid Clone to merge multiple APPL_TOP and COMMON_TOP file systems into a single APPL_TOP and COMMON_TOP file system. Whenever java or any other program like forms want to connect to database. using OUI. How does adcfgclone.dbc file? and its contents? How do applications know the name of the dbc file? dbc stands for database connect descriptor file used to connect to database. There are 100 port pools. PROMPTS: Database SID Domain name Prompts specific to the DBTier Target system database name RDBMS ORACLE_HOME directory DATA_TOP path Prompts specific to the AppsTier Database server node Does the target system have more than one applications tier server node(Y/N)? Is the target system APPL_TOP divided into multiple mount points(Y/N)? APPL_TOP mountpoint COMMON_TOP directory 8. its uses dbc file. 142. verify if latest Rapid Clone Patch has been applied. listed as a pre-requisite to Rapid Clone. What is .sh contextfile= context 144. verify that your system is AutoConfig enabled. Then. 146.0.pl is included with the OUI patch.pl know the target system values? adcfgclone.

This listener is started by adapcctl. pl script Location: $JTF_TOP/admin/ scripts 150. How to compile JSP in Oracle Applications? Run ojspCompile. memory and both? MEMORY: Set for the current instance only.---> on database $APPL_TOP/admin/ contextname/ log-----.How to check whether the packages are available or not? rpm -qa |grep ar/make/qa 158.GUEST_USER_PWD DB_NAME DB_HOST DB_PORT Location: $FND_TOP/secure 149. applsys schema. HTML 152. loc when it is not present and you dont have root access? run .---Oracle user 161.How do you restart the installation? rapidwiz -restart 153.How do you switch the logfile? alter system switch logfile 162.Parameters regarding the performance tuning? audit_trail= true timed_statistics= true max_dump_file_ size=10240 166. D2K. whose passwords can be changed? Oracle-----.What is the difference between apps schema.Location of installation log files? $ORACLE_HOME/ appsutil/ log/contextname. Location: $AD_TOP/bin 164.--------.Do you have to install JDK on all systems. applsyspub schema? Apps schema contains only synonyms for other modules Applsys schema contains all the fnd tables. mandatory 159.How to verify whether java is installed or not? which java 156.How to findout the java version? java -version 157.--Application tier User-------.How do you set the path of /etc/oraInst.-->on application 160. when you are doing multinode installation? Yes.What is Web Listener? Web Listener is web server listener which is listening for web services (HTTP) request. Why do you use scope=spfile.sh 151.sh? It shows whether the system is autoconfig enabled or not.--------./rapidwiz -inventory_loc= 'location' 155.How to force the checkpoint? By setting FAST_START_MTTR_ TARGET parameter (or) alter system checkpoint 163.--------. This is the default behaviour if a PFILE was used at STARTUP .What is the purpose of adcfginfo.---Database tier System-----.What are the development technologies? Java. administration schema Applsyspub is the gateway to login to the application 165.By using FNDCPASS.Documents to be referred for installation? Installation guide Update Release notes 154.

shared_server= no.What is the use of utlrp. the parameter will take effect with next database startup BOTH: affect the current instance and persist to the SPFILE. the server process handles the request of several user processes.0.AD Administration Prompts? Is this the correct APPL_TOP [Yes]? Logfile name [adadmin.Which initialization parameters do you set to effect the SGA size? shared _pool_size db_block_size db_cache_size log_buffer 176.4 – 9. Time stamp facility is available in 9i whereas it is not available in 8i You can drop a column in oracle 9i using alter table command where as this is not available in oracle 8i In 9i. sql script will create the PLAN_TABLE 174. DB_CACHE_SIZE or SHARED_POOL_ SIZE can be resized when the database is up and running. It is not possible with Oracle8i.How do you change the database name? Change SID in controlfile and parameterfile In controlfile. you can findout if Oracle is picking the right indexes and joining your tables in the most efficient manner.6 1)Unzip the patchset in /stage directory and run the runInstaller 2)Select the 10G OUI and again run the runInstaller 3)Select patchset 4)Startup migrate 5)Run the script catpatch. Maintaining the Applications database objects 3.log] Email feature [No] . tnsnames.Steps to apply Patchset? Patchset includes bugfixes for 9. By examining this plan. reuse=xxx 172.Difference between 8i and 9i? In Oracle9i.Which parameters in pfile effect the database? db_name db_block_size control_files 177. Its locations is $ORACLE_HOME/ rdbms/admin 175.What is Cost based optimization? Cost based optimization is used to identify the shortest way to execute and retrieve data from an object 171. Maintaing Applications files 178.Tasks of Adadmin? 1. 169.ora should be modified 170.SPFILE: update the SPFILE.sql? This script compiles the invalid PL/SQL modules. set dbname=xxx. Generating Applications files 2. This is the default behaviour if an SPFILE was used at STARTUP 167.2. What is Explain Plan? Explain Plan parses a query and records the "plan" that Oracle devises to execute it.0.sql 168.What is Shared Server? In Shared Server environment.2. we call undo segments whereas rollback segments in 8i 173. @?/rdbms/admin/ utlxplan. of dispatchers Then.How to enable Shared Server? Two parameters should be set in pfile. of predefined server processes dispatchers= protocol of dispatcher and no.

When do you run Relink Application Programs task in AdAdmin? Run the Relink Application Programs after Installing a new version of the database or a technology stack component Installing another underlying technology component that Oracle Applications rely on Applying a patch to the Applications technology stack Applying a patch to the OS Including a new or changed third party or custom code into Applications programs 181.What is admrgpch? It merges multiple patches into a single. We take cold backup while database is shutdown and it doesnt need to be in archive log mode. of tablespaces but only one should be active. 191.How do you determine howmuch virtual memory is being utilized? Run the vmstat command 196. 186. integrated patch. 184. /usr/tmp must each have atlease 50MB of free space 180.What is adsplice? It registers off-cycle products 195.version 183.Batch size [1000] Is this the correct database [Yes]? Enter the password for 'SYSTEM' ORACLE schema: Enter the password for APPLSYS schema 179.What is adaimgr? It upgrades to the latest version of Oracle Applications 192. Ad Administration Preliminary Tasks? Run the environment file Verify the ORACLE_HOME is set properly Verify the TWO_TASK identifies the correct database Ensure that ORACLE_HOME/ bin and AD_TOP/bin are in path Shutdown the concurrent managers when relinking Ensure sufficient temporary disk space Note: The temporary directories APPLTMP. 189.What is adctrl? It manages parellel workers in Autoupgrade.How do you know database version? Select * from v$sys. 188.What is adadmin? It performs maitenance tasks on the Oracle Applications file system and database 190.What is adrelink? It relinks Oracle Applications executable programs with the Oracle Server Product Libraries 194.Explain the difference between a hot backup and a cold backup? We take hot backup when database is up and running and it must be in archivelog mode.What is Password file? Password file is created on a server side to store valid users and password.How to know which process is consuming more CPU resources? Run the top command .What is adpatch? It applies patches and adds new languages and products. 185. How many undo tablespaces should be there? We can have any no. It is used for validating users and their passwords. ADAdministration and AutoPatch 193. /tmp. APPLPTMP.Where does redo log information store? In memory area 187.What is the pre-requisite before running the 'Convert to Multiple Reporting Currencies' task in Ad Administration? Always run the 'Validate APPS Schema' task before running the convert to MRC task 182. Purpose of Undo segments? Undo segment is used to save the old value when a process changes data in a database. REPORT60_TMP and the OS temporary directories.

-------DB Listener Process addbctl.Database Scripts? addlnctl.app 204.What does OUI do? OUI(Oracle Universal Installer) is used to install.sh-.--------Fulfillm ent Server 209. 203. if Internet Explorer is used Need to be closed.sh.sh.Whats is difference between two env files in <CONTEXT>. if Netscape is used 202.-------Report Server adcmctl.In which mode the recovery is done? mount mode 212.-------Listener adrepctl.sh. What are main configuration files in Web Server (Apache)? httpd.How do you determine the blocklevel utilisation? Run the iostat command 198. you can rollback but if you truncate a table you cannot rollback Delete is a DML command whereas Truncate is a DDL command 207.env under $APPL_TOP.sh.What is Maintenance Mode? Maintenance Mode is a new mode of operation introduced with Release 11.sh-.------Concurrent Manager adapcctl. in which the Oracle Applications system is made accessible only for patching activities.Application Scripts? adfrmctl.sh.197.5. 206. Reports Server.-------Discovere r Server adtcfctl.sh.-------DB Process 210.sh.10.What for do you use the 'netstat' command? Netstat reports on the contents of network data structures 199.How do you bring datafile offline? By using ALTER DATABASE DATAFILE xxx OFFLINE 201.How do you increase the datafile size? By using ALTER DATABASE DATAFILE xxx RESIZE n 200. This provides optimal performance for AutoPatch sessions.How do you increase the tablespace size? By adding datafile to the tablespace or by resizing the datafile . wdbsvr. and minimizes downtime needed. Concurrent Manager.conf.sh.What are various components in Application/ Middle Tier? Web Server.------Web Server addisctl.env and APPS<CONTEXT>. Forms Server .Do we need to close the window after installing Jinitiator? No need. <CONTEXT>.------Forms Metric Server adfmcctl. Maintenance mode is only needed for AutoPatch sessions.env is main environment file which inturn calls other environment files like <CONTEXT>. Admin Server & Discoverer Server.env for any Customized environment files.-------TCF Socket Server jtffmctl.sh. and create database 208. jserv.env under 806 ORACLE_HOME and custom<CONTEXT>.env under $APPL_TOP ? APPS<CONTEXT>.------Forms Metric Client adalnctl. 205.Difference between du and df? du shows the used space for each and every directory and file df shows the used and available space with mount points 211.Difference between delete and truncate? If you delete a table.conf. upgrade or remove software components.sh -------Form Server adfmsctl.

223.How to check the top directories used space in OS level? du -h --max-depth= 1 220. 226. temp/txkValidateRol lup.What happens when the environment is sourced? All the product top directories and necessary executables such as adadmin. and location of other files. The location is passed on command line when the server starts.What is checkpoint? Checkpoint signals the DBWR to write the dirty buffers to datafiles Updates the datafile headers and controlfiles with checkpoint information 229. util/jinitiator 227.What happens when you use alter database archive log? To keep the database in archivelog mode 216. Set. rgf.Contents of ORA directory? IAS_ORACLE_HOME and 806 ORACLE_HOME 228.How do you maintain security? By creating users and assigning them roles and profiles 217. 225.What is there in httpd.Contents of COMMON_TOP? admin/scripts. Oracle HTTP Server does not include any directive that says where to locate it. such as user and group IDs it should use.conf? This is a server configuration file which typically contains directives that affect how the server runs. log On Application tier its under $APPL_TOP/admincont extname/log/ mmddhhmm/ adconfig. java.Which parameters effect the undo? undo_management undo_retention undo_suppress_ errors undo_tablespace 221. log sequence number will be set 0 Set is for new SID Reuse is for reusing the existing controlfiles 218. remote login is not allowed 224.What is the purpose of cmclean.html.What happens when you use alter system archive log start? To enable the automatic archiving 215.sql? and its location? It will purge the concurrent manager logs and tables 222. log .What is JInitiator? JInitiator provides the JVM on which Forms client Applet will run.What is datagroup? Datagroup is the pairing of Oracle user and Application user.ALTER TABLESPACE xxx ADD DATAFILE xxx RESIZE n ALTER DATABASE DATAFILE xxx RESIZE n 213. adpatch are set into path.How to check the free space and used space in OS level? df -h.Why do you use Resetlogs. none in password file? shared is to allow the remote users exclusive is only for particular database If none is set. html.What is RRA/FNDFS ? Report Review Agent(RRA) also referred by executable FNDFS is default text viewer in Oracle Apps 11i for viewing output files & log files 231. Because the server configuration file is the main file that the server starts with.Where to check log files after autoconfig is executed ? On database tier its under $ORACLE_HOME/ appsutil/ log/contextname/ mmddhhmm/ adconfig. exclusive. du -h 219. Reuse? If you reset the logs. 230.Where does undo memory information store? Redo log buffer cache 214.What for do we use shared.

profile option guest user/password.Where would i find .How do you cancel a running concurrent request? Navigate Concurrent Request Summary form.cfg? and its purpose? This file is defined by environment variable FORMS60_WEB_ CONFIG_FILE. request security groups and data groups. Menu is a collection of forms Request security group is a collection of programs Data group is a group of modules to be made accessible by the user through Responsibility System admin-->security-->define >define Security-->user-- 234. Whats US directory in $AD_TOP or under various product TOP's ? US directory is default language directory in Oracle Applications.rf9 file. Check whether apache/jserv is up Run FND_WEB. 238. If you have multiple languages installed in your Applications then you will see other languages directories besides US. When a user tries to access forms . You can select Cancel or Hold 241.What is a responsibility? Responsibility is a collection of menus. This is usually in directory $OA_HTML/bin on forms tier. What is location of .What could be wrong if you are unable to view concurrent manager log and output files? Most likely listener is down. such as files that were not applied Its location is $APPL_TOP/admin/ SID/log 243.How do you change the apps password? Use FNDCPASS to change APPS password and modify manually wdbsvr. Look at the FND_CONCURRENT_ REQUESTS. AR for arabic. and what exactly it does? These files are used during restart of patch in case of patch failure. 239.How to find the name of a form? Navigate Help-->About Oracle Applications 240.232. simplifies chinese or spanish. How do you troubleshoot self-service login problems? Which profile options and files do you check? Check guest user/password in DBC file. f60webmx picks up this file and based on this configuration file creates a forms session to user/client.How do I check if Multi-org is installed? Select multi_org_flag from fnd_product_ groups. do a Quickpick on the Status column.How do I check the currently installed release of applications? Select realease_name from fnd_product_ groups. In character.app/cgiCMD.Why does Help-->Tools-->Examine ask for a password? This profile option controls whether users can use the Examine utility The password should be the APPS password 242. that directory will contain reports.ora 236. aoljtest etc 235.lgi files? It contains informational messages.What are .What is location of Contexts file in 11i ? Database Context file is under Database $ORACLE_HOME/ appsutil Application Context file is under $APPL_TOP/admin 233. fmx and other code in that respective directory like FR for France. select a request. 244. This file is used by any forms client session. FND_NODES table and FNDFS_entry in tnsname. dat 237. Location is $APPL_TOP/admin/ SID 245. .PING.

259. due to the security problems.246.(It reduces the burden of system) 256. PCTUSED: The percentage of minimum space used for insertion of new row data.What is the use of restore. Oracle will span the data into a number of blocks so that it can hold all of the data. etc. a request will be generated.What are . hostname. 255. port. these files will be converted into .sh.What is Pasta? Pasta is the utility to install the printers.fmx files? When you execute . Location: $ORACLE_HOME/ appsutil/ out/contextname/ MMDDhhmm/ 252. 257.What is yellow bar? How to solve? Whenever the clients are accessing the forms. SID name. block address and type of segments (table. What is listener. it will come to previous stage like how it was. The header also contains information about the table and the actual row (address) that holds the data. clients first contact a listener process that typically resides on database server. Incremental checkpoint. It consists of listener. How to find Version of Apache used with oracle apps 11i ? Go to location $IAS_ORACLE_ HOME/Apache/ Apache/bin and run this command .What is PCTFREE & PCTUSED? PCTFREE: The percentage of space reserved for future update of existing data.What does data block header contain? The header contains general information about the data. create it manually 2) Rename the corrupted globale inventory with a different name 3) Apply OUI patch(5035661) 4) Run the OUISetup. address. It contains description.ora: It is located at the client side and it stores net service names. The listener logs will be $ORACLE_HOME/ network/log tnsnames.sh? When you run restore.Types of checkpoints? Full checkpoint. The command to run that report is called Concurrent request 249.ora: To connect to database.fmb files.pl script on both IAS_ORACLE_HOME & RDBMS_ORACLE_ HOME 5) Change the permissions of new OraInventory 6) Run the runInstaller. 260. sh command on $ORACLE_HOME/ appsoui/oui/ install 250. 258. This value determines when the block gets back into Free List table. port. host.ora? listener. copy identitydb./httpd -version 247. Partial checkpoint .obj from production to test system and run Jinitiator.How do you kill group processes? By using awk command 254.What is the use of SYSAUX tablespace? SYSAUX tablespace contains statistical data. index.What is concurrent request? When a user runs a report. Row Chaining is the storage of data in a chain of blocks.fmb and .e. protocol. 253. i.loc.What is Row Chaining? When a row is so large that it cannot fit into one free block. we get yellow bar warning.How do you work with multiple oracle homes? Whatever oracle home you want to work. The existence of such data results in "Row Chaining". To solve this problem.How do you rebuild the oraInventory? 1) If inventory_loc is not there in oraInst.). servicename. Source that environment file 248.fmx 251.What is Row Migration? Oracle will try to shift the entire row from the current block to another block having 25 (10+15) units of free space. The location of these two configuration files is $ORACLE_HOME/ network/admin 261.ora & tnsnames.

Why do we get snapshot too old error? If undo tablespace is having insufficient space. ALTER USER APPLSYS IDENTIFIED BY XXX. login as the SYSTEM user In the applications session. Oracle Support encourages the use of RDA because it provides a comprehensive picture of the customer's environment. change the APPS and APPLSYSPUB password Save the change • ALTER USER APPLSYS IDENTIFIED BY XXX.6 ORACLE_HOME: On Application Tier used to store 8. 263. Two for Application Tier (Middle Tier) and One in Database tier. The output is also useful for seeing the overall system configuration. RDA is used to gather detailed information about an Oracle environment.What is profile? Profile controls the behaviour of applications 264.9i or 10g database. RDBMS ORACLE_HOME: On Database Tier used by Database Software usually 8i. 265. What is the use of 3 Oracle Homes? There are three $ORACLE_HOME in Oracle Apps. enter the new password for APPLSYS Save the changes ALTER USER <APPLSYS USERNAME> IDENTIFIED BY <NEW PASSWORD> In the same applications session. Shutdown the concurrent managers Login as Sys Admin Navigate to SecurityOracleRegister At the same time. IAS_ORACLE_HOME: On Application Tier used by iAS (Web Server) techstack software. ALTER USER APPS IDENTIFIED BY XXX.What is RDA? RDA is a set of command line diagnostic scripts that are executed by an engine written in the Perl programming language. This is used by Web Listener & contains Apache.0.262. This is used by forms. it does not modify systems in any way. APPS and APPLSYSPUB passwords for Applications? • • • • • • • • • • All users should be log out of application. ORACLE_HOME should point to this ORACLE_HOME which applying Apps Patch. reports & discoverer. we get this error. the data gathered is in turn used to aid in problem diagnosis. 266. it only collects useful data for Oracle Customer Support.6 techstack software. . This can greatly reduce service request resolution time by minimizing the number of requests from Oracle Customer Support for more information. How to manually change the APPLSYS. 8.0. RDA is designed to be as unobtrusive as possible.

In a Multi Node Installation.o file then how do you remove it from libar. how will you find which node is running what Services? Query the table FND_NODES and check for the columns SUPPORT_CP for Concurrent Manager SUPPORT_FORMS for Forms server Web Server SUPPORT_ADMIN for Admin Server SUPPORT_DB for database tier 268. you can restore FNDLIBR executables run adadmin on concurrent manager node select option 2. Can FNDLIBR be restored if it is deleted? Yes.• • Open a new session in applications.a contains raacet.o and oracle supports asks u to remove the raacet. and login Restart the concurrent managers 267. 269. without closing the previous session. What are .a ? 5 How does autopatch works ?? 6 What is adodfcmp? 7 What is ADUNLOAD ? 8 What is the use if FNDXLOAD ? 9 when applying the patch if you get an error FND_INSTALL_ PROCESSES table alredy exists ? Then what do you do? 10 How do you clone the oracle applications ? What does adclone do ? 11 How do you find out patch set level of applications ? 12 patch history database ?? 13 what os commnad is used to find the version of a file ? and what is the oracle applications utility? .odf file in apps patch? SUPPORT_WEB for odf stands for Object Description Files used to create tables & other database objects ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++++++++++++++++++ 1 What is the adutilities ? 2 When applying the patch if you get an error worker1 is failed then what utility is used to examine the adutility ? and where the log files whill be stored ? 3 What is adrelink ? 4 If a library file libar. Maintain Applications Files menu then select 1. Relink Applications programs when prompts for Enter list of products to link ('all' for all products) [all] select FND when prompt for Generate specific executables for each selected product [No] ? YES select YES & from list of executables select FNDLIBR This will create new FNDLIBR executables.

3 to 9.netmgr even though the files present in $OH/bin What could be the problem ? 20 What do you do you do if records struck in the interface tables ???? 21 Oracle Applications has APPLSYSD.APPLSYSX ARE NOT LOCALLY MANAGED TABLESPACE. used space for a tablesapce ?? 37 What is the difference between row migration and row chaining?? 38 How to Turn Archiving ON and OFF ??? 39 CAN ARCHIVING BE TURNED OFF/ON WITHOUT BOUNCING THE DATABASE? 40 ALTER SYSTEM ARCHIVE LOG STOP DOES NOT TURN OFF ARCHIVELOG MODE Then what do you do ?? 41 How do you estimate the amount of redo per day?? 42 What you do if you get an error CANNOT ALLOCATE LOG.2.0.2 ?? 50 Cannot view Workflow Monitor Diagrams ?? 51 Unable to see online help ?? 52 while applying the patch if you get an error on database tire ?? 53 How to remove yello worning bar?? 54 How to communicate clients to the applications ? 55 How to release the space below high water mark ? 56 What should be the size of redolog members ? 57 How do i set optimal parameter for rollback segments ? 58 Unable to allocate log sequence number ? 59 How to find the paging space in AIX system ?? 60 how to find out the physical memory on AIX ?? .1. ARCHIVAL REQUIRED 43 what is responsibility ?? 44 what is the use of responsibility key defining the responsibility ?? 45 what is a adata group ? 46 what is Request Security group ? 47 what is menu in oracle applications ?? 48 What is the profile option is used to set the window help ?? 49 Unable to login to personal home page after upgrade the database from 9.14 What you do if your temp table space getting full frequently ? 15 When do you rebuild Indexes ?? 16 How do you change the apps password ?? 17 How do you restrict the SQL access based on IP address ?? 18 What does the gather schema does ? how frequently you run this program ?? 19 If you try to run netca/netmgr on unix and you get an error unable to configure netca. HOW DO YOU REORGANIZE THESE TABLESPACE ? 22 CAN I CONVERT SYSTM TABLESPACE FROM DICTIONARY TO LOCALLY MANAGED TABLESPACE IN 8I ??? 23 How to convert dictionary managable tablespact to locally managable tablespace ? 24 Why is the table extending with the next extent that is specified even though it is a locally managed tablespace.0. 25 How to Resize a Datafile ?? 26 How to 'DROP' a Datafile from a Tablespace?? 27 How do you Determining the Source of Invalid Objects ??? 28 What is core fiel ? how do you examine the core file ?? 29 What command is used to find size of a process ??? 30 How do you find out what shared memorysegments are assigedn to different os users ?? 31 Some cases if you down the database even though shared memory is not released what command is used to clear the shared memory ?? 32 How big i create the data file size ?? 33 when do i go for multiple dbwr processes ???what parameters are considered ??? 34 When you run a report you got snapshot tool old error? what do you do ??? 35 How do i see what is there in redolog files ?? 36 How do you get the free space.

Also gives useful cpu usage info.pls? 100 What Oracle Applications DBA has useful collection of SQL scripts.61 How to find out what divesies are defined to the system ?? 62 How to find the number of processor in a system ?? 63 How to estimate of the percentage of cpu and memory utilized by each process currently running ?? 64 how to determining how much paging activity is taking place on the system. 101 How to cancel the request which is submited by other user?? 102 How to bounce the http server for maximo ??? 103 Finding the maximum number of processes defined per user 104 How to determine os file system block size in AIX?? 105 Is it posible to create a Database link without alias in tnsnames. USER or DBA? 99 How can I recompile all my invalid objects using ADCOMPSC. 65 How to determining disk utilization for each hard drive? 66 How do I find out the operating system version? 67 How do I found out the process memory space usage? 68 How to find which instance owns which shared memory and semaphores On a Unix machine give the following commands 69 How do you generate Apps Forms menu modules or MMB files? 70 How do you generate Apps Forms modules or FMB files? 71 How do you generate Apps Forms library modules or PLL files? 72 When do you have to regenerate your Apps Forms modules? 73 What is compile_all= special? 74 How do you get the latest package release? 75 How can you affect the look and feel of your Apps forms? 76 How do you disable direct Forms access through the http://host: port/dev60cgi/ f60cgi URL? 77 How is Forms load balancing accomplished? 78 How is Forms load balancing accomplished with Forms listener servlet? 79 How to set up Forms to work through a firewall? 80 Note down some important profile options in sysadmin point of view ??? 81 What is f60webmx? 82 How can you recreate the f60webmx executable? 83 How do you enable Forms Runtime Diagnostics (FRD) in Apps? 84 Are there any changes to the Forms product components when in Forms listener servlet? 85 How do you change the background color of a required item in Apps? 86 How can you affect the look and feel of your Apps forms? 87 How to create a custom event alert to fire against a custom table ?? 88 How to integrate custom applications with oracle applications? ?? 89 What are the actual executables called? 90 What are some of the related Forms/Apps files? 91 List most usefull profile options for concurrent managers ?? 92 How to find the files which contain the string MTL_SYSTEM_ITEMS_ KFV ? 93 Why do I have invalid objects? What causes them? 94 Why does Oracle Support always tell me to recompile my invalid objects? 95 Are invalid objects ever acceptable? How many is too many? 96 Are invalid objects ever acceptable? How many is too many? 97 If we do not use the application with the invalid objects. can we delete them? 98 Which OBJECTS table is best to use for queries? ALL.ora file ?? 108 Grant privs to access v$ views ? 109 What command is used to find the zombi processes /dead process in unix? 110 How to kill all the processes under perticulat file system ? 111 How to find what are the products installed in your database ? 112 Create a directory with the user privaliges from root .ora ? 106 How to determine size of a oracle process on Unix ? 107 How do you create a database link with out changing tnsnames.

You can run the adrelink utility manually to relink individual executable programs. and patch a specific set of products contained in a given release of Oracle Applications. 2 When applying the patch if you get an error worker1 is failed then what utility is used to examine the adutility ? and where the log files whill be stored ? A: adctrl.o and oracle supports asks u to remove the raacet.1.o 5 How does autopatch works ?? The following steps summarize the way autopatch works: 1. adrelink force=y ranlib=y "ar RAXTRX" $adrelink force=y ranlib=y "fnd all" 3 If a library file libar.a ? ar -d libar.o file then how do you remove it from libar.7 database 114 How to find the file size greater than 2Gb ? 115 How to determine the size of a Table ? 116 How do I restrict or allow a few client machines to connect to Server ? 117 Export file Greater than 2GB is not a problem in 8I ? 118 How to eliminate migrated or chained rows ? 119 Performance Measurement of PLSQL code by DBMS_PROFILER 120 When to rebuid an index ? 121 Explain the analytical functions with examples • ROLLUP AND CUBE AGGREGATE FUNCTIONS • RANKED FUNCTION • CASE • LAG AND LEAD FUNCTION • RATIO_TO_REPORT 122 What is High Water Mark ? 123. $APPL_TOP/admin/ <SID>/log 3 What is adrelink ? AD Relink (or adrelink) allows you to relink Oracle Applications executable programs with the Oracle Server product libraries. or use the relink option in the AD Administration utility to relink all executable programs. You log in as applmgr and run your applications environment file. .a contains raacet.113 Exporting a database from 9i and Importing on 8. upgrade.a raacet. maintain. what is the utility used to licence a product ? Is it possible to delicence a product which is fully licenced ? 124 How to find the version of iAS ? 125 How to generate a report on Unix ? 126 How to generate a report on NT ? 127 Running SQL*Trace on an Applications Report ? 128 How to find ojsp version ? 1 What is the adutilities ? A: AD Utilities are a group of tools designed to install.

adlibout. 12. It also makes this type of comparison with files such as forms. If a file in the patch directory is a more recent version than the product's current file.X only) 10. The loader reads a configuration file to determine . Autopatch compares the extracted object modules (C libraries) with their corresponding files in the patch directory. or media files to their respective destinations.txt in the $APPLT_TOP directory.log) 6. (this occurs in Rel 11. Autopatch runs sql scripts and exec commands. 13. reports. After you answer some questions.txt. 8. Autopatch extracts the appropriate files from each product's C library. 6 What is adodfcmp? adodfcmp is an object comparisan utility. Autopatch identifies the Oracle Applications products that need to be updated. Java. Autopatch generates Oracle Reports files. Autopatch backs up any files you listed in adlinkbk. fmb 8 What is the use if FNDXLOAD ? FNDXLOAD is a concurrent program that can move Oracle Applications seed data between database and text file representations. The unload utility is provided in case you need to unload a small number of files after you have installed or upgraded your system $adunload product=gl $adunload product=gl directory=forms/ US filename=GLSTUOM. Autopatch generates Oracle Forms files. admvcode. (adlibin. 14. HTML.log) 11. Autopatch then replaces each product_s outdated files with newer files from the patch directory. Autopatch loads the new object modules into the C libraries. Autopatch appends a record of how it changed your system to applptch. 15.log) 9. Unload the new software into a patch directory and start the autopatch utility under a Bourne or Korn shell. which change Oracle Applications database objects. (admvcode. Autopatch copies any specified PL/SQL. adlibin. (adrelink. 3. log) 5. aderlink. (Every file in $APPL_TOP has version information inside it) 7. By default. autopatch backs up the product's current file by appending "O" to it's filename. autopatch does this in parallel. 4. (adlibout. $adodfcmp <parameter>= <value> [<parameter> =<value> ] 7 What is ADUNLOAD ? This utility is used to unload Oracle Applications product files from CD-ROM. and SQL scripts. Autopatch relinks the Oracle Applications products with the Oracle Database.2.

Review the documentation for our configuration file for a list of parameters that an be set. Parameters vary for each onfiguration file.sh. dbf' size 1500M extent management local uniform size 150K 2) Change the users temporary tablespace to new one. 10 How do you clone the oracle applications ? What does adclone do ? adclone autoconfg manual cloning(not supported) 11 How do you find out patch set level of applications ? patches. drop old temp tablespad > or increase the temp tablespace size 1) Create the new temporary tablespace temp_local. 9 when applying the patch if you get an error FND_INSTALL_ PROCESSES table alredy exists ? Then what do you do? If previous patch is not applied successfully then this table will not drop. You have to login to sql as applsys/apps then drop this table and reapply the patch. For information on specific configuration files consult the Open Interfaces Guide for your product group. .txt or ad_applied_patches( table) 13 what os commnad is used to find the version of a file ? and what is the oracle applications utility? strings -s <file name> | grep "Header" or adident <file name> 14 What you do if your temp table space getting full frequently ? Create new temp tablespace. assign all users temp tablespace newone. Ex: create temporary tablespace temp_local tempfile '/testdata/testdata /temp_local. The following sections describe the operation of the Generic Data Loader.what data to access.sql 12 patch history database ?? applptch. adutconf. FNDXLOAD <username/password> 0 Y UPLOAD | DOWNLOAD <config_file> <data_file> <entity> [<parameters> ] where <username/password> is the APPLSYS account <config_file> is the configuration file <data_file> is the file that will be read or written <entity> dentifies the entity to upload or download <paramaters> is a list of optional parameters of the form AME=VALUE.

10. 190.21.ora tcp.invited_ nodes=(10.app 17 How do you restrict the SQL access based on IP address ?? SQLNET.1 16 How do you change the apps password ?? FNDCPASS Usage: FNDCPASS logon 0 Y system/password mode username new_password where logon is username/password[ @connect] system/password is password of the system account of that database mode is SYSTEM/USER/ ORACLE username is the username where you want to change its password new_password is the new password in unencrypted format example FNDCPASS apps/apps 0 Y system/manager SYSTEM APPLSYS WELCOME FNDCPASS apps/apps 0 Y system/manager ORACLE GL GL1 FNDCPASS apps/apps 0 Y system/manager USER VISION WELCOME Some you may need to change the password even after using the above utility the file name is as wdbsvr.exclude_ nodes 18 What does the gather schema does ? how frequently you run this program ?? Collect the statistics for the schemas/specified schema which will increase the performance . 5) Drop the old temporary tablespace drop tablespace temp including contents.validnode_ checking= yes tcp. drop tablespace TEMP2 including contents and datafiles. the above query will show the old temp tablespace as default temporary tablespac.select 'alter user ' || username|| ' temporary tablespace temp_local. 25) #tcp. 4) Assign the default temporary tablespace to new one alter database default temporary tablespace temp_local.0.1 and 108573.0. 15 When do you rebuild Indexes ?? Please review articles 77574.' from dba_users where temporary_tablespac e='TEMP' run the spool file created above 3) You cannot drop the temp tablespace directoly check the default temporary tablespace for this instance select * from database_properties where property_name = 'DEFAULT_TEMP_ TABLESPACE' .190.

BUT POSIBLE IN 9i(2) 23 How to convert dictionary managable tablespact to locally managable tablespace ? You migrate a locally managed tablespace and get the following error message: 1 . HOW DO YOU REORGANIZE THESE TABLESPACE ? EXPORT /IMPORT 22 CAN I CONVERT SYSTM TABLESPACE FROM DICTIONARY TO LOCALLY MANAGED TABLESPACE IN 8I ??? NO. dbf' 3 size 20K EXTENT MANAGEMENT DICTIONARY. dbf' 3 size 10K EXTENT MANAGEMENT DICTIONARY.19 If you try to run netca/netmgr on unix and you get an error unable to configure netca. BEGIN sys.APPLSYSX ARE NOT LOCALLY MANAGED TABLESPACE. SQL> execute sys. Re submit the import.dbms_space_ admin.tablespace _migrate_ to_local( tablespace_ name=>'MIGTOLOC' . SQL> create table TMIG (c number) tablespace MIGTOLOC.There are some data in the tablespace : ORA-03244 SQL> create tablespace MIGTOLOC 2 datafile '/ora/ora901/ oradata/V901/ migtoloc01.> rfno=>9).netmgr even though the files present in $OH/bin What could be the problem ? A: note set $ORACLE_HOME/ lib33 for LD_LIBRARY_PATH 20 What do you do you do if records struck in the interface tables ???? A: Fine out the error in enterface table.tablespace _migrate_ to_local( > tablespace_name= >'MIGTOLOC' .dbms_space_ admin. line 0 ORA-06512: at line 1 2 . rectifie the error by updateing the records in interface tablles. END.tablespace _migrate_ to_local( > tablespace_name= >'MIGTOLOC' . Tablespace created.There is no data in the tablespace : ORA-03214 SQL> create tablespace MIGTOLOC 2 datafile '/ora/ora901/ oradata/V901/ migtoloc01. 21 Oracle Applications has APPLSYSD.- . SQL> execute sys. Tablespace created. Table created.rfno=>9) . * ERROR at line 1: ORA-03214: File Size specified is smaller than minimum required ORA-06512: at "SYS.dbms_space_ admin.DBMS_SPACE_ ADMIN".

SQL> execute sys. dbf' 2 resize 100K.tablespace _migrate_ to_local( tablespace_ name=>'MIGTOLOC' .> rfno=>9). rfno=>5). * ERROR at line 1: ORA-03244: No free space found to place the control information ORA-06512: at "SYS.> rfno=>9).tablespace _migrate_ to_local( > tablespace_name= >'MIGTOLOC' . Explanation: -----------When converting a tablespace from dictionary management to local management.dbms_space_ admin.dbms_space_ admin.--------Increase the size for the datafile : SQL> alter database datafile '/ora/ora901/ oradata/V901/ migtoloc01. Therefore the required space needs to be available in the datafile.DBMS_SPACE_ ADMIN". line 0 ORA-06512: at line 1 Solution Description: -----------.-------After migrating a dictionary managed tablespace to locally managed tablespace. END. the tables are still extending with the next extent specified even though it is now a locally managed tablespace. Next Extent Size After Migrating Tablespace from Dictionary to Locally Managed MIGRATED TABLESPACES -----------. PL/SQL procedure successfully completed. Example: ============ ========= ========= ========= ========= == MIGRATE FROM DICTIONARY MANAGED TO LOCALLY MANAGED ============ ========= ========= ========= ========= == SQL> begin 2 dbms_space_admin. BEGIN sys. 4 end. 5/ PL/SQL procedure successfully completed.rfno=>9) . Database altered. tablespace_ migrate_to_ local 3 (tablespace_ name=> 'USERS'. EXTENT_MANAGEMENT . Oracle creates bitmaps in the datafile. ============ ========= ========= ========= ======== Verify that tablespace is now locally-managed: ============ ========= ========= ========= ======== SQL> select TABLESPACE_NAME.

For this reason. SQL> select TABLESPACE_NAME. extent_id. and UNIFORM or SYSTEM value for tablespaces which were created as locally managed. This would be too difficult to implement. ============ ========= ========= ========= ========= = SQL> create table DW_GSO_COLLN_ NEW 2 tablespace USERS 3 storage (initial 500M next 500M pctincrease 0) 4 as select * from cdwadm. but can still get performance benefits . This option allows you to change the physical size of a datafile from what was specified during its creation. the user does not get the policy benefits from migration.dw_gso_ colln 5 where rownum < 10000000.--------. If you select from DBA_TABLESPACES.--------. I.--------. since the tablespace is likely to contain the existing objects which already aviolate new policy. Increase Datafile Size II.--------. Typical solutions are to drop and recreate the tablespace with different sized datafiles. ALLOCATION_TYPE. you should see "USER" value in the ALLOCATION_TYPE column for migrated tablespaces.---------DW_GSO_COLLN_ NEW 0 524288000 DW_GSO_COLLN_ NEW 1 524288000 DW_GSO_COLLN_ NEW 2 524288000 QUESTION: 24Why is the table extending with the next extent that is specified even though it is a locally managed tablespace.2 FROM DBA_TABLESPACES 3 where tablespace_name = 'USERS'.---------. 25 How to Resize a Datafile?? How to Resize a Datafile: ============ ========= ==== Datafile management has two sides to it: not enough room for existing datafiles. Cautions and Warnings . PLUGGED_IN 2 from DBA_TABLESPACES. SEGMENT_NAME EXTENT_ID BYTES -----------. TABLESPACE_NAME EXTENT_MAN -----------.no ST enqueue contention and more efficient extent operations. migrated tablespace only support the same allocation policy as the dictionary tablespaces. RESIZE. Table created. Decrease Datafile Size III. ANSWER: Migrated tablespaces are not subject to the UNIFORM/SYSTEM policy of newly created locally managed tablespaces. EXTENT_MANAGEMENT. Therefore.---------USERS LOCAL ============ ========= ========= ========= ========= = CREATE TABLE with the storage segments. or to add more datafiles to a tablespace. or not enough room IN existing datafiles. SQL> select segment_name. bytes 2 from dba_extents 3 where segment_name= 'DW_GSO_COLLN_ NEW'.

For the above file we get: SELECT * FROM DBA_FREE_SPACE WHERE TABLESPACE_NAME= 'TEMP' ORDER BY BLOCK_ID. You cannot deallocate space from a datafile that is currently being used by database objects. you have to have contiguous space at the END of the datafile. II.Attempting to use the RESIZE command on versions prior to 7. you use the same command.---------.---5 ONLINE READ WRITE 7450 2097152 102400 /databases/oracle/ test. We want to leave some room for growth in our datafile. For example: FILE# STATUS ENABLED CHECKPOINT BYTES CREATE_BYT NAME -----.---------. For example. and depending on how the objects in that datafile allocate new extents. you would use the command: ALTER DATABASE DATAFILE '<full_path_ name>' RESIZE <integer> [K|M].2 will receive the following error: ORA-00923: FROM keyword not found where expected I. BLOCK_ID=102 and contains 923 blocks). INCREASE DATAFILE SIZE To increase the size of a datafile. where the size specified is larger than the existing file size.-----. and the CREATE_BYTES column shows what the size was specified when the file was created. The BYTES column shows the current size of the datafile.Check the view DBA_FREE_SPACE to see how much space is not being used in a datafile. we could reduce the file above back to 1MB with the command: ALTER DATABASE DATAFILE '/databases/ oracle/test. there are two large extents at the high end of the datafile (BLOCK_ID = 55 and contains 47 blocks. we could remove easily up to 1. TABLESPACE_NAME FILE_ID BLOCK_ID BYTES BLOCKS -----------. To remove space from a datafile. DECREASE DATAFILE SIZE To decrease the size of a datafile. Check V$DATAFILE for current settings.-------. but specify a size smaller than the existing datafile.---------.---------. .dbf As you can see.---------.89MB of disk space from the datafile without damaging any objects in the tablespace. dbf' RESIZE 1MB. This means there are 1986560 unused bytes at the end of our datafile.---------TEMP 4 2 102400 50 TEMP 4 55 96256 47 TEMP 4 102 1890304 923 As you can see. Downsizing a datafile is more complicated than increasing the size of a datafile.---------.-----------. The size of the datafile will also be changed at the operating system level.------. the file was created with a size of 100K (CREATE_BYTES) and was increased to a size of 2MB (BYTES) with the RESIZE command. almost 2MB.

-----. blocks blks from dba_extents where file_id = &file_id order by block_id / Example Output: SQL> @findext. extent_id exid. and REM segment type SET ECHO OFF ttitle . and how many blocks the REM segment contains. REM the blockid where it starts. REM findext. block_id blid. and some object taking up room at the end of the datafile. segment_name name.-------.SQL to find this object. then drop it. you can use the query FINDEXT.-----------. and REM then lists all the segments contained in that datafile. If you export this object. you should then free up contiguous space at the end of your datafile so you will be able to resize it smaller.center 'Segment Extent Summary' skip 2 col ownr format a8 heading 'Owner' justify c col type format a8 heading 'Type' justify c trunc col name format a28 heading 'Segment Name' justify c col exid format 990 heading 'Extent#' justify c col fiid format 9990 heading 'File#' justify c col blid format 99990 heading 'Block#' justify c col blks format 999.SQL Script to find database object locations for a given datafile.------.If you have a large extent in the middle of a datafile. segment_type type. segment name.990 heading 'Blocks' justify c select owner ownr.------. Make sure you leave enough room in the datafile for importing the object back into the tablespace. file_id fiid. FINDEXT.sql Enter value for file_id: 5 old 12: file_id = &file_id new 12: file_id = 5 Segment Extent Summary Owner Segment Name Type Extent# File# Block# Blocks -------. It shows the owner.sql REM This script prompts user for a datafile ID number.-------USER EMP TABLE 0 5 2 5 USER TAB3 TABLE 0 5 108 5 USER TEST TABLE 0 5 348 5 USER PK_EMP INDEX 0 5 483 5 USER EMP TABLE 1 5 433 5 USER EMP TABLE 2 5 438 10 .

26 How to 'DROP' a Datafile from a Tablespace? How to 'DROP' a Datafile from a Tablespace: ============ ========= ========= ========= ==== Before we start with detailed explanations of the process involved. unable to write header block. This bug is fixed in RDBMS version 7. although we can use some workarounds. This appears as ORA-7374 errors when accessing the datafile after it has been resized. you will see that the file size does not change unless the operation is successful. you should take a backup of your database whenever you change its structure. for objects in these tablespaces specify explicitly INITIAL and NEXT extent size as well as MAXEXTENTS. and trying to drop them. etc. Finally. Once you make a datafile part of a tablespace. You can confirm how many datafiles make up a tablespace by running the .3. this causes not only a huge number of records in the dictionary tables. If you try to resize a datafile larger than can be created. CAUTIONS AND WARNINGS For safety reasons. certainly specify the NEXT and MAXSIZE parameters. simply drop the entire tablespace using: DROP TABLESPACE <tablespace name> INCLUDING CONTENTS. the datafile CANNOT be removed. ensure you have a full backup. Before performing certain operations such as taking tablespaces/ datafiles offline. This will cause the new datafile size information to be refreshed to all the dbwr slave processes. please note that Oracle does not provide an interface for dropping datafiles in the same way that you could drop a schema object such as a table. you will get an error: ORA-03297: file contains <number> blocks of data beyond requested RESIZE value The resize operation will fail at this point. If you try to resize a datafile to a size smaller than is needed to contain all the database objects in that datafile. but dropping them will take a very long time while smon is consuming all cpu resources it can get. a user.3. The workaround is to shutdown and restart the database after resizing a datafile (a convenient time to take a backup). without 2GIG of available disk space you will get something similar to: ORA-01237: cannot extend datafile <number> ORA-01110: data file <number>: '<full_path_ name>' ORA-09971: sfsfs: write error. MANUAL versus AUTOMATIC extension: Be careful giving datafiles the AUTOEXTEND attribute. you might run into [BUG:311905] . If you check V$DATAFILE.USER PK_EMP INDEX 1 5 488 10 III. For instance. in trying to create a file of 2GIG. if using multiple database writers (db_writers > 1). you will also get an error. a view. which includes altering the size of datafiles. avoid UNLIMITED sizes and extents to prevent objects with a very high number of extents will be created. If the datafile you wish to remove is the only datafile in that tablespace. set appropriate values for the default storage parameters on tablespace level and MAXEXTENTS.

tablespace_name from dba_data_files where tablespace_name ='<name of tablespace>' . on Windows NT. Oracle will no longer have access to ANY object that was contained in this tablespace. Make sure you specify the tablespace name in capital letters. (See the comment above about possible problems in doing this. the datafiles. or if you can easily recreate the information in this tablespace.segment_ name. then import the objects into that tablespace. then use the same command as above: DROP TABLESPACE <tablespace name> INCLUDING CONTENTS. (This may have to be done at the table level. Gather information on the current datafiles within the tablespace by running this query: select file_name. What the command really means is that you are offlining the datafile with the intention of dropping the tablespace. You can then use CREATE TABLESPACE and re-import the appropriate objects back into the tablespace. Again. file locks are still held by Oracle. use the following query: select owner.segment_ type from dba_segments where tablespace_name= '<name of tablespace>' Now. The DROP TABLESPACE command removes the tablespace. If you are running in archivelog mode. you may not be able to physically delete the datafile until Oracle is completely shut down. Note that this PERMANENTLY removes all objects in this tablespace.) NOTE: The ALTER DATABASE DATAFILE <datafile name> OFFLINE DROP command. issue the DROP TABLESPACE tablespace INCLUDING CONTENTS. Oracle will no longer have access to ANY object that was contained in this tablespace. In order to allow you to identify which objects are inside the affected tablespace for the purposes of running your export. (For example. and the tablespace's contents from the data dictionary.) If you have more than one datafile in the tablespace.) Recreate the tablespace with the datafile(s) desired. but it is still considered part of that tablespace. instead of OFFLINE DROP. Once the datafile is offline. Delete the datafiles belonging to this tablespace using the operating system. this will remove the tablespace. The physical datafile must then be removed using an operating system command (Oracle NEVER physically removes any datafiles). Once the export is done. The entry for that . Oracle no longer attempts to access it. Depending on which platform you try this on. then you must export all the objects inside the affected tablespace. export all the objects that you wish to keep.following query: select file_name. If you have more than one datafile in the tablespace and you wish to keep the objects that reside in the other datafile(s) which are part of this tablespace. depending on how the tablespace was organized. and you do NOT need the information contained in that tablespace. you can also use: ALTER DATABASE DATAFILE <datafile name> OFFLINE. the datafile. and the tablespace's contents from the data dictionary. you may have to shutdown Oracle AND stop the associated service before the operating system will allow you to delete the file .in some cases. This datafile is marked only as offline in the controlfile and there is no SCN comparison done between the controlfile and the datafile during startup (This also allows you to startup a database with a non-critical datafile missing). is not meant to allow you to remove a datafile. tablespace_name from dba_data_files where tablespace_name ='<name of tablespace>' .

Validating Objects -----------.-----When the above query on an object returns zero rows.If you really added the datafile by mistake. If you do not wish to follow any of these procedures. 27 How do you Determining the Source of Invalid Objects ??? Identifying Problem Object(s) -----------. type. there are other things that can be done besides dropping the tablespace. If it doesn't compile.------The following SQL*Plus query may be used to identify the object which is the source of the problem: sql> SELECT owner. The subquery finds all the objects that the invalid object depends on. This identifies the source package(s) and eliminates wasted time attempting to compile the wrong objects. then try recompiling those objects that were dependent on that object. object_type. replacing the value of INVALID_OBJECT_ NAME until zero rows are returned. then it will never be considered for extent allocation. If the datafile is resized to smaller than 5 oracle blocks. then you can use ALTER DATABASE DATAFILE <filename> RESIZE. object_name FROM dba_objects WHERE status = 'INVALID' AND object_name IN (SELECT referenced_name FROM dba_dependencies WHERE name = '<INVALID_OBJECT_ NAME>'). The outer query brings up the owner. sql>SHOW ERRORS . . command to make the file smaller than 5 Oracle blocks. select privilege to the dba_dependencies and dba_objects is required. then consider using the RESIZE command.If the reason you wanted to drop the file is because you mistakenly created the file of the wrong size. the tablespace can be rebuilt to exclude the incorrect datafile. . At some later date. and name for any invalid objects on which the INVALID_OBJECT depends. and Oracle has not yet allocated any space within this datafile. attempt to validate that object name using the following command: ALTER PACKAGE invalid_pkg_ name COMPILE. The actual invalid object name must be substituted for the <INVALID_OBJECT_ NAME> as indicated above.See 'Related Documents' below.--------. For this query to work. This query should be run interactively. If it compiles.datafile is not deleted from the controlfile to give us the opportunity to recover that datafile. issue the following command from within SQL*Plus.

EXAMPLE: Suppose we have the following object dependencies: Pkg1 (Invalid) | | _______|____ ___ || Pkg2 (Invalid) Pkg3 (Valid) | _______|____ ____ || Pkg4 (Valid) Pkg5 (Invalid) Use the following SELECT statement: sql> SELECT owner. Introduction ~~~~~~~~~~~~ This short article aims explain how to get a stack trace from a core dump produced by any of the Oracle products. object_type. object_name FROM dba_objects WHERE status = 'INVALID' AND object_name IN (SELECT referenced_name FROM dba_dependencies WHERE name = 'PKG1'). or determine the problems associated with PKG5 before the other two packages will compile. The following information is returned: OWNER OBJECT_TYPE OBJECT_NAME APPS PACKAGE PKG2 Run the query again for PKG2 instead of PKG1. it is preventing the proper compilation of packages PKG2 and PKG1. . Run the query once more for PKG5 which then returns zero rows. By following the steps below you can provide Oracle Support with vital information to help identify the cause of a problem. it is necessary to either rebuild. PKG5 will be returned. This indicates that because PKG5 is invalid. 28 What is core fiel ? how do you examine the core file ?? A: system resource(memory leak etc) dbx utility to examine the same. Use the results from that query to further diagnose the problem(s).Or use the following SQL command and search the dba_errors table: sql> SELECT NAME. Therefore.TEXT FROM DBA_ERRORS WHERE NAME ='<INVALID_OBJECT_ NAME>'.

but it is usually because the process has attempted to do something which the operating system does not like. The most common causes of this are: The program tried to access memory outside its allowed range. Now follow the instructions below in order: 1) Check you have a 'core' file. Eg: If it was a SQL*Forms problem and you were using 'mrunform30' . If the word . in addition to the details below. or in $ORACLE_HOME/ dbs OR $ORACLE_HOME/ dbs/core_ NNNNN if it is the 'oracle' executable. the operation being performed. The program tried to obtain a resource which was either exhausted or unavailable. it should be in the directory where the command was issued.Please note that it is important to include information about the tool being used. 2) Log in as ORACLE and change in to the $ORACLE_HOME/ bin directory. write this down. Enter the command: file program and write the result down letter for letter. the RDBMS. What should I do if I get a core dump ? ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ As with any problem you should first note down the FULL version numbers of the product. An attempt was made to execute illegal instructions. What is a 'core dump' ? ~~~~~~~~~~~~ ~~~~~~~~~ ~~ A core dump is an image copy of a processes state at the instant it 'aborted'. It is also possible for a user to produce a core dump by sending one of these signals to a process manually. environment etc. PL/SQL (if used) and any related products. You should also note the EXACT command you were running when this occurred. What causes a core dump ? ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~ There are many situations which can cause a core dump to be produced. any code involved.. An attempt was made to read unaligned data In Unix systems the offending process is sent one of a number of signals which force a core dump to be produced. This command will be referred to as 'program' below. It is produced in the form of a file called 'core' usually located in the current directory.

. Example commands: DBX: $ script /tmp/mystack $ dbx $ORACLE_HOME/ bin/<program> core (dbx) where .-. One of the following commands should exist on your machine . 4) Log out ..-----------.-----------.. then log in as the user who encountered the error. The next step will vary slightly depending on which version of Unix you are using.) .. << Stack should appear here . 3) Now enter: chmod +r program to add read permission to the program. << Stack should appear here (xdb) quit $ exit SDB: $ script /tmp/mystack $ sdb $ORACLE_HOME/ bin/<program> core (sdb) t . << Stack should appear here (dbx) quit $ exit XDB: $ script /tmp/mystack $ xdb $ORACLE_HOME/ bin/<program> core (xdb) t .try each in order until you find one that exists: Command NB Exit command Stack Trace command ------.------dbx quit where xdb (HPUX 10) quit t gdb (HPUX 11) q bt dde (HPUX 11) q bt sdb q t adb $q (or Ctrl-D) $c debug (PTX only) quit stack gdb (Linux) quit bt Change to the directory where the core dump is located and enter the commands as in the relevant example below.'dynamic' or 'dynamically linked' appears in the output of this command then please make a note of this as there are a few platforms on which Oracle does NOT support dynamic linking and this may be the cause of your problem.. If you are not sure which program produced the 'core' file then on some Unix platforms the command 'file core' will tell you the executable name that the core file is from (this does not work on ALL Unix platforms.. see note below.

5) If the debug command failed to give a stack trace then try using a different debugger from the list above (if available)... . $q $ exit DEBUG: $ script /tmp/mystack $ debug -c core $ORACLE_HOME/ bin/<program> debug> stack . Common reasons for not getting a sensible stack ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~ Filesize Limits: Note that on some machines there may be a kernel parameter or user limit which controls the maximum size of core file that can be produced . << Stack should appear here (gdb) quit $ exit DDE: $ script /tmp/mystack $ dde -ui line core $ORACLE_HOME/ bin/<program> dde> bt .. dde> q $exit Assuming this worked then the stack trace should be shown in the file '/tmp/mystack' . << Stack should appear here debug> quit $ exit GDB: $ script /tmp/mystack $ gdb $ORACLE_HOME/ bin/<program> core (gdb) bt ..(sdb) q $ exit (NOTE: In the 'adb' commands below literally type the $c & $q) ADB: $ script /tmp/mystack $ adb $ORACLE_HOME/ bin/<program> core $c << NB: adb has no prompt so just enter $c . Upload this to Oracle Support. If all debuggers fail then there is probably a problem with either the permissions or the file type ..see the section below and then contact Oracle Support with all the details you have so far...you can usually check this by typing: limit in the C shell OR ulimit -a in the Bourne / Korn shells..

export LANG . This makes the stack trace useless. . The location of this special file may be different depending on your HPUX version. To identify the same lets create a tablespace with some default value and set the autoextend on without the MAXSIZE specified. If 'file program' shows the word 'stripped' or 'nm program' shows no output then it is likely that the executable is stripped of symbolic information. Here is a simple way of identifying to what size a datafile can grow maximum and then switch to the next datafile. HP Unix Some platforms like HP Unix need a special object file linking in at link time to ensure symbols in shared objects can be reported by the debug tool.on most Unix platforms this involves ensuring there is no '-s' option on the link line. If 'file core' does not return the executable name: ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~ Try using the 'strings' command: csh> setenv LANG C or ksh> LANG=C. Contact Oracle Support with details of the link line used to link the tool. 29 What command is used to find size of a process ??? ps -aefl 30 How do you find out what shared memorysegments are assigedn to different os users ?? ipcs -s 31 Some cases if you down the database even though shared memory is not released what command is used to clear the shared memory ?? ipcrm 32 How big i create the data file size ?? Identifying the Oracle database datafile maxsize on a given platform There are always some ambiguity on the datafile size limit on a given platform and version of the database. Typically this involves relinking the tool including /usr/lib/end.. 'xdb' generally tells you the location of this file if it was not linked into the executable. o on the link line. Stripped Executable Some program executables are stripped of symbol information. In this case the problem tool must be relinked without being stripped .If this limit is too small the core file will be useless raise the limit and reproduce the problem..to get rid of non-ASCII characters return by 'strings' > strings -a core | more The first part of the output may reveal the executable name.

SVRMGR>Create tablespace WORK_SPACE_DATA datafile '/keg4/oradata/ fpdev1/work_ space_data01. dbf' size 400M AUTOEXTEND ON EXTENT MANAGEMENT LOCAL UNIFORM SIZE 4M NOLOGGING; Lets get the file id of the datafile created for the WORK_SPACE_DATA tablespace. SVRMGR>select file_id,file_ name,autoextensi ble from dba_data_files where tablespace_name like 'WORK_SPACE_ DATA'; FILE_ID AUT FILE_NAME ---------- --- ------31 YES /keg4/oradata/ fpdev1/work_ space_data01. dbf Querying the filext$ table we can get the value of the maximum size in database blocks the datafile can grow before switching to the next file. So technically this must be the maximum filesize that oracle can presumably understand for a database datafile. SVRMGR> select * from filext$ where file# = 31; FILE# MAXEXTEND INC ---------- ---------- ---------31 4194302 1 Setting the default would give you a maximum value of 4194302 blocks with increments of 1block when the datafile extends. On a database of 8K block size this would work out to be, SVRMGR> select (4194302*8192) /1024/1024/ 1024 Max from dual; Max ---------31.9999847 So, the database datafile can have a maximum size of 32Gb on a 8k database block size and Sun Solaris8 platform. The above shows that the dependency is on the database block size for a given platform. Also if we do not set the MAXSIZE for the datafile , then the first datafile would grow to the MAXEXTEND value and only then would shift to the next datafile for a given tablespace with multiple datafiles. So it is imperative to set the MAXSIZE value when turning on the AUTOEXTEND option. 33 when do i go for multiple dbwr processes ???what parameters are considered ??? 34 When you run a report you got snapshot tool old error? what do you do ??? Shrink the rollback segment and then re-run the report or assign private rollback segment to report 35 How do i see what is there in redolog files ?? logminor. 36 How do you get the free space, used space for a tablesapce ?? SELECT SUBSTR(FILE_ NAME,1,30) file_name, a.file_id file#, A.TABLESPACE_ NAME,A.BYTES/ (1024*1024) totsize,

(A.BYTES/(1024* 1024)- round(nvl(SUM( B.BYTES/( 1024*1024) ),0),2)) used, nvl(round(SUM( B.BYTES/( 1024*1024) ),2),0) "FREE" FROM DBA_DATA_FILES A, DBA_FREE_SPACE B WHERE A.TABLESPACE_ NAME =B.TABLESPACE_ NAME(+) AND A.FILE_ID =B.FILE_ID(+ ) AND A.TABLESPACE_ NAME='SYSTEM' GROUP BY SUBSTR(FILE_ NAME,1,30) , A.TABLESPACE_ NAME,A.BYTES/ (1024*1024) ,a.file_id order by 2 37 What is the difference between row migration and row chaining?? Concepts -------There are two circumstances when this can occur, the data for a row in a table may be too large to fit into a single data block. This can be caused by either row chaining or row migration. Chaining --------Occurs when the row is too large to fit into one data block when it is first inserted. In this case, Oracle stores the data for the row in a chain of data blocks (one or more) reserved for that segment. Row chaining most often occurs with large rows, such as rows that contain a column of datatype LONG, LONG RAW, LOB, etc. Row chaining in these cases is unavoidable. Migration ---------Occurs when a row that originally fitted into one data block is updated so that the overall row length increases, and the block's free space is already completely filled. In this case, Oracle migrates the data for the entire row to a new data block, assuming the entire row can fit in a new block. Oracle preserves the original row piece of a migrated row to point to the new block containing the migrated row: the rowid of a migrated row does not change. When a row is chained or migrated, performance associated with this row decreases because Oracle must scan more than one data block to retrieve the information for that row. o INSERT and UPDATE statements that cause migration and chaining perform poorly, because they perform additional processing. o SELECTs that use an index to select migrated or chained rows must perform additional I/Os. Detection --------Migrated and chained rows in a table or cluster can be identified by using the ANALYZE command with the LIST CHAINED ROWS option. This command collects information about each migrated or chained row and places this information into a specified output table. To create the table that holds the chained rows, execute script UTLCHAIN.SQL. SQL> ANALYZE TABLE scott.emp LIST CHAINED ROWS; SQL> SELECT * FROM chained_rows; You can also detect migrated and chained rows by checking the 'table fetch continued row' statistic in the v$sysstat view. SQL> SELECT name, value FROM v$sysstat WHERE name = 'table fetch continued row'; NAME VALUE ------------ --------- --------- --------- --------- --------- - --------table fetch continued row 308 Although migration and chaining are two different things, internally they are represented by Oracle as one. When detecting migration and chaining of rows you should analyze carrefully what you are dealing with.

Resolving --------o In most cases chaining is unavoidable, especially when this involves tables with large columns such as LONGS, LOBs, etc. When you have a lot of chained rows in different tables and the average row length of these tables is not that large, then you might consider rebuilding the database with a larger blocksize. e.g.: You have a database with a 2K block size. Different tables have multiple large varchar columns with an average row length of more than 2K. Then this means that you will have a lot of chained rows because you block size is too small. Rebuilding the database with a larger block size can give you a significant performance benefit. o Migration is caused by PCTFREE being set too low, there is not enough room in the block for updates. To avoid migration, all tables that are updated should have their PCTFREE set so that there is enough space within the block for updates. You need to increase PCTFREE to avoid migrated rows. If you leave more free space available in the block for updates, then the row will have more room to grow. SQL Script to eliminate row migration : -- Get the name of the table with migrated rows: ACCEPT table_name PROMPT 'Enter the name of the table with migrated rows: ' -- Clean up from last execution set echo off DROP TABLE migrated_rows; DROP TABLE chained_rows; -- Create the CHAINED_ROWS table @.../rdbms/admin/ utlchain. sql set echo on spool fix_mig -- List the chained and migrated rows ANALYZE TABLE &table_name LIST CHAINED ROWS; -- Copy the chained/migrated rows to another table create table migrated_rows as SELECT orig.* FROM &table_name orig, chained_rows cr WHERE orig.rowid = cr.head_rowid AND cr.table_name = upper('&table_ name'); -- Delete the chained/migrated rows from the original table DELETE FROM &table_name WHERE rowid IN (SELECT head_rowid FROM chained_rows) ; -- Copy the chained/migrated rows back into the original table INSERT INTO &table_name SELECT * FROM migrated_rows; spool off Note ---When you run the script in the document to clean up the chained rows if the table contains long raw columns, the script will fail with ORA-997: Illegal use of LONG datatype. This error is normal as you cannot do a CTAS when you have long raws. Also, by the nature of the long raw datatype, chaining is unavoidable. 38 How to Turn Archiving ON and OFF ??? Turning Archiving On and Off ============ ========= ======= This section describes the aspect of archiving and includes the following topics: - Setting the Initial Database Archiving Mode

. you set the initial archiving mode of the redo log in the CREATE DATABASE statement.---------. the initial archiving mode of the database is operating system specific. NOTE: ARCHIVELOG mode is necessary for creating on-line backups and for certain types of database recovery. you should generally not switch the database between archiving modes.Performing Manual Archiving You set a database's initial archiving mode as part of database creation. If you do not specify either ARCHIVELOG or NOARCHIVELOG.Disabling Automatic Archiving * Disabling Automatic Archiving at Instance Startup * Disabling Automatic Archiving after Instance Startup .-----------. After a database has been created. NOTE: If a database is automatically created during Oracle installation.----. After creating the database. the database can be restored from a backup in case of failure. See your operating system-specific Oracle documentation. execute following statement: SVRMGR> Select * from V$DATABASE NAME CREATED LOG_MODE CHECKPOINT ARCHIVE_CH ---. If ARCHIVELOG mode is disabled. NOARCHIVELOG is the default. decide whether to change from the initial archiving mode. However.Changing the Database Archiving Mode . Configuring the database to operate in ARCHIVELOG mode allows the user to perform complete and point-in-time recovery from media (disk) failures using off-line or on-line backups.---------ORCL 05/21/97 17:55:06 NOARCHIVELOG 172185 170808 Enabling Automatic Archiving at Instance Startup ============ ========= ========= ========= ========= .-----------. you can switch the database's archiving mode on demand. To verify database mode.Enabling Automatic Archiving * Enabling Automatic Archiving at Instance Startup * Enabling Automatic Archiving After Instance Startup . but it cannot be rolled forward from that to a point when failure occured. you can use the default of NOARCHIVELOG mode at database creation because there is no need to archive the redo information generated at that time. Setting the Initial Database Archiving Mode ============ ========= ========= ========= ==== When you create the database. Usually.

if your format is: arch%s. in the database's parameter file: LOG_ARCHIVE_ START=TRUE The new value takes effect the next time you start the database. arch2. For example. arch3. LOG_ARCHIVE_ DEST: This parameter specifies the directory where your archive logs will be placed. LOG_ARCHIVE_ FORMAT: This parameter names the archive logs in this format. if an instance is shutdown and restarted after automatic archiving is enabled using this option. Changing the Database Archiving Mode ============ ========= ========= ====== There are "init. which may or may not enable automatic archiving. etc is the sequence number. the instance does not have to be shut down to enable automatic archiving. Enabling Automatic Archiving After Instance Startup ============ ========= ========= ========= ========= ==== To enable automatic archiving of filled online redo log groups without shutting down the current instance.To enable automatic archiving of filled groups each time an instance is started. .arc where the '1'. Set this parameter to TRUE if you do NOT wish to have to MANUALLY archive your redo log files when in ARCHIVELOG mode. When using this option. However.ora" parameters you need to modify in order to properly handle your database being in archive log mode. The following statement enables archiving: SVRMGRL> ALTER SYSTEM ARCHIVE LOG START. They are: LOG_ARCHIVE_ START LOG_ARCHIVE_ DEST LOG_ARCHIVE_ FORMAT LOG_ARCHIVE_ START: Enables automatic archiving of filled groups each time an instance is started.arc. include the "LOG_ARCHIVE_ START" parameter. '2'. use the SQL command ALTER SYSTEM with the ARCHIVE LOG START parameter. the instance is reinitialized using the settings of the parameter file ("LOG_ARCHIVE_ START"). '3'. set to TRUE.arc Your log files will be called: arch1.arc.

Perform any operating system specific steps (optional). Archive all your redo logs at this point. See the Oracle7 Parallel Server Concepts & Administration guide for more information about switching the archiving mode when using the Oracle Parallel Server. Open the database. This backup can be used with the archive logs that you will generate. SVRMGRL> shutdown An open database must be closed and dismounted and any associated instances shut down before the database's archiving mode can be switched. but do not open the database. Verify your database is now in archivelog mode. 7. Archiving cannot be disabled if any datafiles need media recovery. Switch the database's archiving mode. 2. 4. you must mount the database exclusively using one instance to switch the database's archiving mode.To Prepare to Switch Database Archiving Mode ============ ========= ========= ========= ===== 1. SVRMGRL> startup mount NOTE: If you are using the Oracle Parallel Server. SVRMGRL> alter database open. Database log mode Archive Mode Automatic archival Enabled Archive destination for example: $ORACLE_HOME/ dbs/arch Oldest on-line log sequence 275 Next log sequence 277 Current log sequence 278 8. SVRMGRL> alter database archivelog. . 3. Shut down the database instance. 5. 9. Backup the database. SVRMGRL> archive log list. Ensure these newly created Archive log files are added to the backup process. Start up a new instance and mount. 6. SVRMGRL> archive log all.

If a database is operated in ARCHIVELOG mode. and all groups of online redo log files are filled but not archived. you must be connected with administrator privileges and have the ALTER SYSTEM privilege. set the "LOG_ARCHIVE_ START" parameter of a database's parameter file to FALSE: LOG_ARCHIVE_ START=FALSE The new value takes effect the next time the database is started. if an instance is shut down and restarted after automatic archiving is disabled. database operation is temporarily suspended until the necessary archiving is performed. The following statement stops archiving: SVRMGRL> ALTER SYSTEM ARCHIVE LOG STOP. To disable automatic archiving after instance startup. Therefore. Disabling Automatic Archiving at Instance Startup ============ ========= ========= ========= ========= = To disable the automatic archiving of filled online redo log groups each time a database instance is started. However. However. use the SQL command ALTER SYSTEM with the ARCHIVE LOG STOP parameter. LGWR cannot reuse any inactive groups of online redo log groups to continue writing redo log entries. the instance is reinitialized using the settings of the parameter file ("LOG_ARCHIVE_ START"). ARCH finishes archiving the current group. once automatic archiving is disabled.Disabling Automatic Archiving ============ ========= ======== You can disable automatic archiving of the online redo log groups at any time. If ARCH is archiving a redo log group when you attempt to disable automatic archiving. And. automatic archiving is disabled. The instance does not have to be shut down to disable automatic archiving. but does not begin archiving the next filled online redo log group. which may or may not enable automatic archiving. archive log list. NOTE: If you choose to disable automatic archiving and have not . command executed from SVRMGRL will show: Automatic archival Disabled Disabling Automatic Archiving after Instance Startup ============ ========= ========= ========= ========= ==== To disable the automatic archiving of filled online redo log groups without shutting down the current instance. you must manually archive groups of online redo log files in a timely fashion. Automatic archiving can be disabled at or after instance startup.

archives all unarchived log files.) To manually archive a filled online redo log group. You want to turn archiving off for a period of time and then turn it on to continue archiving without bouncing your database. Manually archive inactive groups of filled online redo log members using the SQL command: SVRMGRL> ALTER SYSTEM ARCHIVE LOG ALL. You can manually archive groups of the online redo log whether or not automatic archiving is enabled. you can use manual archiving. the instance can decide to reuse the redo log group before you have finished manually archiving. Resources ========= See your Administrators Guide for other ALTER SYSTEM ARCHIVE options. thereby overwriting the files. you are responsible to archive all filled redo log groups or else database operation is temporarily suspended (you will experience a database hang) until the necessary archiving is performed. Attempting to repeat that command with a last redo log group will show hang. If all online redo log groups are filled but not archived. You believe the following commands will work: SVRMGR> alter system archive log stop SVRMGR> alter system archive log start . Therefore. You can exercise this scenario by executing alter system switch logfile command when automatic archival is disabled. (However.disabled archiving altogether. Performing Manual Archiving ============ ========= ====== If a database is operating in ARCHIVELOG mode. LGWR cannot reuse any inactive groups of online redo log members to continue writing redo log entries. Oracle will display an error message in the ALERT file. and it won’t be completed with ‘statement processed’ message until archiving is done. but you want to rearchive an inactive group of filled online redo log members to another location. inactive groups of filled online redo log files must be archived. you must be connected with administrator privileges. 39 CAN ARCHIVING BE TURNED OFF/ON WITHOUT BOUNCING THE DATABASE? Problem Description: ============ ======== Your database is in ARCHIVELOG mode. If automatic archiving is not enabled. If this happens. you must manually archive groups of filled online redo log files in a timely fashion. database operation is temporarily suspended until the necessary archiving is performed. If automatic archiving is enabled.

SVRMGR> archive log list. 3. They do not turn archiving off or on. The following test shows that the database will eventually hang if you issue this command.2/dbs/arch Oldest online log sequence 90 Next log sequence to archive 93 Current log sequence 93 SVRMGR> alter system switch logfile. SVRMGR> archive log list.2/dbs/arch SVRMGR> alter system switch logfile. SVRMGR> archive log list. Solution Description: ============ ========= You must bounce the database to turn archiving off and on. Statement processed. Statement processed. Statement processed. SVRMGR> alter system archive log stop. Database log mode Archive Mode Automatic archival Disabled . Database log mode Archive Mode Automatic archival Enabled Archive destination /u02/app/oracle/ product/7.2/dbs/arch Oldest online log sequence 91 Next log sequence to archive 94 Current log sequence 94 SVRMGR> alter system archive log stop. Database opened. SVRMGR> archive log list. Example: Database mounted. Database log mode Archive Mode Automatic archival Enabled Archive destination /u02/app/oracle/ product/7. Database log mode Archive Mode Automatic archival Disabled Archive destination /u02/app/oracle/ product/7. 3.You want to know if the commands will allow archiving to be turned off and on without bouncing the database. These commands only alternate the archiving mode from AUTOMATIC to MANUAL. 3.

. Statement processed.. SVRMGR> alter system switch logfile. When all redo logs are full (this was simulated by switching logs).2/dbs/arch Oldest online log sequence 92 Next log sequence to archive 94 Current log sequence 95 *** log files until all the log files need archiving. another log file switch will not occur until the log files are MANUALLY archived. or automatic archiving is enabled.. but. *** Open another Server Manager session and issue the following command: SVRMGR> alter system archive log start. *** automatic archiving. 3.. Statement processed. the log switch occurs. Solution Description: ============ ======== . the database is still running in archivelog mode... the database is no longer hung. 40 ALTER SYSTEM ARCHIVE LOG STOP DOES NOT TURN OFF ARCHIVELOG MODE Then what do you do ?? Problem Description: ============ ======== You have attempted to turn off archiving using the command: SVRMGRL> alter system archive log stop. Statement processed. After issuing this command the full redo logs are archived.. SVRMGR> alter system switch logfile...Archive destination /u02/app/oracle/ product/7. .. At this point the DB hangs because automatic archiving is disabled. *** SVRMGR> alter system switch logfile. Explanation: ============ You had to bounce the database to turn archiving off or on.. and the first session returns to the Server Manager prompt. The commands you attempted to use to do this only alternate the archiving mode from AUTOMATIC to MANUAL.

but it will not change the database from archivelog mode to noarchivelog mode. startup mount SVRMGRL> alter database noarchivelog. alter the database to run in noarchivelog mode as follows: Before issuing alter database noarchivelog. 41 How do you estimate the amount of redo per day?? Problem Description ============ ======= How do we find out how much redo is generated per day? Solution Description: ============ ========= Multiply (Redo per Day) by (Redo File Size).. you first need to be in mount mode.ora parameter LOG_ARCHIVE_ START = false. To ensure archiving has been disabled run: SVRMGR> archive log list Database log mode No Archive Mode Automatic archival Disabled Archive destination ?/dbs/arch Oldest online log sequence 481 Current log sequence 483 Solution Explanation: ============ ======== 'Alter system archive log stop' will disable the automatic archiving of redo log file groups. Issuing the command "ARCHIVE LOG LIST" SVRMGR> archive log list. Changing the database to run in noarchivelog mode will turn off archiving. you should also set the init.. alter database open. do the following: SVRMGRL> alter database noarchivelog. So. Database log mode Archive Mode Automatic archival Enabled . Then.To turn off archiving. If you intend this to be a permanent change. To turn off archiving.

osupport dba 2048 Oct 30 11:57 _0000000016. Archival Required. log osupport dba 12288 Nov 3 09:48 _0000000021.PROD Description: Archive Process Error: Cannot allocate Log. but nothing happens. In ARCHIVE Log mode. taking the Number of Redo Logs created in 24 hours and multiplying that by the redo log file size will give us the general estimate of redo generated in bytes per day. log osupport dba 14336 Nov 3 09:47 _0000000020. log osupport dba 10240 Oct 30 14:00 _0000000018. log osupport dba 2048 Nov 3 09:48 _0000000023. Oracle just hangs. ARCHIVAL REQUIRED Problem Description: ============ ======== Oracle starts up and users connect. The Windows NT Event Viewer has a message from Oracle7. log 42 What you do if you get an error CANNOT ALLOCATE LOG. log osupport dba 3072 Nov 3 09:48 _0000000022. log osupport dba 79872 Nov 3 09:48 _0000000024. Database was then shutdown and restarted. So adding the archive file sizes during a 24-hour period will give us the amount of redo generated. since we have the archived log files with the date/time stamp and the varying byte size for each log. we can estimate the value even better. log osupport dba 26624 Nov 3 09:44 _0000000019.PROD: Event ID: 20 Source: Oracle7. .Archive destination /u05/home/usupport/ kbahadur/ database/ archive Oldest online log sequence 20 Next log sequence to archive 25 Current log sequence 25 command on two consecutive days at the same time and taking the difference between the 'current log sequence' will give us the number of redo logs generated during a 24 hour period. log osupport dba 6048 Oct 30 12:11 _0000000017. Explanation: ============ In NOARCHIVE Log mode. log osupport dba 5035 Nov 3 10:11 _0000000025. Solution Description: ============ ========= The database was recently put in Archivelog mode by doing a 'startup mount exclusive' and then an 'alter database archivelog'.

no activity will be allowed until the log files are archived. 43 what is responsibility ?? A responsibility is a level of authority in Oracle Applications that lets users access only those Oracle Applications functions and data appropriate to their roles in an organization. This parameter enables automatic archiving and prevents you from needing to manually archive redo logs every time they fill up.' when connected as SYS or INTERNAL shows the following: Database log mode Archive Mode Automatic archival Disabled Explanation: ============ This problem occurs because automatic archiving is disabled.ora and set the parameter 'LOG_ARCHIVE_ START=TRUE' . The cause of the problem is automatic archiving is disabled. See Oracle7 Server SQL Reference for syntax of the ALTER SYSTEM command and the ARCHIVE LOG clause. concurrent programs. Redo logs can be manually archived by issuing the command ALTER SYSTEM ARCHIVE LOG ALL. that may be run by an application user under a particular responsibility. A Data Group determines which Oracle database accounts a responsibility’s forms. or you can specify individual log files. If the database is not archiving automatically. 47 what is menu in oracle applications ?? A menu is a hierarchical arrangement of application functions (forms) that displays in the Navigate window. To help ensure that your responsibility key is unique throughout your system. and reports connect to. 44 what is the use of responsibility key defining the responsibility ?? This is a unique name for a responsibility that is used by loader programs. A better option is to modify the init. 45 what is a adata group ? A Data Group defines the mapping between Oracle Applications products and ORACLE IDs. user profiles and user profile values into your Oracle Applications tables. Menus can also point to non form functions (subfunctions) that do not display in the Navigate . When the databse is in archive log mode and the redo logs fill up. 46 what is Request Security group ? A request security group defines the concurrent programs.Doing an 'Archive log list. Loaders are concurrent programs used to load such information as messages. including requests and request sets. begin each Responsibility Key name with the application short name associated with this responsibility. activity will cease until the redo logs are manually archived.

Or as a user that has the responsibility determined in step 3 assigned to them. then any user login will work). which is the # after the colon : i. 48 What is the profile option is used to set the window help ?? Applications Help Web Agent : http://apps01. which is either a specific: . (like FND_RESP1:20420) then use the following sql to find the Responsibility Name from the ID.Login to Core (forms based) Applications as the user determined in step 2. version=1.System Administrator 4. or . 1.ad4a-11d5.b63e-00c04faedb1 8 2.sql jvmsec5.sql 50 Cannot view Workflow Monitor Diagrams ?? 1.window. Each responsibility is associated with a menu.RESPONSIBILITY.0.2. select text from wf_resources where name = 'WF_ADMIN_ROLE' TEXT -----------.2 ?? Run the following scripts as sys user jvmsec3.com:8005/ pls/CRP/fnd_ help.Verify which userid the WF_ADMIN_ROLE is assigned to: The following SQL should reveal the Workflow Adminstrator ROLE.16 jinit_mimetype= application/ x-jinit-applet.An Asterisk '*' which indicates Everyone. but that define the range of application functionality available for a responsibility. hil.--------.e. FND_RESP1:20420 = ID = 20420 select RESPONSIBILITY_ NAME from FND_RESPONSIBILITY_ TL where RESPONSIBILITY_ ID = '20420' RESPONSIBILITY_ NAME -----------.--------. or .Check that the jinitiator version and the classid in use on your system by looking at the following entries in the $OA_HTML/bin/ appsweb.8. (If step 2 returned '*'.3 to 9. 1.8.-SYSADMIN 3.USER.1.--------.cfg jinit_ver_name= Version=1.launch? lang=US 49 Unable to login to personal home page after upgrade the database from 9. .If the above sql returns a Responsibility.0.16 jinit_classid= clsid:9b935470.

parameters= -Djava.msg 51 Unable to see online help ?? Added the following line in jserv.00c04faedb18 Jinitiator Version = 1.msg (from step 7) using the following command: WFRESGEN APPS/<APPS Password> 0 Y $FND_TOP/resource/ wfcfg. Finally. substr(text. from the example above Jinitiator Classid = 9b935470-ad4a.18) Name.1.7 wrapper.16 7.msg file WFTKN WF_WEB_AGENT 0 http://<host> .16 8.1.11d5-b63e.<domain> :<port> /pls/<SID> WFTKN WF_ADMIN_ROLE 0 SYSADMIN WFTKN WF_CLASSID 0 9b935470-ad4a. 0.55) Value from wf_resources where name in ('WF_WEB_AGENT' . 9.11d5-b63e. verify the values in $FND_TOP/resource/ wfcfg. 0.e. If the values in the database are incorrect you can upload the values from the wfcfg. verify the settings in the database with the following SQL: select substr(name.properties file for online help this has to done on application servers For online Help on 11. 'WF_VERSION' .Verify the settings match the ones from the $OA_HTML/bin/ appsweb.Select Global Preferences from the Workflow Menu 6.5.Similarly.zip A: copy the directory form BOM_TOP/java/ make to database tire then reapply the patch.8. 'WF_PLUGIN_VERSION' ). 'WF_PLUGIN_DOWNLOAD '.cfg file in step 1 i. 'WF_ADMIN_ROLE' .00c04faedb18 WFTKN WF_PLUGIN_VERSION 0 1.5.8.prm file .bin.compiler= NONE 52 while applying the patch if you get an error on database tire ?? adogjf() Unable to generate jar files under APPL_TOP AutoPatch error: Failed to generate the product JAR files AutoPatch error: Error updating apps. 'WF_CLASSID' . Unable to start the express instance ?? add the following entry in express.

.0. htm 5) install jinitiator then connect to apps.0. hil.#Added from Support AIXTHREAD_STK= ${AIXTHREAD_ STK:="320000" } .24 hiltrn.25 apps01. but I personally recommend a window of 5-30 minutes between switches when the system is under load...8.hil. 55 How to release the space below high water mark ? alter index index_name deallocate unused.sh to create new certification on client side.hil. 6)If it is taking lot of time then ftp the file from the server at following location then install $COMMON_TOP/ util/jinitiator/ Ex: /devl/viscomn/ util/jinitiator/ jinit11816.26 apps02.com 10.16 change network access to unrestricted then restart the browser and then relogin even if u get the same message clear a jcache and temporary internet files from the browser properties then restart the machine and connect. export AIXTHREAD_STK 53 How to remove yello worning bar?? over write identitydb.0.. exe What if you get an error FRM-9200 when connecting to applications ?? start the jinitiator control panel 1.190. 54 How to communicate clients to the applications ? For Windows 98 machines: 1) open a note pad 2) put the following entries in the notepad 10.190.1.( to release the space below high water mark) 56 What should be the size of redolog members ? Redo logs should be sized based upon 2 factors: 1) Are you archiving 2) How often are your logs switching If you are archiving You need to size the logs such that log switches occur no LESS than every 5 minutes You also need to make sure that logs are not switching too infrequently .190.com 10..com:8003/ OA_HTML/US/ ICXINDEX. you dont want to loose more than say 30 minutes of work .hil.com 3) save as "hosts" in c:\windows 4) restart the browser and give the URl like as below http://apps02. The reason we recommend this is in case the online redo log becomes corrupt and the DB has to be recovered point in time to the last log switch .obj on clint machine from where there is no yello warrning bar or run adjkey and adjbuild. sometimes this is not possible as there are gaps in work ..

On our systems we force a log switch every 15 minutes.... On our systems we force a log switch every 15 minutes. . Since recovery is not possible when not archiving a long time between switches really becomes irrelivant Bottom line you are trying to hit a happy medium between requiring use of a stale log before it is finished switching (switching logs too fast) and having too long of a time between switches If you need further assistance on this issue. Please feel free to post a reply and we will be happy to assist you It is better to make the redo logs much bigger and then run a cron script to force a log switch every so often (during the slow periods). This way the heavy periods do not bog down due to a bunch of log switches and the light periods are broken up by the forced switches.>> There is no problem issuing this command while transactions are happening... Example: from 8am to 5pm force a switch every 15 min from 5pm to midnight force a swithc every hour from midnight to 8am dont force a switch I dont know if this can be done with CRON . This way the heavy periods do not bog down due to a bunch of log switches and the light periods are broken up by the forced switches. >> You can do that . this way I can control exactly when the logs get forced . is there any problem if i issue this command when transactions are happening.. but I know it can be done with a stored procedure 57 How do i set optimal parameter for rollback segments ? OPTIMAL= initial+next CREATE ROLLBACK SEGMENT r01 TABLESPACE rbs STORAGE (INITIAL 512000 NEXT 512000 MINEXTENTS 2 MAXEXTENTS 2147483645 OPTIMAL NULL) CREATE ROLLBACK SEGMENT r02 TABLESPACE rbs STORAGE (INITIAL 512000 NEXT 512000 MINEXTENTS 2 MAXEXTENTS 2147483645 OPTIMAL NULL) << How do i set optimal parameter for the rollback segments ? >> Please see the SQL Reference under CREATE / ALTER ROLLBACK SEGMENT << I am explicitily saying alter rollback segment <rbs name> shrink. << It is better to make the redo logs much bigger and then run a cron script to force a log switch every so often (during the slow periods).. I personally would use a stored procedure and an EXECUTE IMMEDIATE ..If you are not archiving You need to size the logs such that log switches occur no LESS than every 30 seconds.

. Please search Metalink on : OPTIMAL 58 Unable to allocate log sequence number ? Most likely this is due to your logs switching too quickly If archiving you want to switch no less than ever 5 min (ie adjust the size of your redo logs) If not archiving you want to make sure that you have sufficiently sized or sufficient number of redo log groups such that when a log switch occurs that you are not trying to switch into a 'stale' log 59 How to find the paging space in AIX system ?? lsps -a Lists the status of defined paging spaces. there are several documents on setting the optimal parameter . iostat 3 20 or topas (topas) 66 How do I find out the operating system version? oslevel or oslevel -r [for maintenance level] . Also gives useful cpu usage info.. vmstat 3 20 or (topas) 65 How to determining disk utilization for each hard drive.. 60 how to find out the physical memory on AIX ?? lsattr -E -lsys0 | grep realmem or lsdev -C | grep Memory 61 How to find out what divesies are defined to the system ?? lsdev -Cc disk 62 How to find the number of processor in a system ?? Lsdev -Cc processor 63 How to estimate of the percentage of cpu and memory utilized by each process currently running ps av 64 how to determining how much paging activity is taking place on the system..<< What will be the effect of this statement? >> Please see the SQL Reference under ALTER ROLLBACK SEGMENT for an explanation <<On what basis i should set the optimal parameter for the rollback segments? >> This is a tuning question that is outside the scope of support .

pls 115. you would encounter an issue that would necessitate manually regenerating the Forms module executable or FMX file. mmb userid=apps/ apps output_file= FNDMENU. 75 How can you affect the look and feel of your Apps forms? .--------. fmx module_type= form batch=yes compile_all= special 71 How do you generate Apps Forms library modules or PLL files? To do this you issue the following command: f60gen module=library_ name.-------FND_REQUEST PACKAGE package FND_REQUEST AUTHID CURRENT_USER as ND_REQUEST PACKAGE /* $Header: AFCPREQS. To do this you issue the following command: f60gen module=form_ name.pls 115.--------. 73 What is compile_all= special? For standalone Forms the only valid values for compile_all are ?yes? and ?no?.27 2001/07/28 09:35:16 $ */ What we?re looking for is the name and version number (AFCPREQS.type.mmx module_type= menu batch=yes compile_all= special 70 How do you generate Apps Forms modules or FMB files? Oftentimes as part of upgrading Forms or modifying a Form module or applying a patch modifying a Form module.text from user_source where name ='FND_REQUEST' and line < 3 NAME TYPE TEXT -----------. After applying an Apps patch? True.--------.-----------. some are true some are not: After an operating system upgrade? False After a database upgrade? False After applying a Developer patch? False.27) of the files that create the package.4 2000/02/29 11:51:08 $ */ FND_REQUEST PACKAGE BODY package body FND_REQUEST as FND_REQUEST PACKAGE BODY /* $Header: AFCPREQB.67 How do I found out the process memory space usage? svmon -P <process id#> 68 How to find which instance owns which shared memory and semaphores On a Unix machine give the following commands $ ipcs -b 69 How do you generate Apps Forms menu modules or MMB files? f60gen module=FNDMENU.--------.-----------.--.pls 115.4 and AFCPREQB. After applying an I/O patch? True. but only if there is a g driver involved.fmb userid=apps/ apps output_file= form_name. 74 How do you get the latest package release? SQL> select name. Support will then determine if it?s advisable to apply the latest release of those files.pls 115. compile_all= special is similar except that it doesn't attempt to update the source files.pll userid=apps/ apps module_type= library batch=yes compile_all= special 72 When do you have to regenerate your Apps Forms modules? Apps forms are regenerated.

g. hil.e. 77 How is Forms load balancing accomplished? Currently Forms load balancing is done through proprietary programs called Metric Server and Metric Clients.D patch will allow control of some of these settings through the system profile: Java Look and Feel=Oracle (or generic) Java Color Scheme=blue (or teal. purple) 76 How do you disable direct Forms access through the http://host: port/dev60cgi/ f60cgi URL? You can do this by using the mod_rewrite (the Swiss Army Knife of URL manipulation :) engine of the Apache server. if the URL does not have certain parameters in it then I redirect the user to a different web page of my choice. The Oracle HTTP server handles the initial request. and presents a list of responsibilities for the end user to choose from. The Forms Listener/Server port will allow socket or https traffic. olive. titanium. The Metric Server then uses this information to decide which machine to pass a request to run a web form. load balancing will no longer be done via Metrics Servers and Metric Clients. Self Service applications will continue to use only this listener. In your httpd.1 are good sources for more info.cfg file: lookAndFeel= Oracle (or generic) colorScheme= blue or (teal. etc. requests to the TCF servlet. but if a core application is invoked. requests for help files. khaki.com You'll have to tighten up the code somewhat but here I am taking advantage of the fact that the URL for accessing Apps directly and through the personal home page are not exactly the same i. blue.1 and Metalink Note# 148516. titanium.You can alter the interface look and feel of Apps forms by changing the values of the following variables in the appsweb. Metalink Note# 111270. blue. red. red. authentication to the server. purple) background=no readonlyBackground= automatic The FND. khaki. olive. 79 How to set up Forms to work through a firewall? In the current Form Services architecture a firewall needs be configured to allow traffic on 2 ports. The Metric clients are setup on machines with a corresponding Forms server and they constantly report to a Metric Server their load situation. The built-in load balancing capability of the HTTP server (Oracle HTTP powered by Apache) along with its jserv mod will be used instead. The listener port of the Oracle HTTP server (usually port 80 or 8002) and the Forms Listener/Server (usually 9000). In the new Forms Servlet architecture the only port that needs to be open is the Oracle HTTP 80 Note down some important profile options in sysadmin point of view ??? APPS_WEB_AGENT ATTACHMENT_FILE_ DIRECTORY CZ_UIMGR_URL HELP_WEB_AGENT ICX_FORMS_LAUNCHER ICX_REPORT_CACHE ICX_REPORT_IMAGES . the client makes a request to the Forms Listener that then creates a new Forms Server Runtime process. The Oracle HTTP server port will allow http traffic e. 78 How is Forms load balancing accomplished with Forms listener servlet? Once Forms servlet is supported in Apps.conf file add the following lines at the end: RewriteEngine on RewriteCond %{QUERY_STRING} !NLS_LANG RewriteRule ^/dev60cgi/f60cgi$ http://hiltrn.

dat file and change the RGB value for app.requiredFiel dVA from true to false (note that this is what the OracleApplications2 . etc.com:8003/ dev60cgi/ f60cgi?config= test115&play= &record=collect& log=/usr/ tmp/sysadmin_ frd. To turn off the color of the required item you can either change the value of app.com/ access/scripts 81 What is f60webmx? The f60webmx is your web forms runtime executable.log Note that like any Apps profiles you can do this on various levels e.dat is for. us.click on Profile/System . To do this you issue the following command: $ad_relink. class) Forms Server . 86 How can you affect the look and feel of your Apps forms? . hil. a requirement for the ADA). site. You have to restart Jinitiator for this to take effect. class) 85 How do you change the background color of a required item in Apps? Change the $OA_JAVA/oracle/ apps/fnd/ formsClient/ OracleApplicatio ns.Forms Listener Servlet (ListenerServlet. user. With Forms Listener Servlet certain Forms components are replaced: Forms CGI . so that you target your FRD accordingly. For the trace to have meaninful info the executable needs to have been created with debugging symbols.login to Apps as sysadmin . similar to f60webm except that it has Apps specific user exits linked into 82 How can you recreate the f60webmx executable? To do this you issue the following command: $ad_relink.ui. 84 Are there any changes to the Forms product components when in Forms listener servlet? Yes. Also be aware that FRD incurs significant overhead to Apps processing so disable it when not in use.Forms Servlet (FormsServlet.oracle.ICX_REPORT_LAUNCHER ICX_REPORT_LINK ICX_REQ_SERVER MRP_I2_P_FP_ NET_DIR MRP_I2_P_LOG_ DIR MRP_I2_P_RL_ DATA_DIR OE_CONC_LOG_ DIRECTORY TCF:HOST AMS_IMP_DATA_ PATH OE_DEBUG_LOG_ DIRECTORY /USR/TMP OE_DEBUG_LOG_ DIRECTORY /tmp/ JTF_BIS_OA_HTML http://ap804sun.ui.dnb.requiredFiel dVABGColor.g. com:778/OA_ HTML HZ_DNB_URL https://globalacces s.sh force=y debug=y "fnd f60webmx" 83 How do you enable Forms Runtime Diagnostics (FRD) in Apps? To enable Forms Runtime Diagnostics (FRD): .sh force=y ?fnd f60webmx? Note that there might be times when you you need to generate a stack trace from the f60webmx process.add the following to the end of its value "&record=collect& log=" without the quotes Ex: http://apps02.query ICX%FORMS%LAUNCHER (set for user level) .

Unfortunately. whether executed from within the Oracle Application form or executed from the command line is within the context of Oracle Applications. like sending an email to a user. khaki. titanium. blue. If you want to build an alert to fire against a custom table. b. then you will need the following information. Overview of Event Alerts -----------.D patch will allow control of some of these settings through the system profile: Java Look and Feel=Oracle (or generic) Java Color Scheme=blue (or teal. the event alert will only work from within the context of the Oracle Applications. which will fire when a row in a custom table is updated. purple) background=no readonlyBackground= automatic The FND. red. 1]. The article assumes a novice or beginner level. khaki. blue. This can be done from any user/schema account with the DBA Role privileges. How to create and register a customer schema in the Oracle Applications. For example.You can alter the interface look and feel of Apps forms by changing the values of the following variables in the appsweb. You may use event alerts to audit changes to standard Oracle Applications objects or custom objects in user defined database schemas.--------.cfg file: lookAndFeel= Oracle (or generic) colorScheme= blue or (teal.--------. However. Please remember that you must grant to the newly created schema a minimum of "CONNECT" and "RESOURCES" to the . it is not found in the Oracle Alert User's Guide.--------. However. Likewise. titanium. Event alerts can be configured to trigger an action. purple) 87 How to create a custom event alert to fire against a custom table ?? Purpose ------The article should provide you with a step-by-step guide on how to create a custom event alert. The article provides the following information: a. red.--------. Create a Custom Schema. 1] and [NOTE:73492. you must create the schema within the database. First. How to register the Oracle Alert against the custom table. The following provides a step-by-step approach to creating a customer application and registering it within Oracle Applications. 1. Table and Responsibility -----------.--------You may find additional reference to setting up a custom schema in [NOTE:70276. The update can be the result of an insert or update DML statement.--An event alert is a database trigger that tells you when data in an object within the database has been changed. you will not trigger the event alert. olive. olive. if you manually update or insert data from the SQL*Plus environment without setting the Oracle Application context. you should note that the when you use Oracle Alerts to define database triggers. any registereed concurrent manager process or report. any database event that affects the objects made from within a form accessed by a menu from within an Oracle Application Responsibility is within the context of Oracle Applications.

Create the user/schema in the database by using SQL*Plus under any account with DBA Role privileges: Unix Prompt ----------$ sqlplus system/manager SQL*Plus Prompt -----------. The Application Object Library is a repository of Oracle Application specific metadata.--------.--------. for example the Oracle Applications Developers Guide Release 11 contains this information on pages 2-6. like "CUS" .--------. The following is an example row for your user registration: Data Group: Standard . The following is an example row for your user registration: Database Username Password Privilege Install Group Description -----------. (Please refer to the Oracle SQL Reference Guide for your release of the database to secure more information.--------. Then. You register your custom user/schema as an Oracle user within the context of Oracle Applications.--SQL> create user XXCUS identified by XXCUS. You can do this by logging into Oracle Applications as the System Administrator and navigate: Security --> ORACLE --> DataGroup.--------. Log into Oracle Applications as the System Administrator and navigate: Security --> ORACLE --> Register. ) If you would like to follow the Oracle Application guidelines for naming conventions. 4. It is recommended that you prepend an "XX" to the custom schema short name so it will not conflict with any future Oracle Application short names. prepend it with an "XX" so that you have an user/schema "XXCUS" name.--------. You can register the user with the Application Object Library. SQL> grant resource to XXCUS.--------.schema for it to be accessed. or data that lets you extend the functionality of standard Oracle Application System Administration to your customized extensions. SQL> grant connect to XXCUS.--------. you are storing the information within the Application Object Library tables.--------. which is data that defines data. please name your schema with a three character name. 2.Custom Application XXCUS XXCUS_TOP Custom Application You may refer to your Oracle Applications Developers Guide for additional information. You need to add the custom user/schema to a data group.--------.XXCUS XXCUS Enabled 0 Custom Application You may refer to th Oracle Applications Release 11 System Administrator' s Guide on page 9-5 for more detail. For example: Application Short Name Basepath Description -----------. When you register your custom application within the Application Object Library.Customer. 3. When you put the user/schema within the context of Oracle Applications. Log into Applications as the System Administrator and navigate to: Application --> Register.

--------. DECLARE var1 VARCHAR2(1) := 'A'.Description: Standard Data Group Application Oracle ID Description -----------.Custom Application APPS Custom Application 5. 6.---1.--------.--------. Then.--------. You can create a stored code module like the one shown below.--------. they are the defined here for your convenience: General Who-Audit Columns -----------.----You can create a simple one column table as noted below in the sample DDL statement. The Oracle Coding standards suggest that you add the WHO audit columns to the definition of the tables and views. you should create your custom tables. If you are unfamiliar with the concept of WHO audit columns. views and sequences. BEGIN ins_my_event( '1'. which will be a stored procedure in this example. XXCUS. / 2. var2 VARCHAR2(1) := 'B'. you can write a sample query to ensure that a row was inserted based on the example PL/SQL program. var2). Create a Stored Object Code Module -----------. You can log into SQL*Plus as the custom schema owner. in the example the object will be a table with a single column. indexes. CREATION_DATE DATE c. Based on the preceeding example. and a local stored database object.--------.--------. which is required because they are passed by reference. COMMIT. var1. You can now build an object. retcode IN OUT NUMBER ) AS BEGIN INSERT INTO my_event_test VALUES (value). and create the following database objects: Create a Repository Object -----------. END. CREATE TABLE my_event_test (v1 NUMBER). END.--------. errbuf IN OUT VARCHAR2 . You can test your created procedure by writing a small PL/SQL program that passes variables into the "errbuf" and "retcode" variables above. LAST_UPDATE_ DATE DATE Special Who-Audit Columns for Concurrent Manager Programs . / SELECT v1 FROM my_event_test.--------. CREATED_BY NUMBER(15) b. LAST_UPDATED_ BY NUMBER(15) d. CREATE OR REPLACE PROCEDURE ins_my_event_ test ( value IN OUT NUMBER .---a.

--------.--------.--------. PROGRAM_ID NUMBER(15) g.--------. which is defined below.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_KEY_NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_DESCRIPTION VARCHAR2 IN P_KEY_TYPE VARCHAR2 IN DEFAULT P_AUDIT_FLAG VARCHAR2 IN DEFAULT P_ENABLED_FLAG VARCHAR2 IN DEFAULT PROCEDURE REGISTER_PRIMARY_ KEY_COLUMN Argument Name Type In/Out Default? -----------.-----.-. PROGRAM_APPLICATION _ID NUMBER(15) h.-----------.--------. you will find examples for registering the tables and columns from SQL*Plus.-----.-----.--------.--------.--------.--------.-----------.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_COL_NAME VARCHAR2 IN PROCEDURE DELETE_PRIMARY_ KEY_COLUMN Argument Name Type In/Out Default? -----------.-----------.--------.-----------.--------.-----.--------.-.-----.--------.-.--------e.--------.--------.--------. PROGRAM_UPDATE_ DATE DATE 7.--------. Definition of the AD_DD Specification -----------.-.-----------.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_COL_NAME VARCHAR2 IN P_COL_SEQ NUMBER IN P_COL_TYPE VARCHAR2 IN P_COL_WIDTH NUMBER IN P_NULLABLE VARCHAR2 IN P_TRANSLATE VARCHAR2 IN P_PRECISION NUMBER IN DEFAULT P_SCALE NUMBER IN DEFAULT PROCEDURE REGISTER_PRIMARY_ KEY Argument Name Type In/Out Default? -----------.------PROCEDURE DELETE_COLUMN Argument Name Type In/Out Default? -----------.-.--------.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN PROCEDURE REGISTER_COLUMN Argument Name Type In/Out Default? -----------.-------P_APPL_SHORT_ NAME VARCHAR2 IN .--------.-----------.--------.--------. After the specification declarations.--------.-.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_KEY_NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_COL_NAME VARCHAR2 IN DEFAULT PROCEDURE DELETE_TABLE Argument Name Type In/Out Default? -----------.-----. You can register your custom user/schema' s tables or views and any flexfields with the PL/SQL package AD_DD.-----------. REQUEST_ID NUMBER(15) f.--------.--------.

the general form illustrates only the mandatory parameters. P_TRANSLATE ).-----------.register_ column ('XXCUS' .'MY_EVENT_TEST' .REGISTER_ TABLE and AD_DD.You may use the AD_DD.register_ table ('XXCUS' .------EXECUTE ad_dd.-.-. EXECUTE ad_dd.REGISTER_ TABLE & AD_DD.register_ table ( P_APPL_SHORT_ NAME . EXECUTE ad_dd. P_COL_SEQ .--------. P_NULLABLE .--------. The general form and example syntax is noted below.REGISTER_ COLUMN -----------.P_KEY_NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_COL_NAME VARCHAR2 IN P_COL_SEQUENCE NUMBER IN PROCEDURE REGISTER_TABLE Argument Name Type In/Out Default? -----------.REGISTER_ COLUMN to seed the Oracle Applications Object Library with knowledge about your custom objects.'T').register_ column ( P_APPL_SHORT_ NAME .------EXECUTE ad_dd.-----.'V1' .-------P_APPL_SHORT_ NAME VARCHAR2 IN P_KEY_NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_DESCRIPTION VARCHAR2 IN P_KEY_TYPE VARCHAR2 IN DEFAULT P_AUDIT_FLAG VARCHAR2 IN DEFAULT P_ENABLED_FLAG VARCHAR2 IN DEFAULT Example Use of the AD_DD. P_TAB_NAME . P_TAB_NAME . P_COL_WIDTH . For convenience.-----------. You will need to execute these calls to the packages from your "APPS" user/schema.--------. P_COL_TYPE .--------. P_TAB_TYPE ).--------. General Syntax Form -----------.-----.--------.--------.--------. P_COL_NAME . Example Syntax Form -----------.'MY_EVENT_TEST' .--------.--------.-------P_APPL_SHORT_ NAME VARCHAR2 IN P_TAB_NAME VARCHAR2 IN P_TAB_TYPE VARCHAR2 IN P_NEXT_EXTENT NUMBER IN DEFAULT P_PCT_FREE NUMBER IN DEFAULT P_PCT_USED NUMBER IN DEFAULT PROCEDURE UPDATE_PRIMARY_ KEY Argument Name Type In/Out Default? -----------.--------.

'NUMBER' . Below you will find the necessary grants and synonyms required for the sample objects to be accessible by the Oracle Applications. 1. Please remember that you must run these scripts from the "APPS" user/schema account. You must run the scripts from the $AD_TOP/admin/ sql directory in the order noted below. 38 .pls 3.--------. pls MANAGER XXCUS XXCUS SQL> @$AD_TOP/admin/ sql/adaddlb.--------.--------. You may refer to the Oracle Applications Release 11 Oracle Applications Installation manual.------Group: XXCustom Application: Custom Application Code: Description: Custom Application .--------.--------.--------. adaddlb.--------. Example Custom Request Group: -----------.SQL> GRANT all ON my_event_test TO apps.pls General Syntax Form -----------..my_event_ test. You can do this by logging into Oracle Applications as System Administrator and navigate: Security --> Responsibility --> Request.--------SQL> CREATE SYNONYM my_event_test FOR xxcus.'N'). You need to create a custom request group that will hold your custom and/or standard requests within a custom responsibility. You can find supplemental material in the Oracle Applications Developers Guide Release 11 on page 3-2.--------.--------. adaddls. Create Synonyms from the APPS Schema to the Custom Schema -----------. SQL> GRANT execute ON ins_my_event_ test TO apps.1 . pls MANAGER XXCUS XXCUS 9.------SQL> @$AD_TOP/admin/ sql/adaddls. pls MANAGER XXCUS XXCUS SQL> @$AD_TOP/admin/ sql/adaaddlb. pls MANAGER XXCUS XXCUS SQL> @$AD_TOP/admin/ sql/adaaddls. pls <SYSTEM_PW> <SCHEMA_NAME> <SCHEMA_PW> SQL> @$AD_TOP/admin/ sql/adaaddlb. SQL> CREATE SYNONYM ins_my_event_ test FOR xxcus.pls 2. pls <SYSTEM_PW> <SCHEMA_NAME> <SCHEMA_PW> SQL> @$AD_TOP/admin/ sql/adaddlb. adaaddls. Grant Priviledges from the Customer Schema to the APPS Schema -----------.pls 4.ins_my_ event_test. or to the Oracle SQL Reference manual. The general form for executing the command is noted below and then examples based on the "XXCUS" user/schema and "XXCUS" password from above. adaaddlb.--------. After creating and registering your objects and schema. 10. you need to run the APPS_DDL and APPS_ARRAY_DDL packages against your user/schema. pls <SYSTEM_PW> <SCHEMA_NAME> <SCHEMA_PW> SQL> @$AD_TOP/admin/ sql/adaaddls. pls <SYSTEM_PW> <SCHEMA_NAME> <SCHEMA_PW> Example Syntax Form -----------.'N' . 8. Based on the examples provided in step #5 above. you should connect to SQL*Plus and create the appropriate grants and synonyms. page A-7.------SQL> @$AD_TOP/admin/ sql/adaddls.

----+ x Oracle Application Name: Standard Oracle Self Service Web Applications Application: Custom Application +----------.----+ Menu: Requests Menu | Request Group | .--------.sql b) Second. which can be done by navigating: Security --> Responsibility --> Request Group = XXCustom Application = Custom Application . as System Administrator you should do the following steps. you define the concurrent program.--------.--+ Type Name Description You may refer to the Oracle Applications Release 11 System Administrator' s Guide on page 2-9 for more information.----+ Web Host Name: Name: XXCustom Web Agent Name: Application: Custom Application +----------.11. After creating your custom request group. You can now register your test program as a concurrent program under SQL*Plus execution method.--------.--------.-------. Do register the program. you need to ensure that the program is located in the $XXCUS_TOP/sql directory. you setup the executable program. you add the concurrent program to the concurrent request group.--------.----+ | Available From | | Data Group | +----------.----+ +----------.Other Responsibilities +----------. You can do this by logging into Oracle Applications as System Administrator and navigate: Security --> Responsibility --> Define Example Custom Responsibility: -----------. Then.--------.--------.------+ -----------.----+ +----------.--+ | Function and Menu Exclusions | +----------. c) Third. a) First. which can be done by navigating: Concurrent --> Program --> Executable Executable = xxcus_ins Short Name = xxcus_ins Application = PLSQL Test Description = XXCUS insert into event test Execution Method = SQL*Plus Execution File Name = xxcus.+----------.--------. you need to create a custom responsibility for your custom user/schema. 12.----Responsibility Name: XXCustom | Effective Dates | Application: Custom Application +----------.--------.--------. which can be done by navigating: Concurrent --> Program --> Define Program = xxcus_ins Short name = xxcus_ins Application = PLSQL Test Description = XXCUS insert into event test Executable Name = xxcus_ins NOTE: You should leave all other settings as they are set as defaults.------+ Responsibility Key: From: 05-JAN-1999 Description: Custom Responsibility To: +----------.--------.

and click on the Action Set button. You can click on action details: At this point. You can now click on the Action Button and create the detail action for your event alert. you can choose an action type.-------This section will guide you through creating your test event alert based on the example in the first section above. You enter the appropriate general information for your alert: Application = xxcus Name = xxcus_event_ alert Description = My event alert test Type = Event b. The next section discusses how you can create the alert in Oracle Alerts. You should set members as follows: Seq = 1 Action = xxcus_event_ action Type = Action: Message Seq = 2 Action = Exit Action Set Successfully Type = Exit from Action Set successfully .--------. example is based on the test components provided above: SELECT 'Insert into my_event_test table' INTO &V_OUTPUT1 FROM SYS. 3. You can navigate back to the main Alert Definition form. choose the Alert Manager Responsibility and then navigate: Alert --> Define You can create a new alert as follows: a. 1. You can set the general action parameters: Action Name = xxcus_event_ action Action Description = xxcus event detail action Action Level = Detail b. Create the Custom Event Alert -----------. Below is a basic example consistent with the example code in this entry. Seq = 1 Action Set Name = xxcus_event_ actionset Then. by the following steps: a. like a message and complete the message detail.DUAL. you need to check the "Enabled" check box so that your event alert is enabled to run.Code = <not entered> Description = xxcus_ins Requests Type = Program Requests Name = xxcus_ins Requests Application = XXCustom You have now completed the steps on how to create and register a customer schema in the Oracle Applications. You enter the select statement. You log into the Oracle Applications. which will allow you to enter a new action set. NOTE: The article assumes that the integration between Oracle Applications and an operating system mail server is already configured correctly. You enter the Event Alert Details section for your alert and then check the "After Insert" and "After Update" boxes: Application = XXCustom Table = my_event_test c. 2.

you should close the Concurrent Request form.). choose the "xxcust_ins" Concurrent Manager Program and then submit the job. concurrent processing server.Custom Application XXCUS XXCUS_TOP Custom Application 2.Run and View the Custom Alert -----------. programs. After submitting the Concurrent Request. forms server and the database server). 88 How to integrate custom applications with oracle applications? ?? Overview -------This article contains information on how to integrate custom Applications with the APPS schema. Register your custom application with the Application Object Library.--------. This top level directory will reside just under APPL_TOP. you should also receive an email message based on the event alert. 4. You should sign-on to the Oracle Application and navigate to the submit Concurrent Request form. 2... etc. click on "View My Requests" and check that the request completed without error. Log into Applications as the System Administrator and navigate to: Application --> Register. For example: APPL_TOP (/d01/visappl) | . reports. It is not meant to fix and/or solve all issues. It is recommended to use an XX as the preface to the custom schema short name so that it does not conflict with any future Oracle Application short names. For example: Application Short Name Basepath Description -----------. It is recommended that you develop the custom applications code by following the standards exactly as described in the Oracle Applications Developers Guide and the Oracle Applications User Interface Standards manual. but it is a good guideline. Use the basepath parameter from the Application registration for the top level directory.--------. The subdirectories under the custom directory may vary depending on the server type (forms server. If custom Applications are not integrated properly. 3. If the Concurrent Request completed without error. etc. Make sure that the rights/protections are open for the world (rwx).. requests. Create a custom directory tree for your custom schema as the APPLMGR user. Deviations from these standards can have unpredictable results.--------..--------. problems can occur with alerts.--------. Procedure --------1. click the "OK" button. you should be able to sign on to SQL*Plus and view an new row in your test table.-------1.--------. Oracle Applications Release 11i is a multi-tier architecture that allows functions to be distributed among multiple tiers of servers (desktop client. You should make the request a single request.

--------. Register the user with the Application Object Library.env) to include the custom schema basepath as the APPLMGR user. Modify the applications environmental file (example: VIS.Custom Application APPS Custom Application . b. For example: $ sqlplus system/manager SQL> create user XXCUS identified by CUST default tablespace USER_DATA temporary tablespace TEMP quota unlimited on USER_DATA quota unlimited on TEMP. 5. Register the custom schema as an Oracle user. a.0)--> other product directories | -----------. CUST is the password for the custom schema.--------.--------|||||||| bin forms html lib log mesg out reports || US US 3. For example: Data Group: Standard Description: Standard Data Group Application Oracle ID Description -----------. For example: XXCUS_TOP="/ d01/visappl/ XXCUS" export XXCUS_TOP 4.--------.--------.--------. Add the custom schema to a data group.XXCUS CUST Enabled 0 Custom Application 5.--------.--------.--------.--------. Note: XXCUS is the product short name. Log into Applications as the System Administrator and navigate to: Security --> ORACLE --> DataGroup.--------.XXCUS_TOP (/d01/visappl/ XXCUS/11. USER_DATA and TEMP are existing tablespaces.--------.--------. Create the user in the RDBMS database using SQL*Plus under the system account.--------. Give the user a default and temporary tablespace with quotas and then grant the CONNECT role. For example: Database Username Password Privilege Install Group Description -----------. SQL> grant connect to XXCUS identified by CUST. Log into Applications as the System Administrator and navigate to: Security --> ORACLE --> Register.

next extent. execute ad_dd. p_tab_name in varchar2. 6. % free. p_tab_type Use ’T’ if it is a transaction table (almost all application tables). table name. p_col_name in varchar2. p_col_width in number. You use the procedure AD_DD.register_ table(appl short name. % used) Procedures in the AD_DD Package procedure register_table ( p_appl_short_ name in varchar2. p_pct_used Minimum percentage of used space in each data block of the table (1–99). p_nullable in varchar2. p_appl_short_ name The application short name of the application that owns the table (usually your custom application) . p_pct_free in number default 10. Register your custom schema's tables (including flexfields) with the PL/SQL package AD_DD. p_tab_name in varchar2). Create your custom tables. or ’S’ for a ”seed data” table (used only by Oracle Applications products). p_pct_used in number default 70). p_scale in number default null). p_precision in number default null. p_tab_name in varchar2. p_pct_free The percentage of space in each of the table’s blocks reserved for future updates to the table (1–99). p_col_seq in number. The sum of p_pct_free and p_pct_used must be less than 100.register_ column for the custom schema table columns. p_next_extent in number default 512. views and sequences. p_col_name in varchar2). This depends upon your own requirements. indexes. . p_col_type in varchar2. p_tab_name in varchar2. procedure register_column (p_appl_short_ name in varchar2. procedure delete_table ( p_appl_short_ name in varchar2. table type. p_translate in varchar2. p_tab_name The name of the table (in uppercase letters).register_ table for the custom schema tables and AD_DD. p_tab_type in varchar2. The sum of p_pct_free and p_pct_used must be less than 100. procedure delete_column ( p_appl_short_ name in varchar2.It is recommend that you use the STANDARD datagroup and pair the custom schema with APPS or you can add a new data group. It is suggested that you add WHO columns to your custom tables so that Oracle Applications can keep track of customizations.

Example of Using the AD_DD Package Here is an example of using the AD_DD package to register a flexfieldtable and its columns: EXECUTE ad_dd. ’VARCHAR2’. 1. ’N’.’UNIQUE_ID_COLUMN’. 38. 38.register_ column(’FND’. ’CUST_FLEX_TEST’. ’NUMBER’. p_precision The total number of digits in a number. ’VARCHAR2’. 1. Use 9 for DATE columns.’LAST_UPDATE_ DATE’. ’N’). 6. ’VARCHAR2’.register_ column(’FND’. etc. ’DATE’. ’CUST_FLEX_TEST’. 38. ’N’).register_ table(’FND’.8. EXECUTE ad_dd.’LAST_UPDATED_ BY’. 30.’UNIQUE_ID_COLUMN2’. ’CUST_FLEX_TEST’. EXECUTE ad_dd. ’N’. ’N’. ’N’. EXECUTE ad_dd. EXECUTE ad_dd. 4.’SUMMARY_FLAG’. p_next_extent The next extent size. 38. ’CUST_FLEX_TEST’. ’N’. ’N’. 38 for NUMBER columns (unless it has a specific width). 7.register_ column(’FND’. 38.’APPLICATION_ ID’. 5. ’NUMBER’. ’N’). ’T’.).register_ column(’FND’. ’DATE’.register_ column(’FND’. . 2. 90). EXECUTE ad_dd. ’CUST_FLEX_TEST’. EXECUTE ad_dd. 9. ’N’).’ID_FLEX_CODE’. p_col_type The column type (’NUMBER’. ’NUMBER’. ’N’). p_scale The number of digits to the right of the decimal point in a number. p_translate Use ’Y’ if the column values will be translated for an Oracle Applications product release (used only by Oracle Applications products) or ’N’ if the values are not translated (most application columns). ’N’. ’CUST_FLEX_TEST’. ’CUST_FLEX_TEST’. p_col_width The column size (a number). Do not include the ’K’.’SET_DEFINING_ COLUMN’. ’N’. ’N’). ’N’). ’NUMBER’. ’CUST_FLEX_TEST’. EXECUTE ad_dd. p_col_seq The sequence number of the column in the table (the order in which the column appears in the table definition). EXECUTE ad_dd.register_ column(’FND’. ’N’).p_col_name The name of the column (in uppercase letters). ’NUMBER’. ’CUST_FLEX_TEST’. 10. 3. in kilobytes.register_ column(’FND’.register_ column(’FND’. 8. p_nullable Use ’N’ if the column is mandatory or ’Y’ if the column allows null values.

’N’). 16.register_ table ('XXCUS'. translate='N' 7. ’Y’. column width=5. 9. ’N’). ’N’). ’N’. column width. EXECUTE ad_dd. % free=10. ’CUST_FLEX_TEST’. ’VARCHAR2’. table name='CUST_TABLE' . table name='CUST_TABLE' . ’Y’. next extent=8.pls and then adaaddlb. ’CUST_FLEX_TEST’.register_ column(’FND’.’SEGMENT5’. translate) For example: $ sqlplus apps/apps SQL> execute ad_dd.’SEGMENT2’.register_ column(’FND’. 11. pls. ’CUST_FLEX_TEST’. 60.’END_DATE_ACTIVE’. 'CUST_TABLE' . ’N’). column type. ’DATE’. 15. ’CUST_FLEX_TEST’.register_ column(’FND’. EXECUTE ad_dd. pls system_pword custom_schema custom_schema_ pword SQL> @$AD_TOP/admin/ sql/adaaddls. ’N’). adaaddls.5. column name='CUST_NO' . table type='T'. ’N’).EXECUTE ad_dd. ’Y’. For example: $ sqlplus apps/apps SQL> execute ad_dd. ’VARCHAR2’. column name. 13. Run the custom schema against the APPS_DDL and APPS_ARRAY_DDL packages.register_ column(’FND’. table name. 'NUMBER'.’SEGMENT3’.pls. EXECUTE ad_dd. 9. ’VARCHAR2’.8. Run the scripts $AD_TOP/admin/ sql/adaddls. 60. adaddlb. ’CUST_FLEX_TEST’.register_ column(’FND’. 14. % used=90 execute ad_dd. EXECUTE ad_dd. 'T'.pls (in this order) under SQL*Plus: $ sqlplus apps/apps SQL> @$AD_TOP/admin/ sql/adaddls. ’CUST_FLEX_TEST’. column seq=1. 10. 'CUST_NO'. column type='NUMBER' .register_ column ('XXCUS'. ’N’. ’VARCHAR2’. 'CUST_TABLE' . 90) where appl short name='XXCUS' . 1. ’CUST_FLEX_TEST’.register_ column(’FND’. ’Y’. ’Y’. ’DATE’. 60. 12. ’N’).register_ column (appl short name. 10. ’N’.register_ column(’FND’. 60.’SEGMENT4’. null.register_ column(’FND’. 60. ’N’). 9. pls system_pword custom_schema .’ENABLED_FLAG’.’START_DATE_ACTIVE’. null='N'. ’CUST_FLEX_TEST’. EXECUTE ad_dd. EXECUTE ad_dd. 'N') where appl short name='XXCUS' .’SEGMENT1’.1. EXECUTE ad_dd.' N'. ’VARCHAR2’. ’VARCHAR2’. column seq.

GLOBE and CUSTOM libraries attached. Use the TEMPLATE form located in $AU_TOP/forms/ US directory as the required starting point for your development work for your custom forms. For example: $ sqlplus apps/apps SQL> create synonym APPS.CUST_TABLE for XXCUS. menus and libraries as the APPLMGR user. move the generated form to its proper directory. pls system_pword custom_schema custom_schema_ pword SQL> @$AD_TOP/admin/ sql/adaaddlb. APPDAYPK. The TEMPLATE form already has the APPCORE. FNDSQF.1 a. Make a copy of the TEMPLATE form and then rename it as the APPLMGR user.frm test. register the form with the Oracle Application Object Library and then add it to a menu. Follow the form development steps (which incorporate the development standards) that are described in the Oracle Application Developers Guide. In the forms designer attach any additional libraries to your custom form.custom_schema_ pword SQL> @$AD_TOP/admin/ sql/adaddlb.CUST_TABLE c) Create custom code objects in APPS For example: $ sqlplus apps/apps SQL> create function CUST_FUNCTION… 9. For example: $ sqlplus xxcus/cust SQL> grant all on CUST_TABLE to APPS b) Create a synonym in APPS to each custom data object. Build your custom forms. Integrate your database objects with the APPS schema by granting APPS the access to your custom schema's objects. pls system_pword custom_schema custom_schema_ pword 8. For example: $ cd $AU_TOP/forms/ US $ cp TEMPLATE.If the forms are being developed on a Windows client refer to Note:73880. The only Oracle Applications library that you should modify is the CUSTOM library. a) Grant all privileges from each custom data object to APPS. The following examples assume you are developing on the forms server.frm b. . You will modify the form as needed. All the libraries need to reside in directory $AU_TOP/resource/ plsql and make sure that your FORM45_PATH includes $AU_TOP/resource so that your form can find the libraries.

fmx module_type= form batch=no compile_all= special where form name=TEMP. Modify the form as desired following the development standards. 5. Register your form. Click on "Description" in the popup list.--------.c.fmb output_file= <schema_top> /forms/<language >/<form name>.0/forms/ US/TEMP.--------.--------.schema_ top=/d01/ visappl/XXCUS/ 11.--------. fmb output_file= /d01/visappl/ XXCUS/11. item handler. enabling querying behavior. coding table handler.TEST Custom Application TEST Custom Form Now click on "Form" in the popup list.--------.5. register subfunctions per the functionality that you require. event handler and code logic. Test the form by itself. Create either a static html file that calls your form directly (instead of the usual signon form) or create a dynamic html file and cartridge.--------.fmx module_type= form batch=no compile_all= special For example: $ f45gen userid=apps/ apps module=TEMP. Make sure that the $FORMS45_PATH is set and that the current directory is $AU_TOP/forms/ us.--------. creating window layout.TEST Custom Application TEST Custom Form g. coding messaging. For example: -----------. Generate the form on the forms server as the APPLMGR user. For example: Form Application User Form Name Description -----------. f.0 and language=US e. Log into Applications as the Application Developer responsibility and navigate to: Application --> Function.--------.--------. -----| Form | ------ . d. adding flexfield logic and coding any other appropriate logic.--------. You will be setting the properties of container and widget objects. If needed. f45gen userid=apps/ appspwd module=<form name>. Register the form as a function. Log into Applications as the Application Developer responsibility and navigate to: Application --> Form.| Description | -----------.Form Application User Form Name Description -----------.

Be sure to add the responsibility to a user.--------.--------. For example: -----------.--------.--------. It will automatically be filled in when you enter the form name in the Form field.1 Custom TEST Custom Form 2 Requests Standard Request Submi Administer Requests i. Log into Applications as the System Administrator and navigate to: Security --> Responsibility --> Define. Log into Applications as the System Administrator and navigate to: Security --> Responsibility --> Request. For example: Menu: XXCUS_MAIN User Menu Name: XXCUS_MAIN Description: Main Custom Menu Navigator Seq Prompt Submenu Function Description -----------.--------.--------. For example: Group: XXCustom Application: Custom Application Code: Description: Custom Application Requests -------Type Name Application -----------.--------.--------. Log into Applications as the Application Developer responsibility and navigate to: Application --> Menu.Program Custom Report 1 Custom Application Program Custom Report 2 Custom Application j) Create a custom responsibility for your custom schema.--------. Create a custom request group that will hold your custom and/or standard requests for your custom responsibility. The menu will be tied to a responsibility.--------.--------.--------.TEST TEST Custom Application Note: the Application field will be grayed out.----Responsibility Key: From: 05-JAN-1999 Description: Custom Responsibility To: .--------.--------.--------. Add your custom functions (forms and subfunctions) to an existing menu or create a new one.Function Form Application Parameters -----------.----Responsibility Name: XXCustom | Effective Dates | Application: Custom Application -----------. h.

'Template Form'.set_ window_position( 'BLOCKNAME' . app_window.--------. in the forms designer open your custom form and navigate to: Triggers --> PRE-FORM. b. Create a subdirectory under your help files subdirectory to hold the links files.-----------. XXCUS is the custom application short name and BLOCKNAME is the name of the window: begin FND_STANDARD. For example.BLOCKNAME: .-----------. The target name is comprised of the form name and the window name.--------.--Menu: XXCUS_MAIN | Request Group | -----------. Make sure that your custom form refers to your custom application short name in the call to the FND_STANDARD.x Oracle Application Name: Standard Oracle Self Service Web Applications Application: Custom Application -----------. The target tag with form name=CUSTOM and window name=BLOCKNAME would be custom. Include the html target tags of the form near the beginning of the file. app_standard.----.| Function and Menu Exclusions | -----------. '$Author: John Doe $').-----------| Available From | | Data Group | -----------. The target name is comprised of the form name and the window name. Include the html target tags of the form near the beginning of the file.--------.Type Name Description k. Create your online help html files.'FIRST_WINDOW' ). d. c.--------. FORM_INFO routine in the PRE-FORM trigger. Create your online help html files. end. Build online help for your custom applications as the APPLMGR user. Create a subdirectory for your help files using the application short name. create a file called $OA_DOC/US/XXCUS/ custom.----. FORM_INFO( '$Revision: 99 $'. The links allow Oracle Applications to find the correct help files. 10.--Web Host Name: Name: XXCUS Web Agent Name: Application: Custom Application -----------. a. d. event('PRE_ FORM'). This subdirectory will reside under the directory path specified by the profile HELP_BASE_URL plus the language that you are working under. For example. Test the form from within Applications. 'XXCUS' '$Date: 99/05/25 12:01:01 $'.htm using an html editor.

0 transitional/ /en"> <html> <head> <meta http-equiv=" Content-Type" content="text/ html.8859-1"> <meta name="GENERATOR" content="Mozilla/ 4. charset=iso.BLOCKNAME ' var queryString location.replace( newloc) return true } var CUSTOM_BLOCKNAME = 'custom.location.htm with a target tag of custom. URL. You will have one links file for each form and it will be named after the form.replace( newloc) </script></body> </html> f.<!doctype html public "-//w3c//dtd html 4.--------. Login as the Application Developer and navigate to: Application --> Messages. copy an existing links file to your custom links subdirectory.0 transitional/ /en"> <html> <head> <meta http-equiv=" Content-Type" content="text/ html.--------.indexOf( '?')+1. a link to your custom application can be added to the Oracle Applications online help file. a. href. href. the html help file is custom.length) var newloc = '. htm?' + queryString location. library. Create your links file. For example: Name Language Application Number -----------.--------.htm# custom./. Define your messages following the message standards.htm 11. I) [Netscape]"> <title>Custom Application Help </title> </head> <body bgcolor="#F8F8F8" > <a NAME="toc_"> </a> <a NAME="custom..51 [en] (WinNT./notfound. If desired. I [Netscape]"> </head> <body> <script LANGUAGE='JavaScrip t'> function onerror(msg.--------. b. Create your message dictionary. htm using an html editor. The links file stores the connection between the target and target in the destination html file. modify $OA_DOC/US/XXCUS/ links/custom. lineNum) { var newloc = '.href.8859-1"> <meta name="GENERATOR" content="Mozilla/ 4. BLOCKNAME" ></a> e...51 [en] (WinNT./' + eval(queryString) location.--------. The target is CUSTOM_BLOCKNAME (form name=CUSTOM and window name=BLOCKNAME) .BLOCKNAME: <!doctype html public "-//w3c//dtd html 4. Copy an existing Oracle Applications links file to your links subdirectory and modify it. Make sure you have a message (mesg) subdirectory under your custom applications basepath. For example. substring( location.- . charset=iso.

SQL*Plus. FNDMDGEN apps/appspword 0 Y <Language> <Application Short Name> DB_TO_RUNTIME For example: $ FNDMDGEN apps/apps 0 Y US XXCUS DB_TO_RUNTIME where Language=US and Application Short Name=XXCUS The FNDMDGEN program will generate a message file named <Language>. You will use calls to the FND_MESSAGE package to display messages. PL/SQL.XXCUS_UPDATE US Custom Application 1 Current Message Text -----------. Oracle Reports or a host language program (a shell script).--------. e. a. Set up your concurrent processing for your Custom Schema. Log into Applications as the System Administrator and navigate to: Concurrent --> Program --> Executable. Pro*C.--------. Write the concurrent program execution file and place it in the appropriate directory.--------. You will either display the message to a user on the client or write it to a file on the server. f. Code the logic to set up messages. From the operating system run the Message Dictionary Generator program (FNDMDGEN) as the APPLMGR user. This links the execution file and the method used to execute it with a defined concurrent program. d.Custom Applications update message c. You can use a variety of methods such as C. Log . Define the concurrent program with the Oracle Application Object Library along with any program parameters or any incompatibilities. b. You will use calls to the FND_MESSAGE package to retrieve and set up messages for display. For example: Executable: XXCUS Short Name: XXCUS Application: Custom Application Description: Custom Program for Updates Execution Method: Spawned Execution File Name: XXCUSUPT Subroutine Name: c. Code the logic to display messages.msb in place it in the custom applications basepath mesg directory. Define the concurrent program executable with the Oracle Application Object Library.--------.--------. 12. Create the message files. If needed make a copy of the generated file (located on the server) and transfer the copy to the appropriate mesg directory for the custom application on the client system.

into Applications as the System Administrator and navigate to: Concurrent --> Program --> Executable. For example: Program: Custom Update x Enabled Short Name: XXCUS Application: Custom Application Description: Custom Program for Updates Executable ---------Name: XXCUS Options Method: Spawned Priority Request Output ------- -----Type: Format: Text Use in SRS x Save Allow Disabled Values x Print Enable Trace Columns: x Restart on System Failure Rows: NLS Compliant style Style: Style Required Printer: d. Add the request functionality for your concurrent program. The program can be called from the run reports form, from a trigger within an application form or from a Pro*C program. To use the run reports form, just add the submit request window to your custom menu so that you have access to the Standard Request Submission interface (SRS). 89 What are the actual executables called? 1. These are the various Forms component names on Unix and Windows: Unix Windows Forms Builder f60desm ifbld60.exe Forms Compiler/Generator f60gen/f60genm ifcmp60.exe Forms Runtime f60run/f60runm ifrun60.exe Forms Metric Server d2ls60 d2ls60.exe Forms Metric Client d2lc60 d2lc60.exe Forms CGI f60cgi ifcgi60.exe Forms Server f60srvm ifsrv60.exe Forms Web Runtime f60webm ifweb60.exe 90 What are some of the related Forms/Apps files? adfmcctl.sh - located in $COMMON_TOP/ admin/scripts, this script starts and stops the Forms Metric Client for your Apps instance; it uses the Forms d2lc60 executable to accomplish this. adfmsctl.sh - located in $COMMON_TOP/ admin/scripts, this script starts and stop the Forms Metric Server for our Apps instance; it uses the Forms d2ls60 executable to accomplish this. adfrmctl.sh - located in $COMMON_TOP/ admin/scripts, this script starts and stops the Forms Server Listener; similar to and actually calls the f60ctl found in $ORACLE_HOME/ 6iserver/ bin of IAS.

appsweb.cfg - located in $OA_HTML/html/ bin, this file defines parameter values used by the Forms Web CGI, similar to formsweb.cfg found in $ORACLE_HOME/ 6iserver/ forms60/server of IAS. appsbase.html - located in $OA_HTML/<language> , this is the default HTML file for starting an applet using Jinitiator, similar to basejini.htm found in $ORACLE_HOME/ forms60/server of IAS. d2lc60.txt - located in $COMMON_TOP/ admin/install, this is the Forms metric client log file. d2ls60.txt - located in $COMMON_TOP/ admin/install, this is the Forms metric server log file. f60svrm.txt - located in $COMMON_TOP/ admin/install, this is the adfrmctl.sh log file. This is not the same as the Forms server log file which not only logs startup and shutdown info but also client connectivity (which client IP is associated with which f60webm process) and debug stack trace info. OracleApplications. dat - located in $JAVA_TOP/oracle/ apps/fnd/ formsClient, among other things this file determines the path Apps uses to find their icons; its similar to and supplements registry.dat found in $ORACLE_HOME/ forms60/server of IAS. 91 List most usefull profile options for concurrent managers ?? Profile Options Concurrent Manager 1. Concurrent: Active Request Limit Value: Numeric This profile options will restrict the number of concurrent requests that may be run simultaneously by each user. If you do not specify a limit, then no limit is imposed. 2. Concurrent: Attach URL Values: YES/NO If you set this option to YES, then this causes a URL to be attached to request completion notifications. For example, when a user submits a request and uses the 'Defining Completion Options' region to specify people to be notified, a notification is sent each of the people designated. 3. Concurrent: Collect Request Statistics Values: YES/NO If you set this option to YES, this causes applications to collect statistics on your run-time concurrent processes. 4. Concurrent: Conflicts Domain Values: LOV (list of values: domains) This option identifies the domain within which all the incompatibilities between programs has to be resolved 5. Concurrent: Debug Flags This option is used to debug the transactions managers. You should only use this option at the request of Oracle Support. 6. Concurrent: Directory for Copy You can identify a directory on your operating system to store copies of your report output or log files. This directory is used when a copy operation is requested in character mode of the applications. 7. Concurrent: Enable Request Submission in View Mode Values: YES/NO Setting this option to YES will enable the 'Submit a New Request' button when users invoke the form FNDRSRUN (Find Requests Form). Navigation

path is either: (1) Menu: Help > View My Requests, or (2) navigate (with system administrator responsibility) to, Requests > View. 8. Concurrent: Hold Requests Values: YES/NO This option enables you to automatically place requests on hold after submission 9. Concurrent: Multiple Time Zones Values: YES/NO When the client's session and the concurrent manager are running in different times zones, use this option to ensure that the request is scheduled immediately regardless of you client session's time zone. 10. Concurrent: PMON Method This option is presented for documentation purposes only. Users cannot see or alter this profile option. This option is not visible or cannot be updated from the System Profile Option (FNDPOMPV) form. The PMON method refers to the process monitor. The Internal Concurrent Manager (ICM) monitors the individual concurrent managers' processes to verify the managers are running. Normally, the PMON method must be set to LOCK. To change the profile option setting, you must execute the SQL script "afimpmon.sql" which resides in directory "$FND_TOP/sql/ ". 11. Concurrent: Report Access Level Values: RESPONSIBILITY/ USER This option determines access privileges to report output files and log files generated by a concurrent program. This option can be set by a system administrator or by the user. 12. Concurrent: Report Copies Values: Numeric This option determines the number of default copies that print for each submitted concurrent request. 13. Concurrent: Request Priority Values: Numeric Concurrent requests in Oracle Applications are queued. Requests normally run according to a start time on a first submitted, first run basis. Priority overrides this request start time. A higher priority request starts before an earlier request. This option displays the default priority for you concurrent requests. Only a system administrator can change your request priority. 14. Concurrent: Request Start Time Values: Numeric (Date/Time) With this profile option, you can set the date and time that your requests are available to start running * If the start time is at or before the current date and time, requests are available to run immediately * Start a request in the future, for example, at 6:00 PM on December 31, 2000, enter the following value, 31-DEC-2000 18:00 * This profile option requires the date and time, for example, 31-DEC-2000 18:00 * Changing values does not affect request already submitted

93 Why do I have invalid objects? What causes them? Invalid objects can and will occur for many reasons. upgrading. 20. Concurrent: Show Requests Summary After Each Request Submission Values: YES/NO By default the Request Summary (FNDRSRUN) form appears after every request submission. 16. doing an export/import. 21.15. 18. 92 How to find the files which contain the string MTL_SYSTEM_ITEMS_ KFV ? $grep -i MTL_SYSTEM_ITEMS_ KFV `find . You will usually find invalid objects after running (or failing to run) adprepdb. Invalid objects are usually caused by missing grants. Concurrent: Show Requests Set Stages Values: YES/NO Set this option to YES to show request set stages in the concurrent request screens. This option specifies how long (in minutes) the URL is to be kept active. views. -depth -print | grep -v log` The above command provide a list of the files that contain the string "MTL_SYSTEM_ ITEMS_KFV" and display the line on which it occurrs. Concurrent: Use ICM Values: YES/NO ICM (Internal Concurrent Manager) Set this option to YES to use the Internal Concurrent Manager to resolve request conflicts (result from programs that are defined to be incompatible) instead of using the Conflict Resolution Manager (CRM). 19. tables or packages. Concurrent: URL Lifetime Value: Numeric If the profile option 'Concurrent: Attach URL' has been set to YES. but can also be caused by corrupted packages. . 17. Concurrent: Sequential Requests Values: YES/NO Setting this option to YES will force concurrent requests to run sequentially in the order in which they were submitted. synonyms. Set this option to NO if you have multiple requests to submit and do not wish to see the Request Summary form after each submission. or applying patches. Concurrent: Save Output Values: YES/NO Setting this option to YES will save the output from a concurrent request to a file. Concurrent: Wait for Available TM Value: Numeric TM (Transaction Manager) Use this option to specify the number of minutes that a client will wait for a given transaction manager to become available before trying a different transaction manager. a URL is associated the output of an execution and is passed to anyone flagged for notification during the request submission.

pls: 1 . but you must ensure that they are in a product or application that is not used.pls apps apps % . can we delete them? There are times when invalid objects have occurred where you may opt to simply delete them. APPS_DDL and APPS_ARRAY_DDL should exist in all schema's. APPS and then all others. one of the first questions they will probably ask is whether you have checked for and resolved any invalid objects. 98 Which OBJECTS table is best to use for queries? ALL.pls SCHEMA_NAME SCHEMA_PASSWORD % Example: SQL> @adcompsc. If you encounter an ORA-1555 error while running adcompsc. If invalid objects exist for a product or application that you do have installed and are using. but every effort should be made to resolve them one way or another.94 Why does Oracle Support always tell me to recompile my invalid objects? Compiling invalid objects on your database is almost the equivalent of running scandisk on a PC hard drive.returns objects owned by the user (schema) you are connected as. there is a script to compile INVALID objects . This should be one of the first things you check if you start experiencing problems with your Oracle database. it may be ok to have some.Schema to run in 2 . 99 How can I recompile all my invalid objects using ADCOMPSC.called ADCOMPSC. The script can be run as follows: cd $AD_TOP/sql sqlplus @adcompsc. but it is preferable to have no invalid objects existing at all.Password for schema 3 . SYSTEM. It is not recommended to use ALL_OBJECTS.pls? Within Applications. When you call in to Oracle Support with a database or installation issue. 96 Are invalid objects ever acceptable? How many is too many? If the invalid objects exist for a product or application that is not installed.Check errors for objects starting with #3 NOTE: The order in which to compile Invalid Objects in schemas is SYS.pls. USER or DBA? You should normally use DBA_OBJECTS.pls Arguments for ADCOMPSC. but there may be occasions when you will want to use USER_OBJECTS. USER_OBJECTS . There is no set number of invalid objects that could be considered 'acceptable' as each situation will vary widely from one database to the next. DBA_OBJECTS . It is also a good idea to schedule regular checks for invalid objects.returns every object in the Database. then it should be considered unacceptable and any existing invalid objects should be resolved before further issues can occur. 97 If we do not use the application with the invalid objects. You could just have a few invalid objects or they could number in the hundreds or even thousands. just restart the script.

sql x x x Reports all compilation errors for a given schema. look for a corresponding row with data_group_id dg_id. For each row with data_group_id 0 in FND_RESPONSIBILITY. Show Database Configuration formerly. but you still have invalid objects. aderrch2.sql x x x Report the number of blocks used and the number of extents used for every table or index in every user in the database.sql x x x Same as aderrch2.sql x x x Estimate the effect of a bigger SGA cache on cache hit rate. List Session Objects ADXLMQMS.sql x x x Generate a list of tables and indexes whose next extent to be grabbed would be too large to be allocated in their corresponding tablespaces. you should run adcompsc.sql x A fix for customers who have more than one set of books and they installed languages other than AMERICAN English.sql x x x Find the size (blocks.sql x x x Lock Problem. config. ADXRSESH.sql x x x Report Configuration. Show Lock Users adxpriv7. The symptom of the bug is that responsibility names are not translated properly for non-Standard data groups.sql x The script duplicates rows in FND_RESPONSIBILITY in the following way: Find data_group_id dg_id for the given data_group_name.pls x x x Compile objects in a given schema adcpresp.sql x x x AD .x 10.sql x x x Utility script to display product dependency information ADXANLYZ. ADXGNPIN. Select Table Grants adxrfmi. ADXRSFIS.sql x x x Install tables and views used by the Applications* DBA sql scripts. Script 11.sql x x x Drops and recreates an index as nonunique. adxirc.7NCA 10.sql x x x Count objects by object type in schema adutconf.sql x x x Query the shared_pool area to determine space used by PL/SQL objects and whether they have been pinned.sql plus it fails if there are any errors adtresp.sql x x x Report free extents in each tablespace. ADXRSFTS.sql x x x Lock Problem. Query Monitor Statistics ADXLPFLS.sql x x x Analyze all tables in an ORACLE ID with estimate sample 20% ADXCKPIN.0.sql x x x Creates and runs a "pin" script for all sequences in a give schema ADXINMAI. extents. and responsibility_ name that only differs in the given suffix string suffix_string. data files) ADXRCSTG. If such a row does not exist for the data_group_id dg_id.sql x x x Creates and runs a "pin" script for all packages and functions in a give schema ADXGNPNS. Keep running adcompsc.sql x x x Produce a brief database used space report.sql x x x Check for cache effectiveness for dc_xxxxx parameters' values.pls until number of invalid objects stops decreasing. Categorize Block Contention ADXLMLSO. check for invalid objects again.sql x x x Report Configuration. ADXRSFUA.report columns adxirn.1 Description adcompsc.sql (rollback. insert it. ADXRSLFS.sql x x x Live Monitor.sql x x x grant privileges to a user ADXRCSDC. extpct) of the given table.After the script completes. ADXRSSIE. adutcobj.sql x x x Estimate the effect of a smaller SGA cache on cache hit rate.sql x x x report installed modules from fnd_module_installa tions adxrfpi. ADXRSQDP. extpct) of the given index. ADXRSRTS.sql x x x Utility script to display configuration of Applications adutfip.sql x x x report rows from fnd_product_ installations and related tables ADXRSEBH. 100 What Oracle Applications DBA has useful collection of SQL scripts. tablespace.sql x x x Live Monitor. If the number has decreased.sql x x x Find the size (blocks. aderrchk.index . with the same application_ id.sql x x x Live Monitor. ADXLMCBC. .7SC/16.pls again. Find Lock Source ADXLPSLU. extents.sql x x x Utility script to display worker information adutfpd.

1.sql X x x Show v$rollstat statistics.sql x x Modified CRT definitions for Applications Environment Regular Activities: 1) Check the alert_SID.ADXRSSMF.sql X x x Show all users that have active transactions per Rollback Segment that they are writing to.sql X x x Find space used for one's own segments.7/admin/ TEST/bdump -user testora -mtime +7 -exec rm -f {} \. If you sure then only remove this files OS Related /var/adm/wtmp /var/spool/* /* $HOME/smit. ADXRSSRS. 2>/dev/null Note: You can modify above commands accordingly for other instances.1. 2>/dev/null find /testdata/testdb/ 8. 2>/dev/null find /testfm/testcomn/ admin/out -user testappl -mtime +7 -exec rm -f {} \. applcrt.sql X x x List tables and indexes with a number of allocated extents close to their max_extents. find /testdata/testdb/ 8.log file and check the errors 2) What steps to be performed if problem accours like database hangs or listener downs a) Check the file system b) If the file system full then increase the file system for database for others purge the logs 3) Purge the conncurrent request manager logs select the parameters as entity : all mode : age mode value: 7 You may get the error snapshot too old some times then you need to shrink the rollback segments and then re-run the program. ADXUPLUP.7/admin/ TEST/udump -user testora -mtime +7 -exec rm -f {} \. ADXRSSMS.sql X x x Produce a brief report of database fragmentation by tablespace. you have to remove it manually. 2>/dev/null find /testdata/testdb/ 8.7/admin/ TEST/cdump -user testora -mtime +7 -exec rm -f {} \. ADXRSSTF. ADXRSSUS. ADXRSSSU.1.sql X x x Report how much space each user has. 2>/dev/null find /testfm/testcomn/ admin/log -user testappl -mtime +7 -exec rm -f {} \. report the number of blocks used and the number of extents used for every table or index in that username.log . 2>/dev/null What files can be removed for OS ? The following files can be removed to the respective directory.sql X x x Generate a list of processes which the given user (NOT the database account's username) owns.sql X x x For a username. find /var/tmp -user testora -mtime +7 -exec rm -f {} \. ADXUPSRU. this program will not remove the logfiles from the os levl.

log $HOME/websm.$HOME/smit.3.3 flags a.o gives NATTCH (for a flag $9 gives NATTCH.root system root system 0 4008 27606 27606 0:30:08 0:30:09 0:30:08 ipcs -map|awk '$9==0 {print $2}' gives the shared memory ID that is 7 you can use "ipcrm -m 7" to kill the shared memory segment 106 How to cancel the request which is submited by other user ??? Login as sysadmin user with system administrator responsibility and go to Concurrent ïƒ Requestïƒ Specific Request(give the request id) ïƒ find and then cancel 107 How to bounce the http server for maximo ??? Login as root on hiltrn then goto /ust/HTTPServer/ bin #. PS:You have to login as ORACLE_HOME owner to remove the segment for eg In our AIX 4. script /etc/security/ failedlogin /var/adm/sulog 1) rm /var/adm/wtmp touch /var/adm/wtmp chown adm:adm /var/adm/wtmp chmod 544 /var/adm/wtmp 2) rm /var/adm/sulog touch /var/adm/sulog chown root:system /var/adm/sulog chmod u+rw /var/adm/sulog 3) rm $HOME/smit* How to remove shared memory segments in UNIX after killing processes ? A: There must be some flag in ipcs command which gives NATTCH(which is the number of processes attached to it./apachectl stop .script $HOME/websm.for o flag $7 gives NATTCH ipcs -map|awk '$9==0' T ID KEY MODE OWNER GROUP CREATOR CGROUP NATTCH SEGSZ CPID LPID ATIME DTIME CTIME m 7 0x00000790 --rw-rw-rw.refer to the man pages of ipcs command).

The number shown in 'Maximum number of PROCESSES allowed per user' will show the maximum limit the user has defined. Select 'Change / Show Characteristics of Operating System'.#. Create database link <db link name> connect to <username> identified by <password> using '(DESCRIPTION = (ADDRESS_LIST = (ADDRESS =(PROTOCOL = TCP) (HOST = <your host>) (PORT = 1521))) (CONNECT_DATA = (SID = <your sid> )))' 106 How to determine size of a oracle process on Unix Purpose ~~~~~~~ DBAs are often alarmed by the percieved size of an Oracle process. 2./apachectl start 108 Finding the maximum number of processes defined per user ?? The procedures are valid for AIX version 4. Scope & Application ~~~~~~~~~~~~ ~~~~~~~ .0 1. This note describes the various aspects of measuring the actual size. 4.0.3.ora is shared on a fileserver and you don't have the privileges to update the file.ora file. 104 How to determine os file system block size in AIX?? As the root user startup the 'smitty fs' o/s utility Go to Add / Change / Show / Delete File Systems => Journaled File Systems => Change / Show Characteristics of a Journaled File System => Select the file system you want to see You can see this output SIZE of file system (in 512-byte blocks) [16384] Alternate Method Create a test directory and determine its size using ls -l mkdir test ls -l test 105 Is it posible to create a Database link without alias in tnsnames.ora Yes It's possible to create a database link without having a alias in your tnsnames. 3. Start up the SMIT utility. Select 'System Environments' . This is beneficial when you use a remote database only for one time or when your tnsnames.

'top' shows the size as approx 148MB. Determining the Size of an Oracle Process: ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~ INTRODUCTION On UNIX platforms.It is intended to clarify the various measurements that can be obtained.. and not once per process..-----total Kb 148024 127424 10896 116528 From the above. the size of a process is often measured using operating system utilities such as 'ps' or 'top'. commands such as 'ps' and 'top' include TEXT sizes when measuring private data.114928 read/write/exec/ shared [shmid=0x191] <--SGA .B. and the operating system not reclaiming freed memory. 1] "Virtual Memory on HP-UX 10. The shared memory ID is given as [shmid=0x191] . the SGA size can also be included. Inclusion of non-private memory ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~ A process in memory is composed of several parts: shared memory (the SGA) shared libraries (both public. or heap) the executable (referred to as TEXT) N.-----. These topics are covered in more detail below. These are mapped only once into memory.. shared) memory in the process memory figure. For example. and private) private data (referred to as DATA. and HP has glance (view the process' virtual memory map) or the kernel debugger q4 (see the following note: [NOTE:66637. oracleV817 % top PID USERNAME THR PRI NICE SIZE RES STATE TIME CPU COMMAND 3254 usupport 1 59 0 148M 124M sleep 0:00 0. and how to proceed further. Such utilities can imply alarmingly large process sizes.. The SGA and TEXT regions are shared by all Oracle processes.. As such. against an Oracle server process (pid 3254): % ps -eafl | grep 3254 F S UID PID PPID C PRI NI ADDR SZ .-----. CMD 8 S usupport 3254 3253 0 55 20 62f4a0b8 18985 ..e. 'top' and 'pmap' on Solaris.<deleted some output here>. these are not part of the incremental cost of spawning a new Oracle process. 'pmap' shows the total size to be 148MB. Some operating systems provide better tools for measuring process sizes. giving a wildly inaccurate figure for the private data of a server process. but gives a breakdown by region: The TEXT size is approx 28MB DATA area is 150kB SGA is approx 115MB.. Further. WHY CAN PROCESS SIZES BE REPORTED INCORRECTLY? ============ ========= ========= ========= ======= The two main reason for incorrect reporting of process memory usage are: inclusion of non-private (i.144 read/write/exec [ heap ] <--private DATA 80000000 114928 114928 . Here is an example of using 'ps'.. -------. 'ps' shows the SZ value as 18985 or approaching 19MB. Unfortunately.-----.X").05% oracle % /usr/proc/bin/ pmap -x 3254 3254: oracleV817 (DESCRIPTION= (LOCAL=YES) (ADDRESS= (PROTOCOL= beq))) Address Kbytes Resident Shared Private Permissions Mapped File 00010000 26744 9368 8416 952 read/exec oracle <--TEXT 01A3C000 272 272 208 64 read/write/exec oracle <--TEXT 01A80000 152 144 .. Solaris has /usr/proc/bin/ pmap...

15 session uga memory 16 session uga memory max 20 session pga memory 21 session pga memory max To check the heap sizes for all sessions: select value. standard operating system utilities such as 'ps' and 'top' should not be used to get absolute figures. If such a query shows a session's memory usage constantly increasing over time. v$statname n where s. this is just another piece of memory allocated to an application. using a query similar to the v$sesstat SQL given above. but used instead to observe trends (for example. For example. The heap names of interest are PGA and UGA. To the operating system. sid from v$sesstat s . as the operating system may not have reclaimed previously freed memory. a process may be allocating memory for a particular repeated . it is not returned immediately to the operating system's free pool. A specialist utility such as 'pmap' should be used to get a more accurate figure. Consequently. name from v$statname where name like '%ga memory%'. is a process size increasing or decreasing).name like '%ga memory%' order by value. Operating system not reclaiming memory ~~~~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~~ ~~~~~~~~ In general. without levelling off. The purpose of these heaps is unimportant in the context of this note.ora parameters affect the size: Parameter:SORT_ AREA_SIZE Parameter:SORT_ AREA_RETAINED_ SIZE Parameter:HASH_ AREA_SIZE IS THERE A PROBLEM? ============ ======= Firstly. A large PGA/UGA does not necessarily indicate a problem. operating system utilities can report process sizes to be larger than they really are. n. and starts to take freed pages back. The amount of memory that Oracle currently has. Instead. HOW MUCH MEMORY IS ORACLE ACTUALLY USING? ============ ========= ========= ========= == From an Oracle perspective.statistic# ||')' . to determine how much memory Oracle thinks it is using.name|| '('||s. for the reasons previously stated. a server process' private memory is composed of several Oracle 'heaps'. Always query the database. until such time that the operating system runs low on free memory. For example. This correlates with ipcs: %ipcs -m T ID KEY MODE OWNER GROUP m 401 0xe265699 c --rw-r----. then there may be a memory leak of some description. Even this may be misleading.statistic# and n. In Oracle terminology. the following init. this memory is still associated with the process. after a process has freed some memory. and has ever had in these heaps is obtained from the following statistics: select statistic#.statistic# = n.usupport dba ^^^ This highlights that the private data area of approx 150kB cannot be measured accurately from standard operating system utilities such as 'ps' and 'top' whereas 'pmap' allows a more accurate figure to be determined. a heap is a managed area of memory.The shared memory segment identifier is 0x191=401.

Pro*Lang code PL/SQL procedure 107 How do you create a database link with out changing tnsnames. v$statname n where s. and must show the increase in memory.It is needed to quary for database name that which database he or she is access 109 What command is used to find the zombi processes /dead process in unix? ps -aef | grep defunct . This will potentially lead to a large trace file. and how often. To start diagnosing a problem with the process size. or the memory size hits some operating system defined limit (such as maxdsiz on HP-UX).statistic# = n. A memory leak would typically result in a large process size that cannot be explained by the related init.ora file ?? create database link EDW_APPS_TO_ WH connect to APPS identified by <pwd> using '(DESCRIPTION= (ADDRESS= (PROTOCOL= TCP)(HOST= ibm1) (PORT=1524)) (CONNECT_ DATA=(SID= TEST)))' With entry in tnsnames. Once the memory usage starts to increase.ora file create public database link HILVIS connect to SAMPLEOLAP identified by <pwd> using 'VIS' 108 Grant privs to access v$ views ? SQL>grant select on v_$instance to gitesh. If a process size keeps growing. from near the start of the session. Note that all heapdumps will write to the same trace file in the user_dump_dest (for non-background processes). An indication of what the client process is doing.statistic# and n. such as a suspected memory leak. so be aware of this when deciding when to dump the heaps.operation.ora parameter settings. get multiple heapdumps (say a maximum of five). Than gitesh will be able to access v$instance.name like '%ga memory%' and sid= <sid of problem session>. 4. 3. These should be run periodically. separated by a time period that will highlight the increase. but not freeing it in between. Identify the problem session 2.statistic# ||')' from v$sesstat s . Run the following to demonstrate the memory growth: select to_char(sysdate. select value. a heapdump of the offending process is required: $ svrmgrl SVRMGR> connect internal SVRMGR> oradebug setospid <pid> SVRMGR> oradebug unlimit SVRMGR> oradebug dump heapdump 5 <--this dumps PGA and UGA heaps The following information should be provided to Oracle Support Services: 1. For example.name|| '('||s. 'dd-mon-yyyy hh24:mi:ss') from dual. then it may eventually fail with an ORA-4030 "out of process memory when trying to allocate %s bytes" error if the operating system is exhausted of memory. n.

1.7 installation to Oracle 9i installation. cd $ORACLE_HOME/ rdbms/admin cp catexp..sql file to Oracle 9i database as sys to rebuild the export catalog on Oracle 9i database similar to Oracle 8. production database is cloned to another server.1. I came with idea to implement which is supported by oracle of "Sharing Tablespace Data Between Different Databases" and it works.110 How to kill all the processes under perticulat file system ? fuser –xkuc /uatfm -ïƒ to kill the processes under /uatfm file system 111 How to find what are the products installed in your database ? Select Application_ id.1. PATCH_LEVEL from fnd_product_ installations where PATCH_LEVEL LIKE '%FND%' 112 Create a directory with the user privaliges from root Su uatcappl –c “mkdir –p /uatfm/uatappl” 113 Exporting a database from 9i and Importing on 8. To avoid db-link performance . Oracle document says that it can be done for a table or user by user.sql file for Oracle 8. Requirements for implementations The tablespace(s) that are to be shared must have the same oracle block size and must always be in READ ONLY status for both databases. Also we were storing the duplicate data for reference only .sql catexp92. Also both databases should be on same server and their versions should be same . More specially if you are using Policy. It will export successfully.sql 2. Target database on Oracle 8i -----------. But usually this gives an error.7 is a problem. Reason for error: There are some export catalog views in Oracle 9i which are not compitable with Oracle 8i. Source database on Oracle 9i -----------. duplicating data etc.1. Using some of tools data for current month are loaded into a reporting database which holds the historical as well as current month end data Corporate Reporting . Now take an export of oracle 9i database and ftp to oracle 8i installation. Apply the Oracle 8i catexp.7.--------. I have used process successfully. 114 Sharing Tablespace Data Between Different Databases Last day of every month once inventory is closed from all over the country.--------. Ftp the catexp.------1. 3.------Import the export file into Oracle 8i database.7 database 114 Sharing Tablespace Data Between Different Databases Importing a database from Oracle 9i to Oracle 8. I am listing a way to achieve this for the whole database. Processing the data via database link sometimes cause a performance problem. 4. Different groups/Teams use the same reporting databases using db-link to process the report . .

resource to arjun. Tablespace altered. You can access the data from both database. User created. Insert few records .dbf' size 10M. SQL> grant connect . Export userid exp userid=###BOT_TEXT###quot;sys/ change_on_ install as sysdba###BOT_TEXT###quot; file=arjd.dmp transport_tablespac e=y datafiles=/u03/ gsbaseddata/ ARJD01. Tablespace altered. Table created. User created. SQL> grant connect . imp userid=###BOT_TEXT###quot;sys/ change_on_ install as sysdba###BOT_TEXT###quot; file=arjd. SQL> create user arjun identified by arjun default tablespace ARJD temporary tablespace temp. perform the following steps : On database DB1 SQL> create tablespace ARJD datafile '/u03/gsbaseddata/ ARJD01.correct size 116 How do I restrict or allow a few client machines to connect to Server ? ..dmp transport_tablespac e=y tablespaces= ARJD SQL> alter tablespace ARJD offline. On database DB2 SQL> create user arjun identified by arjun default tablespace users temporary tablespace temp... SQL> select * from share_arjun. Grant succeeded.. ID ---------10 20 SQL> alter tablespace ARJD read only. Tablespace created. 113 How to find the file size greater than 2Gb ? Find /-xdev –size +2048 –ls |sort –r +6 115 How to determine the size of a Table ? Analyze table <<Table>> compute statistics ( for the table you're interested in ) followed by: select blocks from user_tables where table_name = '<<desired table>>' then calculate: blocks * block_size Result :. DB1 is databases which holds the data and it should be shared with DB2 databases . resource to arjun .dbf Take tablespace on line from DB1. Assuming that tablespace ARJD to be shared between DB1 and DB2 .PROCEDURE TO SHARE TABLESPACE The To test these functionalities I used 2 databases namely DB1 ( source ) and DB2 target . SQL> create table share_arjun (id number).

.EXCLUDED_ NODES=(<Client IP-ADDRESS 1>.dmp . dmp and exp3. 12 ) tcp. # Add the following lines if you want to invite only the following client machine to connect TCP.dmp in filesystem .invited_ nodes=(192. FILESIZE=1024 Causes 1K files to be generated.3. you need the following things 1) You must know the IP-address or host name of the client machine. you also have to use FILESIZE option of import utility. 4)Stop and restart the listener to make this effect.dmp) filesize=1000M ignore=Y .ora in 8I .Production With the Partitioning option JServer Release 8.1. file2. IMPORT from more then one dump file Syntax imp <username/password> tables=<tablename> file=(file1.6. FILESIZE=1M Causes 1Meg files to be generated.11.10.dmp. exp3. 2) You have to create a file named protocol.) filesize=<FLSZ> Caution : FILESIZE value in imp should match with FILESIZE value of Export eg in our case 1000M for example C:###BOT_TEXT###gt;imp sam/dba_pass tables=EMPTEST file=(exp1. to allows the user to connect to the oracle database with IP-ADDRESS 192.ora on the server. <Client IP-ADDRESS 2>) # Add the following lines if you want to invite all the client machine except the following TCP.12 only . Now you have three export files exp1.192. 117 Export file Greater than 2GB is not a problem in 8I ? Filesize greater than 2Gb is always been a problem at most of OS.> filesize=<FLSZ> FILESIZE=0 (default) Causes one file.dmp.6.dmp is of size 1000M and exp3.validnode_ checking= yes 3)The destination of this file should be same as of sqlnet. configure the protocol.20 or 192.ora in a your favorite editor say notepad or vi and add the following lines in it. exp3. exp2. Connected to: Oracle8i Enterprise Edition Release 8.10.ora The step are very simple .dmp 13333426 rows exported Export terminated successfully without warnings.0 . C:###BOT_TEXT###gt;exp sam/dba_pass tables=EMPTEST file=(exp1. dmp .Production Export done in WE8ISO8859P1 character set and WE8ISO8859P1 NCHAR character set About to export specified tables via Conventional Path . exp2.. exp2. FILESIZE=1G Causes 1Gig files to be generated For example Here I am trying to create a dump file each of size 1000M.1. TCP..6. .dmp.dmp.20 .dmp and exp3. exp1.ora /protocol.3.0 .dmp. .168.dmp. <Client IP-ADDRESS 2>) # The following is the required parameter.ora and tnsnames. Syntax exp <username/password> tables=<exportTable Name> file=<fil1.3.168. FILESIZE=1K Same as above.ora as follows :tcp. This new feature of oracle 8i split the output dump file according to your size of wish by using FILESIZE OPTION .VALIDNODE_ CHECKING= yes Here is the simple example.dmp. Observation : I observer file exp1. so to import these dump files .dmp continuing export into file exp3.0 .dmp) filesize=1000M Export: Release 8. 168.protocol. All rights reserved..(In 9I implement the same in sqlnet.dmp.dmp. exporting table EMPTEST continuing export into file exp2.1.dmp and exp2.11.dmp is a last dump file of size 700K.168. ..Production on Thu May 3 13:09:05 2001 (c) Copyright 1999 Oracle Corporation.file2.exp2.INVITED_ NODES =(<Client IP-ADDRESS 1>.

0 .. SQL> connet scott/tiger Let us consider your oracle home is e:\ora816 SQL> @ e:\ora816\rdbms\ admin\utlchain. importing NGUV50's objects into NGUV50 .1.3. SQL > Prompt create a intermediate table first . Above will displays the rowid of migrated or chained rows . Let us consider a table samtest in scott user.Production With the Partitioning option JServer Release 8. SQL> analyze table samtest list chained rows.01. importing table "EMPTEST" 13333426 rows imported About to enable constraints. (ii) Analyze table < table_name> list chained rows.1. I am discussing here insert delete method..6.Import: Release 8.table_ name. All rights reserved. Now we will determine rowchaining in it and the way to eliminiate it. (iii) Eliminate the migrated or chained rows either by export/import or insert/delete method.6. ..1. 06 via conventional path import done in WE8ISO8859P1 character set and WE8ISO8859P1 NCHAR character set .Production on Thu May 3 13:10:58 2001 (c) Copyright 1999 Oracle Corporation.exp. SQL > select owner_name. Above will create populate a chained_rows table in case of chaining.6. Pratical example. . Prior to 8I # create a named pipe mknod exp. If you found chaining eliminate is by export/import or insert/delete method.0 .Production Export file created by EXPORT:V08.pipe p # read the pipe – output to zip file in the background gzip < exp.pipe > scott. 118 How to eliminate migrated or chained rows ? To eliminate migrated or chained rows You have to (i) Create chained rows table.3.pipe .3.head_ rowid from chained_rows.gz & # feed the pipe exp userid=scott/ tiger file=exp. sql Above will create a chained_rows table in scott user.if any. Connected to: Oracle8i Enterprise Edition Release 8. Import terminated successfully without warnings.0 .

The row moves to another block when it is not able to fit in the same block. SQL>Commit.SQL and PROFTAB. sql Package created. SQL> Prompt insert the rows from the intermediate table samtest_tab2 to samtest SQL> insert into samtest select * from samtest_tab2. Synonym created. All rights reserved. Grant succeeded.SQL SETUP : U:###BOT_TEXT###gt;sqlplus /nolog SQL*Plus: Release 9. SQL> @D:\oracle\rdbms\ admin\profload.1.0 . Testing for correct installation SYS. Above will create a table samtest_tab2 with all the chained rows. SQL> Prompt Delete the chained rows from the original table SQL> delete from samtest where rowid in (select head_rowid from chained_rows where table_name=' samtest') . SQL> connect sys/***** as sysdba Connected. If you have more update on the table set pctfree more to make room in the block for increase in the size of the row after updation. This way you can eliminate row chaining . Library created. Package body created. Oracle Corporation. SQL> DELETE * from chained_rows where table_name=' samtest'.>admin SCRIPT : PROFLOAD.SQL > create table samtest_tab2 as select * from samtest where rowid in (select head_rowid from chained_rows where table_name = 'samtest'). SQL> prompt drop the intermediate table SQL> drop table samtest_tab2.Production on Mon Apr 14 13:26:03 2003 Copyright (c) 1982. To avoid row-chaining set pctfree and pctused correctly.DBMS_PROFILER successfully loaded. 119 Performance Measurement of PLSQL code by DBMS_PROFILER If you are not already configured DBMS_PROFILE package look the following script in Oracle Home>rdbms. SQL> @D:\oracle\rdbms\ admin\proftab. Create the profiler tables SQL> connect hr/hr Connected.2. sql drop table plsql_profiler_ data cascade constraints * ERROR at line 1: ORA-00942: table or view does not exist drop table plsql_profiler_ units cascade constraints * ERROR at line 1: ORA-00942: table or view does not exist . 2002.0. PL/SQL procedure successfully completed.

testemp (emp ) VALUES (i ). SQL> SQLDECLARE . Comment created. FOR i IN 1 . DELETE FROM hr. Table created. END LOOP. SELECT COUNT (*) INTO vempno FROM hr.testemp (emp ) VALUES (i ).testemp. vempno NUMBER. The above script will create the following table PLSQL_PROFILER_ DATA TABLE PLSQL_PROFILER_ RUNS TABLE PLSQL_PROFILER_ UNITS TABLE Let us create a sample table and a procedure for demonstration SQL> create table testemp(emp number). put_line ('No of record' || vempno). CREATE OR REPLACE PROCEDURE hr. 100000 LOOP INSERT INTO hr.testproc IS i NUMBER := 0.testemp. END LOOP. Sequence created. COMMIT. COMMIT. END testproc. Table created. DBMS_OUTPUT. Comment created.drop table plsql_profiler_ runs cascade constraints * ERROR at line 1: ORA-00942: table or view does not exist drop sequence plsql_profiler_ runnumber * ERROR at line 1: ORA-02289: sequence does not exist Table created. Table created. COMMIT. i := i + 1. BEGIN WHILE i < 100000 LOOP INSERT INTO hr.. / The following PL/SQL will call the profile SQL> Set serveroutput on. Comment created.

461.unit_owner AND s.calling procedure vrun := SYS. 40) stext FROM plsql_profiler_ runs r. HR.testemp.' || u. . put_line( 'No of record'||vem HR. 1.unit_type AND s.000 100000 insert into hr.TYPE = u.---------. DBMS_OUTPUT. put_line ('0 successful') .total_occur tc.000 2 dbms_output.-------.000 1 delete from hr.NAME = u.000 1 commit.runid AND d.TESTPROC 6 58.DBMS_PROFILER.--------.unit_name unit.line# ORDER BY line# / Expected Output UNIT LINE# TIME[s] Exection STEXT -----------.951.runid AND u.test HR. / Expected Output START PROFILER STATUS 0 No of record100000 STOP PROFILER STATUS 0 0 successful 1 incorrect parameter 2 data flush operation failed -1 version mismatch between package and tables PL/SQL procedure successfully completed. DBMS_OUTPUT. ROUND (d.TESTPROC 15 0.DBMS_PROFILER. hr.total_time / 1000000000) total_time_s.runid = u. put_line ('-1 version mismatch between package and tables').testproc.TESTPROC 10 131. put_line ('START PROFILER STATUS ' || vrun). line#. DBMS_OUTPUT.TESTPROC 8 4. put_line ('STOP PROFILER STATUS ' || vrun).000 1 select count(*) into vempno from hr.unit_owner || '.unit_name AND s.unit_number = d. DBMS_OUTPUT. HR. Now run the sql to find out the most extensive part of the plsql SET linesize 132 COL unit format a20 COL tc format 9999999 heading "Exection" COL stext format a40 SELECT u. HR.--.000 100001 while i < 100000 HR. d. plsql_profiler_ units u.unit_number AND s.vrun NUMBER. END. HR.901. SUBSTR (s.runid = u.000 100000 commit.000 1 i number := 0.TESTPROC 12 6.-----------. -.run_comment = 'TESTRUN1' AND r.owner = u. put_line ('1 incorrect parameter'). stop_profiler.testemp(emp ) values (i).TESTPROC 9 2.TESTPROC 14 1.text. DBMS_OUTPUT. DBMS_OUTPUT.--------.--------.TEST 3 0. BEGIN vrun := SYS. start_profiler ('TESTRUN1') .line = d. put_line ('2 data flush operation failed'). all_source s WHERE r.TESTPROC 13 0. HR. plsql_profiler_ data d.-----------.HR.000 100000 i := i + 1.

.--------.TESTPROC 18 5. lf_rows. DEPTNO JOB TOTSAL ---------.000 100000 insert into hr.job.height. 120 When to rebuid an index ? Observation 1. 121 Explain the analytical functions with examples • ROLLUP AND CUBE AGGREGATE FUNCTIONS • RANKED FUNCTION • CASE • LAG AND LEAD FUNCTION • RATIO_TO_REPORT To understand the power of ROLLUP and CUBE functions .000 100000 commit.TESTPROC 16 70.371.-----------.----------.---------. Example :ora816 SamSQL :> analyze index IND_PK validate structure. ora816 SamSQL :> select name.--------. HR.consider the following SQL statement :ora816 SamSQL :> compute sum of totsal on deptno ora816 SamSQL :> break on deptno ora816 SamSQL :> select deptno. Check the index_stats again. It may be assumed that It is correct . NAME HEIGHT DEL_LF_ROWS LF_ROWS (DEL_LF_ROWS/ LF_ROWS)* 100 -----------.job.HR.---------.000 100001 for i in 1.TESTPROC 19 2.---INDX_PK 4 277353 990206 28.955. If the percentage (del_lf_rows/ lf_rows)* 100 > = 20 . del_lf_rows. Observe del_lf_rows and lf_rows in index_stats view after analyzing the particular index.sum( sal) totsal from emp group by deptno. So observer the height in index_stats time to time and if height remain unchanged .--------. It is good to rebuild index as it indicate unbalanced tree because of high update and delete occurred on it. Although there is always been an exception to this rule.--------.( del_lf_rows/ lf_rows) *100 from index_stats.100000 HR. Observe height in index_stats view after analyzing the particular index.testemp(emp ) values (i). Obervation 2. If it is >= 4 .0096263 ora816 SamSQL :> alter index IND_PK rebuild. it is good to rebuild index as it indicate a skewed tree structure.---------10 CLERK 1300 MANAGER 2450 PRESIDENT 5000 ********** ---------sum 8750 20 ANALYST 6000 .

---------10 CLERK 1300 10 MANAGER 2450 10 PRESIDENT 5000 10 8750 Total of Deptno 10 20 ANALYST 6000 20 CLERK 1900 20 MANAGER 2975 20 10875 30 CLERK 950 30 MANAGER 2850 30 SALESMAN 5600 30 9400 29025 Grand Total . job). DEPTNO JOB TOTSAL ---------.--------.job.sum( sal) totsal from emp group by ROLLUP(deptno.CLERK 1900 MANAGER 2975 ********** ---------sum 10875 30 CLERK 950 MANAGER 2850 SALESMAN 5600 ********** ---------sum 9400 Now see the use of ROLLUP Function ora816 SamSQL :> select deptno.

Also at end you will see the grand total . Now see the use of CUBE Function ora816 SamSQL :> select deptno.t JOB PRESIDENT 5000 SALESMAN 5600 Grand Total 29025 Cube also do a total with respect to second group for example JOB in our case . By using rollup you can avoid compute and break clausesfrom SQL.job. job).sum( sal) totsal from emp group by CUBE(deptno.So if you compare the two output you will notice that you are getting the same output.r. This will mostly helpful in PL/SQL . Fri Mar 23 NuGenesis Report DEPTNO JOB TOTSAL ---------. We do not have to put logic for computing values on break of groups.--------.---------10 CLERK 1300 10 MANAGER 2450 10 PRESIDENT 5000 10 8750 Total of Deptno 10 20 ANALYST 6000 20 CLERK 1900 20 MANAGER 2975 20 10875 30 CLERK 950 30 MANAGER 2850 30 SALESMAN 5600 30 9400 ANALYST 6000 CLERK 4150 MANAGER 8275 Total w.

---------. rank() over ( partition by repcol 2 order by value desc ) ranked_value 3 from test.---------A 100 A 200 A 300 B 1000 B 900 B 800 A 500 B 400 B 500 Ora816 SamSQL> select repcol. REPCOL VALUE ---------.Conclusion : Rollup and Cube are the aggregate function which allows developers and dbas to avoid compute and break clauses and simplify logic of programming Ranked Function in 8i (816) Suppose you have a data in table which you want to rank in a specified order for example you have a table test and you want to rank a value of repcol.-----------A 500 1 A 300 2 A 200 3 A 100 4 B 1000 1 B 900 2 B 800 3 . REPCOL VALUE RANKED_VALUE ---------.value. Ora816 SamSQL> select * from test.

-----------. 3 sum(case when value = 500 then 1 else 0 end) Value_Eq_500. 4 sum(case when value > 100 then 1 else 0 end) Value_Gre_100 5* from test Ora816 SamSQL> / SUM_OF_A SUM_OF_B VALUE_EQ_500 VALUE_GRE_100 ---------.- . 2 sum(Case when repcol='B' then value else 0 end) Sum_of_B. 3 sum(case when value = 500 then 1 else 0 end) Value_Eq_500.B 500 4 B 400 5 The above value is ranked by the rank function provided by 8.1.buf 1 select sum(case when repcol='A' then value else 0 end) sum_of_A.---------.---------.sum(case when repcol='A' then value else 0 end) sum_of_A.6 Use of Case in SELECT Case Statement are similar to decode .---------.1100 3600 2 8 Use of Group by in CASE Ora816 SamSQL> ed Wrote file afiedt.-----------.-----------. 2 sum(Case when repcol='B' then value else 0 end) Sum_of_B.buf 1 select repcol.-----------. 4 sum(case when value > 100 then 1 else 0 end) Value_Gre_100 5 from test 6* group by repcol Ora816 SamSQL> / REPCOL SUM_OF_A SUM_OF_B VALUE_EQ_500 VALUE_GRE_100 ---------. it is more flexible and gives better performace Ora816 SamSQL> ed Wrote file afiedt.

buf 1 select (case when value between 100 and 300 then '100-300' 2 when value between 400 and 700 then '400-700' 3 when value between 800 and 900 then '800-900' 4 when value > 900 then '>900' end) VALUE_RANGE. 5 count(*) as VALUE_COUNT 6 from test 7 group by 8 (case when value between 100 and 300 then '100-300' 9 when value between 400 and 700 then '400-700' 10 when value between 800 and 900 then '800-900' 11* when value > 900 then '>900' end ) Ora816 SamSQL> / VALUE_R VALUE_COUNT ------.A 1100 0 1 3 B 0 3600 1 5 Ora816 SamSQL> ed Wrote file afiedt. value .----------100-300 3 400-700 3 800-900 2 >900 1 Ora816 SamSQL> ed Wrote file afiedt.buf 1 select (case when value between 100 and 300 then '100-300' 2 when value between 400 and 700 then '400-700' 3 when value between 800 and 900 then '800-900' 4 when value > 900 then '>900' end) VALUE_RANGE.

Lag and Lead Functions Ora816 SamSQL> ed Wrote file afiedt. 3 lag(value.---------.---------100-300 100 100-300 200 100-300 300 >900 1000 800-900 900 800-900 800 400-700 500 400-700 400 400-700 500 9 rows selected. 2 value.1) over (order by repcol) lag_value . 4 lead(value.---------.---------A 100 200 A 200 100 500 A 500 200 300 A 300 500 1000 .1) over (order by repcol) lead_value 5* from test Ora816 SamSQL> / REPCOL VALUE LAG_VALUE LEAD_VALUE ---------.5* from test Ora816 SamSQL> / VALUE_R VALUE ------.buf 1 select repcol.

. Its syntax is: RATIO_TO_REPORT () OVER ([PARTITION BY [..buf 1 select repcol. RATIO_TO_REPORT also evaluates to NULL. but it is treated as zero for computing the sum of values for the denominator.]] ORDER BY [collate clause>] [ASC | DESC] [NULLS FIRST | NULLS LAST] [. The functions have the following syntax: {LAG | LEAD} (.. The LAG function provides access to a row at a given offset prior to the position and the LEAD function provides access to a row at a given offset after the current position.. If the expression value expression evaluates to NULL. If the PARTITION BY clause is absent. 3 sum(value) over() sumofvalue.B 1000 300 500 B 500 1000 900 B 900 500 400 B 400 900 800 B 800 400 9 rows selected. ]]) OVER ([PARTITION BY [.. 2 value.value Ora816 SamSQL> / . 4 ratio_to_report (sum(value)) over() RATIO 5 from test 6* group by repcol .. Ratio_to_report The RATIO_TO_REPORT function computes the ratio of a value to the sum of a set of values. • The PARTITION BY clause defines the groups on which the RATIO_TO_REPORT function is to be computed. then the function is computed over the whole query result set.. Ora816 SamSQL> ed Wrote file afiedt.]) is an optional parameter and defaults to 1.]]) where • and can be any valid expression involving column references or aggregates. is an optional parameter and is the value returned if the falls outside the bounds of the table or partition.. [ [..

272727273 A 500 1100 .085106383 B 500 4700 .---------.222222222 B 900 3600 .063829787 A 500 4700 .212765957 9 rows selected.106382979 B 800 4700 .---------A 100 1100 .021276596 A 200 4700 .---------. 3 sum(value) over(partition by repcol) sumofvalue.sh utility is used to licnece a product/products You cannot de-license an existing fully licensed product.170212766 B 900 4700 .---------A 100 4700 . Ora816 SamSQL> ed Wrote file afiedt. 2 value.454545455 B 400 3600 .25 B 1000 3600 .042553191 A 300 4700 .191489362 B 1000 4700 .111111111 B 500 3600 .REPCOL VALUE SUMOFVALUE RATIO ---------.106382979 B 400 4700 .value Ora816 SamSQL> / REPCOL VALUE SUMOFVALUE RATIO ---------. 122 What is High Water Mark ? High-water mark is an indicator or pointer up to which table or index has ever contain data 123 what is the utility used to licence a product ? Is it possible to delicence a product which is fully licenced ? A: adlicmgr.181818182 A 300 1100 .090909091 A 200 1100 .buf 1 select repcol. 124 how to find the version of iAS ? .138888889 B 800 3600 .---------.---------.277777778 9 rows selected. 4 ratio_to_report (sum(value)) over(partition by repcol) RATIO 5 from test 6* group by repcol .

rex stype=rexfile dtype=rdffile dest=FNDSCURS. rex overwrite=yes batch=yes r25convm userid=apps/ apps source=FNDSCURS.rdf *Note: userid is the schema owner.4 uses Apache 1.1s) --> OHS 1. .5. just ignore the error message.rex stype=rexfile dtype=rdffile dest=<report name>.Apps 11.2. this *** is a known issue with the reports team.19 (iAS 1.8 uses Apache 1.3.7 <schema top>/reports If your Application version is 11 Logon as applmgr r25convm userid=<schema owner of report>/<password> source=<report name>.rdf report file to a .rdf' .19 means iAS version is 1.7 uses Apache 1.2.3.rex' to 'FNDSCURS.5.0.2.rdf) file from the UNIX command line? Solution Description -----------.5 uses Apache 1.9 (must upgrade) Apps 11.2 karunakarkandhi: right bkpraveen25: yep bkpraveen25: Apache Version is 1.3.7 cd $FND_TOP/reports If your Application version is 11 Logon as applmgr The command line syntax is: r25convm userid=apps/ apps source=FNDSCURS.19 (iAS 1.0.-------Use r25convm. REP-25200: Converting 'FNDSCURS.2. If the report is a GL report then the userid will be gl/gl If the report is a FND report then the userid will be apps/apps For the FNDSCURS.rex report file and back to a .2) --> OHS 1.rex overwrite=yes batch=yes ie: r25convm FNDSCURS.9 in Agilent 125 How do you generate a report (.0.0.2..3.rdf stype=rdffile dtype=rexfile dest=<report name>.2 Apps file resides which is: <schema top>/srw If your Application version is 10.1s Apps (iAS 1. rdf overwrite=yes batch=yes *** Note: You may get the following error.rex overwrite=yes batch=yes r25convm userid=<schema owner of report>/<password> source=<report name>..3.rdf report file: r25convm syntax: cd to where your . The following command will convert an .rdf example the report reside in: cd $FND_TOP/srw If your Application version is --> OHS 1.2 karunakarkandhi: that means if the apache version is 1. rdf stype=rdffile dtype=rexfile dest=FNDSCURS.2.

rdf using r25conv32 ***Note: userid is the schema owner. rdf stype=rdffile dtype=rexfile dest=FNDSCURS.--------. If the report is a GL report then the userid will be gl/gl If the report is a FND report then the userid will be apps/apps 1.Method #1: --------- .rdf report file to a . rex overwrite=yes batch=yes r25conv32 userid=apps/ apps source=FNDSCURS.126 How do you generate a report (.rdf example the report resides in: cd $FND_TOP/srw If your Application version is 10. Issue the following commands: r25conv32 userid=<schema owner of report>/<password> source=<reportname> .rdf stype=rdffile dtype=rexfile dest=<report name>. 127 Running SQL*Trace on an Applications Report ? Running a Report with SQL*Trace -----------. The following command will convert an .7 <schema top>/reports If your Application version is 11 3.rdf overwrite=yes batch=yes Example: Generating FNDSCURS. cd to where your . Logon as applmgr 2.rex stype=rexfile dtype=rdffile dest=<report name>. Logon as applmgr 2.-------Use r25conv32.rex overwrite=yes batch=yes r25conv32 userid=<schema owner of report>/<password> source=<reportname> .--------. For the FNDSCURS.rdf file resides which is: <schema top>/srw If your Application version is 10.rdf file) from a Windows NT command line? Solution Description -----------. The command line syntax is: r25conv32 userid=apps/ apps source=FNDSCURS.7 cd $FND_TOP/reports If your Application version is 11 3.exe to generate a report from the Windows NT command line. rex stype=rexfile dtype=rdffile dest=FNDSCURS.rdf report file: r25conv32 syntax: 1. rdf overwrite=yes batch=yes .rex report file and back to a .

Arrange to run JUST that specific report without running anything else. with a NAME of 'beforerep__ __': Example I: DEFINE TOOL_PLSQL BEGIN ITEMID = 103 NAME = <<"beforerep0040" >> . Run the report. Turn SQL*Trace off by modifying your init. 4.rex For Example: r25convm userid=ar/ar source=RAXIIR.ora file. adding two simple lines. 7.rdf and .--------. 3.rdf of the report. After running the report. Edit the . Modify the .rex text file to save space on their system).rdf stype=rdffile dtype=rexfile dest=<reportname> . How to Run a Report with SQL*Trace using Method #2 -----------. You should find an entry similar to the following. rex 3. shut down the database and concurrent managers.ora file.rex file if necessary: Make sure a . Backup your current .rex into the new . 4. Create the .rex file into your editor of choice and search for 'SRWINIT'.rex for the report. 5. Turn SQL*Trace on by modifying your init. rdf stype=rdffile dtype=rexfile dest=RAXIIR. Convert the new . Restore the original . If the .rdf file. create one by issuing the following command as the applmgr user: r25convm userid=<userid> /<password> source=<reportname> . 2. you would have to do the following: 1. Method #2: --------A simpler method is as follows (detailed instructions follow): 1. 2. Shut down the concurrent managers and the database.rex does not exist. 3. 5.rex file: A.--------.rex text file of the report exists. 6.rdf file.--------.--------.rex files. in order to run a report with SQL*Trace.-1. Backup your current . Pull the . 2. Bring the database and the concurrent managers back up. Bring the database and concurrent managers back up.Normally. (Customers are not shipped the .

PLSLFID_EP = (BLONG) NULLP OBJECT_ID = 0 TYPE PLSLFID_ST = (TLONG) <<"SRW.do_sql(' alter session set sql_trace=TRUE' ). IF (:p_debug_switch = 'Y') THEN SRW. Find the line similar to the following.USER_ EXIT('FND SRWEXIT'). Immediately after the . srw. ">> END Example II: BEGIN SRW.do_sql(' alter session set sql_trace=TRUE' ). END IF.USER_EXIT( 'FND SRWINIT').USER_EXIT( 'FND SRWINIT').USER_ EXIT('FND SRWINIT').MESSAGE( '1'. ">> .'After SRWINIT'). END IF.USER_ EXIT('FND SRWINIT'). The modified versions of the above examples should look like the following: Example I: DEFINE TOOL_PLSQL BEGIN ITEMID = 103 NAME = <<"beforerep0040" >> PLSLFID_EP = (BLONG) NULLP OBJECT_ID = 0 TYPE PLSLFID_ST = (TLONG) <<"SRW. srw. ">> END Example II: BEGIN SRW. IF (:p_debug_switch = 'Y') THEN SRW. by searching for 'SRWEXIT': <<"SRW. END C. which follows 'FND SRWINIT'. END B.MESSAGE( '1'.'After SRWINIT'). (and remaining within the "" that surround the line) add the following line: srw.do_sql(' alter session set sql_trace=TRUE' ).

6. Restore the original report files: Restore the original . Access the trace file: The trace file will be located in the directory specified by the user_dump_dest variable in your init.rdf For Example: r25convm userid=ap/ap source=RAXIIR. add the following line: srw.rex if one existed before modification) . For Example: <<"SRW. .rex file. Immediately after the . rex stype=rexfile dtype=rdffile dest=RAXIIR.USER_ EXIT('FND SRWEXIT'). How to find the Apache Version? The Apache version can be obtained from the httpd executable: $ORACLE_HOME/ Apache/Apache/ httpd -version. 5.rdf file (and . 7. You may wish to backup the . Once the issue you're troubleshooting is resolved. exit the Applications. the system will not be able to generate the .rdf file: To do this. you can delete it.rex file into a . rdf NOTE: If you did not properly modify the . 128.rdf file containing the SQL*Trace code. ">> END NOTE: This is really not necessary as the trace session will terminate when the report completes.ora file.rdf file. but it's a good idea to include it as a precautionary measure. which follows 'FND SRWEXIT'. Run the report: Logon to the Applications and run the report through the concurrent managers.rex' cancelled". When it has completed. just in case you need to run it at a later time.do_sql(' alter session set sql_trace=FALSE' ). 4. but remaining within the "".END D.rex stype=rexfile dtype=rdffile dest=<reportname> . issue the following command as the applmgr user: r25convm userid=<userid> /<password> source=<reportname> .do_sql(' alter session set sql_trace=FALSE' ). Convert the modified . srw. An example of the message you may get is: "Conversion of 'RAXNCAR.

3. clear the cache.0 Resolution: You may need to upgrade to either OJSP 1.The FND patchset level is E.lang. and one or more control files.1. . getAttribute( "oracle. 5. jsp) it shows "Application Error".0.1.NullPoint erException You have to use the Delete Cookies option (in IE) to get around this. A tablespace is used to grouped related logical structures together. Even restarting the browser doesn't handle it until you delete the cookies.ClassCast Exception: java. What are the components of logical database structure of Oracle database? There are tablespaces and database's schema objects. . What are the components of physical database structure of Oracle database? Oracle database is comprised of three types of files. <HTML> <HEAD> <TITLE>OJSP Version Getter</TITLE> </HEAD> <BODY> The OJSP version that you are using is: <%= application.lang. Java Stack shows java. tablespace and data file. two are more redo log files. One or more datafiles. What is SYSTEM tablespace and when is it created? Every Oracle database contains a tablespace named SYSTEM. and bounce apache [top] Login: "Application Error" when logging into iStore home page (ibeCZzpHome.Object Cause: Profile Option value Resolution: Reset the profile option "IBE: Preload Specialty Store Cache" to null at all levels.java.1 on how to upgrade your OJSP. versionNumber" ) %> </BODY> </HTML> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++++++++++++++++++ 1. which is automatically created when the database is created.The OJSP version is: 1.1.129 how to find the ojsp version ? Login: Accessing ibeCZzdMinisites. jsp) Problem: When logging into iStore home page (ibeCZzpHome. place it in the OA_HTML directory and call it from the browser.0 or OJSP 1.0. The SYSTEM tablespace always contains the data dictionary tables for the entire database.1. jsp it is giving the Application error .0. Explain the relationship among database.2. . What is a tablespace? A database is divided into Logical Storage Unit called tablespaces.lang.jsp. Refer to Note 132604. To check your OJSP version: Create a jsp file with the following code. 4. 2.

(The query is a SELECT statement that identifies the columns and rows of the table(s) the view uses. indexes. What is Partial Backup ? A Partial Backup is any operating system backup short of a full backup. 12. Table data is stored in rows and columns. What is Mirrored on-line Redo Log ? A mirrored on-line redo log consists of copies of on-line redo log files physically located on separate disks. Can objects of the same schema reside in different tablespaces? Yes.) 11.Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace. What is an Oracle view? A view is a virtual table. 7. Schema objects include tables. What are Schema Objects? Schema objects are the logical structures that directly refer to the database's data. Can a tablespace hold objects from different schemes? Yes. sequences. views. . 11. taken while the database is open or shut down. functions packages and database links. clusters. The tables of a database hold all of the user accessible data. changes made to one member of the group are made to all members. 6. database triggers. synonyms. Every view has a query attached to it. What is Oracle table? A table is the basic unit of data storage in an Oracle database. procedures. 10. 9. What is schema? A schema is collection of database objects of a user. 8.

What is Full Backup ? A full backup is an operating system backup of all data files. its control file is used to identify the database and redo log files that must be opened for database operation to proceed. Do View contain Data ? Views do not contain or store data. 15.13. Can a View based on another View ? Yes. DELETE Cascade . 20.UID. What is a Redo Log ? The set of Redo Log files YSDATE. 16. 19. What are the type of Synonyms? There are two types of Synonyms Private and Public. or the pseudo columns LEVEL or ROWNUM. .When a referenced row is deleted all associated dependent rows are deleted. Can a Tablespace hold objects from different Schemes ? Yes. It is also used in database recovery.USER or USERENV SQL functions. 21.A referential integrity rule that disallows the update or deletion of referenced data. on-line redo log files and control file that constitute ORACLE database and the parameter. 17. What are the Referential actions supported by FOREIGN KEY integrity constraint ? UPDATE and DELETE Restrict . ? Yes. 14. 18. Can objects of the same Schema reside in different tablespaces. What is the use of Control File ? When an instance of an ORACLE database is started.

What is a View ? A view is a virtual table. Explain the relationship among Database. Index can be created on one or more columns of a table.22. 29. 28. 25. Every view has a Query attached to it. What is Table ? . Index Segment. What is an Index ? An Index is an optional structure associated with a table to have direct access to rows. What is an Index Segment ? Each Index has an Index segment that stores all of its data. What is an Extent ? An Extent is a specific number of contiguous data blocks. which can be created to increase the performance of data retrieval. 26. and used to store a specific type of information. (The Query is a SELECT statement that identifies the columns and rows of the table(s) the view uses.? Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace 24.) 30. What is an Integrity Constrains ? An integrity constraint is a declarative way to define a business rule for a column of a table. 23. obtained in a single allocation. 27. Tablespace and Data file. Rollback Segment and Temporary Segment. What are Clusters ? Clusters are groups of one or more tables physically stores together to share common columns and are often used together. What are the different type of Segments ? Data Segment.

Simplify commands for the user.Present the data in a different perspective from that of the base table. Table data is stored in rows and columns 31.Provide public access to an object .Provide location transparency for tables.Mask the real name and owner of an object. What are synonyms used for? .Store complex queries. Can a view based on another view? Yes. . What is a private synonym? Only its owner can access a private synonym. What are the advantages of views? .Hide data complexity. . sequence or program unit. . 37. . 33. 38. . 35. by restricting access to a predetermined set of rows and columns of a table. view. 34.Provide an additional level of table security. What is a synonym? A synonym is an alias for a table. What is an Oracle sequence? A sequence generates a serial list of unique numbers for numerical columns of a database's tables. The tables of a database hold all of the user accessible data.A table is the basic unit of data storage in an ORACLE database. What are the types of synonyms? There are two types of synonyms private and public. 36. . What is a public synonym? Any database user can access a public synonym. 32. views or program units of a remote database.

Database Name Names and locations of a database's files and redolog files. Block size is specified in INIT. What is an Oracle index? An index is an optional structure associated with a table to have direct access to rows.Simplify the SQL statements for database users. 46. Once created a data file can't change size.. How to define Data Block size ? A data block size is specified for each ORACLE database when the database is created. 44. A database users and allocated free database space in ORACLE datablocks.What is difference between UNIQUE constraint and PRIMARY KEY constraint ? . What is Rollback Segment ? A Database contains one or more Rollback Segments to temporarily store "undo" information. Changes to table data are automatically incorporated into all relevant indexes. What are the Characteristics of Data Files ? A data file can be associated with only one database. What does a Control file Contain ? A Control file records the physical structure of the database. One or more data files form a logical unit of database storage called a tablespace. 43. 40. It contains the following information. How are the index updates? Indexes are automatically maintained and used by Oracle. which can be created to increase the performance of data retrieval. Index can be created on one or more columns of a table.ORA file and can’t be changed latter. 39. What is a Tablespace? A database is divided into Logical Storage Unit called tablespaces. 45. Time stamp of database creation. 41. A tablespace is used to grouped related logical structures together 42.

49. If you are using a volume manager. How does one create a new database? (for DBA) One can create and modify Oracle databases using the Oracle "dbca" (Database Configuration Assistant) utility. Otherwise the OPTIMIZER chooses RULE_based approach. ALTER SYSTEM SET DB_CREATE_ONLINE_ LOG_DEST_ 2='/u03/oradata/ '. use a larger block size. or be multiples of your operating system block size. 47. Your choice should depend on the type of application you are running. CREATE DATABASE. The dbca utility is located in the $ORACLE_HOME/ bin directory.A column defined as UNIQUE can contain Nulls while a column defined as PRIMARY KEY can't contain Nulls. but the performance cost is significant. parameter of the ALTER SESSION Command ? The Optimizer chooses Cost_based approach and optimizes with the goal of best throughput if statistics for atleast one of the tables accessed by the SQL statement exist in the data dictionary. is falling out of fashion.What is Index Cluster ? A Cluster with an index on the Cluster Key 48. 51. What is the effect of setting the value "CHOOSE" for OPTIMIZER_GOAL. as it is quite involved and error prone. ALTER SYSTEM SET DB_CREATE_ONLINE_ LOG_DEST_ 1='/u02/oradata/ '. What is the effect of setting the value "ALL_ROWS" for OPTIMIZER_GOAL parameter of the ALTER SESSION command ? What are the factors that affect OPTIMIZER in choosing an Optimization approach ? Answer The OPTIMIZER_MODE initialization parameter Statistics in the Data Dictionary the OPTIMIZER_GOAL parameter of the ALTER SESSION command hints in the statement. consider your "operating system block size" to be 8K. 50.When does a Transaction end ? When it is committed or Rollbacked. . This is because volume manager products use 8K blocks (and this is not configurable) . The Oracle Universal Installer (oui) normally starts it after installing the database server software. This option. as with a DSS application. use a smaller block size. With fewer but larger transactions. What database block size should I use? (for DBA) Oracle recommends that your database block size match. If you have many small transactions as with OLTP. One can also create databases manually using scripts. 52. Look at this example for creating and Oracle 9i database: CONNECT SYS AS SYSDBA ALTER SYSTEM SET DB_CREATE_FILE_ DEST='/u01/ oradata/' . One can use smaller block sizes. however.

53. NAME FROM SYS. 54. Note that the number of extents per segment does not cause any performance issue anymore. What does ROLLBACK do ? ROLLBACK retracts any of the changes resulting from the SQL statements in the transaction. only for a short period of time. 100K.table ESTIMATE STATISTICS. Thiru Vadivelu contributed the following: Use the same extent size for all the segments in a given tablespace. 100K. For example if you set PCTINCREASE to 1 you will see that your extents are going to have weird and wacky sizes: 100K. What are the different approaches used by Optimizer in choosing an execution plan ? Rule-based and Cost-based. COALESCE. 101K. Where can one find the high water mark for a table? (for DBA) There is no single system table.. With Oracle 7. Bizarre values for PCTINCREASE will contribute to fragmentation. Locally Managed tablespaces (available from 8i onwards) with uniform extent sizes virtually eliminates any tablespace fragmentation. 102K. 56.. Eg. 200K.DBA_FREE_ SPACE_COALESCED dictionary view. 55. How does one prevent tablespace fragmentation? (for DBA) Always set PCTINCREASE to 0 or 100. etc.3 one can manually coalesce a tablespace using the ALTER TABLESPACE . You can get status information about this process by selecting from the SYS. Where 'n' is the tablespace number you get from SELECT TS#. Such extents of bizarre size are rarely re-used in their entirety. contiguous extents every 2 hours and even then. PCTINCREASE of 0 or 100 gives you nice round extent sizes that can easily be reused. ANALYZE TABLE owner. How does one coalesce free space?(for DBA) SMON coalesces free space (extents) into larger.TS$. A table's HWM can be calculated using the results from the following SQL statements: SELECT BLOCKS FROM DBA_SEGMENTS WHERE OWNER=UPPER( owner) AND SEGMENT_NAME = UPPER(table) . etc. 100K. 400K. SELECT EMPTY_BLOCKS FROM DBA_TABLES WHERE OWNER=UPPER( owner) AND SEGMENT_NAME = UPPER(table) . . command. which contains the high water mark (HWM) for a table. until then use: SQL> alter session set events 'immediate trace name coalesce level n'. unless they run into thousands and thousands where additional I/O may be required to fetch the additional blocks where extent maps of the segment are stored. SMON will not coalesce free space if a tablespace's default storage parameter "pctincrease" is set to 0.

Oracle will round it up to 10 blocks. What is COST-based approach to optimization ? Considering available access paths and determining the most efficient execution plan based on statistics in the data dictionary for the tables accessed by the statement and their associated clusters and indexes. What is Read-Only Transaction ? A Read-Only transaction ensures that the results of each query executed in the transaction are consistant with respect to the same point in time. but it allocates 2 blocks or 16K as requested. Can one rename a database user (schema)? (for DBA) No. then Oracle allocates 64K or 8 blocks assuming 8K-block size. Space allocation also depends upon the size of contiguous free space available. The changes made by the SQL statements of a transaction become visible to other user sessions transactions that start only after transaction is committed. 58.(query result 2) . If it were 9 blocks. How are extents allocated to a segment? (for DBA) Oracle8 and above rounds off extents to a multiple of 5 blocks when more than 5 blocks are requested. Define Transaction ? A Transaction is a logical unit of work that comprises one or more SQL statements executed by a single user. If one requests 16K or 2 blocks (assuming a 8K block size). 62. it would give it you. .1. the tables' HWM = (query result 1) . 57. this is listed as Enhancement Request 158508. What does COMMIT do ? COMMIT makes permanent the changes resulting from all SQL statements in the transaction. Oracle doesn't round it up to 5 blocks. If one asks for 8 blocks and Oracle finds a contiguous free space that is exactly 8 blocks. The exception to this rule is locally managed tablespaces.1 NOTE: You can also use the DBMS_SPACE package and calculate the HWM = TOTAL_BLOCKS UNUSED_BLOCKS . Oracle would also give it to you. Workaround: Do a user-level export of user A create new user B Import system/manager fromuser=A touser=B Drop user A 61. Oracle doesn't round it up to the multiple of 5 when a tablespace is locally managed. 59. If one asks for 8 blocks. 60. Clearly Oracle doesn't always round extents to a multiple of 5 blocks. If a tablespace is created with local extent management and the extent size is 64K.Thus.

What is Parallel Server ? Multiple instances accessing the same database (Only In Multi-CPU environments) 67. Shared SQL pool) SMON (System MONito) PMON (Process MONitor) LGWR (LoG Write) DBWR (Data Base Write) ARCH (ARCHiver) CKPT (Check Point) RECO Dispatcher User Process with associated PGS 68. What is a Schema ? The set of objects owned by user account is called the schema. The cluster key is indexed using a cluster index and its value is stored only once for multiple tables in the cluster.indexes. Poor design of front-end application may cause this situation and the performance of server will reduce drastically. The Database contains multiple users/schemas one or more rollback segments one or more tablespaces Data dictionary tables User objects (table. What are the basic element of Base configuration of an oracle Database ? It consists of one or more data files.) The server that access the database consists of SGA (Database buffer. In a database environment this will often happen because of not issuing proper row lock commands. 64. What is clusters ? . one or more control files.. These locks will be released automatically when a commit/rollback operation performed or any one of this processes being killed externally. two or more redo log files.63. 65. views etc. Redo log buffers. Two processes wating to update the rows of a table which are locked by the other process then deadlock arises. What is a deadlock ? Explain . What is a cluster Key ? The related columns of the tables are called the cluster key. 66. Dictionary Cache Buffers.

69. What is default tablespace ? The Tablespace to contain schema objects created without specifying a tablespace name. 71. . What is a Database instance ? Explain A database instance (Server) is a set of memory structure and background processes that access a set of database files. 74. What are the system resources that can be controlled through Profile ? The number of concurrent sessions the user can establish the CPU processing time available to the user's session the CPU processing time available to a single call to ORACLE made by a SQL statement the amount of logical I/O available to the user's session the amout of logical I/O available to a single call to ORACLE made by a SQL statement the allowed amount of idle time for the user's session the allowed amount of connect time for the user's session.Group of tables physically stored together because they share common columns and are often used together is called Cluster. WWhat is the use of ANALYZE command ? To perform one of these function on an index. 73. .To collect statistics about object used by the optimizer and store them in the data dictionary. . An index is automatically created when a unique of primary key constraint clause is specified in create table comman (Ver 7.table. or cluster: . The memory structure that are used to store most queried data from database.0) 70. . This helps up to improve database performance by decreasing the amount of I/O performed against data file. What is Tablespace Quota ? The collective amount of disk space available to the objects in a schema on a particular tablespace. 72.To identify migrated and chained rows of the table or cluster. The process can be shared by all users.To delete statistics about the object used by object from the data dictionary.To validate the structure of the object. What is an Index ? How it is implemented in Oracle Database ? An index is a database structure used by the server to have direct access of a row in a table.

What are Roles ? Roles are named groups of related privileges that are granted to users or other roles. Assign each role to group of users. APPLICATION AWARENESS .The roles granted to a user can be selectively enable (available for use) or disabled (not available for use).It loads data from standard operating system files (Flat files) into ORACLE database tables. 79. only the privileges of the role need to be modified. What are roles? How can we implement roles ? Roles are the easiest way to grant and manage common privileges needed by different groups of database users. The security domains of all users granted the group's role automatically reflect the changes made to the role. Export (EXP) and Import (imp) utilities allow you to move existing data in ORACLE format to and from ORACLE database. This will simplify the job of assigning privileges to individual users.76. DYNAMIC PRIVILEGE MANAGEMENT . 77. . SQL * Loader . Creating roles and assigning provides to roles. This allows specific control of a user's privileges in any given situation. 80. SELECTIVE AVAILABILITY OF PRIVILEGES . 82.A database application can be designed to automatically enable and disable selective roles when a user attempts to use the application. Privilege Auditing and Object Auditing. 81.When the privileges of a group must change. Start up the database.This allows DBA to monitor and control an ORACLE database. 78. What is Statement Auditing ? Statement auditing is the auditing of the powerful system privileges without regard to specifically named objects.ora file. What are the different Levels of Auditing ? Statement Auditing. How can you enable automatic archiving ? Shut the database Backup the database Modify/Include LOG_ARCHIVE_ START_TRUE in init. What are the database administrators utilities avaliable ? SQL * DBA . What are the use of Roles ? REDUCED GRANTING OF PRIVILEGES .Rather than explicitly granting the same set of privileges to many users a database administrator can grant the privileges for a group of related users granted to a role and then grant only the role to each member of the group.

2.V_$INSTANCE SEC where JUL.VALUE. SYS. 60)).v_$instance. What is Privilege Auditing ? Privilege auditing is the auditing of the use of powerful system privileges without regard to specifically named objects. What is Auditing ? Monitoring of user access to aid in the investigation of database use.VALUE.V_$INSTANCE JUL. 2) || Substr (to_char (floor (mod (SEC.83.KEY like '%JULIAN%' and SEC. 'DD-MON-YYYY HH24: MI: SS') "DB Startup Time" FROM sys.INSTANCE.KEY like '%SECOND%'. V$INSTANCE SEC where JUL.VALUE/3600) . 2. '09').V_$INSTANCE SEC.VALUE.VALUE.VALUE. 84. Select to_date (JUL.|| Substr (to_char (mod (SEC. . SYS. 'J') || to_char (floor (SEC. -Return a DATE 'DD-MON-YY HH24:MI:SS') STARTED from V$INSTANCE JUL. 60). SYS. 60).KEY like '%JULIAN%' and SEC. Marco Bergman provided the following alternative solution: SELECT to_char (logon_time. to_date (JUL. 2) STARTED from SYS. How does one see the uptime for a database? (for DBA Look at the following SQL query: SELECT to_char (startup_time. 85. 'J') + (SEC. select to_char (to_date (JUL.KEY like '%SECOND%'. ' HH24:MI:SS') STARTED from SYS. 2.VALUE/86400) . 'SSSSS').KEY like '%JULIAN%' and SEC. '09').V_$INSTANCE JUL. What is Object Auditing ? Object auditing is the auditing of accesses to specific schema objects without regard to user.' || Substr (to_char (mod (SEC. 85.KEY like '%SECOND%'.V_$THREAD C Where JUL. '09').VALUE/60. '09') || ':' -. 'J') || to_char (to_date (SEC. 2) || '.v_$session WHERE Sid=1 /* this is pmon */ / Users still running on Oracle 7 can try one of the following queries: Column STARTED format a18 head 'STARTUP TIME' Select C.VALUE/60. 'Dy dd Mon HH24: MI: SS') "DB Startup Time" FROM sys.

s. u.V_$SORT_ SEGMENT From Oracle 8. Sum (u. How will you enforce security using stored procedures? Don't grant user access directly to tables within the application.serial#.value / . s. Instead use the V$TEMP_SPACE_ HEADER view: SELECT tablespace_name."USER". all sorts are done in one large temporary segment.serial#. sys. value/1024 sort_size from sys.username.tablespace. u. u.saddr = u. vp. s.v_$parameter VP where s. Instead grant the ability to access the procedures that access the tables. 88.osuser like '&1' group by s.process.addr = u. u.bbbb' where 'ffff' is the file it is in and 'bbbb' is first block of the segment.contents. For usage stats. true temporary tablespace information is not listed in DBA_FREE_SPACE.v_$sort_ usage u. 89.osuser.extents. sys.session_addr and vp.process. Where are my TEMPFILES.session_addr / select s.blocks from sys. s.v_$sort_ usage u where s.v$sort_usage. SUM (bytes used). unlike normal datafiles.v_$session s. Look at these examples: select s. I don't see them in V$DATAFILE or DBA_DATA_FILE? (for DBA Tempfiles. Users cannot access tables except via the procedure.username.osuser. When procedure executed it will execute the privilege of procedures owner.v_$session s. s. SUM (bytes free) FROM V$temp_space_ header GROUP BY tablespace_name. sys.86.name = 'db_block_size' and s. u. What is a profile ? Each database user is assigned a Profile that specifies limitations on various system resources available to the user. Instead query v$tempfile or dba_temp_files: SELECT * FROM v$tempfile.username.V$_LOCK with type 'TS'. s. All temporary segments are named 'ffff.0. 87. are not listed in v$datafile or dba_data_files. SELECT * FROM dba_temp_files. How do I find used/free space in a TEMPORARY tablespace? (for DBA Unlike normal tablespaces. How can one see who is using a temporary segment? (for DBA For every user using temporary space.blocks)*vp. there is an entry in SYS. see SYS. 90. If your temporary tablespace is set to TEMPORARY. one can just query SYS.

91. and trigger name will be TLOGS name).. Example: SELECT * FROM v$fixed_view_ definition WHERE view_name='V$ SESSION'.e. a Prepare Phase and a Commit Phase.Log sequence number and is zero left paded. . (The table name created will be MLOGS_tablename. 95. How does one get the view definition of fixed views/tables? Query v$fixed_view_ definition. 93. 96. 92. It has two phase.Log sequence number not padded. It may fail if remote database is having any problem. %T . LOG_ARCHIVE_ FORMAT = arch %S/s/T/tarc (%S . We cannot specify snapshot log name because oracle uses the name of the master table in the name of the database objects that support its snapshot log. What is user Account in Oracle database? An user account is not a physical structure in Database but it is having important relationship to the objects in the database and will be having certain privileges. How can we specify the Archived log file name format and destination? By setting the following values in init.Thread number lefzero-paded and %t . LOG_ARCHIVE_ DEST = path. What are the dictionary tables used to monitor a database spaces ? DBA_FREE_SPACE DBA_SEGMENTS DBA_DATA_FILES. The master table name should be less than or equal to 23 characters. 97.ora file. it should be not be already available) After giving table privileges. The file name created is arch 0001 are if %S is used. What dynamic data replication? Updating or Inserting records in remote database through database triggers. %s . 94.Thread number not padded). What is Two-Phase Commit ? Two-phase commit is mechanism that guarantees a distributed transaction either commits on all involved nodes or rolls back on all involved nodes to maintain data consistency across the global distributed database. When will the data in the snapshot log be used? We must be able to create a after row trigger on table (i.

It is stored in the same database as master table and is only available for simple snapshots. In ver 7. Describe two phases of Two-phase commit ? Prepare phase . 101.If all participants respond to the coordinator that they are prepared.Phase . We can join tables in snopshots by creating a complex snapshots that will based on the master tables. What is the mechanism provided by ORACLE for table replication ? Snapshots and SNAPSHOT LOGs 102. What is a SNAPSHOT ? Snapshots are read-only copies of a master table located on a remote node which is periodically refreshed to reflect changes made to the master table.0 they are read only. What is snapshot log ? It is a table that maintains a record of modifications to the master table in a snapshot. . What is a SQL * NET? SQL *NET is ORACLE's mechanism for interfacing with the communication protocols used by the networks that facilitate distributed processing and distributed databases. 99. 100. What is snapshots? Snapshot is an object used to dynamically replicate data between distribute database at specified time intervals. What are the various type of snapshots? Simple and Complex. if all participants cannot prepare.The global coordinator (initiating node) ask a participants to prepare (to promise to commit or rollback the transaction. 103. It should be created before creating snapshots. the coordinator asks all nodes to commit the transaction. even if there is a failure) Commit . 105.98. the coordinator asks all nodes to roll back the transaction. How can you Enforce Referential Integrity in snapshots ? Time the references to occur when master tables are not in use. Peform the reference the manually immdiately locking the master tables. 104. It is used in Clint-Server and Server-Server communications.

Otherwise it will perform a complete refresh.106. What is Distributed database ? A distributed database is a network of databases managed by multiple database servers that appears to a user as single logical database.A complex snapshots contain atleast any one of the above. What are the Built-ins used for sending Parameters to forms? .Tables are completely regenerated using the snapshots query and the master tables every time the snapshot referenced. What are the options available to refresh snapshots ? COMPLETE . 109. sub-query or snashot of operations. FAST . snapshots ? . .A simple snapshot is based on a query that does not contains GROUP BY clauses.Replication of data in distributed environment. . 111.Using remote procedure calls. 107. Database uses a two phase commit. FORCE . CONNECT BY clauses.If simple snapshot used then a snapshot log can be used to send the changes to the snapshot tables. Differentiate simple and complex. . 112. ORACLE uses a snapshot log to track the rows that have been updated in the master table. How can we reduce the network traffic? . What are the benefits of distributed options in databases? Database on other servers can be updated and those transactions can be grouped together with others in a logical unit. 110. Snapshot logs are used in updating the snapshots based on the master table. The data of all databases in the distributed database can be simultaneously accessed and modified.Default value. JOINs. 108. What is a SNAPSHOT LOG ? A snapshot log is a table in the master database that is associated with the master table.Using snapshots to replicate data. If possible it performs a FAST refresh.

Does a Before form trigger fire when the parameter form is suppressed? Yes. What is mean by Program Global Area (PGA)? It is area in memory that is used by a single Oracle user process. What are the factors causing the reparsing of SQL statements in SGA? Due to insufficient shared pool size.You can pass parameter values to a form when an application executes the call_form. 115. 116. Can you have more than one content canvas view attached with a window? Yes. 117. New_form. 120. At run time only one of the content canvas views assign to a window is displayed at a time. You can also create a window that has manipulated content canvas view. 113. . 114. Open_form or Run_product. dictionary cache. 118. 119. What is a data segment? Data segment are the physical areas within a database block in which the data associated with tables and clusters are stored. What is a shared pool? The data dictionary cache is stored in an area in SGA called the shared pool. This will allow sharing of parsed SQL statements among concurrent users. The structure is database buffers. It holds the most recently requested structural information about the database. redo log buffer and shared pool area. Is the After report trigger fired if the report execution fails? Yes. Each window you create must have atleast one content canvas view assigned to it. It holds the most recently requested structural information between users. What is SGA? The System Global Area in an Oracle database is the area in memory to facilitate the transfer of information between users.

. Can a property clause itself be based on a property clause? Yes 128. 123. 124. 125. 126. 127.Monitor the ratio of the reloads takes place while executing SQL statements.5 create the parameter. What are the dictionary tables used to monitor a database space? DBA_FREE_SPACE DBA_SEGMENTS DBA_DATA_FILES. exist betw. Instead grant the ability to access the procedures that access the tables. 121. report 2. Users cannot access tables except via the procedure. What are clusters? Clusters are groups of one or more tables physically stores together to share common columns and are often used together.5 when the query is applied? While both reports 2. What is cluster key? The related columns of the tables in a cluster are called the cluster key. How will you enforce security using stored procedures? Don't grant user access directly to tables within the application.0 and 2. When procedure executed it will execute the privilege of procedures owner. 122. Do a view contain data? Views do not contain or store data. What is user Account in Oracle database? A user account is not a physical structure in database but it is having important relationship to the objects in the database and will be having certain privileges. what diff. report 2. If a parameter is used in a query without being previously defined. If the ratio is greater than 1 then increase the SHARED_POOL_ SIZE.0 and 2.5 gives a message that a bind parameter has been created.

and operators can navigate between the forms as desired. Data parameters are used to pass data to produts invoked with the run_product built-in subprogram.129. event_window to determine the name of the window for which the trigger fired. 133. any windows that belong to the calling form are disabled. when one form invokes another form by executing call_form. and operators cannot navigate to them until they first exit the called form. you can examine the built in system variable system. the operator will be prompted to save them before the new form is loaded. What is trigger associated with the timer? When-timer-expired. 135. 130. What is new_form built-in? When one form invokes another form by executing new_form oracle form exits the first form and releases its memory before loading the new form calling new form completely replace the first with the second. What are the different windows events activated at runtimes? When_window_ activated When_window_ closed When_window_ deactivated When_window_ resized Within this triggers. What are the sql clauses supported in the link property sheet? Where start with having. What is difference between open_form and call_form? when one form invokes another form by executing open_form the first form remains displayed. When do you use data parameter type? When the value of a data parameter being passed to a called product is always the name of the record group defined in the current form. 131. That is. the called form is modal with respect to the calling form. 134.pressed fires when an operator clicks or double clicks on an image item 132. What are the trigger associated with image items? When-image-activate d fires when the operators double clicks on an image itemwhen-image. If there are changes pending in the first form. .

What is the use of transactional triggers? Using transactional triggers we can control or modify the default functionality of the oracle forms. pattern proprieties that you set for form and menu objects that appear in your application interface. 140. 138. rides and knobs. the LOV is not displayed. How do you create a new session while open a new form? .5)? View by structure and view by type . 143. 144. reports automatically resizes the parent when the child is resized. when Flex mode is mode on and when it is off? When flex mode is on. What is the diff. The controls can use to obtain user inputs and display program outputs. If the value in the text item does not match one of the values in the first column of the LOV. Which of the two views should objects according to possession? view by structure.vbx control where originally develop as extensions for the ms visual basic environments and include such items as sliders. color. What are the vbx controls? Vbx control provide a simple method of building and enhancing user interfaces. 142. 141. What is the "LOV of Validation" Property of an item? What is the use of it? When LOV for Validation is set to True. Oracle Forms displays the LOV and uses the text item value as the search criteria to automatically reduce the lis 137. What are the two types of views available in the object navigator(specific to report 2. If the value in the text item matches one of the values in the first column of the LOV. What is the diff.136. and processing continues normally. Whenever the validation event occurs. 139. when confine mode is on and when it is off? When confine mode is on. validation succeeds. an object cannot be moved outside its parent in the layout. Oracle Forms compares the current value of the text item to the values in the first column displayed in the LOV. What are visual attributes? Visual attributes are the font.

state whether the following are true/False 145.Using open_form built-in setting the session option Ex.'Paramete r my_param') 152. What is a timer? Timer is an "internal time clock" that you can programmatically create to perform an action each time the times. How do you reference a parameter indirectly? To indirectly reference a parameter use the NAME IN. COPY 'built-ins to indirectly set and reference the parameters value' Example name_in ('capital parameter my param'). Open_form('Stocks '. 150.active. Vertical tool bar canvas views? Tool bar canvas views are used to create tool bars for individual windows. What are the ways to monitor the performance of the report? Use reports profile executable statement. What is the purpose of the product order option in the column property sheet? To specify the order of individual group evaluation in a cross products. 151. .session) . Copy ('SURESH'. when invoke the mulitiple forms with open form and call_form in the same application. Use SQL trace facility. Explain about horizontal. 146. If two groups are not linked in the data model editor. What is the hierarchy between them? Two group that is above are the left most rank higher than the group that is to right or below it. just under its menu bar. 147. An open form can not be execute the call_form procedure if you chain of called forms has been initiated by another open form? True 148. Horizontal tool bars are display at the top of a window. What is the use of image_zoom built-in? To manipulate images in image items. Vertical Tool bars are displayed along the left side of a window 149.

What are Most Common types of Complex master-detail relationships? There are three most common types of complex master-detail relationships: master with dependent details master with independent details detail with two masters 155. all control files and all log files. the clear phase. select name from sys. Sometimes Oracle takes forever to shutdown with the "immediate" option. During the population phase. allowing the operator to view and select undisplayed values. Oracle Forms navigates internally to the detail block and flushes the obsolete detail records. What is a text list? The text list style list item appears as a rectangular box which displays the fixed number of values. How does one do off-line database backups? (for DBA Shut down the database from sqlplus or server manager. What are the two phases of block coordination? There are two phases of block coordination: the clear phase and the population phase. As workaround to this problem. a vertical scroll bar appears. Oracle Forms issues a SELECT statement to repopulate the detail block with detail records associated with the new master record. What is term? The term is terminal definition file that describes the terminal form which you are using r20run 167. switch your database into ARCHIVELOG mode and perform hot (on-line) backups. tapes). If you cannot take your database down for a cold (off-line) backup at a convenient time.v_$datafile. shutdown using these commands: alter system checkpoint.153. . Do the following queries to get a list of all files that needs to be backed up: select name from sys. 156.v_$controlfile. When completed. select member from sys. These operations are accomplished through the execution of triggers. Backup all files to secondary storage (eg. When the text list contains values that can not be displayed.v_$logfile. During. Ensure that you backup all data files. 154. restart your database. one can still use archived log files to roll forward from an off-line backup. shutdown abort startup restrict shutdown immediate Note that if you database is in ARCHIVELOG mode.

} Example RMAN restore: rman target sys/*** nocatalog run { allocate channel t1 type disk.Force log switch to update control file headers ALTER DATABASE BACKUP CONTROLFILE TO '/backupDir/ control. Look at this simple example. 172. Look at this example: ALTER SYSTEM SWITCH LOGFILE. release channel t1. release channel t1. recover tablespace users. NOTE: Do not run on-line backups during peak processing periods. Normally one would rather setup a RMAN catalog database to store RMAN metadata in. By default Oracle uses the database controlfiles to store information about backups. 171. Oracle will write complete database blocks instead of the normal deltas to redo log files while in backup mode. restore tablespace users. It is better to backup tablespace for tablespace than to put all tablespaces in backup mode. Read the Oracle Backup and Recovery Guide before implementing any RMAN backups. How does one backup a database using RMAN? (for DBA The biggest advantage of RMAN is that it only backup used space in the database. rman target sys/*** nocatalog run { allocate channel t1 type disk. } The examples above are extremely simplistic and only useful for illustrating basic concepts. Rman doesn't put tablespaces in backup mode. What is strip sources generate options? . Note: RMAN cannot write image copies directly to tape. saving on redo generation overhead. backup format '/app/oracle/ db_backup/ %d_t%t_s% s_p%p' ( database ). When done. How does one do on-line database backups? (for DBA Each tablespace that needs to be backed-up must be switched into backup mode before copying the files out to secondary storage (tapes). Look at this simple backup example. ALTER TABLESPACE xyz BEGIN BACKUP. RMAN will re-read database blocks until it gets a consistent image of it. One needs to use a third-party media manager that integrates with RMAN to backup directly to tape. -. remember to backup your control files. ! cp xyfFile1 /backupDir/ ALTER TABLESPACE xyz END BACKUP. # set until time 'Aug 07 2000 :51'.dbf' . This will lead to excessive database archiving and even database freezes. 173.170. Backing them up separately incurs less overhead. What are the different file extensions that are created by oracle reports? Rep file and Rdf file. Alternatively one can backup to disk and then manually copy the backups to tape.

This statement is often used to switch archiving between a set of directories. and bounce the database: SQLPLUS> connect sys as sysdba SQLPLUS> startup mount exclusive. NOTE1: Remember to take a baseline database backup right after enabling archivelog mode.. 174. and is essential for database point-in-time recovery. your database will hang! Look at this simple RMAN backup script: RMAN> run { 2> allocate channel dev1 type disk. statement. pll userid=scott/ tiger strip_source YES output_file 173. The resulting file can be used for final deployment. and log_archive_ format=. f45gen module=old_lib. Without it one would not be able to recover.ex. Does Oracle write to data files in begin/hot backup mode? (for DBA . Also. you need to shut down all nodes before changing the database to ARCHIVELOG mode. 3> backup 4> format '/app/oracle/ arch_backup/ log_t%t_s% s_p%p' 5> (archivelog all delete input).. It is also necessary to enable ARCHIVELOG mode before one can start to use on-line database backups. simply change your database startup command script. If the archive log directory becomes full. SQLPLUS> alter database open. Archiving can be used in combination with on-line and off-line database backups. NOTE4: You can change the archive log destination of a database on-line with the ARCHIVE LOG START TO 'directory'. but can not be subsequently edited in the designer. 6> release channel dev1. To enable ARCHIVELOG mode. 175. SQLPLUS> archive log start. What is the basic data structure that is required for creating an LOV? Record Group. NOTE3: You may want to set the following INIT. SQLPLUS> alter database archivelog. How does one backup archived log files? (for DBA One can backup archived log files using RMAN or any operating system backup utility. log_archive_ dest=.ORA parameters when enabling ARCHIVELOG mode: log_archive_ start=TRUE. NOTE5: When running Oracle Real Application Server (RAC). 7> } 176. implement an archivelog backup to prevent the archive log directory from filling-up. Remember to delete files after backing them up to prevent the archive log directory from filling up. NOTE2: ARCHIVELOG mode was introduced with Oracle V6. How does one put a database into ARCHIVELOG mode? (for DBA The main reason for running in archivelog mode is that one can provide 24-hour availability and guarantee complete data recoverability.. .Removes the source code from the library file and generates a library files that contains only pcode.

you cannot be sure who they really are. but will continue to write data to the database files even if a tablespace is in backup mode. How does one add users to a password file? (for DBA One can select from the SYS. GRANT SYSDBA TO scott. New users can be added to the password file by granting them SYSDBA or SYSOPER privileges. you cannot. If REMOTE_OS_AUTHENT is set to FALSE (recommended) . How does one connect to an administrative user? (for DBA If an administrative user belongs to the "dba" group on Unix. Control of these privileges is managed outside of the database via password files and special operating system groups. he/she can connect like this: connect / as sysdba No password is required. 191.Oracle will stop updating file headers. Oracle will write out complete changed blocks to the redo log files. Why are OPS$ accounts a security risk in a client/server environment? (for DBA If you allow people to log in with OPS$ accounts from Windows Workstations. remote users will be unable to connect without a password. Because of this. What is an administrative (privileged) user? (for DBA Oracle DBAs and operators typically use administrative accounts to manage the database and database instance. This is equivalent to the desupported "connect internal" method. if you are using "OPS$" as your prefix. Remote connections via Net8 are classified as non-secure. 197. Startup the database (SQLPLUS> STARTUP) NOTE: The orapwd utility presents a security risk in that it receives a password from the command line. An administrative account is a user that is granted SYSOPER or SYSDBA privileges. 188.V_$PWFILE_ USERS view to see which users are listed in the password file. Administrators needs to be aware of this! 195. This password is visible in the process table of many systems. Shutdown the database (SQLPLUS> SHUTDOWN IMMEDIATE) . Normally only deltas (changes) are logged to the redo logs. Log in as the Oracle software owner . Edit the INIT. In backup mode. With terminals. one should notice increased log activity and archiving during online backups. . If you set REMOTE_OS_AUTHENT= TRUE in your init. Oracle assumes that the remote OS has authenticated the user. Look at this example: connect sys/password as sysdba 192. This is done to enable reconstruction of a block if only half of it was backed up (split blocks). A password is required for "non-secure" administrative access. This password file is created with the orapwd utility. you can rely on operating system passwords. you will be able to log on locally with or without a . or by using the orapwd utility. or the "ORA_DBA" (ORA_sid_DBA) group on NT. How does one create a password file? (for DBA The Oracle Password File ($ORACLE_HOME/ dbs/orapw or orapwSID) stores passwords for users with administrative privileges.ora file. SYSDBA and SYSOPER allow access to a database instance even if it is not running. One needs to create a password files before remote administrators (like OEM) will be allowed to connect. Runcommand: orapwd file=$ORACLE_ HOME/dbs/ orapw$ORACLE_ SID password=mypasswd .ORA file and ensure REMOTE_LOGIN_ PASSWORDFILE= exclusive is set. Also. IDENTIFIED EXTERNALLY will only be in effect from the local host. Follow this procedure to create a new password file: . with Windows. These passwords are stored in password files.

Where should the tuning effort be directed? (for DBA Consider the following areas for tuning. Are the listeners up and responding to requests . Is the database up and responding to requests . The Oracle RDBMS is highly tunable and allows the database to be monitored and adjusted to increase its performance.formerly ADSM Legato Networker ManageIT Backup and Recovery Sterling Software's SAMS: Alexandria . For example. regardless of whether you have identified your ID with a password or defined it to be IDENTIFIED EXTERNALLY.password. etc. one needs to remember than you cannot tune a Buick into a Ferrari. User and process limits reached Things that can cause bad performance: See question "What tuning indicators can one use?". Objects getting close to their max extents . it is no good increasing the buffer cache if you can reduce I/O by rewriting a SQL statement. Are the Web Listeners up and responding to requests Things that can cause service outages: .formerly from Spectralogic Sun Solstice Backup 237. If an alarm is triggered. Are the Oracle Names and LDAP Servers up and responding to requests . Veritas NetBackup EMC Data Manager (EDM) HP OMNIBack II IBM's Tivoli Storage Manager . page. or buying a third-party monitoring product can achieve this. Although this FAQ is not overly concerned with hardware issues. and Optimize hardware usage to save money (companies are spending millions on hardware). The order in which steps are listed needs to be maintained to prevent tuning side effects.) to take appropriate action. 241. Writing custom scripts. What database aspects should be monitored? (for DBA One should implement a monitoring system to constantly monitor the following aspects of a database. Is the archive log destination filling up? . 236. 242. the system should automatically notify the DBA (e-mail. Infrastructure availability: . One should do performance tuning for the following reasons: The speed of computing might be wasting valuable human time (users waiting for response). What third party tools can be used with Oracle EBU/ RMAN? (for DBA The following Media Management Software Vendors have integrated their media management software packages with Oracle Recovery Manager and Oracle7 Enterprise Backup Utility. implementing Oracle's Enterprise Manager. Database Design (if it's not too late): . The Media Management Vendors will provide first line technical support for the integrated backup/recover solutions. Enable your system to keep-up with the speed business is conducted. Why and when should one tune? (for DBA One of the biggest responsibilities of a DBA is to ensure that the Oracle database is tuned properly.

buffer cache. 256.gz & # feed the pipe exp userid=scott/ tiger file=exp.log Use the following technique if you use an Oracle version prior to 8i: Create a compressed export on the fly. aggregation tables for decision support systems. compress or whatever. This example uses gzip. Application Tuning: Experience showed that approximately 80% of all Oracle system performance problems are resolved by coding optimal SQL. missing indexes. For example.sql on an Oracle 8 database to allow the Oracle 7. This feature enables large exports to be divided into files whose sizes will not exceed any operating system limits (FILESIZE= parameter). If the sequences are not dropped. one needs to truncate or drop these tables to get rid of the old data.exp. Also look at proper data partitioning. Does one need to drop/ truncate objects before importing? (for DBA Before one import rows into already populated tables. but you can also substitute it with zip.pipe > scott. and import it using a later version of the import utility. data fragmentation.pipe p # read the pipe . It offers the best compression I know of. Can one import/export between different versions of Oracle? (for DBA Different versions of the import utility is upwards compatible. log buffer. they will generate numbers inconsistent with the rest of the database. I/O and memory utilization.Poor system performance usually results from a poor database design.3 exp/imp utilities to run against an Oracle 8 database. How can one improve Import/ Export performance? (for DBA . When designing. Can one export to multiple files?/ Can one beat the Unix 2 Gig limit? (for DBA From Oracle8i. latches and wait events carefully and eliminate where possible. Disk I/O Tuning: Database files needs to be properly sized and placed to provide maximum disk subsystem throughput. etc Eliminate Database Contention: Study database locks. Depending on the type of data.. Pin large objects into memory to prevent frequent reloads. full table scans. If not.sql scripts that can be executed as user SYS enabling older imp/exp versions to work (for backwards compatibility) . Also look for frequent disk sorts. always keep the "data access path" in mind. Also consider proper scheduling of batch tasks after peak working hours. read the related Oracle FAQ dealing with your specific operating system. 262. One should generally normalize to the 3NF. Indexes can easily be recreated after the data was successfully imported. This means that one can take an export file created from an old export version. Memory Tuning: Properly size your database buffers (shared pool. Note: It is also advisable to drop indexes before importing to speed up the import process.pipe . 258.dmp.output to zip file in the background gzip < exp.dmp FILESIZE=10m LOG=scott. # create a named pipe mknod exp. the export utility supports multiple output files. you probably can export up to 10 gigabytes to a single file. row chaining. etc) by looking at your buffer hit ratios. etc. This is quite an effective way of upgrading a database from one release of Oracle to the next. One must always DROP existing Sequences before re-importing. the new data will be appended to the existing tables. Tune the Operating System: Monitor and tune operating system CPU. data replication. Oracle also ships some previous catexpX. Selective denormalization can provide valuable performance improvements. E:\F2. For more information. Look at this example: exp SCOTT/TIGER FILE=D:\F1. When importing from multi-file export you must provide the same filenames in the same sequence in the FILE= parameter. 260.. one can run $ORACLE_HOME/ rdbms/admin/ catexp7.

IMPORT: . It will take forever.). This normally saves a significant amount of database down time. You must edit this file afterwards and supply the passwords for the schemas on all CONNECT statements. the following command can be used to take all of the datafiles out of hot backup mode: ALTER DATABASE END BACKUP.ora file .EXPORT: .Use the IGNORE=Y import parameter to ignore these errors.) violated . No data will be imported but a file containing index definitions will be created. Create an indexfile so that you can create indexes AFTER you have imported data. Oracle Consulting can sometimes extract data from an offline database using a utility called DUL (Disk UnLoad). One can select from V$BACKUP to see which datafiles are in backup mode.You are importing duplicate rows. Stop unnecessary applications to free-up resources for your job. Remember to run the indexfile previously created 264.g. Thiru Vadivelu contributed the following: From Oracle9i onwards. from Oracle7. What now? (for DBA Recovery without any backup is normally not supported. object already exists. The above commands need to be issued when the database is mounted. but be careful as you might end up with duplicate rows. However. The DBA is then required to recover the database and apply all archived logs to the database. ORA-01555: Snapshot too old . 64K) . Set all other rollback segments offline (except the SYSTEM rollback segment of course). 276. Use COMMIT=N in the import parameter file if you can afford it . 279. you can simply take the individual datafiles out of backup mode and restart the database. Set the LOG_BUFFER to a big value and restart oracle. Increase DB_CACHE_SIZE (DB_BLOCK_BUFFERS prior to 9i) considerably in the init$SID. . Set the RECORDLENGTH parameter to a high value (e. Place the file to be imported on a separate physical disk from the oracle data files . ALTER DATABASE DATAFILE '/path/filename' END BACKUP. What are the common Import/ Export problems? (for DBA ORA-00001: Unique constraint (.g. Do this by setting INDEXFILE to a filename and then import. If you run multiple export sessions. ensure they write to different physical disks. however. Set the BUFFER parameter to a high value (e. My database was terminated while in BACKUP MODE.. Create a BIG tablespace with a BIG rollback segment inside.. Stop redo log archiving if it is running (ALTER DATABASE NOARCHIVELOG. do I need to recover? (for DBA If a database was terminated while one of its tablespaces was in BACKUP MODE (ALTER TABLESPACE xyz BEGIN BACKUP. Use IGNORE=NO to skip tables that already exist (imp will give an error if the object is re-created). 2M) .. ) .. . This utility reads data in . it will tell you that media recovery is required when you try to restart the database.2.. The rollback segment must be as big as your biggest table (I think?) .Create bigger rollback segments or set parameter COMMIT=Y while importing IMP-00015: Statement failed .Ask your users to STOP working while you are exporting or use parameter CONSISTENT=NO ORA-01562: Failed to extend rollback segment . DO NOT export to an NFS mounted filesystem. . Use ANALYZE=N in the import parameter file to avoid time consuming ANALYZE statements . . .. My database is down and I cannot restore.

how can I get my DB back? (for DBA The following INIT. It is sometimes referred to as OEBU for Oracle Enterprise Backup Utility. DUL does not care about rollback segments. I've lost my REDOLOG files. semmns and semmsl. Latches are never queued. Please contact Oracle Support before using it. Typical settings are: semmns = sum of the "processes" parameter for each instance . or time out. rbs01. _Corrupted_rollback _segments = (rbs01. RMAN> exit. However. Caution is advised when enabling this parameter as you might end-up losing your entire database.ORA parameter if one of your rollback segments is corrupted. enqueues and semaphores? (for DBA A latch is an internal Oracle mechanism used to protect data structures in the SGA from simultaneous access.sql script. Next. there is no direct upgrade path from EBU to RMAN. etc. Enqueues and locks are different names for the same thing. Caution is advised when enabling this parameter. Both support queuing and concurrency. You can then drop the corrupted rollback segments and create it from scratch.out (FIFO) order. Atomic hardware instructions like TEST-AND-SET is used to implement latches. I've lost some Rollback Segments. Latches are more restrictive than locks in that they are always exclusive. They are queued and serviced in a first-in-first. Semaphores are controlled by the following Unix parameters: semmni. _allow_resetlogs_ corruption = true 283. latches. Look at this example: rman catalog rman/rman target backdba/backdba RMAN> register database. The Oracle Recovery Manager (RMAN) utility that ships with Oracle8 and above is similar to Oracle7's EBU utility. rman catalog rman/rman RMAN>create catalog tablespace tools. how can I get my DB back? (for DBA Re-start your database with the following INIT. Prior to Oracle 8i this was done by running the catrman. and can thus not guarantee that the data is not logically corrupt. rbs03. SQL> grant connect. SQL> exit. Assign an appropriate tablespace to it and grant it the recovery_catalog_ owner role. corrupted blocks. 314. You can now continue by registering your databases in the catalog. recovery_catalog_ owner to rman. resource. How does one create a RMAN recovery catalog? (for DBA Start by creating a database schema (usually called rman). One can very well end up with lost or inconsistent data!!! Please contact Oracle Support before using it. What is the difference between locks. Look at this example: sqlplus sys SQL>create user rman identified by rman. It is intended as an absolute last resort and will most likely cost your company a lot of money!!! 280. but will spin or sleep until they obtain a resource. 285. Semaphores are an operating system facility used to control waiting. high performance interface for backing up Oracle7 databases. rbs04) 284. log in to rman and create the catalog schema.the data files and unloads it into SQL*Loader or export dump files. as uncommitted transactions will be marked as committed. What are the differences between EBU and RMAN? (for DBA Enterprise Backup Utility (EBU) is a functionally rich.ORA parameter may be required if your current redo logs are corrupted or blown away. SQL> alter user rman quota unlimited on tools. SQL> alter user rman default tablespace tools temporary tablespace temp.

x$ksppcv b.ora for each instance) semmni = number of instances running simultaneously.indx and a.ORA parameters with an underscore in front are hidden or unsupported parameters. E..indx = c. or.g. The alter session method only affects the user's current session.indx and substr(ksppinm. Where can one get a list of all hidden Oracle parameters? (for DBA Oracle initialization or INIT. level 4 Trace SQL statements and show bind variables in trace output. alter session set events '10046 trace name context forever. A single rollback segment can have multiple rollback segment entries. b.(see init<instance>. Export utility is used for taking backup and Import utility is used to recover from backup. What is a database EVENT and how does one set it? (for DBA Oracle trace events are useful for debugging the Oracle database server. by issuing an ALTER SESSION SET EVENTS command: E.ksppinm.indx = b. 318. c. What is a logical backup? Logical backup involves reading a set of database records and writing them into a file.ORA parameter file can activate events.ksppstvl "Session Value". The following query displays parameter names with their current value: select a. 316.ORA file will affect all sessions once the database has been restarted. The following two examples are simply to demonstrate syntax. level 4'.1)='_' order by a. 1.1) = '_'. Remember: Thou shall not play with undocumented parameters! 317. level 12' . event='1401 trace name errorstack. x$ksppsv c where a.ksppstvl "Instance Value" from x$ksppi a. ..g. Either adding them to the INIT. 1. What database events can be set? (for DBA The following events are frequently used by DBAs and Oracle Support to diagnose problems: " 10046 trace name context forever.X$KSPPI where substr(KSPPINM.ksppinm "Parameter". What is a Rollback segment entry ? It is the set of before image data blocks that contain rows that are modified by a transaction. Each Rollback Segment entry must be completed within one rollback segment. semmsl = semmns 315. 319. Refer to later notes on this page for an explanation of what these particular events do. One can get a list of all hidden parameters by executing this query: select * from SYS. whereas changes to the INIT.

12). level 1' / o Dump a database block (File/ Block must be converted to DBA address) Convert file and block number to a DBA (database block address). level 2 Data block check " 10211 trace name context forever. The following lists of events are examples only. so please call Oracle before using them: " 10210 trace name context forever. " 60 trace name errorstack level 10 Show where in the code Oracle gets a deadlock (ORA-60). with 10-minute intervals alter session set events 'immediate trace name SYSTEMSTATE level 10' / o Dump the process state alter session set events 'immediate trace name PROCESSSTATE level 10' / o Dump Library Cache details alter session set events 'immediate trace name library cache level 10' / o Dump optimizer statistics whenever a SQL statement is parsed (hint: change statement or flush pool) alter session set events '10053 trace name context forever. level 12 This shows both bind variable names and wait events in the SQL trace files " 1401 trace name errorstack. level 1 Memory heap check " 10262 trace name context forever. level 12 1401 trace name errorstack. o Dump control file contents alter session set events 'immediate trace name CONTROLF level 10' / o Dump file headers alter session set events 'immediate trace name FILE_HDRS level 10' / o Dump redo log headers alter session set events 'immediate trace name REDOHDR level 10' / o Dump the system state NOTE: Take 3 successive SYSTEMSTATE dumps. How can one dump internal database structures? (for DBA The following (mostly undocumented) commands can be used to obtain information about internal database structures. On Unix. exec :x := dbms_utility." 10046 trace name context forever. level 4 1401 trace name processstate Dumps out trace information if an ORA-1401 "inserted value too large for column" error occurs. level 2 Memory protect cursor " 10210 trace name context forever. They might be version specific. level 2 Index block check " 10235 trace name context forever. level 10 These events prevent database block corruptions " 10049 trace name context forever. make_data_ block_address( 1. level 300 Allow 300 bytes memory leak for connections Note: You can use the Unix oerr command to get the description of an event. 320. level 10 10211 trace name context forever. Eg: variable x varchar2. and may help to diagnose the problem. print x alter session set events 'immediate trace name blockdump level 50360894' / . level 8 This shows wait events in the SQL trace files " 10046 trace name context forever. you can type "oerr ora 10053" from the command prompt to get event details. The 1401 can be replaced by any other Oracle Server error code that you want to trace. level 10 10231 trace name context forever.

How does Space allocation table place within a block ? Each block contains entries as follows Fixed block header Variable block header Row Header. .Only affected tables from last incremental date/full backup date. What is a Control file ? Database overall physical architecture is maintained in a file called control file. 329. Make new rollback segment available (After shutdown. What is dictionary cache ? Dictionary cache is information about the databse objects stored in a data dictionary table. 331. Cumulative backup . If the ratio is greater than 1 then increase the SHARED_POOL_ SIZE. Create a Second Rollback Segment name R0 in the SYSTEM tablespace. What are the factors causing the reparsing of SQL statements in SGA? Due to insufficient Shared SQL pool size. What are the different kind of export backups? Full back . It will be used to maintain internal consistency and guide recovery operations.All Data files. Monitor the ratio of the reloads takes place while executing SQL statements.row date (multiple rows may exists) PCTEREE (% of free space for row updation in future) 328. Deactivate Rollback Segment R0 and activate the newly created rollback segments.321.ora file and Start database) Create other tablespaces (RBS) for rollback segments. How will you create multiple rollback segments in a database ? Create a database which implicitly creates a SYSTEM Rollback Segment in a SYSTEM tablespace. What is cold backup? What are the elements of it? Cold backup is taking backup of all physical files after normal shutdown of database.ORA decides the size.Complete database Incremental . What is Database Buffers ? Database buffers are cache in the SGA used to hold the data blocks that are read from the data segments in the database such as tables. .Only affected table from the last cumulative date/full backup date. 327. modify init. 330. indexes and clusters DB_BLOCK_BUFFERS parameter in INIT. LOGICAL & PHYSICAL ARCHITECTURE OF DATABASE. Multiple copies of control files are advisable. 332. 333. We need to take.

the CBO can change the execution plan when you: . . 337. . Generally. What is an SQL *FORMS ? SQL *forms is 4GL tool for developing and executing. What is meant by redo log buffer ? Changes made to entries are written to the on-line redo log files.Cold Backups . How will you estimate the space required by a non-clustered tables? Calculate the total header size Calculate the available dataspace per data block Calculate the combined column lengths of the average row Calculate the total average row size. 381.Hot Backups (Archive log) 358. After arriving the calculation. Calculate the average number rows that can fit in a block Calculate the number of blocks and bytes required for the table. they will first brought to redo log buffers in SGA and LGWR will write into files frequently. What is meant by free extent ? A free extent is a collection of continuous free blocks in tablespace. add 10 % additional space to calculate the initial extent size for a working table.ora file (Optional) 334.The init. it won't help much to just have the larger tables analyzed. So that they can be used in roll forward operations during database recoveries. Oracle has to revert to rule-based optimization for that statement. 336.. Oracle based interactive application.All on-line redo log files. 335.Logical Backups . When is cost based optimization triggered? (for DBA It's important to have statistics on all tables for the CBO (Cost Based Optimizer) to work correctly. What are the different methods of backing up oracle database ? . When a segment is dropped its extents are reallocated and are marked as free. If one table involved in a statement does not have statistics. How will you monitor the space allocation ? By querying DBA_SEGMENT table/view. So you really want for all tables to have statistics right away. LOG_BUFFER parameter will decide the size.All Control files. Before writing them into the redo log files. 349.

If the index is physically smaller than the table (which is usually the case) it will take less time to scan the entire index than to scan the entire table. Change some initialization parameters (for example: hash_join_enabled.1.This defines how ordered the rows are in the index. USER_INDEXES. . Have the tables been re-analyzed? Were the tables analyzed using estimate or compute? If estimate. db_file_multiblock_ read_count) . Where can one find I/O statistics per table? (for DBA The UTLESTAT report shows I/O per tablespace but one cannot see what tables in the tablespace has the most I/O. .ORA? . 382. Has OPTIMIZER_MODE been changed in INIT. Usually the previous plan is not available. look at the header comments in the $ORACLE_HOME/ rdbms/admin/ catio. USER_TAB_COLUMNS. Fundamental things that can be checked are: . Which tables are currently analyzed? Were they previously analyzed? (ie. NUM_ROWS . After executing the procedure. If CLUSTERING_FACTOR approaches the number of blocks in the table. sort_area_size. the rows are ordered. Change statistics of objects by doing an ANALYZE. For more details. This can be done by specifying hints. My query was fine last week and now it is slow. what percentage was used? . 2.ORA parameter SORT_AREA_SIZE been changed? . the cost of using an index increase thereby is making the index less desirable. one can do a simple SELECT * FROM io_per_object. 384.ORA parameters been changed? . Why? (for DBA The likely cause of this is because the execution plan has changed. The $ORACLE_HOME/ rdbms/admin/ catio. USER_TABLES. 386.If NUM_DISTINCT = NUM_ROWS then using an index would be preferable to doing a FULL TABLE SCAN. The usual cause is because the CBO calculates that executing a Full Table Scan would be faster than accessing the table via the index. CLUSTERING_ FACTOR . Why is Oracle not using the damn index? (for DBA This problem normally only arises when the query plan is being generated by the Cost Based Optimizer. Some factors that can cause a plan to change are: . Generate a current explain plan of the offending query and compare it to a previous one that was taken when the query was performing well.This column defines the number of distinct values the column holds. What do you think the plan should be? Run the query with hints to see if this produces the required performance.ORA parameter DB_FILE_MULTIBLOCK_ READ_COUNT been changed? . Has the INIT. As the NUM_DISTINCT decreases. Have the statistics changed? . How can one optimize %XYZ% queries? (for DBA It is possible to improve %XYZ% queries by forcing the optimizer to scan all the entries from the index instead of the table. Was the query using RBO and now CBO?) . Have any other INIT. NUM_DISTINCT . to extract the required information. Has the DEGREE of parallelism been defined/changed on any table? .sql script creates a sample_io procedure and table to gather the required information. If it . 385. Has the INIT.sql script.

* Oracle Sales Analysis: Allows for better forecasting. reduce outstanding receivables. but sometimes the above can help to show why an index is not being used by the CBO. Remember that you MUST supply the leading column of an index. . * Oracle Order Entry: Provides organizations with a sophisticated order entry system for managing customer commitments. and financial reporting needs. When should one rebuild an index? (for DBA You can run the 'ANALYZE INDEX VALIDATE STRUCTURE' command on the affected indexes . There are many other factors that affect the cost. . . and reporting of sales information. so copy the contents of the view into a local table after each ANALYZE.each invocation of this command creates a single row in the INDEX_STATS view. try specifying an index hint. * Oracle Receivables: . * Oracle Payables: Lets an organization process more invoices with fewer staff members and tighter controls. This row is overwritten by the next ANALYZE INDEX command.ORA parameter DB_FILE_MULTIBLOCK_ READ_COUNT . bank float. allocations. budgeting. * Oracle Personnel: Improves the management of employee. or with AUTOTRACE to see the statistics. 438.A higher value will make the cost of a FULL TABLE SCAN cheaper. and prevention of duplicate payment. Decrease the INIT. helps negotiate bigger discounts.approaches the number of rows in the table. . Obtain an explain plan of the query either using TKPROF with TIMED_STATISTICS. and improve collection effectiveness. increases financial controls. Oracle Financials can meet accounting management demands with: * Oracle Assets: Ensures that an organization' s property and equipment investment is accurate and that the correct asset tax accounting strategies are chosen. Helps save money through maximum discounts. for the index to be used (unless you use a FAST FULL SCAN or SKIP SCANNING). and increases productivity. consolidation. * Oracle General Ledger: Offers a complete solution to journal entry. * Oracle Purchasing: Improves buying power. without off-line research. Regardless of the size of the business. Helps correctly account for cash. so that one can see the CPU utilization. In such a case. 397. The 'badness' of the index can then be judged by the ratio of 'DEL_LF_ROWS' to 'LF_ROWS' 389. eliminates paper flow. If from checking the above you still feel that the query should be using an index. * Oracle Inventory: Helps an organization make better inventory decisions by minimizing stock and maximizing cash flow. Compare this to the explain plan when not using an index. Improves cash flow by letting an organization process more payments faster. What is Oracle Financials? (for DBA Oracle Financials products provide organizations with solutions to a wide range of long. it is unlikely that index entries in the same leaf block will point to rows in the same data blocks. What is an Lov? A list of values is a single or multi column selection list displayed in a pop-up window 444.and short-term accounting system issues. the rows are randomly ordered. planning. What is an Alert ? An alert is window that appears in the middle of the screen overlaying a portion of the current display. * Oracle Revenue Accounting Gives an organization timely and accurate revenue and flexible commissions reporting.related issues by retaining and making available every form of personnel data.

fga_log$ . 475.. Each segment has an assigned name and a set of valid values. or alternatively. Look at this example: o Add policy on table with autiting condition. this feature works with CBO (Cost Based Optimizer) analyze table EMP compute statistics. All other modules provide information to it. select * from EMP where c1 = 11.. What is Oracle Label Security? (for DBA . delete from sys. what kind of information should be entered in the field. Using this option. What is a Virtual Private Database? (for DBA Oracle 8i introduced the notion of a Virtual Private Database (VPD). 449. 'deptno > 10'). or delete information.Will trigger auditing select * from EMP where c1 = 09.. What is the difference between Fields and FlexFields? (for DBA A field is a position on a form that one uses to enter. If you implement Oracle Financials. without them knowing about it. 'EMP'. 472.add_ policy('HR' . Select from SYS. -. 448. A list of defined policies can be obtained from DBA_AUDIT_POLICIES. 473. one could even store multiple companies' data within the same schema. A field prompt describes each field by telling what kind of information appears in the field. What is the MultiOrg and what is it used for? (for DBA MultiOrg or Multiple Organizations Architecture allows multiple operating units and their relationships to be defined within a single installation of Oracle Applications. Oracle Applications uses flexfields to capture information about your organization. What is the most important module in Oracle Financials? (for DBA The General Ledger (GL) module is the basis for all other Oracle Financial modules. You should go live with it first to give your implementation team a chance to be familiar with Oracle Financials. select sqltext from sys. This ensures that users only have access to data that pertains to them.446. There are two types of flexfields: key flexfields and descriptive flexfields 470. 'policy1'.. view.GL is relatively easy to implement. A flexfield is an Oracle Applications field made up of segments. -. Use the following query to determine if MuliOrg is intalled: select multi_org_flag from fnd_product_ groups. A VPD offers Fine-Grained Access Control (FGAC) for secure separation of data. Audit records are stored in DBA_FGA_AUDIT_ TRAIL. What is Fine Grained Auditing? (for DBA Fine Grained Auditing (DBMS_FGA) allows auditing records to be generated when certain rows are selected from a table. you should switch your current GL system first.V$VPD_POLICY to see existing VPD configuration. This keeps each operating unit's transaction data separate and secure. o Must ANALYZE. VPD configuration is done via the DBMS_RLS (Row Level Security) package.No auditing o Now we can see the statments that triggered the auditing condition.fga_log$ . What is Fine Grained Access Control? (for DBA See question "What is a Virtual Private Database". execute dbms_fga. update.

The console can be opened from a Windows workstation. What are the advantages of having a Package ? Increased functionality (for example. and monitor the database. and loaded into memory once) 506.global package variables can be declared and used by any proecdure in the package) and performance (for example all objects of the package are parsed compiled. 478. and customize complex security authorizations. 479. Console: This is a graphical interface from where one can schedule jobs. . Oracle Label Security is configured. Intelligent Agent (OIA): The OIA runs on the target database and takes care of the execution of jobs and events scheduled through the Console. enforce complex Integrity constraints. 477. controlled and managed from the Policy Manager. an Enterprise Manager-based GUI utility. Question What is PL/SQL ? PL/SQL is a procedural language that has both interactive SQL and procedural programming language constructs such as iteration. Management Server (OMS): Middle tier server that handles communication with the intelligent agents. . What are the components of OEM? (for DBA Oracle Enterprise Manager (OEM) has the following components: . What are the uses of Database Trigger ? Database triggers can be used to automatic data generation. audit data modifications. events. Unix XTerm (oemapp command) or Web browser session (oem_webstage) . What is OEM (Oracle Enterprise Manager)? (for DBA OEM is a set of systems management tools provided by Oracle Corporation for managing the Oracle environment.Oracle Label Security (formerly called Trusted Oracle MLS RDBMS) uses the VPD (Virtual Private Database) feature of Oracle8i to implement row level security. 507. The OEM Console connects to the management server to monitor and configure the Oracle enterprise. . What is a Package ? A Package is a collection of related procedures. It provides tools to monitor the Oracle environment and automate tasks (both one-time and repetitive in nature) to take database administration a step closer to "Lights Out" management. What is a Procedure ? A Procedure consist of a set of SQL and PL/SQL statements that are grouped together as a unit to solve a specific problem or perform a set of related tasks. conditional branching. 508. . functions. Access to rows are restricted according to a user's security sensitivity tag or label. variables and other package constructs together as a unit in the database.

eg INSTR('ABC-DC. Can the default values be assigned to actual parameters? Yes 512. 511. 510. Differentiate between TRUNCATE and DELETE? TRUNCATE deletes much faster than DELETE TRUNCATE DELETE It is a DDL statement It is a DML statement It is a one way trip. What is Database Trigger ? A Database Trigger is procedure (set of SQL and PL/SQL statements) that is automatically executed as a result of an insert in.'-'. What is difference between SUBSTR and INSTR? SUBSTR returns a specified portion of a string eg SUBSTR('BCDEF' . 518.509. Can a primary key contain more than one columns? Yes 515. or delete from a table.4) output BCDE INSTR provides character position in which a pattern is found in a string.F'. What is a OUTER JOIN? .2) output 7 (2nd occurence of '-' 529. What are different Oracle database objects? -TABLES -VIEWS -INDEXES -SYNONYMS -SEQUENCES -TABLESPACES etc 519.update to.cannot ROLLBACK One can Rollback Doesn't have selective features (where clause) Has Doesn't fire database triggers Does It requires disabling of referential constraints. What is difference between Procedures and Functions ? A Function returns a value to the caller where as a Procedure does not.

553. 551. How do you find the numbert of rows in a Table ? A bad answer is count them (SELECT COUNT(*) FROM table_name) A good answer is :'By generating SQL to ANALYZE TABLE table_name COUNT STATISTICS by querying Oracle System Catalogues (e. 547. How will you delete duplicating rows from a base table? delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_ field_name) . oracle allows a developer to create a CLUSTER. USER_TABLES or ALL_TABLES). . What is use of a cursor variable? How it is defined? A cursor variable is associated with different statements at run time.return_ type is a record type indicating the types of the select list that will eventually be returned by the cursor variable. A cursor variable is reference type (like a pointer in C). What is a view ? A view is stored procedure based on one or more tables.g. Declaring a cursor variable: TYPE type_name IS REF CURSOR RETURN return_type type_name is the name of the reference type. However. for the purpose of increasing performance.Outer Join--Its a join condition used where you can query all the rows of one of the tables in the join condition even though they don’t satisfy the join condition. What is a cursor? Oracle uses work area to execute SQL statements and store processing information PL/SQL construct called a cursor lets you name a work area and access its stored information A cursor is a mechanism used to fetch more than one row in a Pl/SQl block. The best answer is to refer to the utility which Oracle released which makes it unnecessary to do ANALYZE TABLE for each Table individually. 554. What is difference between UNIQUE and PRIMARY KEY constraints? A table can have only one PRIMARY KEY whereas there can be any number of UNIQUE keys. The columns that compose PK are automatically define NOT NULL.dv) . since that is a part of the function of the RDBMS. 530. whereas a column that compose a UNIQUE is not automatically defined to be mandatory must also specify the column is NOT NULL. 552. which can hold different values at run time.dv=tb. 531. or delete duplicate_values_ field_name dv from table_name ta where rowid <(select min(rowid) from table_name tb where ta. What is the purpose of a cluster? Oracle does not allow a user to specifically locate tables. it’s a virtual table. Static cursors can only be associated with one run time query. A CLUSTER provides a means for storing data from different tables together for faster retrieval than if the table placement were left to the RDBMS.

564. 562.Database triggers fire on DELETE. What are the advantages of VIEW ? To protect some of the columns of a table from other users.. What is a transaction ? Transaction is logical unit between two commits and commit and rollback. What is difference between TRUNCATE & DELETE ? TRUNCATE commits after deleting entire table i. 563. What are the usage of SAVEPOINTS ?value in a session before accessing next value ? SAVEPOINTS are used to subdivide a transaction into smaller parts.To hide complexity of calculations.To hide complexity of a query. 565. . can not be rolled back. What is the fastest way of accessing a row in a table ? Using ROWID.CONSTRAINTS 560. Database triggers do not fire on TRUNCATEDELETE allows the filtered deletion. Deleted records can be rolled back or committed.558. 567. It enables rolling back part of a transaction. Where the integrity constraints are stored in Data Dictionary ? The integrity constraints are stored in USER_CONSTRAINTS. Maximum of five save points are allowed.e. 561. What is the Subquery ? Sub query is a query whose return values are used in filtering conditions of the main query. How will you a activate/deactivate integrity constraints ? The integrity constraints can be enabled or disabled by ALTER TABLE ENABLE constraint/DISABLE constraint. 559. What is ON DELETE CASCADE ? When ON DELETE CASCADE is specified ORACLE maintains referential integrity by automatically removing dependent foreign key values if a referenced primary or unique key value is removed.

568. What is ROWID ?in a session before accessing next value ? ROWID is a pseudo column attached to each row of a table. It is 18 character long, blockno, rownumber are the components of ROWID. 571. What is Referential Integrity ? Maintaining data integrity through a set of rules that restrict the values of one or more columns of the tables based on the values of primary key or unique key of the referenced table.

572. What is a join ? Explain the different types of joins ? Join is a query which retrieves related columns or rows from multiple tables.Self Join - Joining the table with itself.Equi Join - Joining two tables by equating two common columns.Non- Equi Join - Joining two tables by equating two common columns.Outer Join - Joining two tables in such a way that query can also retrieve rows that do not have corresponding join value in the other table. 573. If an unique key constraint on DATE column is created, will it validate the rows that are inserted with SYSDATE ? It won't, Because SYSDATE format contains time attached with it. 574. How does one stop and start the OMS? (for DBA Use the following command sequence to stop and start the OMS (Oracle Management Server): oemctl start oms oemctl status oms sysman/oem_temp oemctl stop oms sysman/oem_temp Windows NT/2000 users can just stop and start the required services. The default OEM administrator is "sysman" with a password of "oem_temp". NOTE: Use command oemctrl instead of oemctl for Oracle 8i and below.

575. What is an Integrity Constraint ? Integrity constraint is a rule that restricts values to a column in a table.

576. How does one create a repository? (for DBA For OEM v2 and above, start the Oracle Enterprise Manager Configuration Assistant (emca on Unix) to create and configure the management server and repository. Remember to setup a backup for the repository database after creating it. 579. What is a database link ? Database Link is a named path through which a remote database can be accessed.

580. How does one list one's databases in the OEM Console? (for DBA

Follow these steps to discover databases and other services from the OEM Console: 1. Ensure the GLOBAL_DBNAME parameter is set for all databases in your LISTENER.ORA file (optional). These names will be listed in the OEM Console. Please note that names entered are case sensitive. A portion of a listener.ora file: (SID_DESC = (GLOBAL_DBNAME = DB_name_for_ OEM) (SID_NAME = ... 2. Start the Oracle Intelligent Agent on the machine you want to discover. See section "How does one start the Oracle Intelligent Agent?". 3. Start the OEM Console, navigate to menu "Navigator/ Discover Nodes". The OEM Discovery Wizard will guide you through the process of discovering your databases and other services. 593. What utility is used to create a physical backup? Either rman or alter tablespace begin backup will do.. 594. What are the Back ground processes in Oracle and what are they. This is one of the most frequently asked question.There are basically 9 Processes but in a general system we need to mention the first five background processes.They do the house keeping activities for the Oracle and are common in any system. The various background processes in oracle are a) Data Base Writer(DBWR) :: Data Base Writer Writes Modified blocks from Database buffer cache to Data Files.This is required since the data is not written whenever a transaction is commited. b)LogWriter( LGWR) :: LogWriter writes the redo log entries to disk. Redo Log data is generated in redo log buffer of SGA. As transaction commits and log buffer fills, LGWR writes log entries into a online redo log file. c) System Monitor(SMON) :: The System Monitor performs instance recovery at instance startup.This is useful for recovery from system failure d)Process Monitor(PMON) :: The Process Monitor peforms process recovery when user Process fails. Pmon Clears and Frees resources that process was using. e) CheckPoint(CKPT) :: At Specified times, all modified database buffers in SGA are written to data files by DBWR at Checkpoints and Updating all data files and control files of database to indicate the most recent checkpoint f)Archieves( ARCH) :: The Archiver copies online redo log files to archival storal when they are busy. g) Recoveror(RECO) :: The Recoveror is used to resolve the distributed transaction in network h) Dispatcher (Dnnn) :: The Dispatcher is useful in Multi Threaded Architecture i) Lckn :: We can have upto 10 lock processes for inter instance locking in parallel sql. 595. How many types of Sql Statements are there in Oracle There are basically 6 types of sql statments.They are a) Data Defination Language(DDL) :: The DDL statments define and maintain objects and drop objects. b) Data Manipulation Language(DML) :: The DML statments manipulate database data. c) Transaction Control Statements :: Manage change by DML d) Session Control :: Used to control the properties of current session enabling and disabling roles and changing .e.g :: Alter Statements,Set Role e) System Control Statements :: Change Properties of Oracle Instance .e.g:: Alter System f) Embedded Sql :: Incorporate DDL,DML and T.C.S in Programming Language.e.g: : Using the Sql Statements in languages such as 'C', Open,Fetch, execute and close

596. What is a Transaction in Oracle

A transaction is a Logical unit of work that compromises one or more SQL Statements executed by a single User. According to ANSI, a transaction begins with first executable statment and ends when it is explicitly commited or rolled back.

597. Key Words Used in Oracle The Key words that are used in Oracle are :: a) Commiting :: A transaction is said to be commited when the transaction makes permanent changes resulting from the SQL statements. b) Rollback :: A transaction that retracts any of the changes resulting from SQL statements in Transaction. c) SavePoint :: For long transactions that contain many SQL statements, intermediate markers or savepoints are declared. Savepoints can be used to divide a transactino into smaller points. d) Rolling Forward :: Process of applying redo log during recovery is called rolling forward. e) Cursor :: A cursor is a handle ( name or a pointer) for the memory associated with a specific stament. A cursor is basically an area allocated by Oracle for executing the Sql Statement. Oracle uses an implicit cursor statement for Single row query and Uses Explcit cursor for a multi row query. f) System Global Area(SGA) :: The SGA is a shared memory region allocated by the Oracle that contains Data and control information for one Oracle Instance.It consists of Database Buffer Cache and Redo log Buffer. g) Program Global Area (PGA) :: The PGA is a memory buffer that contains data and control information for server process. g) Database Buffer Cache :: Databese Buffer of SGA stores the most recently used blocks of datatbase data.The set of database buffers in an instance is called Database Buffer Cache. h) Redo log Buffer :: Redo log Buffer of SGA stores all the redo log entries. i) Redo Log Files :: Redo log files are set of files that protect altered database data in memory that has not been written to Data Files. They are basically used for backup when a database crashes. j) Process :: A Process is a 'thread of control' or mechansim in Operating System that executes series of steps. 603. What is in all those X$ tables? (for DBA The following list attempts to describe some x$ tables. The list may not be complete or accurate, but represents an attempt to figure out what information they contain. One should generally not write queries against these tables as they are internal to Oracle, and Oracle may change them without any prior notification. X$K2GTE2 Kernel 2 Phase Commit Global Transaction Entry Fixed Table X$K2GTE Kernel 2 Phase Commit Global Transaction Entry Fixed Table X$BH Buffer headers contain information describing the current contents of a piece of the buffer cache X$KCBCBH

X$KCVFH File Header Fixed Table X$KDNCE SGA Cache Entry Fixed Table X$KDNST Sequence Cache Statistics Fixed Table X$KDXHS Histogram structure Fixed Table X$KDXST Statistics collection Fixed Table X$KGHLU One-row summary of LRU statistics for the shared pool X$KGLBODY Derived from X$KGLOB (col kglhdnsp = 2) X$KGLCLUSTER Derived from X$KGLOB (col kglhdnsp = 5) X$KGLINDEX Derived from X$KGLOB (col kglhdnsp = 4) X$KGLLC Latch Clean-up state for library cache objects Fixed Table X$KGLPN . The db_block_lru_ statistics parameter has to be set to true to gather information in this table.Cache Buffer Current Buffer Header Fixed Table. It can predict the potential loss of decreasing the number of database buffers.

Library cache pin Fixed Table X$KGLTABLE Derived from X$KGLOB (col kglhdnsp = 1) X$KGLTR Library Cache Translation Table entry Fixed Table X$KGLTRIGGER Derived from X$KGLOB (col kglhdnsp = 3) X$KGLXS Library Cache Access Table X$KKMMD Fixed table to look at what databases are mounted and their status X$KKSBV Cursor Cache Bind Variables X$KSMSP Each row represents a piece of memory in the shared pool X$KSQDN Global database name X$KSQST Enqueue statistics by type X$KSUCF Cost function for each Kernel Profile (join to X$KSUPL) X$KSUPL

Resource Limit for each Kernel Profile X$KSURU Resource Usage for each Kernel Profile (join with X$KSUPL) X$KSQST Gets and waits for different types of enqueues X$KTTVS Indicate tablespace that has valid save undo segments X$KVII Internal instance parameters set at instance initialization X$KVIS Oracle Data Block (size_t type) variables X$KVIT Instance internal flags, variables and parameters that can change during the life of an instance X$KXFPCDS Client Dequeue Statistics X$KXFPCMS Client Messages Statistics X$KZDOS Represent an os role as defined by the operating system X$KZSRO Security state Role: List of enabled roles X$LE Lock Element: each PCM lock that is used by the buffer cache (gc_db_locks)

X$MESSAGES Displays all the different messages that can be sent to the Background processes X$NLS_PARAMETERS NLS database parameters

Handy X$table queries Some handy queries based on the X$ memory tables: . Largest # blocks you can write at any given time: select kviival write_batch_ size from x$kvii where kviitag = 'kcbswc'; . See the gets and waits for different types of enqueues: select * from x$ksqst where ksqstget > 0; Oracle Kernel Subsystems Listed below are some of the important subsystems in the Oracle kernel. This table might help you to read those dreaded trace files and internal messages. For example, if you see messages like this, you will at least know where they come from: OPIRIP: Uncaught error 447. Error stack: KCF: write/open error block=0x3e800 online=1

OPI Oracle Program Interface KK Compilation Layer - Parse SQL, compile PL/SQL KX Execution Layer - Bind and execute SQL and PL/SQL K2 Distributed Execution Layer - 2PC handling NPI Network Program Interface KZ

Validate privs KQ Query Layer RPI Recursive Program Interface KA Access Layer KD Data Layer KT Transaction Layer KC Cache Layer KS Services Layer KJ Lock Manager Layer KG Generic Layer KV Kernel Variables (eg.Security Layer . x$KVIS and X$KVII) S or ODS .

Assign password DEFAULT TABLESACE tools -. -. type "password user_name". Below are a few of them: SYS/CHANGE_ON_ INSTALL or INTERNAL Oracle Data Dictionary/ Catalog Created by: ?/rdbms/admin/ sql.bsq Can password be changed: Yes (Do so right after the database was created) Can user be dropped: NO SCOTT/TIGER. CLARK/CLOTH and BLAKE/PAPER.Drop users cascade from all production environments HR/HR (Human Resources). How does one create and drop database users? Look at these examples: CREATE USER scott IDENTIFIED BY tiger -. SH/SH (Sales History).Make user a DB Administrator Remember to give the user some space quota on its tablespaces: ALTER USER scott QUOTA UNLIMITED ON tools.bsq Can password be changed: Yes (Do so right after the database was created) Can user be dropped: NO OUTLN/OUTLN Stored outlines for optimizer plan stability Created by: ?/rdbms/admin/ sql. OE/OE (Order Entry).Assign sort space DROP USER scott CASCADE. Look at this example: SQL> password Changing password for SCOTT Old password: New password: Retype new password: 606. -. ADAMS/WOOD.Assign space for table and index segments TEMPORARY TABLESPACE temp. From Oracle8 you can just type "password" from SQL*Plus.sql scripts Can password be changed: Yes (Do so right after the database was created) Can user be dropped: NO SYSTEM/MANAGER The default DBA user name (please do not use SYS) Created by: ?/rdbms/admin/ sql. RESOURCE TO scott. Training/ demonstration users containing the popular EMPLOYEES and DEPARTMENTS tables . JONES/STEEL. Who created all these users in my database?/ Can I drop this user? (for DBA Oracle creates a number of default database users or schemas when a new database is created. How does one change an Oracle user's password?(for DBA Issue the following SQL command: ALTER USER <username> IDENTIFIED BY <new_password>. sql Can password be changed: Yes Can user be dropped: YES . -. assign the required privileges: GRANT CONNECT. Training/ demonstration users containing the popular EMP and DEPT tables Created by: ?/rdbms/admin/ utlsampl. or if you need to change another user's password.Operating System Dependencies 605. GRANT DBA TO scott.bsq and various cat*.Remove user After creating a new user. 607.

sql MDSYS/MDSYS Oracle Spatial administrator user Created by: ?/ord/admin/ ordinst. PASSWORD_REUSE_ MAX .sql DBSNMP/DBSNMP Oracle Intelligent agent Created by: ?/rdbms/admin/ catsnmp.Only if you do not use the Intelligent Agents ORDPLUGINS/ORDPLUGI NS Object Relational Data (ORD) User used by Time Series. ALTER USER scott PROFILE my_profile.sql.number of password changes required before the current password can be reused . Also. Created by: ?/ord/admin/ ordinst. PASSWORD_LOCK_ TIME .sql ORDSYS/ORDSYS Object Relational Data (ORD) User used by Time Series. This means that one can hack an account for years without ever locking the user. How does one enforce strict password control? (for DBA By default Oracle's security is not extremely good. FAILED_LOGIN_ ATTEMPTS . etc Created by: ?/ord/admin/ ordinst.failed login attempts before the account is locked . PASSWORD_REUSE_ TIME .limits the number of days the same password can be used for authentication . 608.sql TRACESVR/TRACE Oracle Trace server Created by: ?/rdbms/admin/ otrcsvr.number of days after the grace period begins during which a warning is issued and login is allowed . sql called from ?/javavm/install/ initjvm.Created by: ?/demo/schema/ mksample. From Oracle8 one can manage passwords through profiles.number of days an account will be locked after maximum failed login attempts .Drop users cascade from all production environments CTXSYS/CTXSYS Oracle interMedia (ConText Cartridge) administrator user Created by: ?/ctx/admin/ dr0csys.sql DSSYS/DSSYS Oracle Dynamic Services and Syndication Server Created by: ?/ds/sql/dssys_ init. PASSWORD_VERIFY_ FUNCTION .password complexity verification script Look at this simple example: CREATE PROFILE my_profile LIMIT PASSWORD_LIFE_ TIME 30.number of days before a password can be reused . sql Remember to change the passwords for the SYS and SYSTEM users immediately after installation! Except for the user SYS. etc.sql PERFSTAT/PERFSTAT Oracle Statistics Package (STATSPACK) that supersedes UTLBSTAT/UTLESTAT Created by: ?/rdbms/admin/ statscre. For example. PASSWORD_LIFE_ TIME .put the new password in snmp_rw. passwords don't ever expire. PASSWORD_GRACE_ TIME .sql Can password be changed: Yes .ora file Can user be dropped: YES .sql AURORA$ORB$UNAUTHEN TICATED/INVALID Used for users who do not authenticate in Aurora/ORB Created by: ?/javavm/install/ init_orb. Oracle will allow users to choose single character passwords and passwords that match their names and userids. . called from catalog. sql Can password be changed: Yes Can user be dropped: YES . Some of the things that one can restrict: . there should be no problem altering these users to use a different default and temporary tablespace.

What is the difference between candidate key. The grant has to be given by the owner of the object. How does one switch to another user in Oracle? (for DBA Users normally use the "connect" statement to connect from one database user to another. e. b) Share lock We can do the table as Share_Lock as many share_locks can be put on the same resource.When a database is created two table spaces are created. SQL> connect system/manager Connected. Locks useful for accesing the database are a) Exclusive The exclusive lock is useful for locking the row when an insert. Note: Also see the su. User altered. SQL> alter user scott identified by values 'F894844C34402B67' . Previleges and Grants Previleges are the right to execute a particulare type of SQL statements.609. 612.) 613.This lock should not be applied when we do only select from the row. but look at this example: SQL> select password from dba_users where username='SCOTT' .sql script in the Useful Scripts and Sample Programs Page. Table Space. Of course it is not advisable to bridge Oracle's security. SQL> connect scott/tiger Connected. However. Right to create. SQL> connect scott/lion Connected. Control Files Table Space :: The table space is useful for storing the data in the database. a) System Table space :: This data file stores all the tables related to the system and dba tables b) User Table space :: This data file stores all the user related tables .Data Files. DBAs can switch from one user to another without a password. REM Do whatever you like. 615..g :: Right to Connect. unique key and primary key Candidate keys are the columns in the table that could be the primary keys and the primary key is the key that has been selected to identify the rows. 614. Right to resource Grants are given to the objects so that the object might be accessed accordingly. User altered.update or delete is being done. Unique key is also useful for identifying the distinct rows in the table.. PASSWORD F894844C34402B67 SQL> alter user scott identified by lion. What is concurrency Cuncurrency is allowing simultaneous access of same data by different users.Parameter File.

To increase the size of the database to store more data we have to add data file. .g. Pctused 40 618.acme lang Control Files :: Control files record the physical structure of the data files and redo log files They contain the Db name. Physical Storage of the Data The finest level of granularity of the data base are the data blocks. Read only or abort Reply 620. 619.Once the Data file is created the size cannot change. Parameter Files :: Parameter file is needed to start an instance. Data Files :: Every Oracle Data Base has one or more physical data files. Segments :: Set of Extents allocated for Extents.s.:: db_block_buffers = 500 db_name = ORA7 db_domain = u.We should have seperate table spaces for storing the tables and indexes so that the access is fast.:: Pctfree 20.Every datafile is associated with only one database.They store the data for the database. It contains DML statements or Remote Procedural calls that reference a remote object. Data Block :: One Data Block correspond to specific number of physical database space Extent :: Extent is the number of specific number of contigious data blocks. What are the Pct Free and Pct Used Pct Free is used to denote the percentage of the free space that is to be left when creating a table. a) Prepare Phase :: Global coordinator asks participants to prepare b) Commit Phase :: Commit all participants to coordinator to Prepared. What is Row Chaining The data of a row in a table may not be able to fit the same data block. Similarly Pct Used is used to denote the percentage of the used space that is to be used when creating a table eg. name and location of dbs. There are basically 2 phases in a 2 phase commit.Data for row is stored in a chain of data blocks . There are three types of Segments a) Data Segment :: Non Clustered Table has data segment data of every table is stored in cluster data segment b) Index Segment :: Each Index has index segment that stores data c) Roll Back Segment :: Temporarily store 'undo' information 617.A parameter file contains the list of instance configuration parameters e. This is useful to maintain the integrity of the database so that all the users see the same values. What is a 2 Phase Commit Two Phase commit is used in distributed data base systems. data files . What is the difference between deleting and truncating of tables Deleting a table will not remove the rows from the table but entry is there in the database dictionary and it can be retrieved But truncating a table deletes it completely and it cannot be retrieved.redo log files and time stamp. 616.

or delete their values. What are mutating tables When a table is in state of transition it is said to be mutating. 629. 623. What is Normalisation Normalisation is the process of organising the tables to remove the redundancy. No RDBMS satisfies all the 12 codd rules and Oracle Satisfies 11 of the 12 rules and is the only Rdbms to satisfy the maximum number of rules. How many columns can table have? The number of columns in a table can range from 1 to 254. update. but is not actually stored in the table. 622. What is pseudo columns ? Name them? A pseudocolumn behaves like a table column. Is space acquired in blocks or extents ? In extents . What are Codd Rules Codd Rules describe the ideal nature of a RDBMS. a) 1 Normal Form :: A table is said to be in 1st Normal Form when the attributes are atomic b) 2 Normal Form :: A table is said to be in 2nd Normal Form when all the candidate keys are dependant on the primary key c) 3rd Normal Form :: A table is said to be third Normal form when it is not dependant transitively 624. . but you cannot insert. Deleting the Duplicate rows in the table We can delete the duplicate rows in the table by using the Rowid 627.There are mainly 5 Normalisation rules.621. This section describes these pseudocolumns: * CURRVAL * NEXTVAL * LEVEL * ROWID * ROWNUM 628. 625. eg :: If a row has been deleted then the table is said to be mutating and no operations can be done on the table except select. What is the Difference between a post query and a pre query A post query will fire for every row that is fetched but the pre query will fire only once. You can select from pseudocolumns.

What are the steps involved in Database Startup ? Start an instance. 680.630. rows are stored together based on their cluster key values . what is clustered index? In an indexed cluster. Can Full Backup be performed when the database is open ? No. 679. 678. the corresponding redo entries temporarily stores in redo log buffers of the SGA are written to an on-line redo log file by the background process LGWR. Can not applied for HASH. including the contents of rollback segments. Rolling back transactions that have been explicitly rolled back or have not been committed as indicated by the rollback segments regenerated in step a. What is On-line Redo Log? The On-line Redo Log is a set of tow or more on-line redo files that record all committed changes made to the database. Resolving any pending distributed transactions undergoing a two-phase commit at the time of the instance failure. When objects are created their INITIAL and MINEXTENS values cannot be changed. Whenever a transaction is committed. Releasing any resources (locks) held by transactions in process at the time of the failure. What is Log Switch ? The point at which ORACLE ends writing to one online redo log file and begins writing to another is called a log switch. yet has been recorded in the on-line redo log. Mount the Database and Open the Database. Which parameter specified in the DEFAULT STORAGE clause of CREATE TABLESPACE cannot be altered after creating the tablespace? All the default storage parameters defined for the tablespace can be changed using the ALTER TABLESPACE command. What are the different modes of mounting a Database with the Parallel Server ? . 677. The on-line redo log files are used in cyclical fashion. < ? Recovery Instance in involved steps the are What> Rolling forward to recover data that has not been recorded in data files. 683. 682.

What is a Segment ? A segment is a set of extents allocated for a certain logical structure. 690. 685. Dismount the Database and Shutdown the Instance. 684. 691. 687. 689. sequence or program unit. 688. view.. Parallel Mode If the first instance that mounts a database is started in parallel mode. Online database backup is possible only in ARCHIVELOG mode. only that Instance can mount the database. What is schema? A schema is collection of database objects of a User.Exclusive Mode If the first instance that mounts a database does so in exclusive mode. other instances that are started in parallel mode can also mount the database. What is a Synonym ? A synonym is an alias for a table. What are the advantages of operating a database in ARCHIVELOG mode over operating it in NO ARCHIVELOG mode ? Complete database recovery from disk failure is possible only in ARCHIVELOG mode. What is Archived Redo Log ? Archived Redo Log consists of Redo Log files that have archived before being reused. 686. . What is Restricted Mode of Instance Startup ? An instance can be started in (or later altered to be in) restricted mode so that when the database is open connections are limited only to those whose user accounts have been granted the RESTRICTED SESSION system privilege. What is a Sequence ? A sequence generates a serial list of unique numbers for numerical columns of a database's tables. What are the steps involved in Database Shutdown ? Close the Database.

692. What is index cluster? A cluster with an index on the cluster key. All rows with the same hash key value are stores together on disk. .What is hash cluster? A row is stored in a hash cluster based on the result of applying a hash function to the row's cluster key value. 699. Describe Referential Integrity ? A rule defined on a column (or set of columns) in one table that allows the insert or update of a row only if the value for the column or set of columns (the dependent value) matches a value in a column of a related table (the referenced value). The resulting hash key value points directly to the area on disk that stores the specified rows. What is Database Link ? A database link is a named object that describes a "path" from one database to another 696. 698. For such queries the specified cluster key value is hashed. 694. 693. What is a Private Synonyms ? A Private Synonyms can be accessed only by the owner. For such queries the specified cluster key value is hashed. The resulting hash key value points directly to the area on disk that stores the specified rows.When can hash cluster used? Hash clusters are better choice when a table is often queried with equality queries. What is Hash Cluster ? A row is stored in a hash cluster based on the result of applying a hash function to the row's cluster key value. It also specifies the type of data manipulation allowed on referenced data and the action to be performed on dependent data as a result of any action on referenced data.When can hash cluster used? Hash clusters are better choice when a table is often queried with equality queries. All rows with the same hash key value are stores together on disk. 697. 695.

A database users and allocated free database space in Oracle data blocks. A private database link can be used only when the owner of the link specifies a global object name in a SQL statement or in the definition of the owner's views or procedures.700. A public database link can be used when any user in the associated database specifies a global object name in a SQL statement or object definition. all of the data for a row in a table may not be able to fit in the same data block. . How to define data block size? A data block size is specified for each Oracle database when the database is created. 703. 704. public database link & network database link. What is network database link? Network database link is created and managed by a network domain service. 702. What is row chaining? In circumstances. 707. What is public database link? Public database link is created for the special user group PUBLIC. 701. the data for the row is stored in a chain of data block (one or more) reserved for that segment. What is private database link? Private database link is created on behalf of a specific user. What are the types of database links? Private database link. When this occurs. What is data block? Oracle database's data is stored in data blocks. One data block corresponds to a specific number of bytes of physical database space on disk. What is an extent? An extent is a specific number of contiguous data blocks. Block size is specified in init. obtained in a single allocation and used to store a specific type of information. A network database link can be used when any user of any database in the network specifies a global object name in a SQL statement or object definition.ora file and cannot be changed latter. 706. 705.

What is a datafile? Every Oracle database has one or more physical data files. 709. All of the table's data is stored in the extents of its data segment. 712. What is rollback segment? A database contains one or more rollback segments to temporarily store "undo" information. What is a temporary segment? Temporary segments are created by Oracle when a SQL statement needs a temporary work area to complete execution. What is an index segment? Each index has an index segment that stores all of its data. Each cluster has a data segment. the temporary segment extents are released to the system for future use. The data of logical database structures such as tables and indexes is physically stored in the data files allocated for a database. The data of every table in the cluster is stored in the cluster's data segment. . One or more data files form a logical unit of database storage called a tablespace. Once created a data file can't change size. rollback segment and temporary segment. What are the uses of rollback segment? To generate read-consistent database information during database recovery and to rollback uncommitted transactions by the users. 711.708. 713. What are the different types of segments? Data segment. 709. 714. index segment. A database's data files contain all the database data. 710. What is a data segment? Each non-clustered table has a data segment. When the statement finishes execution. What are the characteristics of data files? A data file can be associated with only one database.

stipulating where on disk all the data files where and then issue the recover command with the using backup control file clause. The benefit of taking a hot backup is that the database is still available for use while the backup is occurring and you can recover the database to any point in time.Database name . It is also used in database recovery 730. its control file is used to identify the database and redo log files that must be opened for database operation to proceed. 731. 718. 717. Explain the difference between a hot backup and a cold backup and the benefits associated with each. . In addition. What is the function of redo log? The primary function of the redo log is to record all changes made to data. The benefit of taking a cold backup is that it is typically easier to administer the backup and recovery process. 732. How would you go about bringing up this database? I would create a text based backup control file. What does a control file contains? . What is the use of redo log information? The information in a redo log file is used only to recover the database from a system or media failure prevents database data from being written to a database's data files. . 719. 716. What is a redo log? The set of redo log files for a database is collectively known as the database redo log. You have just had to restore from backup and do not have any control files.Names and locations of a database's files and redolog files. since you are taking cold backups the database does not require being in archive log mode and thus there will be a slight performance gain as the database is not cutting archive logs to disk. What is the use of control file? When an instance of an Oracle database is started.Time stamp of database creation. A cold backup is taking a backup of the database while it is shut down and does not require being in archive log mode. A hot backup is basically taking a backup of the database while it is still up and running and it must be in archive log mode.715.ora file to a spfile? Issue the create spfile from pfile command. How do you switch from an init.

Give the two types of tables involved in producing a star schema and the type of data they hold. Faster access to data blocks in a table. 734. All the extents that an object takes when grouped together are considered the segment of the database object. an extent and a segment. 733. is a DML operation. The delete command. Give the reasoning behind using an index. 736. . which will produce a rollback and thus take longer to complete. 735. As objects grow they take chunks of additional storage that are composed of contiguous data blocks. on the other hand. Both the truncate and delete command have the desired outcome of getting rid of all the rows in a table. What type of index should you use on a fact table? A Bitmap index. Use the describe command or use the dbms_metadata. Give two examples of referential integrity constraints. A data block is the smallest unit of logical storage for a database object. Give two examples of how you might determine the structure of the table DEPT. A primary key and a foreign key. 737. get_ddl package. Fact tables and dimension tables. Explain the difference between a data block. Where would you look for errors from the database engine? In the alert log. These groupings of contiguous data blocks are called extents. 738.732. 739. The difference between the two is that the truncate command is a DDL operation and just moves the high water mark and produces a now rollback. Compare and contrast TRUNCATE and DELETE for a table. A fact table contains measurements while dimension tables will contain data that will help describe the fact tables.

The database is opened 744.sql 746. How would you do this without affecting the children tables? Disable the foreign key constraint to the parent. STARTUP NOMOUNT . drop the table.sql. NOARCHIVELOG mode is basically the absence of ARCHIVELOG mode and has the disadvantage of not being able to recover to any point in time. If a change was necessary then I would use the alter system set db_cache_size command. ARCHIVELOG mode is a mode that you can put the database in for creating a backup of all transactions that have occurred in the database so that you can recover to any point in time. 747.The database is mounted STARTUP OPEN . A table is classified as a parent table and you want to drop and re-create it. Use the explain plan set statement_id = 'tst1' into plan_table for a SQL statement Look at the explain plan with utlxplp.sql or utlxpls. How would you go about generating an EXPLAIN plan? Create a plan table with utlxplan.740. What column differentiates the V$ views to the GV$ views and how? The INST_ID column which indicates the instance in a RAC environment the information came from. What command would you use to create a backup control file? Alter database backup control file to trace. 741. Explain the difference between ARCHIVELOG mode and NOARCHIVELOG mode and the benefits and disadvantages to each. 745. enable the foreign key constraint. How would you go about increasing the buffer cache hit ratio? Use the buffer cache advisory over a given workload and then query the v$db_cache_advice table. 742. Explain an ORA-01555 . 743. Give the stages of instance startup to a usable state where normal users may access it. NOARCHIVELOG mode does have the advantage of not having to write transactions to an archive log and thus increases the performance of the database slightly.Instance startup STARTUP MOUNT . re-create the table.

Setting GLOBAL_NAMES dictates how you might connect to a database. This variable is either TRUE or FALSE and if it is set to TRUE it enforces database links to have the same name as the remote database to which they are linking. 751. Name three advisory statistics you can collect. (Continued on next part. How would you determine the time zone under which a database was operating? select DBTIMEZONE from dual.You get this error when you get a snapshot too old within rollback. What command would you use to encrypt a PL/SQL application? WRAP 752. Explain the difference between $ORACLE_HOME and $ORACLE_BASE. Where in the Oracle directory tree structure are audit traces placed? . 753. Buffer Cache Advice. ORACLE_HOME located beneath ORACLE_BASE is where the oracle products reside. ORACLE_BASE is the root directory for oracle. A function and procedure are the same in that they are intended to be a collection of PL/SQL code that carries a single task. While a procedure does not have to return any values to the calling application. You should also look at the logic involved in the application getting the error message. a function will return a single value. They are also used to pipeline information in an ETL process. PROCEDURE and PACKAGE. A package on the other hand is a collection of functions and procedures that are grouped together based on their commonality to a business function or application. Explain the use of setting GLOBAL_NAMES equal to TRUE. 749.. & Timed Statistics 755. Table functions are designed to return a set of rows through PL/SQL logic but are intended to be used as a normal table or view in a SQL statement. 748. Explain the difference between a FUNCTION. Explain the use of table functions. Segment Level Statistics. It can usually be solved by increasing the undo retention or increasing the size of rollbacks.) 754. 750..

They are typically used in data warehouse or decision support systems. . When a user process fails. 762. Describe what redo logs are. What does coalescing a tablespace do? Coalescing is only valid for dictionary-managed tablespaces and de-fragments space by combining neighboring free extents into large single extents. 759. or aggregated from base tables. How would you force a log switch? ALTER SYSTEM SWITCH LOGFILE. 761.In unix $ORACLE_HOME/ rdbms/audit. in Windows the event viewer 756. grouped. 757. You could use Logminer or Streams 763. Give two methods you could use to determine what DDL changes have been made. How would you determine what sessions are connected and what resources they are waiting for? Use of V$SESSION and V$SESSION_WAIT 760. Explain materialized views and how they are used. Materialized views are objects that are reduced sets of information that have been summarized. what background process cleans up after it? PMON 758. Redo logs are logical and physical structures that are designed to hold all the changes made to a database and are intended to aid in the recovery of a database. What background process refreshes materialized views? The Job Queue Processes.

Name a tablespace automatically created when you create a database. When creating a user. 772. How do you resize a data file? ALTER DATABASE DATAFILE <datafile_name> RESIZE <new_size>. The SYSTEM tablespace. How would you determine who has added a row to a table? Turn on fine grain auditing for the table. 769. 773. How can you rebuild an index? ALTER INDEX <index_name> REBUILD. Explain what partitioning is and what its benefit is. What view would you use to look at the size of a data file? DBA_DATA_FILES 770. 765. what permissions must you grant to allow them to connect to the database? Grant the CONNECT to the user. 766. 767.764. What view would you use to determine free space in a tablespace? DBA_FREE_SPACE 771. What is the difference between a TEMPORARY tablespace and a PERMANENT tablespace? A temporary tablespace is used for temporary objects such as sort structures while permanent tablespaces are used to store those objects meant to be used as the true objects of the database. . How do you add a data file to a tablespace ALTER TABLESPACE <tablespace_name> ADD DATAFILE <datafile_name> SIZE 768.

777. 776. ALTER DATABASE DATAFILE 'filename2' RESIZE 100M. 778. You have just compiled a PL/SQL package but got errors. SET_SQL_TRACE or Use ALTER SESSION SET SQL_TRACE = TRUE. Because you can change the sizes of datafiles. datafiles can be allowed to automatically extend if more space is required. more manageable pieces. how would you view the errors? SHOW ERRORS 775. you can add more space to your database without adding more datafiles. Can one resize tablespaces and data files? (for DBA) One can manually increase or decrease the size of a datafile from Oracle 7. This is beneficial if you are concerned about reaching the maximum number of datafiles allowed in your database. Also. Manually reducing the sizes of datafiles allows you to reclaim unused space in the database. Name two files used for network connection to a database. dbf' SIZE 3M AUTOEXTEND ON NEXT 1M MAXSIZE UNLIMITED DEFAULT STORAGE (INITIAL 10240 NEXT 10240 MINEXTENTS 1 MAXEXTENTS UNLIMITED PCTINCREASE 0) ONLINE PERMANENT. 774.2 using the command. TNSNAMES. How can you gather statistics on a table? The ANALYZE command.Partitioning is a method of taking large tables and indexes and splitting them into smaller.ORA 781.ORA and SQLNET. The difference is that the import utility relies on the data being produced by another Oracle utility EXPORT while the SQL*Loader utility allows data to be loaded that has been produced by other utilities from different data sources just so long as it conforms to ASCII formatted or delimited files. What is the difference between the SQL*Loader and IMPORT utilities? These two Oracle utilities are used for loading data into the database. . Look at the following command: CREATE TABLESPACE pcs_data_ts DATAFILE 'c:\ora_apps\ pcs\pcsdata1. This is useful for correcting errors in estimations of space requirements. How can you enable a trace for a session? Use the DBMS_SESSION.

---". Note that an export will not work!!! On your standby database. write a job to copy archived redo log files from the primary database to the standby system. 788. When one needs to activate the standby database. What is a trace file and how is it created ? . this is listed as Enhancement Request 148742. ALTER DATABASE MOUNT STANDBY DATABASE. stop the recovery process and activate it: ALTER DATABASE ACTIVATE STANDBY DATABASE. indexes) Enrolling users and maintaining system security. Contacting Oracle Corporation for technical support. and apply then to the standby database. Allocating system storage and planning future storage requirements for the database system.782. This allows the option of later rolling back all work performed from the current point in the transaction to a declared savepoint within the transaction.ORA file and bounce your database for it to take effect. intermediate markers or savepoints can be declared which can be used to divide a transaction into smaller parts. Planning for backup and recovery of database information. What is SAVE POINT ? For long transactions that contain many SQL statements.How does one give developers access to trace files (required as input to tkprof)? (for DBA) The "alter session set sql_trace=true" command generates trace files in USER_DUMP_DEST that can be used by developers as input to tkprof. Monitoring and optimizing the performance of the database. What are the responsibilities of a Database Administrator ? Installing and upgrading the Oracle Server and application tools. 790.ORA parameter that will allow everyone to read (rwx r-r--) these trace files: _trace_files_ public = true Include this in your INIT. take an (image copy) backup and restore it on duplicate hardware. RECOVER STANDBY DATABASE. There is an undocumented INIT. On systems prior to Oracle 8i. log files to the remote site via NET8. issue the following commands: ALTER DATABASE CREATE STANDBY CONTROLFILE AS 'filename'. Ensuring compliance with Oralce license agreement Controlling and monitoring user access to the database. 784. which will send archived. Can one rename a tablespace? (for DBA) No. and apply the redo log files to the standby database (pipe it). How does one create a standby database? (for DBA) While your production database is running. Workaround: Export all of the objects from the tablespace Drop the tablespace including contents Recreate the tablespace Import the objects 787.views. Maintain archived data on tape Backing up and restoring the database. Oracle 8i onwards provide an "Automated Standby Database" feature. On Unix the default file mask for these files are "rwx r-. Remember the database is recovering and will prompt you for the next log file to apply. Managing primary database structures (tablespaces) Managing primary objects (table. 789.

792. 793. it's the little things that will get you. What are the minimum parameters should exist in the parameter file (init.role Contains all database system privileges. Remember. redo log files and control files and control file while database creation.The DBA role will be assigned to this account. The value should be 5 (background process) and additional 1 for each user. 791. it dumps information about the error to its trace.To determine number of operating system processes that can be connected to ORACLE concurrently. DB_BLOCK_BUFFERS . but your data may be irreplaceable! Normally one would schedule a hierarchy of daily. you could very well lose your job. Frequently test your ability to recover and document all possible scenarios.Must set to a text string of no more than 8 characters and it will be stored inside the datafiles. If archive logging is enabled one needs to backup archived log files timeously to prevent database freezes . This can be used for tuning the database. Etc. Rate of data change/ transaction rate .List of control filenames of the database. SYS user account . If name is not mentioned then default name will be used. Backup frequency normally depends on the following factors: . Database availability/ Can you shutdown for cold backups? . ROLLBACK_SEGMENTS . Ensure enough backup media (tapes) are available and that old backups are expired in-time to make media available for new backups. Read-only tablespace needs backing up just once right after you make it read-only .It has all the system privileges for the database and additional tables and views that display administrative information and internal tables and views used by oracle tools are created using this username. Carefully plan backup retention periods.ora) ? DB NAME . DB_DOMAIN . SYSTEM user account . Criticality of the data/ Value of the data to the company .List of rollback segments an ORACLE instance acquires at database startup. If you are running in archivelog mode you can backup parts of a database over an extended cycle of days . Also optionally LICENSE_MAX_ SESSIONS. All of the base tables and views for the database's dictionary are store in this schema and are manipulated only by ORACLE. Most failed recoveries are a result of organizational errors and miscommunications.It is string that specifies the network domain where the database is created. weekly and monthly backups. Hardware and software can always be replaced. however consult with your users before deciding on a backup schedule. .Each server and background process can write an associated trace file. Off-site vaulting is also highly recommended. Why and when should I backup my database? (for DBA Backup and recovery is one of the most important aspects of a DBAs job.To determine the no of buffers in the buffer cache in SGA. If you lose your company's data. When an internal error is detected by a process or user process. What are the roles and user accounts created automatically with the database? DBA . LICENSE_SESSION_ WARNING and LICENSE_MAX_ USERS. The global database name is identified by setting these parameters (DB_NAME & DB_DOMAIN) CONTORL FILES . PROCESSES .

Other backup strategies normally back-up the physical data files. Hot or On-line Backups . What is the difference between online and offline backups? (for DBA A hot backup is a backup performed while the database is online and available for read/write. if you choose to do on-line database backups. use the "rman" utility to backup the database. you also need to backup archived log files. RMAN Backups . It is advisable to use more than one of these methods to backup your database. One of the advantages of exports is that one can selectively re-import tables. Recovery is the process of applying redo logs to the database to roll it forward. Except for Oracle exports. Full exports include more information about the database in the export file than user level exports. however one cannot rollforward from an restored export file. password files. This can be done to replace damaged files or to copy/move a database to a new location. To completely restore a database from an export file one practically needs to recreate the entire database. One can roll-forward until a specific point-in-time (before the disaster occurred). Library Cache Hit Ratio Action: Increase the SHARED_POOL_ SIZE to increase hit ratio . Sql> connect SYS as SYSDBA Sql> RECOVER DATABASE UNTIL TIME '2001-03-06: 16:00:00' USING BACKUP CONTROLFILE. If your database is in ARCGIVELOG mode. How does one backup a database using the export utility? (for DBA Oracle exports are "logical" database backups (not physical) as they extract data and logical definitions from the database into a file. also remember to backup all required software libraries. Cold or Off-line Backups . Always do full system level exports (FULL=YES). Also remember to backup the control files and archived redo log files. It is better to be save than sorry. Buffer Cache Hit Ratio Formula: Hit Ratio = (Logical Reads . What strategies are available for backing-up an Oracle database? (for DBA The following methods are valid for backing-up an Oracle database: Export/Import . 812.Exports are "logical" database backups in that they extract logical definitions and data from the database to a file.While the database is off-line or on-line. Regardless of your strategy. A cold backup is a backup performed while the database is off-line and unavailable to its users. Also test ALL backup and recovery scenarios carefully.Shut the database down and backup up ALL data. also cover yourself by doing database exports.Physical Reads) / Logical Reads Action: Increase DB_CACHE_SIZE (DB_BLOCK_BUFFERS prior to 9i) to increase hit ratio . and control files. 796.794. What tuning indicators can one use? (for DBA The following high-level tuning indicators can be used to establish if a database is performing optimally or not: . For example. etc. set the tablespaces into backup mode and backup their files.If the databases are available and in ARCHIVELOG mode. or roll-forward until the last transaction recorded in the log files. log. 795. one can only do on-line backups when running in ARCHIVELOG mode. 797. What is the difference between restoring and recovering? (for DBA Restoring involves copying backup files from secondary storage (backup media) to disk. parameter files.

822. forced to choose new passwords.sql . 830. DBA's must unlock these accounts to make them available to users.Delete a range of Snapshot Id's from the database . Statspack provides improved BSTAT/ESTAT functionality. though the old BSTAT/ESTAT scripts are still available. o Get a list of snapshots select SNAP_ID. spdrop. etc.Install Statspack sqlplus "/ as sysdba" @spcreate. sppurge. -.813.Truncates all data in Statspack tables 815.sql . . What tools/utilities does Oracle provide to assist with performance tuning? (for DBA Oracle provide the following tools/ utilities to assist with performance monitoring and tuning: . How does one manage Oracle database users? (for DBA Oracle user accounts can be locked. spcreate. . @spreport. Oracle Enterprise Manager . sppurge.snap. What are the common RMAN errors (with solutions)? (for DBA Some of the common RMAN errors are: RMAN-20242: Specification does not match any archivelog in the recovery catalog.Installs the STATSPACK user.Enter tablespace names when prompted Use Statspack: sqlplus perfstat/perfstat exec statspack. read the documentation in file $ORACLE_HOME/ rdbms/admin/ spdoc.sql . sptrunc. Statspack .Tuning Pack 814.sql.Report on differences between values recorded in two snapshots .Deinstall STATSPACK from database (Run as SYS) .Enter two snapshot id's for difference report Other Statspack Scripts: . For example.sql .. UTLBSTAT.snap.sql -.Begin and end stats monitoring . SNAP_TIME from STATS$SNAPSHOT.Take a performance snapshots exec statspack. Add to RMAN script: sql 'alter system archive log current'.Purge a range of Snapshot Id's between the specified begin and end Snap Id's . Install Statspack: cd $ORACLE_HOME/ rdbms/admin sqlplus "/ as sysdba" @spdrop. RMAN-06089: archived log xyz not found or out of sync with catalog Execute from RMAN: change archivelog all validate. What is STATSPACK and how does one use it? (for DBA Statspack is a set of performance monitoring and reporting utilities provided by Oracle from Oracle8i and above. spauto. unlocked.sql -.sql . spreport. For more information about STATSPACK. TKProf .sql .txt.SQL .Schedule a dbms_job to automate the collection of STATPACK statistics .sql . all accounts except SYS and SYSTEM will be locked after creating an Oracle9iDB database using the DB Configuration Assistant (dbca). What is mean by Program Global Area (PGA) ? It is area in memory that is used by a Single Oracle User Process. tables and package on a database (Run as SYS).SQL and UTLESTAT.

-.v_$system_ event b where a.event = 'db file sequential read' and b.average_wait "SCAT READ" from sys. How does one tune Oracle Wait events? (for DBA Some wait events from V$SESSION_WAIT and V$SYSTEM_EVENT views: Event Name: Tuning Recommendation: db file sequential read Tune SQL to do less I/O. -. buffer busy waits Increase DB_CACHE_SIZE (DB_BLOCK_BUFFERS prior to 9i)/ Analyze contention from SYS. these waits would then show up as sequential reads instead of scattered reads.Force user to choose a new password 831. What is the difference between DBFile Sequential and Scattered Reads?(for DBA Both "db file sequential read" and "db file scattered read" events signify time waited for I/O read requests to complete. Make sure all objects are analyzed. data from full table scans could be fitted into a contiguous buffer area. This statistic is NORMALLY indicating disk contention on full table scans.V$BH log buffer spaces Increase LOG_BUFFER parameter or move log files to faster disks 832. and 1000's of a second for Oracle 9i and above. The following query shows average wait time for sequential versus scattered reads: prompt "AVERAGE WAIT TIME FOR READ REQUESTS" select a. Most people confuse these events with each other as they think of how data is read from disk. 836. db file scattered read: Similar to db file sequential reads. b. db file sequential read: A sequential read operation reads data into contiguous memory (usually a single-block read with p3=1. Instead they should think of how data is read into the SGA buffer cache. Rarely. this event is indicative of disk contention on index reads.v_$system_ event a.Look at these examples: ALTER USER scott ACCOUNT LOCK -.unlocks a locked users account ALTER USER scott PASSWORD EXPIRE.lock a user account ALTER USER scott ACCOUNT UNLOCK.average_wait "SEQ READ". sys. except that the session is reading multiple data blocks and scatters them into different discontinuous buffers in the SGA. but can be multiple blocks). Single block I/Os are usually the result of using indexes. How does one use ORADEBUG from Server Manager/ SQL*Plus? (for DBA . Time is reported in 100's of a second for Oracle 8i releases and below. This event is also used for rebuilding the controlfile and reading datafile headers (P2=1).event = 'db file scattered read'. Redistribute I/O across disks. In general.

WHAT IS RMAN ? (for DBA Recovery Manager is a tool that: manages the process of creating backups and also manages the process of restoring and recovering from them. SQLPLUS> ! vi /app/oracle/ admin/orcl/ bdump/ora_ 10121. 850. Look at these examples: From Server Manager (Oracle7. SQLPLUS>> oradebug TRACEFILE_NAME /app/oracle/ admin/orcl/ bdump/pmon_ 1436. Are there any undocumented commands in Oracle? (for DBA Sure there are. 849.e 0x8066d338 from convres dump) 837. * ?Its contains detail of the backups taken etc in its central repository * Facility for testing validity of backups also commands like crosscheck to check the status of backup.o. Look at these examples: SQLPLUS> REM Trace SQL statements with bind variables SQLPLUS> oradebug setospid 10121 Oracle pid: 91. but it is hard to find them.mk oradbx) SQL*Plus: ALTER SESSION SET CURRENT_SCHEMA = SYS.trc SQLPLUS> REM Trace Process Statistics SQLPLUS> oradebug setorapid 2 Unix process pid: 1436. * Faster backups and restores compared to backups without RMAN * RMAN is the only backup tool which supports incremental backups. Anyone brave enough to test this one for us? Previously this functionality was available with ORADBX (ls -l $ORACLE_HOME/ rdbms/lib/ oradbx. make -f oracle. WHY USE RMAN ? (for DBA * No extra costs …Its available free * ?RMAN introduced in Oracle 8 it has become simpler with newer versions and easier than user managed backups * ?Proper security * ?You are 100% sure your database has been backed up. image: oracleorcl SQLPLUS> oradebug EVENT 10046 trace name context forever. * Oracle 10g has got further optimized incremental backup which has resulted in improvement of performance during backup and recovery time .3 and above): ORADEBUG HELP It looks like one can change memory locations with the ORADEBUG POKE command. image: ora_pmon_orcl SQLPLUS> oradebug procstat Statement processed. level 12 Statement processed.Execute the "ORADEBUG HELP" command from svrmgrl or sqlplus to obtain a list of valid ORADEBUG commands.trc SQLPLUS> REM List semaphores and shared memory segments in use SQLPLUS> oradebug ipc SQLPLUS> REM Dump Error Stack SQLPLUS> oradebug setospid <pid> SQLPLUS> oradebug event immediate trace name errorstack level 3 SQLPLUS> REM Dump Parallel Server DLM locks SQLPLUS> oradebug lkdebug -a convlock SQLPLUS> oradebug lkdebug -a convres SQLPLUS> oradebug lkdebug -r <resource handle> (i. Unix process pid: 10121.

. RECOVERY CATALOG Recovery catalog is optional otherwise backup details are stored in target database controlfile . A backup set would contain many backup pieces. Backups in RMAN Oracle backups in RMAN are of the following type RMAN complete backup OR RMAN incremental backup These backups are of RMAN proprietary nature IMAGE COPY The advantage of uing Image copy is its not in RMAN proprietary format.. Backup sets are logical entity In oracle 9i it gets stored in a default location There are two type of backup sets Datafile backup sets.Shutdowns the database startup mount . Archivelog backup sets One more important point of data file backup sets is it do not include empty blocks.. A single backup piece consists of physical files which are in RMAN proprietary format.backup sets and pieces Recovery catalog is a must in following scenarios . For tablespace point in time recovery Media Management Software Media Management software is a must if you are using RMAN for storing backup in tape drive directly. Example of taking backup using RMAN Taking RMAN Backup In non archive mode in dos prompt type RMAN You get the RMAN prompt RMAN > Connect Target Connect to target database : Magic using target database controlfile instead of recovery catalog Lets take a simple backup of database in non archive mode shutdown immediate .* Parallel operations are supported * Better querying facility for knowing different details of backup * No extra redo generated when backup is taken.compared to online * backup without RMAN which results in saving of space in hard disk * RMAN an intelligent tool * Maintains repository of backup metadata * Remembers backup set location * Knows what need to backed up * Knows what is required for recovery * Knows what backups are redundant UNDERSTANDING THE RMAN ARCHITECTURE An oracle RMAN comprises of RMAN EXECUTABLE This could be present and fired even through client side TARGET DATABASE This is the database which needs to be backed up .. It is a repository of information queried and updated by Recovery Manager It is a schema or user stored in Oracle database. One schema can support many databases It contains information about physical schema of target database datafile and archive log . Oracle backup comprises of backup sets and it consists of backup pieces. Backup Format RMAN backup is not in oracle format but in RMAN format. In order to store scripts .

These automatic allocations and options can be overridden by commands in a RMAN command file. RMAN has become intelligent to identify which datafiles has to be restored and the location of backuped up file. We even dont need to bring the data file offline. after every backup or copy command. Many dba are taking oracle database backup inside the hard disk itself since it results in lesser mean time between recoverability. in addition.backup database . Binary compression technique reduces backup space usage by 50-75%.This will results in faster backups lesser space consumption and also reduces the time needed for daily backups Incrementally Updated Backups Oracle database 10g Incrementally Updates Backup features merges the image copy of a datafile with RMAN incremental backup. With the new DURATION option for the RMAN BACKUP command. Controlfile Auto backups Through this new feature RMAN will automatically perform a controlfile auto backup. Block Media Recovery If we can restore a few blocks rather than an entire file we only need few blocks. We can fire the same command in archive log mode And whole of datafiles will be backed Backup database plus archivelog. This results in faster recovery. Oracle Enhancement for RMAN in 10 G Flash Recovery Area Right now the price of hard disk is falling. parallelism .. The resulting image copy is now updated with block changes captured by incremental backups. It is just Restore database. DBAs can optionally specify whether backups should minimize time or system load. By specifying a duration. Restoring database Restoring database has been made very simple in 9i . RMAN will automatically calculate the appropriate backup rate.The merging of the image copy and incremental backup is initiated with RMAN recover command. . backup sets and image copy Oracle 9i New features Persistent RMAN Configuration A new configure command has been introduced in Oracle 9i . that lets you configure various features including automatic channels.its start backing the database alter database open. etc.backup options. The new parameter introduced is DB_RECOVERY_ FILE_DEST = /oracle/flash_ recovery_ area By configuring the RMAN RETENTION POLICY the flash recovery area will automatically delete obsolete backups and archive logs that are no longer required based on that configuration Oracle has introduced new features in incremental backup Change Tracking File Oracle 10g has the facility to deliver faster incrementals with the implementation of changed tracking file feature.. DBAs can weigh backup performance against system service level requirements. New Features in Oem to identify RMAN related backup like backup pieces.

The command for this is as follows Configure backup optimization on Archive Log failover If RMAN cannot read a block in an archived log from a destination. Similar syntax is supported for restores backup device sbt backup set all Copy a disk backup to tape (backing up a backup Additionally it supports . Import. Parallel operation supported . SQL*Plus commands etc. What are the pre requisites ? . Observation Introduced in Oracle 8 it has become more powerful and simpler with newer version of Oracle 9 and 10 g. Now with 9i backup optimization parameter we can prevent repeat backup of read only tablespace and archive log. Extensive reporting available . If you changed the location of backup set it is compulsory for you to register it using RMAN or while you are trying to restore backup It resulted in hanging situations There is no method to know whether during recovery database restore is going to fail because of missing archive log file. It also gives you the flexibility of scheduling custom jobs written with the TCL language. Configure Backup Optimization Prior to 9i whenever we backed up database using RMAN our backup also used take backup of read only table spaces which had already been backed up and also the same with archive log too. run sql scripts. Backup of server parameter file . run OS commands. Scripting . Backup archive logs Pitfalls of using RMAN Previous to version Oracle 9i backups were not that easy which means you had to allocate a channel compulsorily to take backup You had to give a run etc .. Corrupt block detection . Duplex backup sets . Compulsory Media Management only if using tape backup Incremental backups though used to consume less space used to be slower since it used to read the entire database to find the changed blocks and also They have difficult time streaming the tape device. What kind of jobs can one schedule with OEM? (for DBA OEM comes with pre-defined jobs like Export.Syntax for it as follows Block Recover datafile 8 block 22. So if you really don't want to miss something critical please start using RMAN. Considerable improvement has been made in 10g to optimize the algorithm to handle changed block. 855. The syntax was a bit complex …RMAN has now become very simple and easy to use. . RMAN automatically attempts to read from an alternate location this is called as archive log failover There are additional commands like backup database not backed up since time '31-jan-2002 14:00:00' Do not backup previously backed up files (say a previous backup failed and you want to restart from where it left off). 854.

ora.1 and below: lsnrctl dbsnmp_start lsnrctl dbsnmp_status On Windows NT.I. . the table must be empty. How does one start the Oracle Intelligent Agent? (for DBA One needs to start an OIA (Oracle Intelligent Agent) process on all machines that will to be managed via OEM. to modify data type of a column ? ii. If the agent doesn't want to start. . to add a column with NOT NULL constrain. ensure your environment variables are set correctly and delete the following files before trying again: 1) In $ORACLE_HOME/ network/admin: snmp_ro. 859. Net8 Listeners. etc. 856. For OEM 9i and above: agentctl start agent agentctl stop agent For OEM 2. 2) Also delete ALL files in $ORACLE_HOME/ network/agent/ . Select test "Unsolicited Event". enter values similar to these: Event Name: /oracle/script/ myalert Object: * Severity: * Message: * One can now write the script and invoke the oemevent command to send alerts to the console. to add a column with NOT NULL constraint ? To Modify the datatype of a column the column must be empty. Executing tasks associated with jobs submitted to Enterprise Manager. How does one backout events and jobs during maintenance slots? (for DBA Managemnet and data collection activity can be suspended by imposing a blackout. Monitoring of events registered in Enterprise Manager. What is the Oracle Intelligent Agent? (for DBA The Oracle Intelligent Agent (OIA) is an autonomous process that needs to run on a remote node in the network to make the node OEM manageable. Look at this example: oemevent /oracle/script/ myalert DESTINATION alert "My custom error message" where DESTINATION is the same value as entered in the "Monitored Destinations" field when you've registered the event in the OEM Console.). Can one write scripts to send alert messages to the console? Start the OEM console and create a new event. Select option "Enable Unsolicited Event". When entering the parameters. start the "OracleAgent" Service.ora and snmp_rw. Discovering targets that can be managed (Database Servers. The Oracle Intelligent Agent is responsible for: . Look at these examples: agentctl start blackout # Blackout the entrire agent agentctl stop blackout # Resume normal monitoring and management agentctl start blackout ORCL # Blackout database ORCL agentctl stop blackout ORCL # Resume normal monitoring and management agentctl start blackout -s jobs -d 00:20 # Blackout jobs for 20 minutes 858. and .

Etc.OCX . It is a bad practice to create the repository with SYS and System. Check with Oracle for any available patches. What is import/export and why does one need it? (for DBA The Oracle export (EXP) and import (IMP) utilities are used to perform logical database backup and recovery. SNMP_RW. Ensure that all the data can be read. 862.ora. Sometimes you get a Failed status for the job that was executed successfully. Ensure OCX files are registered.0.4 is buggy.Oratcl was originally written by Tom Poindexter 861. Backup and recovery (small databases only) . For example. OraTCL at Sourceforge . using command line parameters. The Tcl Developer Xchange . Create the OEM repository with a user (which will manage the OEM) and store it in a tablespace that does not share any data with other database users. Reorganization of data/ Eliminate database fragmentation . read the SQL*Loader FAQ. The export/import utilities are also commonly used to perform the following tasks: . Solution B: Your version of Intelligent Agent could be buggy.860.Q Files ($Oracle_home/ network/agent folder) Backup and delete SNMP_RO. For more information on how to load and unload data from files. Check the log to see the results of the execution rather than relying on this status. database or schema to another. Are there any troubleshooting tips for OEM? (for DBA . or using parameter files. One can run them interactively. Look at the imp/exp parameters before starting. They are also used to move Oracle data from one machine. If you have a problem starting the Oracle Agent Solution A: Backup the *.dmp full=yes . .download and learn about TCL . Detect database corruption. One cannot export data and expect to import it into a non-Oracle database. If you are unable to launch the console or there is a communication problem with the intelligent agent (daemon). Type the following in the DOS prompt (the current directory should be $ORACLE_HOME\ BIN: C:\Orawin95\ Bin> RegSvr32 mmdx32.ora. .Q files and Delete all the *.ver and services. dept) imp scott/tiger file=emp. Transporting tablespaces between databases . Check the following sites for more information about TCL: .log tables=emp rows=yes indexes=no exp scott/tiger file=emp. The following examples demonstrate how the imp/exp utilities can be used: exp scott/tiger file=emp. 867.dmp log=emp.dmp tables=(emp. These parameters can be listed by executing the following commands: "exp help=yes" or "imp help=yes". Tom Poindexter's Tcl Page . dbsnmp. The imp/exp utilities use an Oracle proprietary binary file format and can thus only be used between Oracle databases. the Intelligent Agent that comes with Oracle 8.OCX C:\Orawin95\ Bin> RegSvr32 vojt.Download the OraTCL package .ora files ($Oracle_Home/ network/admin folder) Start the Oracle Agent service. Where can one get more information about TCL? (for DBA One can write custom event checking routines for OEM using the TCL (Tool Command Language) language. How does one use the import/export utilities? (for DBA Look for the "imp" and "exp" executables in your $ORACLE_HOME/ bin directory.

As.txt contains: BUFFER=100000 FILE=account.30) table_name.'INTO "'). Argentina. Can one export a subset of a table? (for DBA From Oracle8i one can use the QUERY= export parameter to selectively unload a subset of the data from a table.. Contributed by Osvaldo Ancarola. For this to work one needs to be on Oracle 7. where export. 'yyyy-mm. .dmp fromuser=scott touser=scott tables=dept exp userid=scott/ tiger@orcl parfile=export. dmp FULL=n OWNER=scott GRANTS=y COMPRESS=y NOTE: If you do not like command line utilities. What are the two ways to incorporate images into a oracle forms application? Boilerplate Images Image_items 871. Look at this example: exp scott/tiger tables=emp query=###BOT_TEXT###quot;where deptno=10###BOT_TEXT###quot; 870. 'yyyy-mm.3 or higher (7. you can import and export data with the "Schema Manager" GUI that ships with Oracle Enterprise Manager (OEM). trunc(rows_processe d/((sysdate. If the import has more than one table. round((sysdate.to_date(first_ load_time. Window 869. Bs.to_date(first_ load_time. Can one monitor how fast a table is imported? (for DBA If you need to monitor how fast rows are imported from a running import job. Method 2: Use the FEEDBACK=n import parameter.. try one of the following methods: Method 1: select substr(sql_text. What are the types of visual attribute settings? Custom Visual attributes Default visual attributes Named Visual attributes. txt .2 might also be OK).imp scott/tiger file=emp. instr(sql_ text. this statement will only show information about the current table being imported.dd hh24:mi:ss') )*24*60.1) minutes. 868. rows_processed.dd hh24:mi:ss') )*24*60)) rows_per_min from sys. This command will tell IMP to display a dot for every N rows imported.v_$sqlarea where sql_text like 'INSERT %INTO "%' and command_type = 2 and open_versions > 0.

this will create the required tables in the appropriate tablespaces . but comes with more options. sal. Import the table(s) with the IGNORE=Y option.csv file may look like this: 10001." optionally enclosed by '"' ( empno. How does one use the SQL*Loader utility? (for DBA One can load data into an Oracle database by using the sqlldr (sqlload on some platforms) utility. deptname position (08:27) char(20) ) begindata COSC COMPUTER SCIENCE ENGL ENGLISH LITERATURE MATH MATHEMATICS POLY POLITICAL SCIENCE .ctl) will load an external data file containing delimited data: load data infile 'c:\data\mydata."Frank Naude". 876. Import the table 875. 40 10002. Its syntax is similar to that of the DB2 Load utility. This forces the import utility to create tables in the user's default tablespace. 1000. Run this indexfile against your database. empname."Scott Tiger". . Import the dump file using the INDEXFILE= option . SQL*Loader supports various load formats. ctl This sample control file (loader. What is SQL*Loader and what is it used for? (for DBA SQL*Loader is a bulk loader utility used for moving data from external files into the Oracle database. Remove remarks and specify the correct tablespaces. selective loading. One can alter this behaviour by following one of these procedures: Pre-create the table(s) in the correct tablespace: . csv' into table emp fields terminated by ". 20 Another Sample control file with in-line data formatted as fix length records. load data infile * replace into table departments ( dept position (02:05) char(4). deptno ) The mydata. and multi-table loads. 500. Change the default tablespace for the user: . and use BEGINDATA to start the data section in the control file. Make the tablespace to which you want to import the default tablespace for the user . Look at the following example: sqlldr scott/tiger control=loader. . Edit the indexfile. The trick is to specify "*" as the name of the data file. Invoke the utility without arguments to get a list of available parameters. Objects will be re-created in the tablespace they were originally exported from. Revoke the user's quota from the tablespace from where the object was exported.872. Can one import tables to a different tablespace? (for DBA Oracle offers no parameter to specify a different tablespace to import data into. Revoke the "UNLIMITED TABLESPACE" privilege from the user .

D. %s\n'."A. / You might also want to investigate third party tools like SQLWays from Ispirer Systems." OPTIONALLY ENCLOSED BY '"' TRAILING NULLCOLS ( data1. data2 ) BEGINDATA 11111. end.'tab1. utl_file. you can use SQL*Plus to select and format your data and then spool it to a file: set echo off newpage 0 space 0 pagesize 0 feed off head off trimspool on spool oradata. Look at this example: LOAD DATA INFILE * INTO TABLE load_positional_ data SKIP 5 ( data1 POSITION(1:5) .AAAAAAAAAA 22222.putf( fp. or ManageIT Fast Unloader from CA to help you unload data from Oracle.fopen( 'c:\oradata' . 55). utl_file_dir= 'c:\oradata' parameter declare fp utl_file. Is there a SQL*Unloader to download data to a flat file? (for DBA Oracle does not supply any data unload utilities.fclose( fp). look at the following control file example: LOAD DATA INFILE * INTO TABLE load_positional_ data ( data1 POSITION(1:5) . TOAD from Quest.'w'). '%s.B. In the first we will load delimited data (variable length): LOAD DATA INFILE * INTO TABLE load_delimited_ data FIELDS TERMINATED BY ".file_ type. look at the following control file examples. begin fp := utl_file. However. where n = number of logical rows to skip. data2 POSITION(6:15) ) BEGINDATA 11111AAAAAAAAAA 22222BBBBBBBBBB Can one skip header records load while loading? Use the "SKIP n" keyword.C.878.' || col2 || '. utl_file. spool off Alternatively use the UTL_FILE PL/SQL package: rem Remember to update initSID. 'TextField'.txt select col1 || '. 879.txt' . Can one load variable and fix length data records? (for DBA Yes.' || col3 from tab1 where col2 = 'XYZ'. ." If you need to load positional data (fixed length).ora.

mgr POSITION(20: 23) INTEGER EXTERNAL ) INTO TABLE proj . deptno POSITION(17: 18) CHAR. null. ename POSITION(6:15) CHAR. region CONSTANT '31'.data2 POSITION(6:15) ) BEGINDATA 11111AAAAAAAAAA 22222BBBBBBBBBB 880. city. Note that this only applies for the conventional load path and not for direct path loads. :mailing_addr)". mailing_state ) 881. null. state." ( addr.Can one load data into multiple tables at once? (for DBA Look at the following control file: LOAD DATA INFILE * REPLACE INTO TABLE emp WHEN empno != ' ' ( empno POSITION(1:4) INTEGER EXTERNAL. time_loaded "to_char(SYSDATE. data1 POSITION(1:5) ":data1/100". mailing_city "decode(:mailing_ city. mailing_addr "decode(:mailing_ addr. zipcode. :addr. 'YYMMDD')" ) BEGINDATA 11111AAAAAAAAAA9912 01 22222BBBBBBBBBB9901 12 LOAD DATA INFILE 'mail_orders. :city. data3 POSITION(16: 22)"to_date(:data3. data2 POSITION(6:15) "upper(:data2)". :mailing_city)". Can one modify data as it loads into the database? (for DBA Data can be modified as it loads into the Oracle Database. LOAD DATA INFILE * INTO TABLE modified_data ( rec_no "my_db_sequence. 'HH24:MI')". nextval". txt' BADFILE 'bad_orders. txt' APPEND INTO TABLE mailing_list FIELDS TERMINATED BY ".

Can one skip certain columns while loading data? (for DBA One cannot use POSTION(x:y) with delimited data.WHEN projno != ' ' ( projno POSITION(25: 27) INTEGER EXTERNAL. --> LOAD DATA TRUNCATE INTO TABLE T1 FIELDS TERMINATED BY '. FILLER columns are used to skip columns/fields in the load file.dis' APPEND INTO TABLE my_selective_ table WHEN (01) <> 'H' and (01) <> 'T' and (30:37) = '19991217' ( region CONSTANT '31'. Can one selectively load only the records that one need? (for DBA Look at this example. Eg. 890. Luckily. not in column X. CONTINUEIF . field2 FILLER. (30:37) are characters 30 to 37: LOAD DATA INFILE 'mydata. Make sure you have big rollback segments ready when you use a high value for ROWS=. How does one load multi-line records? (for DBA One can create one logical record from multiple physical records using one of the following two clauses: . How can get SQL*Loader to COMMIT only at the end of the load file? (for DBA One cannot. . ignoring fields that one does not want. but by setting the ROWS= parameter to a large value. from Oracle 8i one can specify FILLER columns. CONCATENATE: . committing can be reduced. Can one improve the performance of SQL*Loader? (for DBA . there are no positional fields-the next field begins after some delimiter.use when SQL*Loader should combine the same number of physical records together to form one logical record. call_b_no POSITION(12: 29) CHAR ) 886.dat' BADFILE 'mydata. field3 ) 887.bad' DISCARDFILE 'mydata.' ( field1. 889.use if a condition indicates that multiple records should be treated as one. by having a '#' character in column 1. (01) is the first character. empno POSITION(1:4) INTEGER EXTERNAL ) 885. Look at this example: -.One cannot use POSTION(x:y) as it is stream data. service_key POSITION(01: 11) INTEGER EXTERNAL.

images and audio clips into BLOB and CLOB columns. The direct path loader (DIRECT=TRUE) bypasses much of the logic involved with that. Add the following option in the command line: DIRECT=TRUE. and loads directly into the Oracle data files. image_data LOBFILE (file_name) TERMINATED BY EOF ) BEGINDATA 001. sound clips and documents? (for DBA SQL*Loader can load data from a "primary data file". image_data BLOB). Tablespaces. More information about the restrictions of direct path loading can be obtained from the Utilities Users Guide. Views. This option can only be used with direct data loads. file_name VARCHAR2(30) .image2. SDF (Secondary Data file . This will significantly slow down load times even with ROWS= set to a high value. This will effectively bypass most of the RDBMS processing. .gif 002. Redo Log files. How does one use SQL*Loader to load images.A very simple but easily overlooked hint is not to have any indexes and/or constraints (primary key) on your load tables during the load process.Describe Oracle database's physical and logical structure ? Physical : Data files. However.for loading nested tables and VARRAYs) or LOGFILE. Turn off database logging by specifying the UNRECOVERABLE option. 24.Can you increase the size of a tablespace ? How ? Yes.image1. What is the difference between the conventional and direct path loader? (for DBA The conventional path loader essentially loads the data by using standard INSERT statements. Look at this example: Given the following table: CREATE TABLE image_table ( image_id NUMBER(5). Refer to chapter 8 on Oracle server Utilities manual. 23. file_name CHAR(30). 891. Control file. Run multiple load jobs concurrently. The LOBFILE method provides and easy way to load documents. etc. there are cases when you can't use direct load. Control File: LOAD DATA INFILE * INTO TABLE image_table REPLACE FIELDS TERMINATED BY '. by adding datafiles to it.' ( image_id INTEGER(5). Logical : Tables.jpg 892.

redo log files. running on more than 100 hardware platforms and 20 networking protocols.26. Market Presence : Oracle is by far the largest RDBMS vendor and spends more on R & D than most of its competitors earn in total revenue. Tablespaces.What is the use of Data Dictionary ? Used by Oracle to store information about various physical and logical Oracle structures e. etc 28. etc.g. You can also do point-in-time recovery. 80. Tables. datafiles.What are the advantages of clusters ? Access time reduced for joins. Backup and Recovery : Oracle provides industrial strength support for on-line backup and recovery and good software fault tolerence to disk failure.What is the use of Control files ? Contains pointers to locations of various data files. 27. Performance : Speed of a 'tuned' Oracle Database and application is quite good. even with large databases. Multiple database support : Oracle has a superior ability to manage multiple databases within the same transaction using a two-phase commit protocol. Oracle can manage > 100GB databases. .What are the advantages of Oracle ? Portability : Oracle is ported to more platforms than any of its competitors. This market clout means that you are unlikely to be left in the lurch by Oracle and there are always lots of third party interfaces available.