13.07.2015 Views

CA ERwin Model Manager Implementation Guide

CA ERwin Model Manager Implementation Guide

CA ERwin Model Manager Implementation Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>CA</strong> <strong>ERwin</strong> ® <strong>Model</strong> <strong>Manager</strong><strong>Implementation</strong> <strong>Guide</strong>r7.3r7.3.4 SP1 Edition


This documentation and any related computer software help programs (hereinafter referred to as the“Documentation”) is for the end user‟s informational purposes only and is subject to change or withdrawal by <strong>CA</strong> atany time.This Documentation may not be copied, transferred, reproduced, disclosed, modified or duplicated, in whole or inpart, without the prior written consent of <strong>CA</strong>. This Documentation is confidential and proprietary information of <strong>CA</strong>and protected by the copyright laws of the United States and international treaties.Notwithstanding the foregoing, licensed users may print a reasonable number of copies of the Documentation fortheir own internal use, and may make one copy of the related software as reasonably required for back-up anddisaster recovery purposes, provided that all <strong>CA</strong> copyright notices and legends are affixed to each reproduced copy.Only authorized employees, consultants, or agents of the user who are bound by the provisions of the license forthe Product are permitted to have access to such copies.The right to print copies of the Documentation and to make a copy of the related software is limited to the periodduring which the applicable license for the Product remains in full force and effect. Should the license terminate forany reason, it shall be the user‟s responsibility to certify in writing to <strong>CA</strong> that all copies and partial copies of theDocumentation have been returned to <strong>CA</strong> or destroyed.EXCEPT AS OTHERWISE STATED IN THE APPLI<strong>CA</strong>BLE LICENSE AGREEMENT, TO THE EXTENT PERMITTED BYAPPLI<strong>CA</strong>BLE LAW, <strong>CA</strong> PROVIDES THIS DOCUMENTATION “AS IS” WITHOUT WARRANTY OF ANY KIND, INCLUDINGWITHOUT LIMITATION, ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSEOR NONINFRINGEMENT. IN NO EVENT WILL <strong>CA</strong> BE LIABLE TO THE END USER OR ANY THIRD PARTY FOR ANY LOSSOR DAMAGE, DIRECT OR INDIRECT, FROM THE USE OF THIS DOCUMENTATION, INCLUDING WITHOUTLIMITATION, LOST PROFITS, BUSINESS INTERRUPTION, GOODWILL, OR LOST DATA, EVEN IF <strong>CA</strong> IS EXPRESSLYADVISED OF SUCH LOSS OR DAMAGE.The use of any product referenced in the Documentation is governed by the end user‟s applicable licenseagreement.The manufacturer of this Documentation is <strong>CA</strong>.Provided with “Restricted Rights.” Use, duplication or disclosure by the United States Government is subject to therestrictions set forth in FAR Sections 12.212, 52.227-14, and 52.227-19(c)(1) - (2) and DFARS Section252.227-7014(b)(3), as applicable, or their successors.All trademarks, trade names, service marks, and logos referenced herein belong to their respective companies.Copyright © 2009 <strong>CA</strong>. All rights reserved.


<strong>CA</strong> Product ReferencesThis document references the following <strong>CA</strong> products:■■■■<strong>CA</strong> <strong>ERwin</strong> ® <strong>Model</strong> <strong>Manager</strong> (<strong>CA</strong> <strong>ERwin</strong> MM)<strong>CA</strong> <strong>ERwin</strong> ® Data <strong>Model</strong>er (<strong>CA</strong> <strong>ERwin</strong> DM)<strong>CA</strong> <strong>ERwin</strong> ® Process <strong>Model</strong>er (<strong>CA</strong> <strong>ERwin</strong> PM)<strong>CA</strong> <strong>ERwin</strong> ® <strong>Model</strong> Navigator (<strong>CA</strong> <strong>ERwin</strong> MN)Contact <strong>CA</strong>Contact Technical SupportFor your convenience, <strong>CA</strong> provides one site where you can access theinformation you need for your Home Office, Small Business, and Enterprise <strong>CA</strong>products. At http://ca.com/support, you can access the following:■■■■■Online and telephone contact information for technical assistance andcustomer servicesInformation about user communities and forumsProduct and documentation downloads<strong>CA</strong> Support policies and guidelinesOther helpful resources appropriate for your productProvide FeedbackIf you have comments or questions about <strong>CA</strong> product documentation, you cansend a message to techpubs@ca.com.If you would like to provide feedback about <strong>CA</strong> product documentation,complete our short customer survey, which is also available on the <strong>CA</strong> Supportwebsite, found at http://ca.com/docs.


Documentation ChangesThe following documentation updates have been made since the last release ofthis documentation (r7.3 GA):■r7.3.4 SP1 edition. Topics were updated to reflect changes in securityrequirement for SQL Server 2005/2008. The DBO user is no longerrequired to have the sysadmin role.


ContentsChapter 1: <strong>Model</strong>ing in the Multi-User Environment 9<strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> ....................................................................... 9<strong>Model</strong> Life Cycle Frameworks .................................................................. 11<strong>Model</strong>-Driven Development Framework ..................................................... 11System-Driven <strong>Model</strong> Framework .......................................................... 12Informational <strong>Model</strong> Framework ............................................................ 12Business Process <strong>Model</strong> Framework ........................................................ 13Chapter 2: Installation and Configuration 15Prepare for the Installation .................................................................... 15Specify Use of Foreign Characters With Microsoft SQL Server 2000 ........................... 16Specify Use of Foreign Characters With Microsoft SQL Server 2005 ........................... 16How to Prepare Your DBMS Environment ....................................................... 17Tasks to Create a Microsoft SQL Server DBMS .............................................. 18Tasks to Create a Sybase DBMS............................................................ 19Transact SQL Commands .................................................................. 21Tasks to Create an Oracle DBMS ........................................................... 22<strong>CA</strong> <strong>ERwin</strong> MM Mart Creation Requirements .................................................. 27Server Connection Software ............................................................... 28Connection Prerequisites .................................................................. 28Install the Administrative Files ................................................................. 29License <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> .............................................................. 30Refresh the Mart After Upgrading Your License .................................................. 31Create the <strong>CA</strong> <strong>ERwin</strong> MM Mart ................................................................. 32Chapter 3: Upgrade 37Software Upgrades ............................................................................ 37Conversion Process ........................................................................... 38Property Conversion ....................................................................... 38<strong>Model</strong> Property Conversion ................................................................ 38Conversion Methods ....................................................................... 39How to Upgrade the Mart ...................................................................... 40Microsoft SQL Server or Sybase DBMS Upgrade Considerations .............................. 41Oracle DBMS Upgrade Considerations ...................................................... 41<strong>CA</strong> <strong>ERwin</strong> MM 4.1.4 to <strong>CA</strong> <strong>ERwin</strong> MM r7.3 Conversion ........................................ 41Install the Software Upgrade .................................................................. 42Contents 5


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM Mart ........................................................ 43Appendix A: Microsoft SQL and Sybase Server Tuning Recommendations 49Physical Tuning Parameters ................................................................... 49Hardware Configurations .................................................................. 49Database Placement....................................................................... 50Data Redundancy ......................................................................... 50Server-Level Tuning Parameters ............................................................... 50Named Cache Configuration ................................................................... 51Database Tuning Parameters .................................................................. 51Transaction Log ........................................................................... 51Threshold Procedures ..................................................................... 52"trunc. log on chkpt" Option ............................................................... 52Database and Log Sizing ...................................................................... 53How to Maintain an Efficient Database .......................................................... 53Nightly Maintenance Script ................................................................ 54DBCC Commands ......................................................................... 55Appendix B: Oracle Tuning Recommendations 57Recommended Disk Configurations ............................................................. 57Database Configuration ....................................................................... 58Maximum Number of Processes ............................................................ 58Shared Pool .............................................................................. 58Buffer Cache .............................................................................. 59Redo Log Files ............................................................................ 59Increase Space in Redo Logs ............................................................... 60Redo Log Buffer ........................................................................... 62Checkpoints .............................................................................. 63Turn on the Optimizer Mode ............................................................... 63Storage Parameters ........................................................................... 64Rollback Segments ........................................................................ 64Set Optimal Configuration for the Rollback Logs ............................................. 65Tablespaces .............................................................................. 67Appendix C: <strong>CA</strong> <strong>ERwin</strong> MM Performance 69Optimize Your <strong>CA</strong> <strong>ERwin</strong> MM Performance ...................................................... 69Reindex the Database ......................................................................... 70Run the Oracle DBMS Reindex Script ....................................................... 71Example: Oracle DBMS Reindex Script ...................................................... 72Example: Microsoft SQL Server DBMS Reindex Script ........................................ 73Example: Sybase DBMS Reindex Script ..................................................... 746 <strong>Implementation</strong> <strong>Guide</strong>


Troubleshooting the Reindexing Script ...................................................... 75Run the Database Statistics ................................................................... 75Example: Statistics Commands (Oracle) .................................................... 75Example: Statistics Script (MS SQL Server) ................................................. 76Index 77Contents 7


Chapter 1: <strong>Model</strong>ing in the Multi-UserEnvironment<strong>CA</strong> <strong>ERwin</strong> MM coordinates the development and management of modelscreated with <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er.This section contains the following topics:<strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> (see page 9)<strong>Model</strong> Life Cycle Frameworks (see page 11)<strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong><strong>CA</strong> <strong>ERwin</strong> MM provides a multiuser modeling environment that makescoordinated, large-scale modeling possible. It enables collaboration amongproject managers, data modeling team members, process modeling teammembers, and standards administrators by providing workgroup modelingservices, including conflict resolution, versioning, security, and standardsmanagement. You can coordinate the efforts of model teams to documentexisting systems, create new eBusiness systems, and drive datastandardization. <strong>Model</strong> sharing encourages teamwork, so modelers can worktogether more efficiently to optimize model-based development. Your modelersget more work done in less time with better results.Workgroup modeling operates in a client/server environment so processing isshared between the user client workstation and the server where the modelsare stored. Users access the stored models through one of the clients-<strong>CA</strong><strong>ERwin</strong> Data <strong>Model</strong>er or <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er. <strong>Model</strong>s are held in aplatform and network independent database or mart that resides on a centralserver, using Microsoft SQL Server, Oracle, or Sybase as the host database.Chapter 1: <strong>Model</strong>ing in the Multi-User Environment 9


<strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong>The following diagram shows a typical <strong>CA</strong> <strong>ERwin</strong> MM environment:Workgroup modeling features are provided to help control updates to modelswhen you are opening, closing, and saving models. The administrator installsthe program and initializes the database on the DBMS server. Theadministrator also has the responsibility of setting up the library structure inwhich models are organized, and assigning security profiles to users.Administration overhead is relatively low and proportional to the number andactivity level of the users. After a model is saved to the database, control ofwho can work on the model and how changes are saved to the model ishandled by security, making it possible for workgroups to work on largemodels without confusion. <strong>CA</strong> <strong>ERwin</strong> MM supports many security andadministrative features related to its multiuser capabilities and theclient/server environment in which it operates. For this reason, routinemanagement is usually performed by a dedicated administrator. Administratorscan find detailed information regarding their tasks and responsibilities in theAdministration <strong>Guide</strong>.You can also use <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> Navigator as a client. Read-only access ispermitted to data models and process models, so your workgroup can use <strong>CA</strong><strong>ERwin</strong> <strong>Model</strong> Navigator to share information with others without the risk thatunauthorized changes might be saved to the mart. Additionally, you canconnect to the mart through the Naming Standards Editor or the DatatypeStandards Editor.10 <strong>Implementation</strong> <strong>Guide</strong>


<strong>Model</strong> Life Cycle Frameworks<strong>Model</strong> Life Cycle FrameworksUse one of the following model life cycle frameworks in your organization:<strong>Model</strong>-Driven DevelopmentChanges to the schema are made to the model first and then forwardengineered.System-Driven <strong>Model</strong>sChanges are made directly to the schema and the schema isreverse-engineered into the model to reflect the changes.Informational <strong>Model</strong>sContains logical-only models, enterprise-wide models, or standards andsample models.Business Process <strong>Model</strong>sContains models generated by <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er.Each type of framework has different considerations that you must think aboutwhen configuring your database and developing its supporting policies. You arenot required to choose a particular framework, however, it helps to know yourdevelopment process before building a library structure.<strong>Model</strong>-Driven Development FrameworkIn the model-driven framework, the model is always the source of all changes.You create a new database schema by forward engineering the model. The lifecycle of a model in the model-driven Development framework can follow apath like this:■■■■■■■■■Create the library structure (for example, Development, Test, andProduction) and populate them with <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er templates.Create the logical model in a development library.Promote the model to the test library when it is ready.Generate the schema from the test library.Modify the test model as required and synchronize it to the schema.Promote the model to the production library when it is ready.Publish the refreshed production model.Update the enterprise-wide model, if necessary.Incorporate changes into the development model for further changes, andrepeat the process.Chapter 1: <strong>Model</strong>ing in the Multi-User Environment 11


