Adaptive Server IQ
Administration and Performance Guide
 Document ID
 Contents
 Contents
 104
100
101
103
 138
Contents Deleting views 131 Views in the system tables
132
135
 Vii
 Viii
 277
Using cursors on Select statements in procedures 253
255
273
 309
Contents Referential integrity is unenforced 284
285
299
 Managing User IDs and Permissions
323
339
352
 Xii
 Xiii
 467
448
454
459
 481
473
476
479
 Xvi
 How to use this book
Audience
Xvii
 Documentation for Adaptive Server IQ
Guide to using this book To learn how to Read this chapter
Related documents
Related documents
 Xix
About This Book
 Related documents
 Introduction to Adaptive Server IQ
Overview of IQ system administration
 System administration tasks
System administration tasks
 Overview of Adaptive Server IQ System Administration
Administrative tasks
Security overview
 Granting permissions
Tools for system administration
Tools for system administration
Types of users
 Catalogs and IQ
Database server
 Catalog Store
Adaptive Server Anywhere and Adaptive Server IQ
IQ Store
Temporary Store
 Concurrent operations
Stored procedures
 Stored procedures
Adaptive Server IQ stored procedures
 Stored Procedures for the IQ Store Procedure name Purpose
Adaptive Server Enterprise system and catalog procedures
 System procedure Description
Adaptive Server Enterprise system procedures
 Procedure name Purpose
Catalog stored procedures
Adaptive Server Enterprise catalog procedures
Catalog procedure Description
 System tables and views
System tables and views
System table Description
 Sysdomain
 Syslogin
 Sysuserauth
System view Description
 Functions
Commands and Functions
Commands and Functions
Types of SQL statements
 Message logging
Manipulate date and time data for example, TODAY, Datediff
Fourth line of the file contains version information
 Utility database
Utility database
 Compatibility with earlier versions
 Compatibility with earlier versions
 Starting the database server
 Server command lines
Server command lines
General form for the server command line is as follows
 Running Adaptive Server IQ
Starting the server on Unix
 Using the startup utility
To start the server on Unix using the startup utility
Starting the server on Unix
 Typing the server startup command
 Starting the server on Windows NT
Starting the server from the NT Start menu
Starting the server on Windows NT
 Running the server outside the current session
 Running the Unix database server as a daemon
Using command-line switches
Running the server as a Windows NT service
Using command-line switches
 Case sensitivity Using configuration files
 Elora 16M Tcpipport=2367 -gm Gp 4096 path\mydb.db
 Database started
Naming the server and databases
Required if you do not supply a database
Window
 Sample database on that server
 Setting memory switches
Controlling performance from the command line
 Concurrent user connections on a particular server
Default value of -iqgovernis 2 x the number of CPUs +10
This switch as the number of megabytes of wired memory
Use
 Setting switches that affect timing
 Other performance-related switches
Controlling permissions from the command line
 Setting a maximum Catalog page size
 Selecting communications protocols
Setting up a client/server environment
 Limiting inactive connections
 Connections, and Catalog page size
Starting a server in forced recovery mode
Starting a server from Dbisql
Server from Dbisql
 Log file name has this format
Monitoring server activity
Starting multiple servers or clients on the same machine
Capture server activity in a log file
 Monitoring server activity
 Stopping the database server
 PID
Stopping the database server
 Will be stopped even if there are connections to it
Who can stop the server?
Shutting down operating system sessions
Following example stops a server from Dbisql
 Starting and stopping databases
Starting and stopping databases
 From a command line, type the following command
Command that executes when you perform these steps is
Starting the asiqdemo database
 Starting and stopping Sybase Central
Starting and stopping Sybase Central
 Connecting to a plug-in
Connecting a plug-in
 Introduction to connections
Stopping Sybase Central
Introduction to connections
 If you want Consider reading
How connections are established
 This is equivalent to the following connection string
Connection parameters specify connections
Connection parameters are passed as connection strings
Following form
 Simple connection examples
 To connect from a Unix system