<strong>Model</strong> Life Cycle FrameworksSystem-Driven <strong>Model</strong> FrameworkIn the system-driven framework, there is an established information systemfrom which you can reverse engineer database tables. The life cycle of a modelin the system-driven Development framework can follow a path like this:■■■■■■■■Create the library structure (for example, Reverse Eng, Test, Production).You should not require <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er templates because you donot create models from scratch.Reverse engineer the model from the information system into thedesignated library.Enhance the model with logical information and input from analysts.Update the model to reflect changes in the physical schema.Create a version of the model.Synchronize the schema and the model using Complete Compare.Publish the model.Repeat the last three steps as the system is modified.Informational <strong>Model</strong> FrameworkIn the Informational <strong>Model</strong> framework, <strong>CA</strong> <strong>ERwin</strong> MM contains <strong>CA</strong> <strong>ERwin</strong> Data<strong>Model</strong>er logical-only models, enterprise-wide models, or standards and samplemodels. There is no forward engineering with the intent of using the schema.The life cycle of a model in the Informational <strong>Model</strong> framework can follow apath like this:■■■■■■Create the library structure and populate them with <strong>CA</strong> <strong>ERwin</strong> Data<strong>Model</strong>er templates.Develop the initial model. Use reverse engineering and model newcomponents as required.Publish the initial model to the appropriate parties for modification andrefinement.Get approval, and then version the model.Publish the approved model.Update and publish models as the enterprise model evolves.12 <strong>Implementation</strong> <strong>Guide</strong>


<strong>Model</strong> Life Cycle FrameworksBusiness Process <strong>Model</strong> FrameworkIn the Business Process <strong>Model</strong> framework, you use <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>erto design business process models that define business processes in yourorganization. You can optionally export entities and attributes to <strong>CA</strong> <strong>ERwin</strong>Data <strong>Model</strong>er to develop a model-driven information system that adheres tothe business process rules. The life cycle of a model in the Business Process<strong>Model</strong> framework can follow a path like this:■■■■■■■■Create a working version of an AS-IS model of selected subjects.Critique and analyze the model.Move the model through draft, recommended, and publication versions.Publish the model at the end of the cycle.Create working TO-BE models of the model from Step 4 that incorporatesmanagement‟s future vision.Update the model as changes and enhancements are approved and assupport systems are integrated into the models.Version the modified models based upon the approval of the changes andenhancements.Publish the revised models when each version becomes stable.Chapter 1: <strong>Model</strong>ing in the Multi-User Environment 13


Chapter 2: Installation andConfigurationThis section contains the following topics:Prepare for the Installation (see page 15)How to Prepare Your DBMS Environment (see page 17)Install the Administrative Files (see page 29)License <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> (see page 30)Refresh the Mart After Upgrading Your License (see page 31)Create the <strong>CA</strong> <strong>ERwin</strong> MM Mart (see page 32)Prepare for the InstallationReview the hardware and software requirements and the list of supporteddatabases in the Release Notes before you install the program. You must verifythat your system requirements meet at least the minimum specifiedrequirements, and that you have verified and prepared your DBMSenvironment for installation.Before you can install <strong>CA</strong> <strong>ERwin</strong> MM in your DBMS environment you must dothe following:1. Create the database on your DBMS server.2. Install the administrative files.3. Install or upgrade your license agreement permitting access the mart.4. Create the mart or upgrade your current version of software when a newerversion is available.Note: To create, update, or delete a mart you must have the followingdatabase rights:■■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBArole.If you installed an earlier version of <strong>CA</strong> <strong>ERwin</strong> MM (before release 7) it is notnecessary to remove that version. Because this version is installed to a newfolder, you can continue to work with the earlier version, if you have sufficientdisk space on your PC for both versions.Chapter 2: Installation and Configuration 15


Prepare for the InstallationSpecify Use of Foreign Characters With Microsoft SQL Server 2000For Microsoft SQL Server 2000, it is necessary to select specific settings in theClient Network Utility to have certain foreign language characters in yourmodels recognized.To specify the use of foreign characters with Microsoft SQL Server20001. Click Programs, Microsoft SQL Server, Client Network Utility on the Startmenu.The SQL Server Client Network Utility dialog opens.2. Select the following check boxes on the DB-Library Options tab:■■Automatic ANSI to OEM conversionUse international settingsClick OK.Your configuration is set to recognize foreign language characters in yourmodels.Specify Use of Foreign Characters With Microsoft SQL Server 2005For Microsoft SQL Server 2005, it is necessary to modify your registry settingsto have certain foreign language characters in your models recognized.To specify the use of foreign characters with Microsoft SQL Server20051. Click Run on the Start menu.The Run dialog opens.2. Enter regedit.The Registry Editor opens.3. Verify or Add the following registry entry:[HKEY_LO<strong>CA</strong>L_MACHINE\SOFTWARE\Microsoft\MSSQLServer\Client\DB-Lib]"AutoAnsiToOem"="ON""UseIntlSettings"="ON"Click File, Exit.Your configuration is set to recognize foreign language characters in yourmodels.16 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS EnvironmentHow to Prepare Your DBMS EnvironmentYou must perform the following setup tasks in your DBMS environment beforeyou can install and use the software:1. Install the DBMS.Install the DBMS on the server where you plan to store the mart. For moreinformation about memory and disk space requirements, see the systemrequirements for the supported versions of each DBMS (Microsoft SQLServer, Sybase, and Oracle).2. Create the mart.Use the DBMS features to create or identify the required storage objectsand the mart. The specific requirements vary depending on your DBMStype.3. Create a user profile for each <strong>CA</strong> <strong>ERwin</strong> MM user.Use the DBMS features to create a user profile for each <strong>CA</strong> <strong>ERwin</strong> MM userin the database where <strong>CA</strong> <strong>ERwin</strong> MM is stored.Note: Each user must have Windows authentication enabled (on databasesthat support Windows authentication) or a valid login name on the DBMSand permission to access the database in which the mart is stored. Formore information, see your DBMS administrator's documentation.4. Install the DBMS client software on each client workstation.To connect a client workstation to the DBMS server, you must install theappropriate client connection software (for example, SQL*Net) on eachworkstation. The connection software you use depends on your DBMStype.5. Verify the client/server connection.Use a test command (for example, ping) to check the client/serverconnection between each client workstation and the DBMS server.Alternatively, use another application on a client workstation (for example,ISQL/W, SQLPLUS, or PowerBuilder) to check the connection. For moreinformation about testing the client/server connection, see your DBMSdocumentation.6. Install a client on each client workstation.Install the client software using the CD-ROM that shipped with each client(<strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er or <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er). Then, any userwith a <strong>CA</strong> <strong>ERwin</strong> MM login and password and the appropriate DBMS clientconnection software can connect to the mart from that client workstation.Chapter 2: Installation and Configuration 17


How to Prepare Your DBMS EnvironmentTasks to Create a Microsoft SQL Server DBMSThe following tasks must be performed by the DBA and system administratorresponsible for installing <strong>CA</strong> <strong>ERwin</strong> MM on a Microsoft SQL Server DBMS:1. Use a graphical user interface (GUI) tool, ISQL (all versions), SQLAdministrator, or Enterprise <strong>Manager</strong> to create the <strong>CA</strong> <strong>ERwin</strong> MM database.If a GUI tool is not available, you can use ISQL to type in the appropriatecommands manually.Your database should meet the following criteria:■■■■The initial size of the database file should be set to 60 MB.The initial size of the transaction log file should be set to 50 MB.Set the maximum file size to unrestricted file growth for both files(recommended, but not required).Increase the Set Auto grow file by 10 percent (recommended, but notrequired).The new database is owned by the user who created it.Set the Truncate Log on Checkpoint option and have the server generatecheckpoints frequently. By selecting this option, the log is emptiedperiodically and should not fill up and cause rollbacks.Note: For best performance ensure that separate devices are used to storethe data and the transaction log.2. Add users.For users to access the mart you must either add existing logins as usersto the database or create new logins and add them as users of thedatabase. A login is an entity permitted to connect to the database server;a user gives a login the right to use a particular database. If you useWindows user names and passwords to secure database access (WindowsAuthentication), you must add the Windows users to your DBMS.3. Check tempdb size.Microsoft SQL Server ConnectionsSignificant temporary space is required for installation and use. Thetemporary segments need at least 16 MB of available space. You shouldalso increase available space as the number of concurrent users increase.If you are using a Microsoft SQL Server as your host DBMS, <strong>CA</strong> <strong>ERwin</strong> MM usesDB_LIBRARY to connect.18 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS EnvironmentMicrosoft SQL Server 2005 PermissionsFor SQL Server 2000, you only need the public permission assigned to save tothe mart. However, when the repository is on an SQL Server 2005 instance,you must have the bulkadmin permission designated as well. The ability to dobulk inserts (which was permitted by the public permission, previously) is nolonger part of the public permission. As the administrator, you must explicitlydefine this permission or when you attempt to save a model to a new martcreated using a SQL Server 2005 database, an error "You do not havepermission to use the bulk load statement." is returned.Tasks to Create a Sybase DBMSThe following tasks must be performed by the DBA and system administratorresponsible for installing the software on a Sybase database managementsystem. Information provided in this section includes installation and Sybaseconnectivity software requirements.1. Use a graphical user interface (GUI) tool, ISQL (all versions), SQLAdministrator, Sybase Central Java, or Enterprise <strong>Manager</strong> to create the<strong>CA</strong> <strong>ERwin</strong> MM database. If a GUI tool is not available, you can use ISQL totype in the appropriate commands manually.Your database should meet the following criteria:■■The size of the data device you create determines the size of thedatabase. The minimum database size is 32 MB so there has to be atleast one device that is 32 MB. You should also locate the data deviceon a different disk (and disk controller) than the transaction log.For optimum performance, ensure that separate devices are used tostore the data and the transaction log. For example, you can increaseperformance by creating a 50 MB data device and a 25 MB log device.A minimum of 40 MB of disk space (data and log) is required.2. Add users.For users to access the mart you must either add existing logins as usersto the database or create new logins and add them as users of thedatabase. A login is an entity permitted to connect to the database server;a user gives a login the right to use a particular database. If you useWindows user names and passwords to secure database access (WindowsAuthentication), you must add the Windows users to your DBMS.Chapter 2: Installation and Configuration 19