Connecting to a database from Dbisql
Simple connection examples
If you need to start the sample database, enter
 To connect from a Windows NT system
 Connecting to other databases from Dbisql
Password
Enter the user ID
 Connecting to an embedded database
Start Dbisql by typing at a system command prompt
To connect to a database from Dbisql on Unix
 To connect to an embedded database from Dbsql in Windows NT
Extra cache needed for Java
 To connect using a data source
Connecting using a data source
 Connecting to a server on a network
 Using default connection parameters
 Database
Connecting from Adaptive Server IQ utilities
Named server, using the default database
You may connect to the wrong server
 Working with Odbc data sources
 Working with Odbc data sources
DSNs and FILEDSNs
 Creating and editing Odbc data sources
 To test an Odbc Data Source
Creating and editing Odbc data sources
You could also use the host network address. For example
To create an Odbc User Data Source
 Odbc tab
Configuring Odbc data sources
 Prevent Driver Not Capable errors
 Login tab
Database tab
Selecting this
 Advanced tab
Network tab
 Which the debugging information is to be saved
Enter any additional switches here
Creating a File Data Source
Name of the file
 Using Odbc data sources on Unix
Using Odbc data sources on Unix
 Short Parameter Form Argument Description
Connection parameters
 Connection parameters
 Connection parameters and their values are case insensitive
Not supported in Odbc connections
Parameters
Or NO, OFF, 0, or False if false
 Use the Start parameter to specify cache size
Specify database files using DBF
Specify database names using DBN
Connection parameter priorities
 Steps in establishing a connection
How Adaptive Server IQ makes connections
 Locating the interface library
How Adaptive Server IQ makes connections
Unix dblib6 with an operating system-specific extension
 Parameter
Assembling a list of connection parameters
Connection file
AutoStop Ignored if the database is already loaded
 Is already running
 Ways by supplying network communication parameters
Locating a server
 How Adaptive Server IQ makes connections
 Locating the database
 Server name caching for faster connections
 Interactive SQL connections
Connecting from other databases
 Using an integrated login
Using an integrated login
 Using integrated logins
Enabling the integrated login feature
To use an integrated login
 Creating an integrated login
To map an integrated login from Sybase Central
To map an integrate login using a SQL statement
 Connecting from a client application
Following Dbisql statement
Can connect to a database if all the following are true
 Security concerns unrestricted database access
 Setting temporary public options for added security
 Creating a default integrated login user
Network aspects of integrated logins
 Troubleshooting startup, shutdown, and connections
What to do if you can’t start Adaptive Server IQ
Ensure that your files are valid
 Check environment variables
Debugging network communications startup problems
Troubleshooting startup, shutdown, and connections
Ensure that network communication software is running
 What to do if you can’t connect to a database
 Stopping a database server in an emergency Unix
Resolving problems with your Dbisql window on Unix
 Running Adaptive Server IQ
 Troubleshooting startup, shutdown, and connections
 Designing your database
Building Your Adaptive Server IQ Databases
 100
Using Sybase Central to work with database objects
Tools for working with database objects
Building Your Adaptive Server IQ Databases
 101
Step-by-step overview of database setup
Using Dbisql to work with database objects
Working with Database Objects
 To set up an IQ database
Scheduling data definition tasks
102
 103
Extending data definition privileges
 Selecting a device type
Allocating space for databases
104
 105
Estimating space and dbspaces required
 Working with databases
Working with databases
106
 107
Creating a database
 108
 109
 110
 111
Choosing an IQ page size
 Specifying the size of your database
Choosing a Catalog page size
112
 113
Choosing a block size for your database
Enabling Java in the database
IQ Store size is 8MB and the Temporary Store is 4MB
 114
Adding dbspaces
 To create a dbspace in Sybase Central
115
 116
Dropping dbspaces
 117
=======================================================
 Working with tables
Working with tables
Dropping a database
Creating tables
 119
 120
Types of tables
 121
Table placement
Type of table Permitted placement Default placement
Automatic index creation for IQ tables
 122
Optimizing storage and query performance
Data type of the column and its width
See the following table for implications of IQ Unique
 123
Altering tables
 Dropping tables
124
To drop a table in Sybase Central
 Creating primary and foreign keys
125
To create a primary key in Sybase Central
 126
 To create an unenforced foreign key in Sybase Central
Working with views
Table information in the system tables
127
 128
Creating views
Working with views
Definition in the database system tables
 Using views
129
To create a view in Sybase Central
 Alter View statement maintains the permissions on the view
Modifying views
Permissions on views
An existing view definition
 Deleting views
Views in the system tables
131
 132
Working with indexes
Introduction to indexes
Working with indexes
 Creating indexes
Indexes in the system tables
133
 134
Removing indexes
 135
Overview of indexes
Adaptive Server IQ index types
Indexing
 136
Overview of indexes
 Benefits over traditional indexes
Adaptive Server IQ Indexes
137
 Region column of the salesorder table
Creating Adaptive Server IQ indexes
Create Index statement
Creating Adaptive Server IQ indexes
 To create an index with Sybase Central
Creating an index with Sybase Central
Creating indexes concurrently
139
 Choosing an index type
Choosing an index type
140
 Number of unique values in the index
Types of queries
141
 142
Query type/index
Type of Query Usage Recommended Index Type
 143
Only the default index supports the following data types
Indexing criteria disk space usage
Data types in the index
 144
Adaptive Server IQ index types
Combining index types
Adaptive Server IQ index types
 Recommended use
Default column index
LowFast LF index type
Projections on few rows
 Additional indexes
HighGroup HG index type
Advantages and disadvantages of LowFast
Comparison with other indexes
 HG advantages/disadvantages Advantages Disadvantages
Advantages and disadvantages of HighGroup
Automatic creation of HighGroup index
147
 HighNonGroup HNG index type
Advantages and disadvantages of HighNonGroup
148
 149
Optimizing performance for ad hoc joins
Comparison to other indexes
HighGroup index is also appropriate for an HNG column
 Selecting an index
150
Criteria to identify Index to select
 151
Using join indexes
Adding column indexes after inserting data
Join indexes improve query performance
 Join hierarchy overview
When a join becomes ad hoc
How join indexes are used for queries
Relationships in join indexes
 153
Columns in the join index
 Join hierarchy in query resolution
One-to-many relationship
154
 Custid Lname
155
 156
Multiple table joins and performance
 157
Steps in creating a join index
 Synchronizing join indexes
Privileges needed to create a join index
158
 Defining join relationships between tables
Performance hints for synchronization
159
 Using foreign references
Examples of join relationships in table definitions
160
 Specifying the join type when creating a join index
Specifying relationships when creating a join index
161
 Parameters of this command are
Issuing the Create Join Index statement
162
 163
 To add a join index in Sybase Central
Creating a join index in Sybase Central
Types of join hierarchies
164
 Linear joins
Star joins
165
 You can create this table using the following commands
Another table
166
 167
Modifying tables included in a join index
 168
Inserting or deleting from tables in a join index
 Table versioning controls access to join indexes
Estimating the size of a join index
169
 170
Estimating the size of a join index
 171
Import and export overview
Import and export methods
Databases
 File Format Description
Input and output data formats
Import and export overview
172
 Moving Data In and Out of Databases
Scheduling database updates
Permissions for modifying data
Specifying an output format for Interactive SQL
 174
Using output redirection
Exporting data from a database
Exporting data from a database
 Bulk loading data using the Load Table statement
Null value output
175
 Quotes on OFF Escapes on OFF Escape Character character
Bulk loading data using the Load Table statement
176
Format ’ascii’ ’binary’ Delimited by string
 Binary with Null Byte Prefix 1 2 4 ’delimiter-string’
177
 178
 179
 180
 Start ROW ID number
181
Block Factor number Block Size number
Preview on OFF ROW Delimited by ’delimiter-string’
 Here is a Windows NT example
On default is NATIVE. You can also specify
Specifies the byte ordering during reads. This
Endian platforms like DEC ALPHA, and Windows NT
 183