How to Prepare Your DBMS EnvironmentSybase Connections3. Check the Stored Procedure Cache.Set the Stored Procedure Cache size to at least 8 MB. Setting it higherimproves performance, especially when many users are accessing theserver concurrently. Setting it lower results in fatal errors and rollbackswhen the Stored Procedure Cache size is exceeded.Note: The installation creates more than 100 stored procedures. The <strong>CA</strong><strong>ERwin</strong> MM client invokes these stored procedures to control changes to thedata in the database.4. Check tempdb size.Significant temporary space is required for installation and use. Thetemporary segments need at least 16 MB of available space. You shouldalso increase available space as the number of concurrent users increase.5. Check memory allocated to the database server.Allocate at least 32 MB of RAM to the database server. The amount of RAMallocated should be half of the available RAM on the server.If you are using Sybase as your host DBMS, <strong>CA</strong> <strong>ERwin</strong> MM uses CT_LIBRARY toconnect.Post Database Creation Tasks for Microsoft SQL and SybaseYou must run the Administrative Setup program located on the CD. The Setupprogram prompts you for an installation directory. By default this directory isC:\Program Files\<strong>CA</strong>\<strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong>, but the path may have beenchanged during installation.Note: Do not attempt to run the Setup program unless you are certain thatthe computer you are using can connect to the target server. For moreinformation about tips on how to determine if your installation computer canconnect to the target server, see Microsoft SQL Server Connections or SybaseConnections.When you install the software, the Microsoft SQL installer can be „owner,‟ „userwith DB owner privileges,‟ or „user with alias as DB owner privileges.‟ TheSybase installer can be „owner,‟ „user with sa_role,‟ or „user with alias as DBowner.‟20 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS EnvironmentTransact SQL CommandsIf a graphical DBMS access tool is not available you can use Transact SQLcommands through ISQL.■The following is an example of how to create a device using the TransactSQL DISK INIT command through ISQL:DISK INIT NAME = 'mmdata', /* The logical name. */PHYSNAME = 'C:\SQL\DATA\mmdata.dat', /* The physical name. */VDEVNO = 1 255/* System dependent. */SIZE = number_of_2K_blocks /* 1024 here is 2MB!!! */[, VSTART = virtual_address, /* Optional */CNTRLTYPE = controller_number] /* Optional */■The following is an example of how to create a database using the TransactSQL CREATE DATABASE command through ISQL:CREATE DATABASE mmmaster[ON {DEFAULT | database_device} [= size_in_megabytes] /* The device created in #1. */[, database_device [= size_in_megabytes]]...] /* A database can span devices. */[LOG ON database device [= size_in_megabytes>] /* Separate log device. */[, database device [= size_in_megabytes]]...] /* A transaction log can span devices. */■The following is an example of how to add logins to the database with thesp_addlogin and sp_adduser commands using Transact SQL through ISQL:sp_addlogin login_id [, passwd [, defdb [, deflanguage]]]andsp_adduser login_id [, username [, grpname]]Once you have executed these commands, the DBA can alias an existinglogin as the Database Owner (dbo) or change the dbo to an existing loginusing sp_changedbowner. Use ISQL to execute the following:sp_changedbowner login_id [,true]Chapter 2: Installation and Configuration 21


How to Prepare Your DBMS EnvironmentTasks to Create an Oracle DBMSThe following tasks must be performed by the DBA and system administratorresponsible for installing the software on an Oracle database managementsystem. Information provided in this section includes installation and Oracleconnectivity software requirements.These steps can be performed using graphical tools but you can also use SQL*Plus (all versions), SQL*DBA (either command line or full screen mode), orthe Oracle Enterprise Management Console that started shipping with OracleVersion 8.0. Examples of SQL commands are included where appropriate. Datafile paths, data file sizes, role names, and user names are included for exampleonly.1. Check SYSTEM tablespace.The installation creates several stored procedures. All triggers, storedprocedures, and packages are kept in the Oracle SYSTEM tablespace. Thestandard size of the SYSTEM tablespace assumes that you are not usingprocedural options, so the SYSTEM tablespace often needs to be expanded.If other Oracle applications are not using procedural code, then theSYSTEM tablespace should be expanded to 32 MB. If other Oracleapplications also use procedural code, expand the SYSTEM tablespace to atleast 32 MB.2. Check Rollback Segment tablespace.If your instance uses UNDO tablespace, do not create rollback segments.Significant rollback space is required for installation and use. The rollbacksegments should be in their own separate tablespace and each have atleast 16 MB of available space. There should be one rollback segment forevery four concurrent users, with a maximum of 50 rollback segments. Theavailable space should scale upward with increasing numbers of rollbacksegments. Finally, the rollback segment optimal parameter should be setto control rollback segment growth and space consumption.Note: For Steps 3, 4, and 5, use Dictionary-managed tablespaces.3. Create a data tablespace of at least 32 MB.For example:CREATE TABLESPACE MyMartDATAFILE '/db01/oracle/rdbms9i/data/mymart.ora' SIZE 100M;Or For Locally Managed extents:CREATE TABLESPACE MymartDATAFILE '/db01/oracle/rdbms9i/data/mymart.ora' SIZE 100MEXTENT MANAGEMENT LO<strong>CA</strong>L SEGMENT SPACE MANAGEMENT AUTO;22 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS Environment4. Create a index tablespace of at least 32 MB.For example:CREATE TABLESPACE MMARTINDEXDATAFILE '/db02/oracle/rdbms9i/data/mmartindex.ora' SIZE 75M;Or For Locally Managed extents:CREATE TABLESPACE MMARTINDEXDATAFILE '/db02/oracle/rdbms9i/data/mmartindex.ora' SIZE 75MEXTENT MANAGEMENT LO<strong>CA</strong>L SEGMENT SPACE MANAGEMENT AUTO;5. Create a temporary tablespace.For example:CREATE TEMPORARY TABLESPACE MMTEMP TEMPFILE '/db03/oracle/rdbms9i/data/mmarttemp.ora'SIZE 50M;Or For Locally Managed extents:CREATE TEMPORARY TABLESPACE MMTEMP TEMPFILE '/db03/oracle/rdbms9i/data/mmarttemp.ora'SIZE 50MEXTENT MANAGEMENT LO<strong>CA</strong>L UNIFORM SIZE 1M;Note: For more details on syntax and options regarding tablespacecreation, see the appropriate Oracle documentation.6. Create an Oracle user with DBA privileges to be used by the <strong>CA</strong> <strong>ERwin</strong> MMInstaller or designated schema owner.Assign the data tablespace as this user‟s default tablespace, and thetemporary tablespace as this user‟s temporary tablespace.For example:CREATE USER STEVE IDENTIFIED BY STEVEDEFAULT TABLESPACE MyMartTEMPORARY TABLESPACE MMTEMPQUOTA UNLIMITED ON MyMartQUOTA UNLIMITED ON MMARTINDEX;7. Create the <strong>CA</strong> <strong>ERwin</strong> MM Installer role.The following example is the role required by the Oracle user installing <strong>CA</strong><strong>ERwin</strong> MM.CREATE ROLE MMINSTALL;Chapter 2: Installation and Configuration 23


How to Prepare Your DBMS Environment8. Grant Oracle privileges to the Installer role.The following example shows the Oracle privileges that the <strong>CA</strong> <strong>ERwin</strong> MMInstaller needs to install on Oracle. For the last command, you must log inas sys with the sysdba role in the user-name or the command will fail.grant create sequence to MMINSTALL;grant create table to MMINSTALL;grant create view to MMINSTALL;grant drop public synonym to MMINSTALL;grant create public synonym to MMINSTALL;grant create procedure to MMINSTALL;grant select on dba_data_files to MMINSTALL;9. Create the <strong>CA</strong> <strong>ERwin</strong> MM User role.For example:CREATE ROLE MMUSER;When you select this role as the <strong>CA</strong> <strong>ERwin</strong> MM User role during Step 4 ofthe installation procedure, the Setup program generates grant statementsthat grant object level privileges to this role.10. Grant the create session Oracle privilege to the User role.For example:grant create session to MMUSER;Note: The create session privilege is the only privilege that an Oracle userneeds to use the database.11. Grant the <strong>CA</strong> <strong>ERwin</strong> MM User role to each Oracle user that uses thedatabase.For example:grant MMUSER to USER1;grant MMUSER to USER2;grant MMUSER to USER3;Important! You must specify the User role name created in Step 9 forthese grant statements.12. Grant the <strong>CA</strong> <strong>ERwin</strong> MM User role to the <strong>CA</strong> <strong>ERwin</strong> MM Installer role.For example:grant MMUSER to MMINSTALL;24 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS EnvironmentDatabase Objects Installation13. Grant the <strong>CA</strong> <strong>ERwin</strong> MM Installer role to the <strong>CA</strong> <strong>ERwin</strong> MM Installer user.You must also grant DBA privileges to the user you designate as the <strong>CA</strong><strong>ERwin</strong> MM Installer.For example:grant MMINSTALL to STEVE;grant DBA to STEVE;Note: The DBA role is necessary only during the installation or upgrade.You can strip the installer of the DBA role after the installation or upgradeis complete.14. Run the Setup program.When the setup is complete, select the Initialize <strong>CA</strong> <strong>ERwin</strong> MM option andconnect to Oracle as the <strong>CA</strong> <strong>ERwin</strong> MM Installer user (for example, STEVE).15. Select the <strong>CA</strong> <strong>ERwin</strong> MM tablespaces and <strong>CA</strong> <strong>ERwin</strong> MM User role.When prompted for tablespace and role information, select the <strong>CA</strong> <strong>ERwin</strong>MM data tablespace, the <strong>CA</strong> <strong>ERwin</strong> MM index tablespace, and the <strong>CA</strong> <strong>ERwin</strong>MM User role (the role created in Step 9).16. Add the <strong>CA</strong> <strong>ERwin</strong> MM Installer user as the <strong>CA</strong> <strong>ERwin</strong> MM administrator.When the Security <strong>Manager</strong> is opened, your user name is automaticallyadded to the Administrator profile in the Security Profile list. You can alsodesignate one of the users with the MMUSER role (from step 12) forroutine operations. This completes the setup and you can begin using thesoftware.Note: After successful installation, you can revoke the <strong>CA</strong> <strong>ERwin</strong> MMInstaller role and grant the <strong>CA</strong> <strong>ERwin</strong> MM User role to the <strong>CA</strong> <strong>ERwin</strong> MMInstaller user.Install the software on an Oracle DBMS to create the following databaseobjects:■■■■TablesIndexesStored proceduresPublic synonymsChapter 2: Installation and Configuration 25


How to Prepare Your DBMS EnvironmentOracle ConnectionsOracle SQL*Net is used for client access to the database server. AlthoughOracle provides two utilities (SQL*Net Configuration tool and Network <strong>Manager</strong>tool) for defining your network, clients, and server, you need a networkadministrator to perform this task. The server system administrator is usuallythe best candidate.Note: For more information about these utilities, see the Oracle SQL*NetAdministrator’s <strong>Guide</strong>.SQL*Net requires certain files on both the server and client. These files can begenerated by the Oracle networking tools, but can also be created using a texteditor. Because Oracle does not support those sites that generate these filesmanually, it is better to use the appropriate Oracle utilities. The following liststhe files required by SQL*Net:File Name Required On File ContentsTNSNAMES.ORASQLNET.ORAClient andServerClient andServerA list of service names and connectdescriptors for network destinations(tells the client where it can makeconnections)A list of optional diagnostic parametersLISTENER.ORA Server only A list of names and addresses of alllisteners on a computer and the OracleSIDs for the databases known on thatcomputer26 <strong>Implementation</strong> <strong>Guide</strong>


How to Prepare Your DBMS EnvironmentOracle SQL CommandsIf a graphical DBMS access tool is not available, you can use Oracle SQLcommands through SQL*DBA or SQL*Plus.■The following is an example of how to create a tablespace using theCREATE TABLESPACE command:CREATE TABLESPACE mm_data /* The tablespace name. */DATAFILE ‘C:\ORANT\DATABASE\mmdata.dat‘ᾉ/* The data file name. */SIZE integer_value K or M or G /* The data file size */DEFAULT STORAGE ( /* The default storage parameters */INITIAL integer_value K or M or G /* The initial extent size */NEXT integer_value K or M or G /* The next extent size */PCTINCREASE integer_value /* The percent to grow extents */MINEXTENTS integer_value /* The minimum number of extents */MAXEXTENTS integer_value /* The maximum number of extents */);■The following is an example of how to create an Oracle user using theCREATE USER command:CREATE USER mm_user_1 /* The user id name */IDENIFIED BY password /* The user password */DEAFULT TABLESPACE tablespace_name /* The user’s default tablespace */TEMPORARY TABLESPACE tablespace_name /* The user’s temporary tablespace */QUOTA unlimited_or_integer_K_M_G ON tablespace_name /* The user’s quota on a tablespace */;■The following is an example of how to grant user privileges using theGRANT command:GRANT role_or_privilege_nameTO user_or_role;<strong>CA</strong> <strong>ERwin</strong> MM Mart Creation RequirementsTo create the <strong>CA</strong> <strong>ERwin</strong> MM mart, you must meet one of the followingrequirements:■you must be the database owner (dbo) in the target database on theMicrosoft SQL Server 2000/2005/2008 or Sybase serverNote: The database owner (dbo) is necessary only during the softwareinstallation or upgrade. It is not necessary after you create the mart.■you must be the database schema owner user and have the DBA role inthe target database on the Oracle serverChapter 2: Installation and Configuration 27


How to Prepare Your DBMS EnvironmentServer Connection SoftwareThe software you use to connect your client workstations with your serverdepends on the type of DBMS you are using and your personal preference. Thefollowing lists some commonly used DBMS client software connectionpackages:DBMSMicrosoft SQL Serveror SybaseOracleSuggested SoftwareMicrosoft SQL Server client installation, OpenClient/C Developer's Kit for PC Windows andNet-Library for PC Windows, CT-LIB, or equivalentsoftwareOracle “Required Files,” SQL*Net, and TCP/IP orequivalent communication softwareNote: For more information about memory and disk space requirements, seeyour DMBS documentation.Connection PrerequisitesYou connect to <strong>CA</strong> <strong>ERwin</strong> MM on the server through the client softwarecontained in <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er, <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er, or <strong>CA</strong> <strong>ERwin</strong><strong>Model</strong> Navigator. You must perform the following tasks before you can connectto the mart through the client:■■■■The administrator of the relational database management system (DBMS)must give users permission to access the DBMS, on which the <strong>CA</strong> <strong>ERwin</strong>MM database is set up.The <strong>CA</strong> <strong>ERwin</strong> MM administrator must install the administrative files on theserver, and set up the database. The administrator also defines usersecurity permissions and sets up the library structure in which models areorganized. When you install the <strong>CA</strong> <strong>ERwin</strong> MM software, the administratoris automatically granted Administrator security status. This lets theadministrator assign user permissions and perform all requiredmaintenance or administrative tasks.At least one of the client programs must be installed on the clientworkstation. System requirements for the client workstations are the sameas those for the <strong>CA</strong> <strong>ERwin</strong> MM client software. You can find therequirements in the documentation provided with these products.The client connectivity software for your DBMS on the server must beinstalled on the client workstation so that you can connect to the DBMS onwhich the database resides.28 <strong>Implementation</strong> <strong>Guide</strong>


Install the Administrative FilesInstall the Administrative FilesThe Installation Wizard makes it easy for you to install, change, or remove thesoftware. The installation of the administrative files is the same for eachDBMS supported (Microsoft SQL Server, Sybase, or Oracle).Note: To create, update, or delete a mart you must have the followingdatabase rights:■■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBArole.To install the administrative files1. Insert the installation DVD or double-click the file you downloaded fromthe online <strong>CA</strong> product page.The Installation Wizard opens.2. Follow the prompts in the wizard to proceed. If you install from the DVD,you are prompted to select the applications you wish to change or install.Click Next.A License Agreement opens for you to review.3. Select the option to accept the terms as described in the LicenseAgreement. Click Next.The wizard asks a series of questions you must answer, including:■■Customer InformationDestination folder4. On the Custom Setup Type screen, review the program features that willbe installed. You can also evaluate the space needed to install eachfeature.Click Next to continue and then click Install to start the installation.The program files are copied.Click Finish to exit the wizard.The installation is complete and the Connection <strong>Manager</strong> opens to initializeyour mart.Important! You must install or upgrade the license key before youinitialize the mart. If you have not already licensed <strong>CA</strong> <strong>ERwin</strong> MM, you canlicense the program when the install process is complete. Follow theon-screen prompts to open the License Verification dialog and enter thelicense key provided with the product CD.Chapter 2: Installation and Configuration 29


License <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong>License <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong>If you have not already licensed <strong>CA</strong> <strong>ERwin</strong> MM, you can license the program atthis time. Locate the 25-character License Key that accompanies the productCD. Typically, this key is found on the back of the CD sleeve. You need thisLicense Key to complete the license process.To license <strong>CA</strong> <strong>ERwin</strong> MM1. Click Programs, <strong>CA</strong>, <strong>ERwin</strong>, <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> r7.3, Add MM License onthe Start menu.The License verification dialog opens.2. Select a component in the Component List in the License Verification dialogand select an option:Use Trial VersionSpecifies to use the Try Buy license. The product runs for 30 daysbefore requiring a license.Use License KeySpecifies to enter a license key.3. Enter the License Key in the License Key field for the first component listedin the Licence Verification dialog, and click Add.The information you entered displays in the License Keys field.Note: If you enter an Upgrade license key in the License Key field, and thecomponent is not currently licensed on your system, the Registration IDfield appears, permitting you to enter the Registration ID for yourupgraded component.4. Select the next component you are licensing from the Component List,enter the License Key for this component in the License Key fields and clickAdd.Repeat these steps until you have entered License Keys for all of thecomponents you are licensing.5. Click Continue.The installation process continues.30 <strong>Implementation</strong> <strong>Guide</strong>


Refresh the Mart After Upgrading Your LicenseRefresh the Mart After Upgrading Your LicenseAfter you upgrade the license file, you must refresh the mart.To refresh the mart1. Click Programs, <strong>CA</strong>, <strong>ERwin</strong>, <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> r7.3, <strong>Model</strong> <strong>Manager</strong> onthe Start menu.The Connection <strong>Manager</strong> dialog opens.2. Connect to the database where you upgraded the license.The connection is made.3. Click Close.The database refresh is automatic.Note: If you upgrade your user license with the software upgrade, the Setupprogram automatically detects your new license key and a message displaysconfirming the license upgrade. You should install the new license file beforeyou install the software upgrade.Chapter 2: Installation and Configuration 31


Create the <strong>CA</strong> <strong>ERwin</strong> MM MartCreate the <strong>CA</strong> <strong>ERwin</strong> MM MartAfter you create the <strong>CA</strong> <strong>ERwin</strong> MM database on your DBMS and install theadministrative files, you must create the <strong>CA</strong> <strong>ERwin</strong> MM mart to create thetables, install the stored procedures that manage client workgroup models inthe mart, and prepare the mart for use with <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong><strong>ERwin</strong> Process <strong>Model</strong>er. To create, update, or delete a mart you must have thefollowing database rights:■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBA role.Note: The <strong>CA</strong> <strong>ERwin</strong> MM mart and the <strong>CA</strong> <strong>ERwin</strong> MM Control Tables (m7Masterand m7License) must be installed on the same database for Microsoft SQLServer or Sybase DBMS.Important! You must install or upgrade the license key before you create the<strong>CA</strong> <strong>ERwin</strong> MM mart.To create the mart1. Log on to your DBMS that contains <strong>CA</strong> <strong>ERwin</strong> MM as the dbo or schemaowner. Click Programs, <strong>CA</strong>, <strong>ERwin</strong>, <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> r7.3, <strong>Model</strong><strong>Manager</strong> on the Start menu.The Connection <strong>Manager</strong> opens.32 <strong>Implementation</strong> <strong>Guide</strong>


Create the <strong>CA</strong> <strong>ERwin</strong> MM Mart2. Complete the following information:DatabaseIdentifies the type of relational database management system (DBMS)you will connect to. Select from the current list of supporteddatabases.AuthenticationWindows AuthenticationSpecifies the use of Windows user names and passwords to securedatabase access. You must be logged on to your computer as the userwho is the dbo of the database. (Available only for Oracle and SQLServer.)Database AuthenticationSpecifies the use of a local user name and password for theconnection.Chapter 2: Installation and Configuration 33


Create the <strong>CA</strong> <strong>ERwin</strong> MM Mart3.Parameters/Value OptionsConnection Type (Microsoft SQL Server 2005 Only)Specifies the use of Native Connection to connect using the APIprovided by the SQL Server Native client software or ODBC data toconnect using the ODBC data source you have defined.ServerIdentifies the server name.DatabaseIdentifies the name of the <strong>CA</strong> <strong>ERwin</strong> MM database or mart.Connection String (Oracle Only)Specifies the connection string (TNSNames entry).You can select a database connection from the Recent Connections panelto automatically populate the Database or Connection String previouslyused.Click Connect.The <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> dialog opens.34 <strong>Implementation</strong> <strong>Guide</strong>


Create the <strong>CA</strong> <strong>ERwin</strong> MM Mart4. Select from the following options:5.Database (SQL and Sybase DBMS)Identifies the master database name to create the tables and storedprocedures.<strong>CA</strong> <strong>ERwin</strong> MM Role (Oracle DBMS)Identifies the Oracle MMUSER security role. This role is created in theprocedure for creating the <strong>CA</strong> <strong>ERwin</strong> MM database on Oracle. Otheruser roles can connect to <strong>CA</strong> <strong>ERwin</strong> MM, but they will encounter accessproblems.Table TablespaceIndicates where you want to store the <strong>CA</strong> <strong>ERwin</strong> MM tables.Note: The drop-down box is not active if there is only one tablespace.Index TablespaceIndicates where you want to store the <strong>CA</strong> <strong>ERwin</strong> MM indexes.Note: You can store tables and indexes in the same tablespace or indifferent tablespaces.Truncate Log Before Any ActionSpecifies to remove the database transaction log. Truncating thedatabase transaction log is especially important for Microsoft SQLServer and Sybase users since a large transaction log can cause thedatabase to hang.Note: When you initialize a Microsoft SQL Server 2008 database, it isnot necessary to select the "Truncate Log Before Any Action" option. Ifyou select this check box, and click Create, the following errormessage displays: "Incorrect syntax near the keyword'TRANSACTION'." To avoid this message, clear the check box for"Truncate Log Before Any Action" before you click Create.Click Create.The <strong>CA</strong> <strong>ERwin</strong> MM objects are created and the Security <strong>Manager</strong> dialogopens.Important! If you do not see the Security <strong>Manager</strong> dialog, it can behidden behind other open applications. Minimize all applications or use theAlt-Tab keys until you find it.Your user name is automatically added to the Administrator profile in theSecurity Profile list.Chapter 2: Installation and Configuration 35


Chapter 3: UpgradeThis section contains the following topics:Software Upgrades (see page 37)Conversion Process (see page 38)How to Upgrade the Mart (see page 40)Install the Software Upgrade (see page 42)Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM Mart (see page 43)Software UpgradesNew versions of the software and supported client software products areperiodically released. The upgrade process prepares the tables and storedprocedures to accommodate new functionality and client functionality, but doesnot change or delete any data stored in the mart. To upgrade the software,you must be assigned to the Administrator security profile and logged on tothe DBMS.To create, update, or delete a mart you must have the following databaserights:■■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBArole.The software should be installed or upgraded on the computer that houses the<strong>CA</strong> License Key. This workstation is typically the same computer that theadministrator uses or the first computer that was used to install the software.Note: For some software upgrades, a new license key is required.The mart upgrade process is slightly different depending on your DBMS. Formore information about specific procedures, see the particular section on thedatabase you are running.Chapter 3: Upgrade 37


Conversion ProcessConversion ProcessThe conversion systematically converts a mart, including all <strong>CA</strong> <strong>ERwin</strong> MMproperties and all client models.The time it takes to convert a mart varies for each installation. Server speed,size, complexity, and the number of models in the mart are several factorsthat influence conversion time.Property ConversionThe conversion process upgrades the following <strong>CA</strong> <strong>ERwin</strong> MM properties:■■■All user names and security profiles (even if the user no longer exists inthe database)All session informationAll libraries including the preservation of the complete library structureAccess information is not converted. Access information is stored internally fortracking purposes.<strong>Model</strong> Property ConversionThe model conversion process converts all <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong><strong>ERwin</strong> Process <strong>Model</strong>er model properties including the following:<strong>Model</strong> data<strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er models in the martare converted. The converted models are the same as if opening an .er1file with the upgraded client and saving the model to <strong>CA</strong> <strong>ERwin</strong> MM.All model objects<strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er accept all modelobjects from earlier versions.All object propertiesAll model properties such as object names and user-defined properties(UDPs) are fully retained.38 <strong>Implementation</strong> <strong>Guide</strong>


Conversion ProcessConversion MethodsManual ConversionThe following conversion methods are available to convert your existing clientmodels:Manual ConversionMoves your models from the old mart to the new mart, one model at atime.Automated ConversionInstalls the new software version and initializes the mart in the samelocation as the old mart. Click Convert to automatically convert all existingmodels in the old mart to the new mart.Manual conversion means moving your models from your old mart to your newmart, one model at a time. The following are some advantages to the manualmethod:■■■■Selectively choose the models you want to move, and leave those that youdo not.“Clean up” your mart if there are many models or versions which are nolonger in use, and which would extend conversion time.Run both <strong>CA</strong> <strong>ERwin</strong> MM versions simultaneously, and move incrementally,model by model, to the new mart.Host your new mart on a different server or database platform than yourold mart version.Automated ConversionThe disadvantages are that the version history is lost on models checked in tothe new mart. Being a manual process, it is time consuming and laborintensive.The automated conversion uses the Update option on the <strong>CA</strong> <strong>ERwin</strong> <strong>Model</strong><strong>Manager</strong> dialog. Your existing <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process<strong>Model</strong>er models in the old mart are converted to the new mart. All models areconverted automatically at the same time.The main advantage to this method is that it is automated and all modelsretain their full history. The disadvantage is that it takes a long time if yourmart is large, or your client/server hardware is limited. The automatedconversion must be done in the same database instance as your previousversion. This may require more space than is available, or require you to moveyour old version of the mart, if you cannot create additional space.Chapter 3: Upgrade 39