Table. The default is 0 for no limit
Specifies the maximum number of rows to insert into
Options work together
 184
 185
Following Windows NT example sets the column delimiter for
Carriage return \x0d
With the Limit option, and takes precedence over it
 186
 187
Interpreting notification messages
Memory message
This message displays memory usage information
 188
Main IQ Store blocks messages
IQ Temporary Store blocks message
Main buffer cache activity message
 See the description for the Main buffer cache message above
Temporary buffer cache message
Controlling message logging
These lines display information about the Temp buffer cache
 190
Using the Insert statement
Using the Insert statement
Inserting specified values row by row
 Into the lorderkey column in the lineitem table
Inserting selected rows from the database
Complete description of Adaptive Server IQ data types
Following example adds 1995-06-09 into the lshipdate column
 Inserting from a different database
Inserting selected rows from the database
192
 To insert data directly from Adaptive Server Enterprise
Issue a Commit to commit the insert
Lineitem table in the current database
193
 194
 Importing data interactively
Inserting into tables of a join index
195
 Inserting into primary and foreign key columns
Inserting into primary and foreign key columns
196
 197
Partial-width insertions
 Partial-width insertion rules
Partial-width insertions
198
 199
Query
Additional columns
Instead of the correct number
 200
Start ROW ID option in the second Load Table statement
 201
Index
 Converting data on insertion
Converting data on insertion
202
 203
 Conversion options for loading from flat files
Inserting data from pre-Version 12 Adaptive Server IQ
Load conversion options
204
 205
Data conversions in IQ
 IQ conversions for comparison operations
206
 IQ conversions for arithmetic operations
207
 Column width issues
Using the Ascii conversion option
208
 209
 210
Date Option
Substitution of Null or blank characters
Specifying the Date Format
 211
 Setting Year specified as Years assumed
Datetime conversion option
212
 213
Specifying the format for Datetime conversions
 214
Formatting times
10 Datetime format options
 Where Blanks indicates that blanks convert to Nulls
Working With Nulls
215
 Other factors affecting the display of data
Other factors affecting the display of data
216
 Matching Adaptive Server Enterprise data types
Unsupported Adaptive Server Enterprise data types
217
 Adaptive Server Enterprise data type equivalents
Matching Adaptive Server Enterprise data types
218
 Adaptive Server Enterprise Datatype IQ Datatype
219
Adaptive Server Adaptive Server IQ Enterprise Datatype
13 Character data types
 Handling conversion errors on data import
220
15 DATE/TIME data types
 Creating indexes
Tuning bulk loading of data
Improving load performance during database definition
Optimizing for the number of distinct values
 Adding dbspaces
Setting server startup options
Adjusting your environment at load time
Tuning bulk loading of data
 223
Reducing Main IQ Store space use in incremental loads
 Changing data using Update
Changing data using Update
224
 225
Deleting data
 Importing data by replication
Importing data by replication
226
 227
 228
 229
Overview of procedures
Adaptive Server IQ
Statements, are also available in batches
 230
Benefits of procedures
Introduction to procedures
Benefits of procedures
 Creating procedures
Using Procedures and Batches
231
 232
Calling procedures
Dropping procedures
Introduction to procedures
 Permissions to execute procedures
Returning procedure results in parameters
233
 Returning procedure results in result sets
234
Employee ID Salary
 Introduction to user-defined functions
Creating user-defined functions
235
 Fullname empfname, emplname
Calling user-defined functions
Introduction to user-defined functions
236
 237
Dropping user-defined functions
Permissions to execute user-defined functions
Following statement revokes permission to use the function
 Introduction to batches
Introduction to batches
238
 Control statements
239
Dbisql and batches
 Control statement Syntax
Using compound statements
Control statements
240
 241
Declarations in compound statements
 242
Atomic compound statements
 Structure of procedures
SQL statements allowed in procedures
243
 Declaring parameters for procedures
Structure of procedures
244
 245
Passing parameters to procedures
Passing parameters to functions
Or as follows
 246