How to Upgrade the MartHow to Upgrade the MartIt is important to run through the upgrade process in a test environmentbefore attempting to upgrade your production environment. By doing so, youbecome aware of any challenges that exist, and have fewer surprises whenyou actually convert your production environment. To convert your mart asefficiently and as fast as possible, follow these recommendations:■■■■■■■■■■■■■■■Make a full backup of the current database using the backup utility for yourDBMS before upgrading.Open and save all models in your mart using the current version of theclient before you convert to <strong>CA</strong> <strong>ERwin</strong> MM r7.3.Ensure that all users check in any off-line models and ensure that thereare no active sessions on the mart and that no models are checked out.Remove obsolete models in the current database to reduce the size, whichimproves the conversion speed.Verify that <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er modelsare synchronized if you synchronize data.Verify that your client version is compatible with the database version towhich you are migrating.Increase the size of the database to a minimum of three times the size ofthe previous database for temporary conversion objects.Verify there are no outstanding technical support issues related to <strong>CA</strong><strong>ERwin</strong> MM.Turn on AUTOEXTEND to automatically extend the <strong>CA</strong> <strong>ERwin</strong> MM data filewhen full (Oracle DBMSs only).Make sure the Auto grow file is turned on, with your choice of File Growthand unrestricted File Growth for both data files and transaction logs(SQL2000 DBMSs only).Review the Release Notes file.Run the upgrade during off-peak hours.Truncate the database log file.Start the conversion from the server to eliminate the possibility of networkspeed becoming a bottleneck. Have at least 1 GB on the client, typicallymore memory means faster performance.Log on to your DBMS as either the dbo (Microsoft SQL or Sybase) orschema owner (Oracle) of the database that contains <strong>CA</strong> <strong>ERwin</strong> MM.40 <strong>Implementation</strong> <strong>Guide</strong>


How to Upgrade the MartMicrosoft SQL Server or Sybase DBMS Upgrade ConsiderationsOn a Microsoft SQL Server or Sybase DBMS, if you are updating from aprevious <strong>CA</strong> <strong>ERwin</strong> MM version and the system logs are full, you may not beable to upgrade your previous <strong>CA</strong> <strong>ERwin</strong> MM installation with the currentversion. Before you install the new version, use a DBMS utility (such asMicrosoft SQL Object <strong>Manager</strong>) and type the appropriate command to purgethe transaction log.Oracle DBMS Upgrade ConsiderationsOn an Oracle DBMS, before you start the conversion, it is important that youturn on AUTOEXTEND to automatically extend the <strong>CA</strong> <strong>ERwin</strong> MM data file whenfull.<strong>CA</strong> <strong>ERwin</strong> MM 4.1.4 to <strong>CA</strong> <strong>ERwin</strong> MM r7.3 ConversionVerify that the mart is Version 4.1.4 (Build 3643 or later). If it is a versionearlier than 4.1.4, you must upgrade to 4.1.4 before you can upgrade to r7.3.We recommend you upgrade to the latest Service Pack for <strong>CA</strong> <strong>ERwin</strong> MMVersion 4.1.4. You must open and save your models older than <strong>CA</strong> <strong>ERwin</strong> MMVersion 4.1.4 in <strong>CA</strong> <strong>ERwin</strong> MM Version 4.1.4 before you can upgrade to <strong>CA</strong><strong>ERwin</strong> MM r7.3.See http://ca.com/supportconnect/ for details on upgrading to <strong>CA</strong> <strong>ERwin</strong> MMVersion 4.1.4.Chapter 3: Upgrade 41


Install the Software UpgradeInstall the Software UpgradeTo upgrade the software to a new version you must log on to your DBMS. Tocreate, update, or delete a mart you must have the following database rights:■■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBArole.Note: For some software upgrades, a new license key is required. Locate the25-character License Key that accompanies the product CD. Typically, this keyis found on the back of the CD sleeve.To install the software upgrade1. Close all client connections and insert the CD in your CD-ROM drive.If Autorun is enabled, you are prompted to install. If not, double-clickSetup.exe from the CD drive.The Welcome dialog opens.2. Click Next to continue.A License Agreement opens for you to review.Select the option to accept the terms as described in the LicenseAgreement and continue. Follow the instructions provided by theinstallation wizard.3. When the install completes, a final screen displays. Click Close.4. Some updates require that you re-initialize the mart. To do this, select<strong>Model</strong> <strong>Manager</strong> from the Start menu to connect to the mart and run theupdate process.42 <strong>Implementation</strong> <strong>Guide</strong>


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM MartConvert or Update a <strong>CA</strong> <strong>ERwin</strong> MM MartAll the existing <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er and <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>er modelsin the mart are initialized and prepared for the r7.3 internal structure. Themodel is not fully converted or updated until you open and save the model in<strong>CA</strong> <strong>ERwin</strong> MM r7.3 with <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>er or <strong>CA</strong> <strong>ERwin</strong> Process <strong>Model</strong>erfor the first time. It can take a few minutes longer to open the model the firsttime to complete the process.To convert a martLog on to your DBMS that contains <strong>CA</strong> <strong>ERwin</strong> MM. To create, update, or deletea mart you must have the following database rights:■■For Microsoft SQL Server 2000/2005/2008, you must be the databaseowner (dbo).For Oracle, you must be the database schema owner and have the DBArole.1. Click Programs, <strong>CA</strong>, <strong>ERwin</strong>, <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> r7.3, <strong>Model</strong> <strong>Manager</strong> onthe Start menu.The Connection <strong>Manager</strong> opens.Chapter 3: Upgrade 43


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM Mart2. Complete the following information:DatabaseIdentifies the type of relational database management system (DBMS)you will connect to. Select from the current list of supporteddatabases.AuthenticationWindows AuthenticationSpecifies the use of Windows user names and passwords to securedatabase access. You must be logged on to your computer as the userwho is the dbo of the database. (Available only for Oracle and SQLServer.)Database AuthenticationSpecifies the use of a local user name and password for theconnection.Parameters/Value OptionsConnection Type (Microsoft SQL Server 2005 Only)Specifies the use of Native Connection to connect using the APIprovided by the SQL Server Native client software or ODBC data toconnect using the ODBC data source you have defined.ServerIdentifies the server name.DatabaseIdentifies the name of the <strong>CA</strong> <strong>ERwin</strong> MM database or mart.Connection String (Oracle Only)Specifies the connection string (TNSNames entry).44 <strong>Implementation</strong> <strong>Guide</strong>


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM MartYou can select a database connection from the Recent Connections panelto automatically populate the Database or Connection String previouslyused.Click Connect.3.The <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> dialog opens.Chapter 3: Upgrade 45


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM Mart4. Select from the following options:5.Database (SQL and Sybase DBMS)Identifies the master database name to create the tables and storedprocedures.<strong>CA</strong> <strong>ERwin</strong> MM Role (Oracle DBMS)Identifies the Oracle MMUSER security role. This role is created in theprocedure for creating the <strong>CA</strong> <strong>ERwin</strong> MM database on Oracle. Otheruser roles can connect to <strong>CA</strong> <strong>ERwin</strong> MM, but they will encounter accessproblems.Table TablespaceIndicates where you want to store the <strong>CA</strong> <strong>ERwin</strong> MM tables.Note: The drop-down box is not active if there is only one tablespace.Index TablespaceIndicates where you want to store the <strong>CA</strong> <strong>ERwin</strong> MM indexes.Note: You can store tables and indexes in the same tablespace or indifferent tablespaces.Truncate Log Before Any ActionSpecifies to remove the database transaction log. Truncating thedatabase transaction log is especially important for Microsoft SQLServer and Sybase users since a large transaction log can cause thedatabase to hang.Note: When you initialize a Microsoft SQL Server 2008 database, it isnot necessary to select the "Truncate Log Before Any Action" option. Ifyou select this check box, and click Create, the following errormessage displays: "Incorrect syntax near the keyword'TRANSACTION'." To avoid this message, clear the check box for"Truncate Log Before Any Action" before you click Create.Select one of the following after verifying the mart name in the Statuswindow:CreateCreates an empty mart. You can manually open and save existing <strong>CA</strong><strong>ERwin</strong> Data <strong>Model</strong>er models to this new mart.UpdateCreates a new mart with the current version and updates the datafrom the old mart to the new mart. The Update button is enabled onlywhen an earlier version of a <strong>CA</strong> <strong>ERwin</strong> MM is detected. When youupdate your mart, the old mart is no longer usable in the previousversion.46 <strong>Implementation</strong> <strong>Guide</strong>


Convert or Update a <strong>CA</strong> <strong>ERwin</strong> MM MartNote: The Create and Update buttons are mutually exclusive and the textof the button changes depending if a previous version of the mart isdetected. If the Create button is not enabled, then a previous version of amart is detected.ConvertCreates a new mart with the current version and copies the data fromthe old mart to the new mart. The old mart is retained in the samedatabase.The dialog displays conversion progress messages.6. Click OK on the Upgrade has Successfully Completed message dialog.The <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> dialog displays the status.7. Click Close to exit out of the <strong>ERwin</strong> <strong>Model</strong> <strong>Manager</strong> dialog.The administrative setup is complete.8. Click OK on the Setup Complete dialog.The conversion is complete.The same user profile assignments exist as before the conversion. If you mustmake changes to user profiles, you can access the Security <strong>Manager</strong> on theServices menu or click the User Permissions icon on the <strong>CA</strong> <strong>ERwin</strong> MM Toolbar.Chapter 3: Upgrade 47


Appendix A: Microsoft SQL and SybaseServer Tuning RecommendationsThis section contains the following topics:Physical Tuning Parameters (see page 49)Server-Level Tuning Parameters (see page 50)Named Cache Configuration (see page 51)Database Tuning Parameters (see page 51)Database and Log Sizing (see page 53)How to Maintain an Efficient Database (see page 53)Physical Tuning ParametersThe mart is dynamic, with many queries and data manipulations performedwith each model save and load. Although the Microsoft SQL Server and Sybasearchitectures differ in some ways, the basic operation and configuration of bothserver environments is the same.The configuration changes that must be made to Microsoft SQL Server andSybase for optimum performance with maximum fault tolerance andrecoverability are provided.Hardware ConfigurationsConsider implementing <strong>CA</strong> <strong>ERwin</strong> MM on a multiprocessor system, especially ifmultiple data modelers are saving information simultaneously. Install thesoftware on a stand-alone Microsoft SQL Server, if possible, or on adevelopment computer. The database overhead noticeably affects otherdatabases running on the same system during save and load operations. If fewmodelers save and load simultaneously, the overhead is less.To improve caching performance, implement <strong>CA</strong> <strong>ERwin</strong> MM on servers thathave at least 512 MB of RAM.Appendix A: Microsoft SQL and Sybase Server Tuning Recommendations 49


Server-Level Tuning ParametersDatabase Placement<strong>CA</strong> <strong>ERwin</strong> MM databases are written to in bursts of activity. Stored proceduresand bulk insert statements are used to minimize overhead when saving data toMicrosoft SQL Server. To optimize performance, place the database on lowactivity Microsoft SQL Server files. If possible, place the log and data segmentson different physical drives to reduce contention between log writes anddatabase reads.Data RedundancyMake sure that the transaction log is mirrored on a separate drive to maximizerecoverability of the database. If the up-time of the database is consideredcritical, mirror the database and the transaction logs; you can also mirror theother Microsoft SQL Server files. Consider OS mirroring to speed the mirroringprocess and make it easier to manage.Server-Level Tuning ParametersYou should perform the following server-level tuning tasks:■■■Configure Microsoft SQL Server to use as much memory as possible.Allocating more memory to the Microsoft SQL Server caching mechanismsmeans less physical reads from the disk and improved database queryperformance.Allow several megabytes of disk space for the procedure cache because <strong>CA</strong><strong>ERwin</strong> MM uses many stored procedures.Configure two additional user connections for each simultaneous <strong>CA</strong> <strong>ERwin</strong>MM user. Two connections per session are used.The following shows the recommended configuration parameters for aMicrosoft SQL Server running <strong>CA</strong> <strong>ERwin</strong> MM:Parameter Type Recommended Value Notesmemory (Sybase11: "totalmemory")512 MB minimumNote: 1 GB isrecommendedMore memory implies lessphysical I/Oprocedural cache 30 percent <strong>CA</strong> <strong>ERwin</strong> MM is storedprocedure intensiveuser connections2 times the number ofconcurrent sessionsAdd this value to existinguser connection values50 <strong>Implementation</strong> <strong>Guide</strong>


Named Cache ConfigurationNamed Cache ConfigurationFor Sybase systems, consider setting up a 4 KB pool for the default datacache. Sybase writes I/O to the log more often in 4 KB increments than in 2KB increments (the default). You can set up a 4 KB I/O pool usingsp_poolconfig, but you must restart the server to enable the 4 KB I/O writes tothe log. Set the pool up as a smaller subset of the cache.Note: Be careful when making changes to the data caching systems in Sybase.Monitor your changes with SQL Monitor or sp_sysmon to ensure that thechanges you make do not starve the 2 KB I/O pool or other caches.The following shows the recommended size of the 4 KB I/O pool for small,medium, and large servers:Server Size Data Cache Size 4 KB I/O Pool SizeSmall 128 MB 4 MBMedium 512 MB 6 MBLarge 1 GB 10 MBDatabase Tuning ParametersYou can make database tuning adjustments in three different areas:■■■Transaction logThreshold proceduresDatabase optionsTransaction LogThe transaction log keeps a before and after image of each change made inthe database, and can be backed up independently of the database by issuinga DUMP TRANSACTION command. Microsoft SQL Server keeps a transactionlog for each database.Note: A side effect of the DUMP TRANSACTION command is that it clears theinactive transactions from the log to reduce its size.Back up the transaction log frequently. This keeps the transaction log smalland reduces the amount of data lost in the event of a severe databasecorruption.Appendix A: Microsoft SQL and Sybase Server Tuning Recommendations 51


Database Tuning ParametersThreshold ProceduresFor Sybase, enable a threshold procedure for the last-chance threshold to backup the log when it runs out of disk space.Note: Because Microsoft SQL Server does not provide such an option, youmust back up the log frequently to keep the log small.The following shows a sample Sybase threshold action procedure:create procedure sp_thresholdaction@dbname char(40),@segment_name char(40),@space_left int,@status intas/* make the thresholdaction procedure backup the log */declare @backdevice varchar(255)select @backdevice= '/u/backups/tranfile'+convert(char(8),getdate(),4)dump transaction mart to @backdevicego"trunc. log on chkpt" OptionTo ensure maximum recoverability, do not enable the “trunc. log on chkpt”option, since the log is cleared automatically after each checkpoint operation.If the database device becomes damaged with the log device still active andthis option is set, the database cannot be recovered using the log files sincethey are almost empty.52 <strong>Implementation</strong> <strong>Guide</strong>


Database and Log SizingDatabase and Log SizingSince the database is a dynamic environment, allow plenty of space for themodels you create. Tests have shown that models generate between 10 KBand 20 KB of data per entity during initial save times. Log overhead per objectis approximately 15 KB to 21 KB per entity. Allocate 50 to 65 percent of thedatabase size to the log to avoid running out of room in the log for a typicalmodel save.An average mart can range in size between 200 MB and 1 Gig. Size thetransaction log accordingly. A 50 MB data device can store several largemodels (about 2,500 entities and 100,000 total objects), but keep in mind thatthe database becomes more flexible and has less storage space issues whenthe data device is large.The following table shows the recommended database size and log size forsmall, medium, and large marts:Database Size Database Device Transaction LogDeviceSmall 200 MB 100 MBMedium 500 MB 200 MBLarge 1 GB 400 MBHow to Maintain an Efficient DatabaseTo maintain an efficient database, perform the following maintenance tasks:■■■Run UPDATE STATISTICS and execute sp_recompile frequently on everytable in the database. This keeps the statistics up-to-date for the indexes,resulting in better overall performance.Periodically recreate the clustered indexes in the database to reducefragmentation. Be sure to back up the database and transaction log daily.Run DBCC CheckDB(), DBCC CheckCatalog(), and DBCC CheckAlloc() orDBCC NewAlloc() on the database nightly, to check for corruption andinconsistencies in the database. Check the output of these queries and lookfor keywords like corrupt. Any problems detected by these commands aresent to the query output, so save the files and scan them regularly.Appendix A: Microsoft SQL and Sybase Server Tuning Recommendations 53


How to Maintain an Efficient DatabaseThe following table shows maintenance tasks and the recommended frequencyfor performing these tasks:MaintenanceTaskRecommendedFrequencyReasonDBCC Checkdb Nightly Check for corruption in databases.DBCC NewAlloc Weekly Check for allocation corruption(Microsoft SQL Server only).DBCCCheckAllocDBCCCheckCatalogUPDATESTATISTICSEXECsp_recompileBackupDatabaseBackupTransaction LogWeeklyWeeklyNightlyNightlyWeeklyDailyCheck for allocation corruption(Microsoft SQL Server only).Check for system tableinconsistencies.Recreates the statistics page foreach index.Tells which stored procedures havechanged.Full backup of database should bedone at least weekly, if notnightly.Backing up the transaction logdaily saves all committedtransactions and clears the log.Nightly Maintenance ScriptThe following script is the recommended nightly maintenance script:UPDATE STATISTICS m7ObjectgoUPDATE STATISTICS m7ObjectPropertygo54 <strong>Implementation</strong> <strong>Guide</strong>


How to Maintain an Efficient DatabaseDBCC CommandsUse the following DBCC commands to perform maintenance tasks on thedatabase:DBCC CheckDB(mart)goDBCC CheckAlloc(mart)goDBCC CheckCatalog(mart)goAppendix A: Microsoft SQL and Sybase Server Tuning Recommendations 55


Appendix B: Oracle TuningRecommendationsThis section contains the following topics:Recommended Disk Configurations (see page 57)Database Configuration (see page 58)Storage Parameters (see page 64)Recommended Disk ConfigurationsOracle servers are available on many different platforms ranging from PCs tomainframes. To support the wide range of hardware platforms and applicationrequirements, Oracle servers have a number of configuration options that youcan use to tailor the behavior of an Oracle database. You can also use theseconfiguration options to tailor your database. Some of the options documentedin this guide only apply to specific Oracle versions. For further information, seethe appropriate Oracle documentation.If the Oracle server is not dedicated to <strong>CA</strong> <strong>ERwin</strong> MM, as databaseadministrator you must be careful to balance the requirements of all users onthe server. This is particularly true for database servers that support OLTP (OnLine Transaction Processing) applications that require tight responsecharacteristics.The layout of Oracle database files on physical disk drives plays a major role inthe performance of the database. When used with <strong>CA</strong> <strong>ERwin</strong> MM, Oracleperforms large bursts of database operations (fetches, inserts, updates, anddeletes) in a short period of time. This usage pattern often requires Oracle toperform a significant amount of disk I/O operations. For good performance, itis important that as many I/O operations as possible be performed in parallel.This enables Oracle to retrieve data faster during fetches and to write datafaster during inserts, updates, and deletes.To maximize parallel I/O access, split the Oracle database files across manyphysical disks. Ideally, you should place the database on four physical disks. Ifthis is not possible, you can use three, two, or one disk systems.Note: Installing Oracle on a single disk system causes significant performancedegradation.Appendix B: Oracle Tuning Recommendations 57


Database ConfigurationDatabase ConfigurationProper database configuration is essential to the smooth operation and goodperformance of an Oracle database. You can use the configuration optionsdescribed to optimize the processing of your Oracle server.Maximum Number of ProcessesOracle must be preconfigured at startup with a maximum number of processesthat can access the database. The parameter that controls the maximumnumber of processes, called PROCESSES, is defined in the INIT.ora orINIT.ora file. It should be set to the maximum potential number ofconcurrent users plus seven. The additional seven are for Oracle backgroundprocesses that must also access the database. Setting the number ofprocesses at a lower value can prevent some users from accessing the serverduring peak usage times. Setting the number of processes at a higher valuecan waste a small amount of system memory resources.Shared PoolThe shared pool is an area of Oracle memory that includes two mainstructures:■■The library cache, which stores parsed SQL and PL/SQL statementsThe dictionary cache, which stores the Oracle data dictionary (or Oraclemetadata)The SHARED_POOL_SIZE parameter is defined in the INIT.ora orINIT.ora file and is used to regulate the size of the shared pool. Set theSHARED_POOL_SIZE parameter to a minimum of 3500000 (3.5 million).Setting the shared pool to a smaller value can degrade performance, forcingOracle to do disk I/O to retrieve objects that cannot fit in the shared pool. Alarger shared pool may be required, depending on the size and number ofmodels and the number of users.58 <strong>Implementation</strong> <strong>Guide</strong>


Database ConfigurationBuffer CacheThe buffer cache serves as a memory cache for all data going to and fromOracle data files. When Oracle needs a block of data it first checks whetherthat block exists in the buffer cache. If it does, Oracle gets the data from thebuffer cache—avoiding disk access. Having a large enough buffer cache letsthe Oracle server bypass most I/O requests.Buffer cache size is controlled by the DB_BLOCK_BUFFERS parameter definedin the INIT.ora or INIT.ora file. Set the buffer cache to a minimum of 4MB. Values smaller than 4 MB force Oracle to do many more I/O requests andsignificantly degrades the performance. Values larger than 4 MB improveperformance and should be used if memory is available.Note: In Oracle, the DB_BLOCK_BUFFERS parameter is specified as a numberof database blocks instead of actual size in bytes. To compute the value ofDB_BLOCK_BUFFERS, divide the desired buffer cache size in bytes by thedatabase block size defined by the DB_BLOCK_SIZE parameter in the INIT.oraor INIT.ora file.Redo Log FilesRedo log files contain a record of all Data Manipulation Language (DML)commands (such as INSERT, UPDATE, and DELETE commands) performed onthe database. As DMLs are performed, the Oracle engine writes them tosequential redo log files. Periodically, an Oracle background process retrievesthe DMLs from the Redo log files and writes the actual changes to the Oracletablespace files. This mechanism lets Oracle defer most of the I/O burdenassociated with DMLs to a background process that does not slow down theclient processes.Note: Oracle Redo log files are treated by the database engine as a ring.When one file fills up, the engine performs a log switch and starts writing tothe next log file in the ring. When that log file fills, the engine switches again.The number and size of the Redo log files is an important performanceconsideration. If the log files are too small or if there are not enough of themin the ring, Oracle may have to stall on a log switch. If this happens, the DMLsin the next log in the ring may not have been written to the tablespace files,and therefore the next log file has not been archived by the background ARCHprocess. For more information about Redo log archiving, see the Oracledocumentation.Redo log files are created when the database is created. However, Redo logfiles can be added or deleted at any time using Data Definition Language(DDL) statements.Appendix B: Oracle Tuning Recommendations 59


Database ConfigurationYou should have at least four Redo log files, each 2 MB in size. A smallernumber of Redo log files or a smaller Redo log file size can cause I/Obottlenecks. If the disk space is available, using more than four Redo log filesfurther reduces the chances of delayed log switches. Larger Redo log filesimprove performance, but care must be taken to adequately schedulecheckpoints that write DMLs stored in the Redo logs to the tablespace files.If the number of disks permits, you should mirror Redo log files by creatingRedo log groups with two mirrored members per group. This offers thedatabase some protection against single disk errors.Increase Space in Redo LogsThe number and size of the Redo log files is an important performanceconsideration. Redo log files are created when the database is created.To increase space in the Redo logs1. Log in to Oracle using SQL*Plus as SYSDBA or SYSOPER and run thefollowing script to create eight Redo logs that are 2 MB each:rem -- parm1 -- temp dirrem Generate creation scriptSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_11.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_11.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_12.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_12.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_13.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_13.LOG' )UNION60 <strong>Implementation</strong> <strong>Guide</strong>