Returning results from procedures
Returning a value using the Return statement
Returning results from procedures
 247
Returning results as procedure parameters
 Orders variable that is returned to the calling environment
Declared in the procedure argument list
Show the number of orders placed by the customer with ID
CustomerID parameter is declared as an in parameter. This
 249
Returning result sets from procedures
 250
Returning multiple result sets from procedures
Returning variable result sets from procedures
Procedure
 251
Using cursors in procedures
 252
Using cursors in procedures
Cursor management overview
Cursor positioning
 253
Using cursors on Select statements in procedures
 254
 255
Errors and warnings in procedures
 Default error handling in procedures
Errors and warnings in procedures
256
 257
 258
Error handling with on Exception Resume
 On Exception Resume Begin
259
 260
Default handling of warnings in procedures
 261
Using exception handlers in procedures
 262
 263
Nested compound statements and exception handlers
 Using the Execute Immediate statement in procedures
Following statement executes the InnerProc procedure
264
 265
Transactions and savepoints in procedures
Some tips for writing procedures
Check if you need to change the command delimiter
 Some tips for writing procedures
Remember to delimit statements within your procedure
Use fully-qualified names for tables in procedures
Specifying dates and times in procedures
 Verifying procedure input arguments
Statements allowed in batches
267
 Calling external libraries from procedures
Using Select statements in batches
268
 269
Creating procedures and functions with external calls
 External function declarations
Following form for Microsoft Visual C++
270
 271
How parameters are passed to the external function
 272
Special considerations when passing character types
 Data integrity overview
How data can become invalid
273
 Integrity constraints belong in the database
Data integrity overview
274
 Data integrity tools
How database contents get changed
 276
SQL statements for implementing integrity constraints
 Using table and column constraints
Using Unique constraints on columns or tables
277
 278
Using IQ Unique constraint on columns
Using Check conditions on columns
Using table and column constraints
 Column Check conditions from user-defined data types
Option
279
 280
Using Check conditions on tables
Working with column constraints in Sybase Central
Modifying and deleting Check conditions
 281
Declaring entity and referential integrity
 Enforcing entity integrity
If a client application breaches entity integrity
282
 Primary keys enforce entity integrity
Declaring referential integrity
283
 How you define foreign keys
Referential integrity is unenforced
284
 285
Integrity rules in the system tables
 286
Integrity rules in the system tables
 Transactions are logical units of work
Performance and other aspects of database administration
Overview of transactions and versioning
Introduction to transactions
 Overview of transactions and versioning
Using transactions
Starting transactions
Completing transactions
 289
Options in Dbisql
Committing a transaction writes data to disk
Transactions and Versioning
 290
Introduction to concurrency
Subdividing transactions
How concurrency works in IQ
 Concurrency and IQ Multiplex
Concurrency for backups
Why concurrency benefits you
Introduction to versioning
 Table-level versioning
One writer and multiple readers at the table level
292
 Only one writer at a time
293
 294
Multiple writers and readers in a database
 295
Transactions use committed data
 296
Timing of commits on read transactions affects versions
 297
Hold cursors span transactions
 How Adaptive Server IQ keeps track of versions
Versioning of temporary tables
298
 299
Versioning prevents inconsistencies
How locking works
Locks for DML operations
 Locks for DDL operations
How locking works
300
 301
 302
Isolation levels
Primary keys and locking
Isolation levels
 303
Checkpoints, savepoints, and transaction rollback
 Checkpoints, savepoints, and transaction rollback
Checkpoints aid in recovery
When checkpoints occur
Checkpoints
 Savepoints within transactions
Releasing savepoints
305
 Following scenario
Rolling back to a savepoint
Automatic and user-defined savepoints
Naming and nesting savepoints
 Effect of rollback
System recovery
Rolling back transactions
What causes a rollback
 308
How transaction information aids recovery
 309
Performance implications
 Overlapping versions and deletions
Performance implications
310
 311
Cursors in transactions
 Cursors in transactions