Database ConfigurationSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_14.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_14.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_15.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_15.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_16.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_16.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_17.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_17.LOG' )UNIONSELECT 'ALTER DATABASE ADD LOGFILE '''|| SUBSTR ( MEMBER , 1 , INSTR ( MEMBER , '\' , -1 , 1 ) )|| 'REDO_18.LOG'' SIZE 2M ;'from V$LOGFILEwhere ROWNUM = 1and not exists ( SELECT 1 from V$LOGFILE where MEMBER like '%REDO_18.LOG' ).Spool &1.AddLog.ORA/Spool OffCOMMIT ;SELECT 'ALTER SYSTEM SWITCH LOGFILE ;' from V$LOG where ROWNUM < 5.Spool &1.SwtchLog.ORA/Spool OffCOMMIT ;Appendix B: Oracle Tuning Recommendations 61


Database Configurationrem Generate Deletion scriptSELECT 'ALTER DATABASE DROP LOGFILE GROUP ' || TO_CHAR ( GROUP# ) || ' ;' from V$LOGwhere BYTES < 2097152.Spool &1.DropLog.ORA/Spool OffCOMMIT ;@&1.AddLog.ORA$Del &1.AddLog.ORACOMMIT ;@&1.SwtchLog.ORA$Del &1.SwtchLog.ORACOMMIT ;@&1.DropLog.ORA$Del &1.DropLog.ORACOMMIT ;2. Run the following query to verify the new Redo log configuration:SQLWKS> select group#, status, bytes from v$log;Note: Oracle does not let you drop an older Redo log file that is still ACTIVE. Ifyou must drop an older Redo log file that is still ACTIVE, drop that log filemanually.Redo Log BufferThe Redo log buffer is an area in memory that Oracle uses to collect DMLsbefore they are written to the Redo log files. The log file write occurs wheneither a transaction commits or a Redo log buffer is full. Because <strong>CA</strong> <strong>ERwin</strong> MMtends to generate fairly large transactions, use a log buffer size of 163840bytes. (For single disk Oracle installations, use a log buffer size of 655360bytes.) Setting the Redo log buffer size to a value smaller than therecommended value can degrade I/O performance. Using a larger valuerequires more memory.The Redo log buffer size is defined using the LOG_BUFFER parameter in theINIT.ora or INIT.ora file.62 <strong>Implementation</strong> <strong>Guide</strong>


Database ConfigurationCheckpointsAn Oracle checkpoint is an event that posts DMLs from the Redo log files to thetablespace files. Checkpoints always occur after a Redo log file switch and canalso be configured to occur at predefined time intervals. For <strong>CA</strong> <strong>ERwin</strong> MM,which generates large transactions, checkpoints should occur only after logswitches to minimize I/O.To ensure a checkpoint only after a log switch, do not set theLOG_CHECKPOINT_INTERVAL and LOG_CHECKPOINT_TIMEOUT parameters inthe INIT.ora or INIT.ora file.Turn on the Optimizer ModeYou can increase the response time of a <strong>CA</strong> <strong>ERwin</strong> MM mart on an Oracle 9.xsystem, when you add the optimizer mode in the initialization file.Note: This is not needed on an Oracle 10g system.To add the optimizer mode in the initialization file:1. Open the init.ora file located in \oracle\admin\dbname\pfile\ wheredbname is the name of the database in which mart is created.The init.ora file is open.2. Add optimizer_mode=ALL_ROWS in the optimizer section.The optimizer mode is added.3. Shutdown and restart the database.Then log into the <strong>CA</strong> <strong>ERwin</strong> MM database as sysdba4. Using SQL*Plus, execute the following commands:execute dbms_stats.gather_system_stats('Start');execute dbms_stats.gather_system_stats('Stop');EXEC DBMS_STATS.gather_database_stats;The commands are executed and the optimizer mode is enabled.Appendix B: Oracle Tuning Recommendations 63


Storage ParametersStorage ParametersObject storage parameters in Oracle determine the amount of space allocatedfor each object in the database. Setting these parameters correctly is critical toboth operation and performance of the database. Incorrect storage allocationscan cause a database object to run out of space, which prevents you fromsaving models to the repository. Inefficient selection of storage parameters canlead to performance problems by forcing Oracle to do time-consuming spacemanagement operations during DML statement execution.Recommendations for storage parameter values differ based on the size ofyour model:■■■Small data models: 1 to 50 EntitiesMedium data models: 51 to 100 EntitiesLarge data models: over 100 EntitiesRollback SegmentsRollback segments contain undo information for all changes performed bynoncommitted transactions. Rollback segments are a shared resource used byall active transactions in the database. When a transaction starts, Oracle bindsthat transaction to a particular rollback segment. As DMLs in the transactionexecute, rollback segment space is used. For large transactions, rollbacksegments may need to allocate new extents as the transaction continues.When the transaction ends, a properly configured Oracle database releases theadditional rollback extents so that they can be used for other rollbacksegments. To ensure that the additional rollback extents are released,configure the OPTIMAL parameter for each rollback segment.Use a maximum of five transactions per rollback segment by setting theTRANSACTIONS_PER_ROLLBACK_SEGMENT parameter in the INIT.ora orINIT.ora file. Use the following rollback segment storage parameters forsmall, medium, and large models:<strong>Model</strong>TypeInitial ExtentSizeNext ExtentSizeOptimal SizeSmall 1 MB 1 MB ~ 2 MB x (# of transactions)Medium 6 MB 6 MB ~ 12 MB x (# oftransactions)Large 6 MB 6 MB ~ 12 MB x (# oftransactions)64 <strong>Implementation</strong> <strong>Guide</strong>


Storage ParametersNote: The “# of transactions” is the maximum number of simultaneous <strong>CA</strong><strong>ERwin</strong> MM connections to Oracle.In Oracle it is common to see the following error statement when the Rollbacklogs are not set up optimally:ORA-01562 failed to extend rollback segment number stringSet Optimal Configuration for the Rollback LogsFor large transactions, rollback segments may need to allocate new extents asthe transaction continues. When the transaction ends, a properly configuredOracle database releases the additional rollback extents so that they can beused for other rollback segments. To ensure that the additional rollbackextents are released, configure the OPTIMAL parameter for each rollbacksegment.To set the optimal configuration for the rollback logs of largedatabases1. Log in to Oracle as SYS or SYSTEM and run the following query and checkthe result to view the current configuration of the Rollback Segments:SQLWKS> select SEGMENT_NAME, INITIAL_EXTENT, NEXT_EXTENT, MIN_EXTENTS,MAX_EXTENTS, STATUS from dba_rollback_segs;The result is:SEGMENT_NAME INITIAL_EX NEXT_EXTEN MIN_EXTENT MAX_EXTENT STATUSSYSTEM 51200 51200 2 121 ONLINERB_TEMP 102400 102400 2 121 OFFLINERB1 2097152 2097152 2 121 ONLINERB2 2097152 2097152 2 121 ONLINERB3 2097152 2097152 2 121 ONLINERB4 2097152 2097152 2 121 ONLINERB5 2097152 2097152 2 121 ONLINERB6 2097152 2097152 2 121 ONLINERB7 2097152 2097152 2 121 ONLINERB8 2097152 2097152 2 121 OFFLINERB9 2097152 2097152 2 121 OFFLINERB10 2097152 2097152 2 121 OFFLINERB11 2097152 2097152 2 121 OFFLINERB12 2097152 2097152 2 121 OFFLINERB13 2097152 2097152 2 121 OFFLINERB14 2097152 2097152 2 121 OFFLINERB15 2097152 2097152 2 121 OFFLINERB16 2097152 2097152 2 121 OFFLINE18 rows selected.Note: In this example, there are sixteen rollback segments with 2 MBINITIAL EXTENT, 2 MB NEXT EXTENT, and MAX EXTENTS of 121 MB.Appendix B: Oracle Tuning Recommendations 65


Storage Parameters2. Run the following query for each Rollback Segment:alter rollback segment rb1 offline;drop rollback segment rb1;create public rollback segment rb1tablespace rollback_datastorage (initial 6Mnext 6Mminextents 2maxextents 121optimal 12M);alter rollback segment rb1 online;alter rollback segment rb2 offline;drop rollback segment rb2;create public rollback segment rb2tablespace rollback_datastorage (initial 6Mnext 6Mminextents 2maxextents 121optimal 12M);alter rollback segment rb2 online;This query sets the optimal Rollback Segment configuration to 6 MBINITIAL EXTENT, 6 MB NEXT EXTENT, 2 MB MIN EXTENT, 121 MB MAXEXTENT, and 12 MB OPTIMAL.66 <strong>Implementation</strong> <strong>Guide</strong>


Storage Parameters3. Run the following query to verify the Rollback segment configurationchanges:SQLWKS> select SEGMENT_NAME, INITIAL_EXTENT, NEXT_EXTENT,MIN_EXTENTS,MAX_EXTENTS, STATUS from dba_rollback_segs;The result is:SEGMENT_NAME INITIAL_EX NEXT_EXTEN MIN_EXTENT MAX_EXTENT STATUSSYSTEM 51200 51200 2 121 ONLINERB_TEMP 102400 102400 2 121 OFFLINERB1 6291456 6291456 2 121 ONLINERB2 6291456 6291456 2 121 ONLINERB3 6291456 6291456 2 121 ONLINERB4 6291456 6291456 2 121 ONLINERB5 6291456 6291456 2 121 ONLINERB6 6291456 6291456 2 121 ONLINERB7 6291456 6291456 2 121 ONLINERB8 6291456 6291456 2 121 ONLINERB9 6291456 6291456 2 121 ONLINERB10 6291456 6291456 2 121 ONLINERB11 6291456 6291456 2 121 ONLINERB12 6291456 6291456 2 121 ONLINERB13 6291456 6291456 2 121 ONLINERB14 6291456 6291456 2 121 ONLINERB15 6291456 6291456 2 121 ONLINERB16 6291456 6291456 2 121 ONLINE18 rows selected.TablespacesTo improve performance you can create more than one tablespace for indexes.Then, after you install the software, you can move some indexes to the othertablespaces.The following table lists the suggested initial sizes for DATA and INDEXtablespaces:Tablespace Small Medium LargeDATA 200 MB 500 MB 1 GBINDEX 200 MB 250 MB 500 MBDATA and INDEX tablespaces with these initial sizes can accommodate at leastten models or versions.Appendix B: Oracle Tuning Recommendations 67


Storage ParametersRecommended Initial Table SizesThe following table lists the recommended initial extent sizes in kilobytes forthe most important tables for small, medium, and large models:Recommended Initial Extent Size (KB)Table Name Small Medium Largem7Object 1096 2193 10963m7ObjectProperty 3288 6579 32889Recommended Initial IndexesThese initial extent sizes are chosen so they can accommodate two versions ofa model. These values are the recommended values of the INITIAL parameterin the STORAGE clause of the CREATE TABLE statement. The size of the nextextent (NEXT parameter in the STORAGE clause) should be half of thecorresponding initial size.The following lists the recommended initial extent sizes in kilobytes for themost important indexes for small, medium, and large models:Recommended Initial Extent Size (KB)Index Name Small Medium LargeXPKm7Object 1415 2829 14146XPKm7ObjectProperty 2098 4195 2097568 <strong>Implementation</strong> <strong>Guide</strong>


Appendix C: <strong>CA</strong> <strong>ERwin</strong> MM PerformanceThis section contains the following topics:Optimize Your <strong>CA</strong> <strong>ERwin</strong> MM Performance (see page 69)Reindex the Database (see page 70)Run the Database Statistics (see page 75)Optimize Your <strong>CA</strong> <strong>ERwin</strong> MM PerformanceThe performance of <strong>CA</strong> <strong>ERwin</strong> MM depends on many factors. This appendixoutlines some steps you can take to improve your performance. The five maincomponents where a slow down can occur are the database, the server, thenetwork, the client PC, and the <strong>CA</strong> <strong>ERwin</strong> MM software.Appendix C: <strong>CA</strong> <strong>ERwin</strong> MM Performance 69


Reindex the DatabaseYou should regularly reindex the database and run the database statistics.Sometimes running the database statistics alone does not affect theperformance, however it is good practice to run the database statistics on aregular basis to ensure the maximum performance of your database.In past releases, multiple versions of the same model in the mart can slowdown overall performance. You can remove versions by selectively purgingthem using the MM Version <strong>Manager</strong>. <strong>CA</strong> <strong>ERwin</strong> MM r7.2 or later lets you todisable the versioning so it does not create a new version with every save of amodel to the mart.If you have many domains in a model, they consume a lot of memory/filespace. Having too many domains can slow down both <strong>CA</strong> <strong>ERwin</strong> Data <strong>Model</strong>erand <strong>CA</strong> <strong>ERwin</strong> MM. If you need to use many domains, we suggest you create atemplate model to house them, and then import the specific domains that youneed, to each of your individual models. If you are using the domains toenforce unique attribute or column naming standards, you can alternativelyuse the <strong>ERwin</strong> Glossary (*.nsm) for that purpose.Check the <strong>CA</strong> <strong>ERwin</strong> MM Release Notes for the latest system requirements.Greater CPU speed, and more RAM and disk space result in betterperformance.Reindex the DatabaseOver a period of time, database indexes become fragmented. A large numberof inserts and deletes can lead to significant performance degradation. Thescripts provided in this appendix rebuild the <strong>CA</strong> <strong>ERwin</strong> MM indexes and fixthem. In some cases, it can make a significant difference in the <strong>CA</strong> <strong>ERwin</strong> MMperformance.We recommend that you reindex your <strong>CA</strong> <strong>ERwin</strong> MM database nightly or duringoff-peak hours. As the index is recreated, the process can temporarily degradethe performance of your database. You can create an automated batch job todo the reindex. You should also reindex the database after a large modelmerge, a save to <strong>CA</strong> <strong>ERwin</strong> MM, and right after a conversion of the <strong>CA</strong> <strong>ERwin</strong>MM mart when upgrading to a later version of the software.70 <strong>Implementation</strong> <strong>Guide</strong>


Reindex the DatabaseRun the Oracle DBMS Reindex ScriptAs the new index is being built, it coexists with the old index in the database.For this reason, you should plan for enough space to store both the old indexand the new index. When the index is rebuilt, the new index becomesavailable, the old index is dropped, and the space is reclaimed by thedatabase. If you encounter any errors while rebuilding the indexes, re-run thestatements. If you require more space to rebuild those specific indexes, addmore storage to your index tablespace, and then try rebuilding those specificindexes again.To run the Oracle DBMS reindex script:1. Create the mmreindex.ora script and copy it locally.2. Edit the script and replace 'MODELMART' with the name of the <strong>CA</strong> <strong>ERwin</strong>MM schema-owner and 'MMINDEX' with the name of the <strong>CA</strong> <strong>ERwin</strong> MMindex tablespace. Save your changes.3. Connect to SQL*PLUS as the user SYS.4. Grant the 'ALTER ANY INDEX' privilege to the <strong>CA</strong> <strong>ERwin</strong> MM SchemaOwner.5. Run your Oracle query tool and execute the following at the SQL prompt:GRANT ALTER ANY INDEX TO ;6. Disconnect user SYS and Connect to your Oracle query tool as the SchemaOwner.7. Execute the following Script at the SQL Prompt,@c:\mmreindex.oraAppendix C: <strong>CA</strong> <strong>ERwin</strong> MM Performance 71


Reindex the DatabaseExample: Oracle DBMS Reindex ScriptAn example of the Oracle dbms reindex script (MMReIndex.ora):------------------------------------------------------------------------------------ Object: MMReIndex.ora-- Desc: Use this Procedure to ReIndex the MM ORACLE Repository whenever a-- Merge/Save of big model is done to MM-- Limitation(s) is specific to Oracle Releases >= 817-- For ORACLE DBMS < 8i Modify the script to Use NOPARALLEL-- NOTE: You will need to change MODELMART to the <strong>Model</strong> <strong>Manager</strong> schema owner name.-- You will need to change MMINDEX to the <strong>Model</strong> <strong>Manager</strong> index tablespace.-- Oracle indexes are not self-balancing. They become fragmented after a large-- number of INSERTs and DELETE which may lead to significant performance degradation.-- This script rebuilds the <strong>Model</strong> <strong>Manager</strong> indexes and cures them.-------------------------------------------------------------------------------------set pagesize 1000set linesize 2000set verify offset feedback offset heading offspool c:\mmreindex.oraSELECT 'ALTER INDEX ' || USER || '.' || INDEX_NAME ||' REBUILD PARALLEL NOLOGGING COMPUTE STATISTICS TABLESPACE MMINDEX;'FROM DBA_INDEXESWHERE OWNER = UPPER ('MODELMART')AND (INDEX_NAME like 'XPK%' or INDEX_NAME like 'XAK%'or INDEX_NAME like 'XIE%')order by index_name;spool offset heading onset pagesize 24set verify onset feedback on@c:\mmreindex.ora/72 <strong>Implementation</strong> <strong>Guide</strong>


Reindex the DatabaseExample: Microsoft SQL Server DBMS Reindex ScriptAn example of the MS SQL Server dbms reindex script:-- Drop the Procedure appropriatelyIF EXISTS (SELECT name FROM sysobjects WHERE name = N'usp_ReIndex' AND type = N'P')BeginDROP PROCEDURE usp_ReIndexPrint 'Procedure Dropped'EndGO-------------------------------------------------------------------------------------- Object: usp_ReIndex-- Desc: Use this Procedure to ReIndex the MM SQL REpository whenever a-- Merge/Save of big model is done to MM-- Change History:-- Name Date Reason----------------------------------------------------------------------------------CREATE PROCEDURE usp_ReIndex ASDeclare@Cmd varchar(2000),@Name SysnameDECLARE tmp_Reindex CURSOR LO<strong>CA</strong>L FORSELECT NameFROM SysObjectsWHERE Type = 'U'OPEN tmp_ReindexFETCH NEXT FROM tmp_Reindex INTO @NameWHILE @@FETCH_STATUS = 0BEGINPrint 'Processing Index for Table ' + @NameSet @cmd = 'DBCC DBREINDEX (' + @Name + ', '''', 0)'Exec (@Cmd)If @@Error 0Print 'Error Reindexing Table ' + @NameFETCH NEXT FROM tmp_Reindex INTO @NameENDClose tmp_Reindexgo-- ReIndex the DBExec usp_ReIndexAppendix C: <strong>CA</strong> <strong>ERwin</strong> MM Performance 73