Cursors and versioning
Cursor sensitivity
Cursor scrolling
 Controlling message logging for cursors
Cursor command syntax and examples
Hold cursors
Positioned operations
 314
 315
Adaptive Server IQ international features
Installation to handle international language issues
Introduction to international languages and character sets
 316
Using the default collation
Character set questions and answers
Introduction to international languages and character sets
 317
Understanding character sets in software
Pieces in the character set puzzle
International Languages and Character Sets
 Language issues in client/server computing
318
Database server software messages Applications can cause
 319
Code pages in Windows and Windows NT
 320
Ansi and OEM code pages in Windows and Windows NT
 321
Multibyte character sets
 322
Sorting characters using collations
International aspects of case sensitivity
First-byte collation orderings for multibyte character sets
 323
Understanding locales
Introduction to locales
Case insensitivity of identifiers
 Understanding the locale language
Understanding locales
324
 Understanding the locale character set
325
Alternative Language label Label ISO639 language code
 Equivalent Iana labels and a description
326
Character set Label Iana label Description
 327
 Displaying collations
Setting the Sqllocale environment variable
Understanding collations
Understanding the locale collation label
 Collation Label Type Description
Supplied collations
Following collations are supplied with Adaptive Server IQ
329
 330
 331
Ansi or OEM?
 332
 333
 334
 335
 Understanding character set translation
Using multibyte collations
Understanding character set translation
Character translation for database messages
 To use character translation for database messages
337
 Connection strings and character sets
Avoiding character-set translation
338
 Collation internals
339
Language Character set
 340
Comment lines
Title line
Collation internals
 341
Specification Description
Collation sequence section
Following are some sample lines for a collation
 342
Encodings section
That will be sorted together
Following is part of the Shift-JIS collation file
 343
Properties section
 International language and character set tasks
Finding the default collation
Configuring your character set environment
To configure your character set environment
 To determine the locale of a database server
You can determine locale information using system functions
Determining locale information
345
 346
Setting locales
Creating a database with a named collation
Your current machine
 347
List the supplied collation sequences
 Or on Unix
Starting a database server using character set translation
Using Odbc code page translation
To enable character-set translation on a database server
 349
Character set translation for Sybase Central and Dbisql
Creating a custom collation
Set the Dbisql option CHAROEMTranslation to a value of OFF
 350
 To create a database with a custom collation
Compatibility issues
Creating a database with a custom collation
351
 Performance issues
Performance issues
352
 An overview of database permissions
Manage user IDs
353
 DBA authority overview
An overview of database permissions
354
 Managing User IDs and Permissions
Resource authority overview
Ownership permissions overview
Table and views permissions overview
 Managing individual user IDs and permissions
Group permissions overview
356
 357
Changing a password
With the following command
Creating new users
 358
Granting DBA and resource authority
 359
Granting permissions on tables and views
 To grant user permission on tables in Sybase Central
Granting users the right to grant permissions
Context of groups in Permissions of groups
360
 Granting permissions on procedures
To grant user permissions on procedures in Sybase Central
361
 362
Revoking user permissions
 363
To create a group with a name and password
Managing groups
Creating groups
 To create a group in Sybase Central
Granting group membership to users
Managing groups
364
 Permissions of groups
Referring to tables owned by groups
365
 366
Groups without passwords
 Database object names and prefixes
Special groups
367
 368
Database object names and prefixes
 Using views and procedures for extra security
Following command will now work
369
 Using views for tailored security
Using views and procedures for extra security
370
 Using procedures for tailored security
Grant permission for the Sales Manager to examine this view
371
 Be modified is strictly defined
How user permissions are assessed
Managing the resources connections use
How user permissions are assessed
 373
Temporary Store
 374
Users and permissions in the system tables
Users and permissions in the system tables
Limits the number of prepared
 Default Contents
Views Default Contents
375
 376
 377
Backup protects your data
 Backing up your database
Types of backups
Data in backups
Backing up your database
 Transaction log in backup, restore, and recovery
Backup and Data Recovery
379
 Selecting archive devices
Distribution of backup data
Disk backup requirements
Tape backup requirements
 381
Preparing for backup
Obtaining DBA privileges
Rewinding tapes
 Estimating Media Capacity
Retaining old disk backups
Two ways to run Backup
You can run Backup in two ways
 383
Concurrency and backups
Backup statement
To back up an IQ database, use the following syntax
 384
Specifying the type of backup
Specifying operator presence
Specifying archive devices
 385
 386
 387
 388
Backup Examples
Other backup options
Waiting for Tape Devices
 389
Recovery from errors during backup
Checking for backup space
Recovery attempts
 390
After you complete a backup
Performing backups with non-Sybase products
Do not specify the Stacker or Size parameters
 Performing system-level backups
Shutting down the database
391
 392
Restoring from a system-level backup
Performing system-level backups
Backing up the right files
 Validating your database
393
For this size database It takes about this long
 Orphaned block statistic Meaning
Interpreting results
Validating your database
394
 395
Concurrency issues for spiqcheckdb
 396
Before you restore
Restoring your databases
Restoring your databases
 397
Restore accommodates dbspace changes
 Keeping the database unchanged between restores
Restoring disk backup files
Restoring tape backup files
Specifying files for an incremental restore
 399
Restore statement
Restoring from a compatible backup
To restore a database, use the following syntax
 400
Moving database files
 401
 402
 403
Adjusting data sources and configuration files
Restoring in the correct order
Displaying header information
 Set, and the restore order, are as follows
Set must be restored first, and must be in the first device
404
 405
Renaming the transaction log after you restore
Dblog command-line utility
Switch Description
 Maintaining a transaction log or mirror
Validating the database after you restore
Restore requires exclusive write access
Transaction log utility options
 407
Displaying header information
 Recovery from errors during restore
Using Symbolic Links Unix Only
408
 409
Unattended backup
 410
Getting information about backups and restores
Locating the backup log
Getting information about backups and restores
 411
Content of the backup log
 412
Maintaining the backup log
Viewing the backup log in Sybase Central
Recording dbspace names
 413
Determining your data backup and recovery strategy
 414
Scheduling routine backups
Determining the type of backup
Determining your data backup and recovery strategy
 415
Designating Backup and Restore Responsibilities
Improving performance for backup and restore
Increasing the number of archive devices
 Balancing system load
Spooling backup data
Increasing memory used during backup
Eliminating data verification
 417
Controlling the size of the Catalog Store
 418
 Designing for performance
DBA can tune performance by adjusting resource usage
Your hardware and software configuration
Introduction to performance terms
 420
Overview of memory use
Paging increases available memory
Overview of memory use
 421
Utilities to monitor swapping
Server memory
Managing System Resources
 Managing buffer caches
Determining the sizes of the buffer caches
422
 Operating system and other applications
Adaptive Server IQ memory overhead
423
 Memory requirements for loads
Multi-user database access
424
Raw partitions versus file systems
 Adaptive Server IQ main and temp buffer caches
425
Buffer caches and physical memory
 Memory available for buffer caches Example
Example of setting buffer cache sizes
426
Other considerations
 Setting buffer cache sizes
Methods of adjusting buffer cache sizes
427
 Setting buffer cache size database options
428
To change the buffer cache sizes permanently
 Specifying page size
Setting buffer cache size server switches
Setting the page size
Normally you change the buffer cache sizes by setting
 430
Block size
 Data compression
Decrease buffer cache settings
Adjust blocking factor for loads
Saving memory
 Use the following guideline to determine Block Factor
IQ command line option changes
Actively using the database
Optimizing for large numbers of users
 433
Command and set rlimfdmax=4096 in /etc/system
IQ Temp space
System parameters
 434
Platform-specific memory options
 435
Recommendations for small memory configurations
Physical size of memory on the system
Options that can provide more memory
 436
 437
You must then restart the server with the following command
Managing large buffer caches on HP
Controlling file system buffering
 Options for Java-enabled databases
Other ways to get more memory
438
 439
Process threading model
 440