Reindex the DatabaseExample: Sybase DBMS Reindex ScriptAn example of the Sybase dbms reindex script (MMReIndex.ora):-- Drop the Procedure appropriatelyIF EXISTS (SELECT name FROM sysobjects WHERE name = N'usp_ReIndex' AND type = N'P')BeginDROP PROCEDURE usp_ReIndexPrint 'Procedure Dropped'EndGO-------------------------------------------------------------------------------------- Object: usp_ReIndex-- Desc: Use this Procedure to ReIndex the MM SQL REpository whenever a-- Merge/Save of big model is done to MM-- Change History:-- Name Date Reason----------------------------------------------------------------------------------CREATE PROCEDURE usp_ReIndex ASDeclare@Cmd varchar(2000),@Name Sysname(100) ,@output_str varchar( 255 )DECLARE tmp_Reindex CURSOR FORSELECT nameFROM sysobjectsWHERE type = 'U'OPEN tmp_ReindexFETCH tmp_Reindex INTO @NameWHILE ( @@sqlstatus = 0 )BEGINSELECT @output_str = 'Processing Index for Table '+@NamePrint @output_str--Set @Cmd = 'DBCC REINDEX (' + @Name + ')'--Exec (@Cmd)DBCC REINDEX (@Name )If @@Error 0BeginSELECT @output_str = 'Processing Index for Table1 '+@NamePrint @output_strendFETCH tmp_Reindex INTO @NameENDClose tmp_ReindexgoEXEC usp_ReIndex74 <strong>Implementation</strong> <strong>Guide</strong>


Run the Database StatisticsTroubleshooting the Reindexing ScriptIf your query tool responds:no rows selectednot spooling currentlyit means you do not have the correct name for the <strong>CA</strong> <strong>ERwin</strong> MMschema-owner. You must get the correct user name, replace 'MODELMART'with the user name, and re-run the script.Run the Database StatisticsDatabase statistics show the distribution of the data in the database, and howthe data is stored. When a database executes a query, it uses an optimizer todetermine the best path to access the data. The optimizer relies on executionplans that specify the order in which the database accesses the tables and theexact steps used to pull the data. The database bases the creation of theexecution plans on the database statistics.As the data grows and changes, the statistics quickly become outdated and nolonger reflect the true condition of the database. As a result, the executionplans no longer apply and the optimizer makes poor decisions when processingqueries. You should run statistics regularly to ensure the maximumperformance of your database and, therefore, your <strong>CA</strong> <strong>ERwin</strong> MM mart. Werecommend that you run the database statistics nightly, and create anautomated batch job to simplify the process.Example: Statistics Commands (Oracle)NOTE: In the examples below, the schema owner name is 'MODELMART'To collect statistics for the <strong>CA</strong> <strong>ERwin</strong> MM (does not include the indexstatistics):EXEC DBMS_STATS.gather_schema_stats ('MODELMART',DBMS_STATS.AUTO_SAMPLE_SIZE);To collect statistics for the <strong>CA</strong> <strong>ERwin</strong> MM (includes the index statistics):EXEC DBMS_STATS.gather_schema_stats (ownname => 'MODELMART',cascade =>true, estimate_percent => dbms_stats.auto_sample_size);To delete the statistics:EXEC DBMS_STATS.delete_schema_stats ('MODELMART');Appendix C: <strong>CA</strong> <strong>ERwin</strong> MM Performance 75


Run the Database StatisticsExample: Statistics Script (MS SQL Server)update statistics m7Access with sample 50 percentupdate statistics m7Action with sample 50 percentupdate statistics m7ActionGrouping with sample 50 percentupdate statistics m7Application with sample 50 percentupdate statistics m7BranchLog with sample 50 percentupdate statistics m7Class with sample 50 percentupdate statistics m7Control with sample 50 percentupdate statistics m7ControlCache with sample 50 percentupdate statistics m7Deleted with sample 50 percentupdate statistics m7Library with sample 50 percentupdate statistics m7License with sample 50 percentupdate statistics m7Lock with sample 50 percentupdate statistics m7LockType with sample 50 percentupdate statistics m7Master with sample 50 percentupdate statistics m7Object with sample 50 percentupdate statistics m7ObjectProperty with sample 50 percentupdate statistics m7OldVersions with sample 50 percentupdate statistics m7Permission with sample 50 percentupdate statistics m7PermissionProfile with sample 50 percentupdate statistics m7PermissionType with sample 50 percentupdate statistics m7ProfileAssignment with sample 50 percentupdate statistics m7Property with sample 50 percentupdate statistics m7Query with sample 50 percentupdate statistics m7Session with sample 50 percentupdate statistics m7User with sample 50 percent76 <strong>Implementation</strong> <strong>Guide</strong>


IndexAadministratortasks • 32, 43Bbuffer cache • 59Ccheckpoints • 63createan Oracle user • 27database • 21tablespace • 27Ddatabaseconfiguration • 58convert • 38, 39, 43create • 15, 27database and log sizing • 53initialize • 15, 32, 43maintenance • 53manage • 32, 43options • 52placement • 50post creation tasks • 20tuning parameters • 51update • 43upgrade recommendations • 40Iinstalladministrative files • 29and initialize <strong>CA</strong> <strong>ERwin</strong> MM • 15<strong>CA</strong> <strong>ERwin</strong> MM Objects • 25software upgrade • 42MMicrosoft SQL Serverconnections • 18conversion • 43create • 18database creation requirements • 27database placement • 50initialize • 32, 41, 43maintenance • 53server tuning recommendations • 49settings • 16upgrade recommendations • 41modeling, workgroup • 9, 11, 12, 13OOracle serverconnections • 26conversion • 41, 43create a user • 27create the database • 22initialize • 32Oracle SQL commands • 27Transact SQL commands • 21tuning recommendations • 57upgrade recommendations • 41Rrecommendationsdisk • 57index • 68table size • 68requirementssystem • 27SSybase serverconnections • 20conversion • 43create database • 19initialize • 32server tuning recommendations • 49upgrade recommendations • 41Ttablespaces • 67transaction log • 51Uupgrade<strong>CA</strong> <strong>ERwin</strong> MM • 37recommendations • 40software • 37Index 77


78 <strong>Implementation</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!