Insufficient threads error
IQ options for managing thread usage
Process threading model
 Balancing I/O
Raw I/O on Unix operating systems
441
 Balancing I/O
Using disk striping
Setting up disk striping on Unix
Setting up disk striping on Windows NT
 Internal striping
Recommendations for disk striping
443
 Disk striping option
Disk striping hints
444
 Across multiple disks
Using multiple dbspaces
Temporary data with the Create Dbspace command
Transaction log file
 Strategic file locations
Message log
446
 447
Working space for inserting, deleting, and synchronizing
 448
Options for tuning resource use
Options for tuning resource use
Restricting concurrent queries
 449
Limiting a query’s memory use
Limiting queries by rows returned
Forcing cursors to be non-scrolling
 Prefetching cache pages
Limiting the number of cursors
Limiting the number of statements
Lowering a connection’s priority
 Disk caching
Restricting database access
Other ways to improve resource use
Optimizing for typical usage
 Indexing tips
Using RAM disk
Indexing tips
Picking the right index type
 Using join indexes
Allowing enough disk space for deletions
453
 Managing database size and structure
Managing database size and structure
Managing the size of your database
Denormalizing for performance
 455
Denormalization has risks
Disadvantages of denormalization
Performance benefits of denormalization
 Improving your queries
Improving your queries
Deciding to denormalize
Tips for structuring queries
 Planning queries
Query evaluation options
457
 458
Setting query optimization options
 Network performance
Improving large data transfers
459
 Isolate heavy network users
Network performance
460
 461
Put small amounts of data in small packets
 462
Put large amounts of data in large packets
 Process at the server level
Filter as much data as possible at the server level
463
 464
 Set to control resource use, see , Managing System
Getting information using stored procedures
Other chapters of this guide for more tuning hints
Viewing the Adaptive Server IQ environment
 466
Viewing the Adaptive Server IQ environment
 467
Monitoring and Tuning Performance
Monitoring the buffer caches
Starting the buffer cache monitor
 468
Monitoring the buffer caches
 469
 470
 471
 Into dummytablename Stop Monitor
Stopping the buffer cache monitor
Examining and saving monitor results
472
 Examples of monitor results
Buffer cache
473
 474
 475
-contentionresults for the main cache are
-contentionresults for the temp cache are
Results for the memory manager are
 Avoiding buffer manager thrashing
Avoiding buffer manager thrashing
476
 477
Monitoring paging on Windows NT systems
Monitoring paging on Unix systems
Here is an example
 478
 479
System utilities to monitor CPU use
 480
System utilities to monitor CPU use
 481
Client/server interfaces to Adaptive Server IQ
Data server for client applications
Restrictions for creating and running these applications
 482
Client/server interfaces to Adaptive Server IQ
 483
Configuring IQ Servers with Dsedit
Interfaces file
Adaptive Server IQ as a Data Server
 484
Using the Dsedit utility
Opening a Directory Services session
Starting Dsedit
 Select a server entry in the Server box
Adding a server entry
Adding or changing the server address
Interfaces file sql.ini
 486
Network Settings, in the Control Panel
 Verifying the server address
Renaming a server entry
487
 488
Sybase applications and Adaptive Server IQ
Open Client applications and Adaptive Server IQ
Deleting server entries
 489
Setting up Adaptive Server IQ as an Open Server
System requirements
Starting the database server as an Open Server
 Configuring your database for use with Open Client
Setting up Adaptive Server IQ as an Open Server
490
 Characteristics of Open Client and jConnect connections
491
Option Set to
 Characteristics of Open Client and jConnect connections
To change the option settings for TDS connections
492
 Servers with multiple databases
To connect to the livecredit server, use this syntax
493
 494
 495
Index
 496
Index
 WINLATIN1
497
 Datetime
498
 Odbc Unix
499
 500
 DDL
501
 Pipenotconnected
502
 503
 See Also Dbisql
504
 505
 506
 Null
507
 TCP/IP
508
 See Also stored
509
 Rawdetect
510
 511
 512
 513
 514
 515
 516