Adaptive Server Enterprise 12.5
Release Bulletin ASE 12.5 on Digital UNIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Emulated instructions warning on DEC
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on HP-UX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Running EJB Server on HP 32-bit machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Error message after running truncate table command
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on IBM AIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Re-entrant libraries required for SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Monitor Server counters increment improperly
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Linux
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
/etc/rc.d/init.d/sybase incorrectly defines $SYBASE variables
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
Harmless error messages when starting Linux with SSL enabled
SSL listener port hangs
Highlighted known Sybase Central problems
Unnecessary characters appear when executing Sybase Central
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
Turning off the O_SYNC flag
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Engine not exiting after ueshutdown()
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 11.9.2
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Silicon Graphics IRIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Compatibility with other products
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
dsedit does not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Backup Server hangs when issued an RCP to dump a database
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
shutdown no wait causes a stacktrace
uninstall does not work with Studio Installer
Product compatibilities
Documentation updates and clarifications
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Reference Manual Volume 1: Building Blocks
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Sun Solaris
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Asynchronous large I/O on UNIX file systems
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Windows
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Cannot use Services to start and stop server on mapped network drive
Using Adaptive Server with MTS and DTC
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrade can cause system path to exceed maximum limit
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Problems using named pipes in the sql.ini file
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic configuration in Adaptive Server and PerfMon
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Installation Guide for ASE 12.5 on Digital UNIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
No such device; operation not supported
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for HP-UX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for IBM AIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Linux
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-Client product descriptions
Sybase installation directory
Installation Requirements
System requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
bccdb database
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation Definitions
Pre-installation tasks
Installing the Linux dummy-network interface
Installing server components
Installing using Red Hat Package Manager (RPM)
Registering Adaptive Server features
Configuring the servers
Installing the documentation
Online documentation
Installing the documentation
Removing Sybase servers
Post-Installation Tasks
Setting environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-Client products
Installing a Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Starting servers when the operating system restarts
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Upgrading Sybase Servers
Overview
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Preparing database and devices
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Restoring replication after upgrade
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verifying that servers are running
Restore functionality in Adaptive Server
Reenabling replication server
Removing old log records
Reenabling replication
Reenabling auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to boot
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after the installer creates files
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Editing a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Troubleshooting resource file installations
Creating Raw Partitions
Overview
Creating the partitions
Binding the partitions for raw disk I/O
Accessing raw devices from Adaptive Sever
Installation Guide for Silicon Graphics IRIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Compatibility with other licensed products
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Sun Solaris
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Starting SySAM as an automatic service
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Windows
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Starting SySAM as an automatic service
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Post-Installation Tasks
Environment variables
Setting environment variables
Reset variables temporarily
Reset variables permanently
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Requirements for starting servers
Checking the server status
Starting servers
Starting and stopping servers using the Control Panel
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Setting server start-up parameters
Server start-up parameters
Changing start-up parameters
Starting servers as an automatic service
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Note server and device names and locations
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Upgrading the server
Testing the Adaptive Server upgrade
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase products
Uninstalling Adaptive Server 12.5
To remove an old server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Adaptive Server failed to start
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Resource file variables
Running the sybatch utility
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Configuration Guide for UNIX
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication
Lightweight Directory Access Protocol
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Using a runserver file
Using the startserver command
Using the monserver command
Starting servers when the operating system restarts
For Compaq Tru64
For HP-UX
For IBM RS/6000
For SGI
For Sun Solaris
For Macintosh OS X
The boot sequence
BootROM
BootX
Kernel initialization
System initialization
The rc.boot and rc scripts
Start-up items
Sybase-provided StartupItems
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Configuring the Operating System
Setting environment variables
DSLISTEN
DSQUERY
PATH
Using the stty setting
Restoring correct permissions
File descriptors and user connections
For Compaq Tru64
For HP-UX
For Sun Solaris and SGI
For Macintosh OS X
Displaying current soft and hard limits
Increasing the soft limit
Increasing the hard limit
Sample program
Adjusting the client connection timeout period
For Compaq Tru64
For HP-UX
For IBM RS/6000
For Sun Solaris
For Macintosh OS X
Checking for hardware errors
For Compaq Tru64
For HP-UX
For IBM RS/6000
For SGI
For Sun Solaris
For Macintosh OS X
Monitoring the use of operating system resources
For Compaq Tru64
For HP-UX
For IBM RS/6000
For Sun Solaris
For SGI
For Macintosh OS X
A sample C shell maintenance script
Adaptive Server Default Configuration
Default settings
Setting Up Communications Across the Network
How clients connect to Adaptive Server
Creating an interfaces file
Contents of an interfaces file
How Adaptive Server listens for client connections
How a client uses an interfaces file
Heterogeneous and homogeneous environments
Understanding the format of the interfaces file
Components of an interfaces file entry
Format by platform
Creating interfaces files for SPX
Utilities for editing the interfaces file
Creating a master interfaces file
Using dsedit or dscp to create a master interfaces file
Using a text editor to create a master interfaces file
Configuring interfaces files for multiple networks
Configuring the server for multiple network handlers
Sample interfaces files for multiple network handlers
Configuring the client connections
Using one network-independent DSQUERY name
Using different DSQUERY names
Configuring for query port backup
Troubleshooting
Server fails to start
Error when executing an ESP
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg and libtcl64.cfg files
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the interfaces file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default language and character set
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
Setting error log paths
Setting the Adaptive Server error log path
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
Setting the maximum capacity for a tape drive
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Using disk drives
Monitoring disk usage
Adding Optional Functionality to Adaptive Server
Adding auditing
Audit system devices and databases
Overview of audit installation
Pre-installation tasks for auditing devices
Installing auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuration Guide for Windows NT
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication (the interfaces file)
Lightweight Directory Access Protocol
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Starting and stopping servers using Sybase Central
Starting and stopping servers using the Control Panel
Starting servers as an automatic service
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Monitoring servers
Sybase Central
The Control Panel
Default Adaptive Server Configuration
Starting Server Config for Adaptive Server
Configuring Adaptive Server
Setting Adaptive Server parameters
Changing the default Backup Server
Changing the default XP Server
Configuring Backup Server
Configuring Monitor Server
Supporting access to large memory
Network Communications Using sql.ini
How clients connect to Adaptive Server
How Adaptive Server listens for client connections
How a client accesses Adaptive Server
Enabling client access to a server
Changing the server entries in sql.ini
Components in the sql.ini file
Server name
Network driver
Service type
Server address
Address format
IP address
Named Pipes format
Windows Sockets format
NWLink IPX/SPX format
Sharing network configuration information
Creating a master sql.ini file
Using NT Registry as a directory service
Verifying server connections
Configuring ODBC connections
Configuring the ODBC driver
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg and libtcl64.cfg files
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the sql.ini file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default character set for servers
Default character set after installation
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Logging errors and events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
NT event-logging
Setting up NT event-logging for use by Adaptive Server
Types of information logged
Managing the logs
Setting error log paths
Setting the Adaptive Server error log path
Setting the Backup Server error log path
Setting the Monitor Server error log path
Enabling and disabling NT event logging
Using Server Config
Using sp_configure
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Logging user-defined events
Using a remote log
Using a central logging site
Logging messages from multiple Adaptive Servers
Setting up a local central logging site
To create and define a Registry key
Viewing the messages
In the NT event log
In the Adaptive Server error log
Using Security Services with NT LAN Manager
Security services with NT LAN Manager
How login authentication works
Administering security services using LAN Manager
Modifying configuration files for a unified login
Setting up drivers for network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
Checking the LAN Manager’s local name
Specifying security information for Adaptive Server
Identifying users and servers to LAN Manager
Configuring Adaptive Server for LAN Manager security
Enabling and disabling external security services
Managing unified login
Requiring unified login
Establishing a secure default login
Mapping LAN Manager login names to server names
Requiring data integrity check
Ensuring adequate memory for security services
Initiating the new security services
Adding logins to support unified login
General procedure for adding logins
Defining the connection to a server for security services
Specifying the principal name
Specifying network-based user authentication
Specifying the name assigned to LAN Manager
Determining the status of security services
Configuration parameters used in security services
Checking data integrity
Checking message sequence
Detecting interception or replay
Specifying a login
Controlling user authentication
Managing login security on an NT computer
Overview of security features
Adaptive Server security
Combined Adaptive Server and NT login security
Standard mode
Integrated mode
Mixed mode
Managing the login security features
Permitting trusted connections
NT Registry parameters
Administering login security using system procedures
Assigning trusted connection permissions
Displaying the current Registry values
Displaying permissions and user names
Revoking permissions granted with sp_grantlogin
Configuring login security
Create NT users and groups
Configure mapping and Default Domain values
Set login security mode
Add network login names to syslogins
Assign roles
Changing login security options
Using E-mail with Adaptive Server
Sybmail messages
Sending messages
Receiving messages
Preparing NT Mail for Sybmail
Connecting to a post office
Creating a mailbox for Adaptive Server
Creating a mail profile for Adaptive Server
Creating an Adaptive Server login for Sybmail
Sybmail and extended stored procedures
Managing a mail session
Starting a session
Starting Sybmail without parameters
Stopping a mail session
Stored and extended procedures for handling messages
Sending messages
Text messages
Query result messages
Receiving messages
Finding the next message
Reading a specific message
Deleting a message
Processing incoming mail
Using Sybmail security
Setting execution privileges
Setting the execution context
Naming both the user and the database
Naming the user but not the database
Naming the database but not the user
Naming neither the user nor the database
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
NT tape drive names
Setting the maximum capacity for a tape drive
Using a hard disk
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Optimizing Adaptive Server performance and tuning
Using dedicated Adaptive Server operation
Using disk drives
Monitoring disk usage
Monitoring Adaptive Server statistics with NT Performance Monitor
Adding Optional Functionality to Adaptive Server
Installing auditing
Audit system devices and databases
The sybsecurity device and database
Tables and devices for the audit trail
Device for syslogs systems table
Pre-installation tasks for auditing devices
Installing Auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Troubleshooting Network Connections
The dsedit Server Ping Utility
Running Server Ping
Troubleshooting connection failures
When a test fails
Using returned messages to diagnose a failure
Failure to connect to Adaptive Server
Failure to load Net-Library DLLs
Failure of other applications
Before calling Sybase Technical Support
Adaptive Server Registry Keys
ASE Replicator User's Guide
About this book
Introduction to ASE Replicator
Understanding replication
Table replication
Stored procedure replication
Transaction replication
Guaranteed delivery
Understanding ASE Replicator
ASE Replicator components
ASE Replicator process
Distribution Database
Publisher component
Distributor component
ASE Replicator processing
ASE Replicator objects
Database connections
Publications and subscriptions
Articles
Fields
ASE Replicator limitations
Setting Up and Starting ASE Replicator
Setting up ASE Replicator
Configuring the primary Adaptive Server
Enabling and configuring CIS
Setting up the ASE Replicator system user
Defining a local name and remote alias for the primary Adaptive Server
Defining a remote server name for the ASE Replicator process
Configuring the tempdb database
Creating the Distribution Database
Configuring the replicate servers and databases
Identifying the remote server
Setting up a separate a Maintenance User login
Granting permissions in the replicate database
Initializing the ASE Replicator process
Running the aserep script the first time
Setting up the sp_helpddb system procedure
Starting ASE Replicator
Using the aserep script
Using the RUN script
Setting up a replication system
Administering ASE Replicator
Administering the ASE Replicator process
Configuring ASE Replicator
Shutting down the ASE Replicator process
Suspending replication
Resuming replication
Monitoring ASE Replicator
Managing database connections
Creating a database connection
Creating a primary database connection
Creating a replicate database connection
Deleting a database connection
Deleting a primary database connection
Deleting a replicate database connection
Configuring a database connection
Configuring a primary database connection
Configuring a replicate database connection
Suspending and resuming database connections
Suspending database connections
Resuming database connections
Getting information about database connections
Getting connection metadata and status information
Getting statistics information for connections
Getting connection configuration information
Getting primary connection configuration information
Getting replicate connection configuration information
Managing publications and subscriptions
Creating publications and subscriptions
Deleting publications and subscriptions
Suspending and resuming subscriptions
Getting information about publications and subscriptions
Getting metadata and status information for publications and subscriptions
Getting statistics information for subscriptions
Managing primary and replicate articles
Creating primary articles
Creating replicate articles
Deleting primary articles
Deleting replicate articles
Materializing and validating replicate articles
Getting information about primary articles
Getting primary article metadata information
Getting information about published fields in primary articles
Getting information about primary articles in publications
Getting information about unpublished objects
Getting information about primary articles with no subscribers
Getting information about replicate articles
Getting replicate article metadata information
Getting information about fields in replicate articles
Getting information about replicate articles in subscriptions
ASE Replicator configuration parameters
General configuration parameters
admin_port
ase_charset
ase_host
ase_port
batch_size
batch_timeout
ddb_name
log_directory
log_trace_verbose
log_wrap
monitor_delay
queue_size
scan_sleep_increment
scan_sleep_max
stat_trunc_interval
stat_write_timeout
status_monitoring
truncate_numops
Connection configuration parameters
gen_id
lti_version
mode
numrecs
queue_size
scan_sleep_increment
scan_sleep_max
timeout
ASE Replicator Procedures
sp_addprimaryart
sp_addprimaryconn
sp_addpub
sp_addreplicateart
sp_addreplicateconn
sp_addsub
sp_configprimaryconn
sp_configrep
sp_configreplicateconn
sp_dropprimaryart
sp_dropprimaryconn
sp_droppub
sp_dropreplicateart
sp_dropreplicateconn
sp_dropsub
sp_helpconn
sp_helplastcommit
sp_helplocator
sp_helpprimaryart
sp_helpprimaryconn
sp_helppub
sp_helprep
sp_helpreplicateart
sp_helpreplicateconn
sp_helpsub
sp_materializesub
sp_resumeprimaryconn
sp_resumerep
sp_resumereplicateconn
sp_resumesub
sp_shutdownrep
sp_suspendprimaryconn
sp_suspendrep
sp_suspendreplicateconn
sp_suspendsub
sp_tracerep
sp_validatesub
Troubleshooting ASE Replicator
Problems that prevent replication from starting
Primary server configuration problems
Remote server configuration problems
ASE Replicator configuration problems
User login or permission problems
Problems that cause ongoing replication to fail
Schema changes in primary or replicate tables
Altering a published primary object
Altering a replicate object
Datatypes, constraints, and column properties
Replicating approximate numeric datatypes
Replicating the value of the timestamp datatype
Replicating IDENTITY columns
Incompatible datatypes
Incompatible primary key constraints
Different null types
Distribution Database Schema
Distribution Database base objects
Distribution Database datatypes
Base tables in the Distribution Database
Distribution Database system table
Connections table
Connection properties table
Publications table
Primary articles table
Primary article fields table
Primary articles/publications relation table
Subscriptions table
Replicate articles table
Replicate article fields table
Transaction log table
Configuration table
Trace table
Statistics table
Base procedures in the Distribution Database
Distribution Database shadow tables
Shadow tables for primary tables without large objects
Shadow tables for primary tables with large objects
Shadow tables for primary procedures
Distribution Database replicate objects
Distribution procedures
Replicate article proxy tables
Glossary
Component Integration Services User's Guide
About this book
Audience
How to use this book
Adaptive Server Enterprise documents
Other sources of information
Conventions
If you need help
Introduction
New features in Adaptive Server Enterprise 12.5
Who can use Component Integration Services
Steps needed to use Component Integration Services
Understanding Component Integration Services
Basic concepts
Access methods
Server classes
Object types
Interface to remote servers
Defining the storage location of individual objects
Creating proxy tables
Proxy tables
Using the create table command
Using the create existing table command
Datatype Conversions
Example of Remote Table Definition
Using the create proxy_table command
Remote Procedures as proxy tables
New server limits
Remote server capabilities
create new proxy table
create existing proxy table
create proxy_table
alter proxy table
select, insert, delete, update
RPC handling
Cascading proxy tables
Proxy databases
User proxy databases
User Proxy Database Schema Synchronization
System proxy databases
System proxy database creation
Schema synchronization when current database has a system proxy database
Stored procedure execution within a system proxy database
Additional behavior of the system proxy database
DDL commands behavior affected by proxy databases
File system access
Directory access
Recursion through subordinate directories
File access
Security considerations
ANSI joins
When the remote server supports only ANSI joins
When the remote server supports both ANSI joins and T-SQL joins
When the remote server supports only DB2-ANSI
When an ANSI query is received for a server that does not support ANSI syntax
50-Table join limit
Union in views
Referential integrity
Remote servers
Defining remote servers
Server class ASEnterprise
Server class ASAnywhere
Server class ASIQ
Server class sql_server
Server class db2
Server class direct_connect
Server class sds
Connection management
LDAP directory services
Secure communication with SSL
Trusted root files
Security issues
Remote server logins
Trusted mode
Mapping of external logins
Remote server connection failover
Remote server capabilities
Query processing
Processing steps
Query parsing
Query normalization
Query preprocessing
Decision point
Component Integration Services plan generation
Adaptive Server optimization and plan generation
Component Integration Services remote location optimizer
Query execution
Distributed query optimization
Component Integration Services access methods
Query plan execution
create table command
create existing table command
alter table command
create index command
drop table command
drop index command
truncate table command
Passthrough mode
The connect to command
sp_autoconnect
sp_passthru
sp_remotesql
Quoted identifier support
auto identity option
Triggers
RPC handling and Component Integration Services
Site handler and outbound RPCs
Component Integration Services and outbound RPCs
Text parameters for RPCs
Text parameter support for XJS/390
Transaction management
Two-phase commit
Server classes and ASTC
Strict DTM enforcement
Enable xact coordination
Enable CIS
CIS set commands
Attach and detach
Pre-12.x servers
Transactional RPCs
Restrictions on transaction management
Using update statistics
Finding index names
Java in the database
@@textsize
@@stringsize
Constraints on Java class columns
Error messages
SQLJ in Adaptive Server Enterprise
Changes to CIS
Java Abstract Datatypes (ADTs)
Datatypes
Unicode support
create table
create existing table
create proxy_table
alter table
select, insert, update and delete statements
Datatype conversions
text and image datatypes
Restrictions on text and image columns
Limits of @@textsize
Odd bytes padded
Converting text and image datatypes
Pattern matching with text data
Entering text and image values
readtext using bytes
text and image with bulk copy
Error logging
text and image data with server class sql_server
text and image data with server class direct_connect (access_server)
db2 server issues
Fine-grained access control
The select into command
select into syntax
Execute immediate
Configuration and tuning
Using sp_configure
sysconfigures table
Changing the configuration parameters
Component Integration Services configuration parameters
Dynamic reconfiguration
Global variables for status
SQL reference
dbcc commands
dbcc options
Trace flags
Transact-SQL commands
alter database
alter table
begin transaction
case
close
commit transaction
connect to...disconnect
create database
create existing table
create index
create proxy_table
create table
create trigger
deallocate cursor
declare cursor
delete
drop database
drop index
drop table
execute
fetch
Functions
insert
open
prepare transaction
readtext
rollback transaction
select
set
setuser
truncate table
update
update statistics
writetext
Tutorial
Getting Started with Component Integration Services
Adding a Remote Server
Overview of the Procedure
Step 1: Add the Remote Server to the Interfaces File
Step 2: Create Server Entries in System Tables
Step 3: Add an Alternate Login and Password
Verifying Connectivity
Mapping Remote Objects to Local Proxy Tables
Overview of the Procedure
Step 1: Define the Storage Location of a Remote Object
Step 2: Map Remote Table Schema to Adaptive Server
Join Between Two Remote Tables
Overview of the Procedure
Step 1: Add the Remote Servers to the Interfaces File
Step 2: Define the Remote Servers
Step 4: Map the Remote Tables to Adaptive Server
Step 5: Perform the Join
Troubleshooting
Problems Accessing Component Integration Services
Problems Using Component Integration Services
Unable to Access Remote Server
Requested Server Name Not Found
Driver Call to Connect Two Endpoints Failed
Login Failed
Unable to Access Remote Object
Problem Retrieving Data From Remote Objects
Object Is Altered Outside Component Integration Services
Index Is Added or Dropped Outside CIS
If You Need Help
Full-Text Search Specialty Data Store User's Guide
About this book
Audience
How to Use This Book
Adaptive Server Enterprise Documents
Other Sources of Information
Conventions
Directory Paths
Formatting SQL Statements
SQL Syntax Conventions
Case
Obligatory Options {You Must Choose At Least One}
Optional Options [You Don’t Have to Choose Any]
Ellipsis: Do It Again (and Again)...
If You Need Help
Introduction
What Is the Full-Text Search Specialty Data Store?
Capabilities of the Full-Text Search Engine
High Availablility
Understanding the Full-Text Search Engine
Components of the Full-Text Search Engine
The Source Table
The Verity Collections
Filters
The text_db Database
The vesaux Table
The vesauxcol Table
The Index Table
The text_events Table
Relationships Between the Components
How a Full-Text Search Works
Configuring Adaptive Server for Full-Text Searches
Configuring Adaptive Server for a Full-Text Search Engine
Enabling Configuration Parameters
Running the installtextserver Script
Editing the installtextserver Script
Running the installtextserver Script
Running the installmessages Script
Running the installevent Script
Editing the installevent Script
Running the installevent Script
Name the local server
Creating and Maintaining the Text Indexes
Setting Up Source Tables for Indexing
Adding an IDENTITY Column to a Source Table
Adding a Unique Index to an IDENTITY Column
Creating the Text Index and Index Table
Specifying Multiple Columns When Creating a Text Index
Bringing the Database Online for Full-Text Searches
Propagating Changes to the Text Index
Replicating Text Indexes
Example: Enabling a New Database for Text Searches
Step 1. Verify that the text_events Table Exists
Step 2. Check for an IDENTITY Column
Step 3. Create a Unique Index on the IDENTITY Column
Step 4. Create the Text Index and Index Table
Step 5. Bring the Database Online for a Full-Text Search
Setting Up Verity Functions
Enabling Query-By-Example, Summarization, and Clustering
Editing the Master style.prm File
Editing Individual style.prm Files
Setting Up a Column to Use As a Sort Specification
Using Filters on Text That Contains Tags
Creating a Custom Thesaurus (Enhanced Version Only)
Examining the Default Thesaurus (Optional)
Creating the Control File
Control File Syntax
Creating the Thesaurus
Replacing the Default Thesaurus with the Custom Thesaurus
Creating Topics (Enhanced Version Only)
Creating an Outline File
Creating a Topic Set Directory
Creating a Knowledge Base Map
Defining the Location of the Knowledge Base Map
Executing Queries Against Defined Topics
Troubleshooting Topics
Writing Full-Text Search Queries
Components of a Full-Text Search Query
Default Behaviour
Pseudo Columns in the Index Table
Using the score Column to Relevance-Rank Search Results
Using the sort_by Column to Specify a Sort Order
Using the summary Column to Summarize Documents
Using Pseudo Columns to Request Clustered Result Sets
Preparing to Use Clustering
Writing Queries Requesting a Clustered Result Set
Full-Text Search Operators
Considerations When Using Verity Operators
Using the Verity Operators
accrue
and, or
complement
in
like
near, near/n
or
phrase
paragraph
product
sentence
stem
sum
thesaurus
topic (Enhanced Version Only)
wildcard
word
yesno
Operator Modifiers
System Administration
Starting the Full-Text Search Engine on UNIX
Creating the Runserver File
Starting the Full-Text Search Engine on Windows NT
Starting the Full-Text Search Engine As a Service
Shutting Down the Full-Text Search Engine
Modifying the Configuration Parameters
Modifying Values in the Enhanced Version
Available Configuration Parameters
Setting the Default Language
.Setting the Default Character Set
Setting the Default Sort Order
Setting Trace Flags
Setting Open Server Trace Flags
Setting Case Sensitivity
Backup and Recovery for the Enhanced Full-Text Search Engine
Customizable Backup and Restore
Backing Up Verity Collections
Restoring Collections and Text Indexes from Backup
Performance and Tuning
Updating Existing Indexes
Increasing Query Performance
Limiting the Number of Rows
Ensuring the Correct Join Order for Queries
Reconfiguring Adaptive Server
cis cursor rows
cis packet size
Reconfiguring the Full-Text Search Engine
batch_size
min_sessions and max_sessions
Using sp_text_notify
Configuring Multiple Full-Text Search Engines
Creating Multiple Full-Text Search Engines at Start-Up
Adding Full-Text Search Engines
Configuring Additional Full-Text Search Engines
Multiple Users
Verity Topics
What are Topics?
Topic Organization
Weight Assignments
Using a Topic Outline File
Making Topics Available
Setup Process
Knowledge Bases of Topics
Combining Topics into a Knowledge Base
Structure of Topics
Top-Level Topics
Subtopics
Evidence Topics
Topic and Subtopic Relationships
Maximum Number of Topics
Topic Naming Issues
Topic Name Length
Case Sensitivity
Verity Query Language
Query Language Summary
Evidence Operators
Proximity Operators
Relational Operators
Concept Operators
Boolean Operators
Modifiers
Operator Precedence Rules
Sample Topic Outlines
Operator Reference
ACCRUE Operator
ALL Operator
AND Operator
ANY Operator
CONTAINS Operator
ENDS Operator
= (EQUALS) Operator
FILTER Operator
> (GREATER THAN) Operator
>= (GREATER THAN OR EQUAL TO) Operator
< (LESS THAN) Operator
<= (LESS THAN OR EQUAL TO) Operator
IN Operator
MATCHES Operator
NEAR Operator
NEAR/N Operator
OR Operator
PARAGRAPH Operator
PHRASE Operator
SENTENCE Operator
SOUNDEX Operator
STARTS Operator
STEM Operator
SUBSTRING Operator
THESAURUS Operator
WILDCARD Operator
Using Wildcard Special Characters
Searching for Non-alphanumeric Characters
Searching for Wildcard Characters as Literals
Searching for Special Characters as Literals
WORD Operator
Modifier Reference
CASE Modifier
MANY Modifier
NOT Modifier
ORDER Modifier
Weights and Document Importance
Topic Weights
Which Operators Accept Weights
How Weights Affect Importance
Assigning Weights
Automatic Weight Assignments
Tips for Assigning Weights
Changing Weights
Topic Scoring and Document Importance
Designing Topics
Preparing Your Topic Design
Understanding Your Information Needs
Understanding Your Documents
Using Scanned Data
Categorizing Document Samples
Topic Design Strategies
Top-Down Design
Bottom-Up Design
Designing the Initial Topic
Outlining a Topic
Top-Down Topic Outline Example
Step One: Establishing an Information Hierarchy
Step Two: Establishing Individual Search Categories
Step Three: Establishing the Topics to be Built
Bottom-Up Topic Outline Example
Step One: Identifying Low-level Topics
Step Two: Categorizing Related Subtopics
Step Three: Establishing Top-Level Topics
System Procedures
sp_check_text_index
sp_clean_text_events
sp_clean_text_indexes
sp_create_text_index
sp_drop_text_index
sp_help_text_index
sp_optimize_text_index
sp_redo_text_events
sp_refresh_text_index
sp_show_text_online
sp_text_cluster
sp_text_configure
sp_text_dump_database
sp_text_kill
sp_text_load_index
sp_text_notify
sp_text_online
Sample Files
Default textsvr.cfg Configuration File
The sample_text_main.sql Script
Sample Files Illustrating Full-Text Search Engine Features
Custom Thesaurus
Topics
Clustering, Summarization, and Query-by-Example
getsend Sample Program
Unicode Support
Glossary
Glossary
Java in Adaptive Server Enterprise
About this book
An Introduction to Java in the Database
Advantages of Java in the database
Capabilities of Java in the database
Invoking Java methods in the database
Invoking Java methods directly in SQL
Invoking Java methods as SQLJ stored procedures and functions
Storing Java classes as datatypes
Storing and querying XML in the database
Standards
Java in the database: questions and answers
What are the key features?
How can I store Java instructions in the database?
How is Java executed in the database?
Client- and server-side JDBC
How can I use Java and SQL together?
What is the Java API?
How can I access the Java API from SQL?
Which Java classes are supported in the Java API?
Can I install my own Java classes?
Can I access data using Java?
Can I use the same classes on client and server?
How do I use Java classes in SQL?
Where can I find information about Java in the database?
What you cannot do with Java in the database
Sample Java classes
Preparing for and Maintaining Java in the Database
The Java runtime environment
Java classes in the database
Sybase runtime Java classes
User-defined Java classes
JDBC drivers
The Java VM
Configuring memory for Java in the database
Enabling the server for Java
Disabling the server for Java
Creating Java classes and JARs
Writing the Java code
Compiling Java code
Saving classes in a JAR file
Installing uncompressed JARs
Installing compressed JARs
Installing Java classes in the database
Using installjava
Retaining the JAR file
Updating installed classes
Referencing other Java-SQL classes
Viewing information about installed classes and JARs
Downloading installed classes and JARs
Removing classes and JARs
Retaining classes
Using Java Classes in SQL
General concepts
Java considerations
Java-SQL names
Using Java classes as datatypes
Creating and altering tables with Java-SQL columns
Altering partitioned tables
Selecting, inserting, updating, and deleting Java objects
Invoking Java methods in SQL
Sample methods
Exceptions in Java-SQL methods
Representing Java instances
Assignment properties of Java-SQL data items
Datatype mapping between Java and SQL fields
Character sets for data and identifiers
Subtypes in Java-SQL data
Widening conversions
Narrowing conversions
Runtime versus compile-time datatypes
The treatment of nulls in Java-SQL data
References to fields and methods of null instances
Null values as arguments to Java-SQL methods
Null values when using the SQL convert function
Java-SQL string data
Zero-length strings
Type and void methods
Java void instance methods
Java void static methods
Equality and ordering operations
Evaluation order and Java method calls
Columns
Variables and parameters
Static variables in Java-SQL classes
Java classes in multiple databases
Scope
Cross-database references
Inter-class transfers
Passing inter-class arguments
Temporary and work databases
Java classes
Data Access Using JDBC
Overview
JDBC concepts and terminology
Differences between client- and server-side JDBC
Permissions
Using JDBC to access data
Overview of the JDBCExamples class
The main( ) and serverMain( ) methods
Using main( )
Using serverMain( )
Obtaining a JDBC connection: the Connecter( ) method
Routing the action to other methods: the doAction( ) method
Executing imperative SQL operations: the doSQL( ) method
Executing an update statement: the UpdateAction( ) method
Executing a select statement: the selectAction( ) method
Calling a SQL stored procedure: the callAction( ) method
Error handling in the native JDBC driver
The JDBCExamples class
The main( ) method
The internalMain( ) method
The connecter( ) method
The doAction( ) method
The doSQL( ) method
The updateAction( ) method
The selectAction( ) method
The callAction( ) method
SQLJ Functions and Stored Procedures
Overview
Compliance with SQLJ Part 1 specifications
General issues
Security and permissions
SQLJExamples
Invoking Java methods in Adaptive Server
Using Sybase Central to manage SQLJ functions and procedures
SQLJ user-defined functions
Handling null argument values
Handling nulls when creating the function
Handling nulls in the function call
Deleting a SQLJ function name
SQLJ stored procedures
Modifying SQL data
Using input and output parameters
Returning result sets
Deleting a SQLJ stored procedure name
Viewing information about SQLJ functions and procedures
Advanced topics
Mapping Java and SQL datatypes
Using the command main method
SQLJ and Sybase implementation: a comparison
SQLJExamples class
Introduction to XML in the Database
Introduction
Source code and javadoc
References
An overview of XML
A sample XML document
HTML display of Order data
XML document types
XSL: formatting XML information
Character sets and XML data
XML parsers
Selecting Data with XQL
Accessing the XML parser
Setting the CLASSPATH environment variable
Installing XQL in Adaptive Server
Converting a raw XML document to a parsed version
Inserting XML documents
Updating XML documents
Deleting XML documents
Memory requirements for running the query engine inside Adaptive Server
Using XQL
Query structures that affect performance
Examples
Other usages of the XQL package
com.sybase.xml.xql.XqlDriver syntax
Sample queries
Validating your document
Using XQL to develop standalone applications
Example standalone application
Example JDBC client
Example EJB example
XQL methods
Methods in com.sybase.xml.xql.Xql
parse(String xmlDoc)
parse(InputStream xml_document, boolean validate)
query(String query, String xmlDoc)
query(String query, InputStream xmlDoc)
query(String query, SybXmlStream xmlDoc)
query(String query, JXml jxml)
sybase.aseutils.SybXmlStream
com.sybase.xml.xql.store.SybMemXmlStream
com.sybase.xml.xql.store.SybFileXmlStream
setParser(String parserName)
reSetParser
Specialized XML Processing
The OrderXml class for order documents
OrderXml(String) constructor
OrderXml(date, customerid, server)
void order2Sql(String ordersTableName, String server)
static void createOrderTable (String ordersTableName, String server)
void setOrderElement (String elementName, String newValue)
String getItemElement (int itemNumber, String elementName)
void setItemElement (int itemNumber, String elementName, String newValue
String getItemAttribute (int itemNumber, elementName, attributeName)
void setItemAttribute (int itemNumber, elementName, attributeName, newValue)
void appendItem (newItemid, newItemName, newQuantity, newUnit)
void deleteItem(int itemNumber)
Storing XML documents
Mapping and storage
Advantages and disadvantages of storage options
Client or server considerations
Creating and populating SQL tables for order data
Tables for element storage
Tables for document and hybrid storage
Using the element storage technique
Composing order documents from SQL data
Generating an order on the client
Generating an order on the server
Translating data from an XML order into SQL
Translating the XML document on the client
Translating the XML document on the server
Using the document storage technique
Storing XML order documents in SQL columns
Inserting an order document from a client file
Inserting a generated order document on the server
Accessing the elements of stored XML order documents
Client access to order elements
Server access to order elements
Appending and deleting items in the XML document
Using the hybrid storage technique
XML for SQL Result Sets
The ResultSetXML class
ResultSetXml(String)
Constructor: ResultSetXml (query, cdataColumns, colNames, server)
ResultXml example
String toSqlScript (resultTableName, columnPrefix, goOption)
String getColumn(int rowNumber, int columnNumber)
String getColumn(int rowNumber, String columnName)
void setColumn (int rowNumber, int columnNumber, newValue)
void setColumn (int rowNumber, String columnName, newValue)
Boolean allString (int ColumnNumber, String compOp, String comparand)
Boolean someString (int columnNumber, String compOp, String comparand)
A customizable example for different result sets
The ResultSet document type
The XML DTD for the ResultSetXml document type
Using the element storage technique
Composing a ResultSet XML document from the SQL data
Generating a ResultSet in the client
Generating a result set in Adaptive Server
Translating the XML ResultSet document in the client
Translating the XML ResultSet Document in Adaptive Server
Using the document storage technique
Storing an XML ResultSet document in a SQL column
Accessing the columns of stored ResultSet documents
A client-side call
A server-side script
Quantified comparisons in stored ResultSet documents
Debugging Java in the Database
Introduction to debugging Java
How the debugger works
Requirements for using the Java debugger
What you can do with the debugger
Using the debugger
Starting the debugger and connecting to the database
Compiling classes for debugging
Attaching to a Java VM
The Source window
The debugger windows
Options
Setting breakpoints
Breaking on a line number
Breaking on a static method
Using counts with breakpoints
Using conditions with breakpoints
Breaking when execution is not interrupted
Disconnecting from the database
A debugging tutorial
Before you begin
Start the Java debugger and connect to the database
Attach to a Java VM
Load source code into the debugger
Step through source code
Examples
Inspecting and modifying variables
Inspecting local variables
Modifying local variables
Inspecting static variables
Network Access Using java.net
Overview
java.net classes
Setting up java.net
Example usage
Using socket classes
Saving text out of Adaptive Server
Using the URL class
Using the MailTo class URL to mail a document
Obtaining an HTTP document
Accessing an external document with XQL
User notes
Where to go for help
Reference Topics
Assignments
Assignment rules at compile-time
Assignment rules at runtime
Allowed conversions
Transferring Java-SQL objects to clients
Supported Java API packages, classes, and methods
Supported Java packages and classes
Unsupported Java packages and classes
Unsupported java.sql methods and interfaces
Invoking SQL from Java
Special considerations
Transact-SQL commands from Java methods
Datatype mapping between Java and SQL
Java-SQL identifiers
Java-SQL class and package names
Java-SQL column declarations
Java-SQL variable declarations
Java-SQL column references
Java-SQL member references
Java-SQL method calls
Glossary
Migrating to Adaptive Server Enterprise 12.5
Introduction and Guide to Resources
In This Chapter
Chapters in the Migration Guide
Relating Documentation to Migration Phase
Other Sources of Information
Sybase Certifications on the Web
Migration Web Page
Classes
Consulting Services
If You Need Help
Analyze: Documenting Business Requirements
In This Chapter
Diagramming the System
Operational Business Requirements
Availability Requirements
Database Change Metrics
Database Dump Details
Maintenance Procedures
Service Level Requirements
Transaction Profile
Current Performance Metrics
Additional Business Requirements
Analyze: Documenting Your Environment
In This Chapter
Hardware Configuration
General Server Hardware
CPU Resources per Machine
Disk Configuration
Network Configuration
Tape Configuration
Physical Memory Utilization
Software Configuration
Operating System
Applications
Sybase Configuration
General Information
Database Devices
Databases and Segments
Dump Devices
Adaptive Server Objects
Gather Scripts to Create Objects
If You Don’t Have Scripts
Query Sybase System Tables
Use System Stored Procedures
Use Sybase Tools
Plan: Writing a Plan and Getting Ready to Migrate
In this Chapter
Review Documentation
Review the Upgrade Process
Special Cases: Migrating to 64-bit Operating System or Larger Page Size
Determine Migration Approach
Parallel With Replication
Cutover Without Replication
Phased Cutover
Write a Migration Plan
Build the Adaptive Server Environment
Update Hardware Resources
Verify Operating System Version and EBF Level
Review Adaptive Server Interoperability with Other Sybase Products
Update Applications and System Administration Procedures
Create Migration Scripts
Implement: Making Required Application Changes
In This Chapter
If Your Version is 11.5
Changes to Locking
Data-only Locking
Changes to Table-Level Locking
Workarounds
Changes to Error Checking
Permissions on Objects in Procedures Checked at Run-time
Stored Procedure Existence Checks in Command Batches
Ordering of Integrity and Permissions Checks
Changes in Error Numbers
11.9.2 Query Processing Changes
New and Changed Statistics
Aggregate Optimization
Costing Large I/O
The optdiag Utility
Trace Flag 302
If Your Version is 11.5 or 11.9.x
ANSI Joins
dsync Function
12.0 Query Processing Changes
Predicate Transformation and Factoring
50 Tables in a Query
Abstract Query Plans
Increased Optimization Time
Like Optimization Enhancements
If Your Version is 11.5, 11.9.x, or 12.0
Changes to Transact-SQL
The enable xact coordination Configuration Parameter
New Reserved Words
Wide Columns and Data Truncation
Change in Truncation Behavior
Using New Wide Data Sizes with Open Client
Wide Columns and Optimizer Statistics
Wide Columns with col_length() and datalength()
Implement: Making Database Administration Changes
In This Chapter
If Your Version is 11.5
New Rollback Records
Optimizer Changes
Updating Statistics After Upgrade
Trace Flag 326
If Your Version is 11.5 or 11.9.x
Documentation Changes
Information Moved to Different Manual
Discontinued Documents
Backup Server
Stripes
Network Connections
File Descriptors
Non-Rewinding Tapes
Starting Backup Server
Dump Format
Suspending Updates to Databases for Copying
New Unix File System Device Support
Changes to dbids
CIS Proxy Databases
ASE Plug-in for Sybase Central
The sybsyntax Utility
If Your Version is 11.5, 11.9.x, or 12.0
Changes to Documentation
System Database Sizes
The sybsystemprocs Database
sybsystemdb
Changes to System Tables
BCP with syslogins
New Database and Table Limits
Maximum Number of Users and Logins
New Table Limits
New Reserved Words
Configuration Parameters
stack size
RPC Problem with “enable xact coordination”
Increased Memory
New Storage for text and image Data
buildmaster Command Obsolete
Test: Ensuring Stability and Performance
In This Chapter
The Goal of Testing
Setting Up the Test Environment
Make Backups
Use Scripts to Create the Test System
Create Your Databases by Loading Backups
If the Test Environment Is Not an Exact Duplicate
Prioritizing Applications to be Tested
Establishing Performance Criteria
Developing Fallback Procedures
Summary of Testing Techniques
Writing Performance Scripts
Write Benchmark Scripts
Drivers
General Error Handling
Deadlock Handling
Result Handling
Time Measurement
Runtime Data Generation
Test Cycle: Summary of Tests
Test Cycle: Testing for Performance
Pre-Upgrade Single-User Tests
Optimizer
I/O
Pre-Upgrade Multi-User Tests
Untimed Benchmarks
Timed Benchmarks
Test System Upgrade
Post-Upgrade Single-User Tests
Post-Upgrade Multi-User Tests
Untimed Benchmarks
Timed Benchmarks
Worksheets for Your Current Environment
Adaptive Server Operational Worksheets
Operational Business Requirements
Backup and Restore Procedures
Database Dump Details
Maintenance Procedure Details
Data Architecture Worksheet
Client Application Components
Production Performance Metrics
Transaction Profile
Adaptive Server Infrastructure Worksheets
Host Configuration
Hardware
Physical Memory Usage
Disk I/O Configuration
Network Configuration
Tape Configuration
Operating System Configuration
Adaptive Server Configuration
Database Devices
Databases and Segments
Dump Devices
Sample Migration Task Lists
Sample Task List Template
General Migration Task List Example
Migration Analysis
Document Current Configuration
Gather Business Requirements
Conduct Compatibility Analysis
Develop Migration Strategy
Migration Preparation
Write Test Plans and Test Scripts
Prepare Applications For Migration
Design and Develop Server Migration Scripts
Design and Develop Database Migration Scripts
Design and Develop Data Migration Scripts
Perform Other Pre-migration Tasks
Implement Migration (Using Install/Load Technique)
Create Target Environment
Perform Server Migration
Perform Database Migration
Perform Data Migration
Complete Server and Data Migration
Perform Application Migration
Implement Migration (Using Upgrade Technique)
Upgrade Adaptive Server
Complete Migration
Perform Application Migration
Migration Quality Assurance
Perform System Tests
Perform Integration Tests
Perform Stress Tests
Perform User Acceptance Tests
Perform Production Data Refresh
Parallel Migration Task List Example
Define Test/Acceptance Criteria—Regression Test Suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Set Up Target Production Environment
Set Up Replication Server
Run Regression Test Suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Upgrade Server B (Shadow)
Run Post-upgrade Regression Test Suites on ASE 12.5 (Server B)
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-End Phase 1 and 2 Regression Test Suite
Other Testing
Run User Acceptance Tests on ASE 12.5 (Server B)
Shift Production Users to Adaptive Server 12.5 (Server B)
Perform Final Steps
Cutover Migration Task List Example
Set Up ASE 12.5 Environment on Development System
Define Test/Acceptance Criteria—Regression Test Suites
Front-end simulation regression test suite
Front-end regression test suite
Define Fallback Procedures on Test System
“Baseline” Older Environment on Test System
Run Regression Test Suites on Older Release Test System
Front-end simulation regression test suite
Front-end Regression Test Suite
Upgrade Test System to Release 12.5
Run Regression Test Suites on Release 12.5 Test System
Back-End Regression Test Suite—Production Loads
Front-End Simulation Regression Test Suite
Front-End Regression Test Suite
Other Testing
Run User/Acceptance Tests on Release 12.5 Test System
Execute Fallback Procedures on Test System
Upgrade Production Server to ASE 12.5
Perform Final Steps
Staged Cutover Task Overview
Tasks
Migration Issue Checklists
Logical Data Architecture
Logical Application Architecture
Logical Technology Architecture
Logical Support Architecture
Migration Strategy Design
Pre-Upgrade Checklist
Pre-Upgrade Checklist
Monitor Client Library Programmer's Guide
About this book
Getting started with Monitor Client Library
Overview
What is Adaptive Server Enterprise Monitor
Adaptive Server Enterprise Monitor components
Adaptive Server Enterprise Monitor architecture
Writing a Basic Monitor Client Library program
Application logic flow
Step 1: define error handling
Step 2: connect to a server
Allocating a connection structure
Setting connection structure properties
Required connection properties
Connecting to a server
Step 3: create a view
Data items
Statistical types
Creating views for a connection
Step 4: create filters
Step 5: set alarms
Step 6: request performance data and process results
Step 7: close and deallocate connections
Closing and deallocating connections
Reopening connections
Playing back recorded data
A sample Monitor Client Library program
Example program
Data Items and Statistical Types
Overview
Result and key data items
Data items and views
Rows with no data versus no rows in views
Server-level status
Combining data items
Result and key combinations
Connection summaries
Current statement and application name data items
Data item definitions
Deciphering the names of data items
SMC_NAME_ACT_STP_DB_ID
SMC_NAME_ACT_STP_DB_NAME
SMC_NAME_ACT_STP_ID
SMC_NAME_ACT_STP_NAME
SMC_NAME_ACT_STP_OWNER_NAME
SMC_NAME_APPLICATION_NAME
SMC_NAME_APP_EXECUTION_CLASS
SMC_NAME_BLOCKING_SPID
SMC_NAME_CONNECT_TIME
SMC_NAME_CPU_BUSY_PCT
SMC_NAME_CPU_PCT
SMC_NAME_CPU_TIME
SMC_NAME_CPU_YIELD
SMC_NAME_CUR_APP_NAME
SMC_NAME_CUR_ENGINE
SMC_NAME_CUR_EXECUTION_CLASS
SMC_NAME_CUR_PROC_STATE
SMC_NAME_CUR_STMT_ACT_STP_DB_ID
SMC_NAME_CUR_STMT_ACT_STP_DB_NAME
SMC_NAME_CUR_STMT_ACT_STP_ID
SMC_NAME_CUR_STMT_ACT_STP_NAME
SMC_NAME_CUR_STMT_ACT_STP_OWNER_NAME
SMC_NAME_CUR_STMT_ACT_STP_TEXT
SMC_NAME_CUR_STMT_BATCH_ID
SMC_NAME_CUR_STMT_BATCH_TEXT
SMC_NAME_CUR_STMT_BATCH_TEXT_ENABLED
SMC_NAME_CUR_STMT_CONTEXT_ID
SMC_NAME_CUR_STMT_CPU_TIME
SMC_NAME_CUR_STMT_ELAPSED_TIME
SMC_NAME_CUR_STMT_LINE_NUM
SMC_NAME_CUR_STMT_LOCKS_GRANTED_IMMED
SMC_NAME_CUR_STMT_LOCKS_GRANTED_WAITED
SMC_NAME_CUR_STMT_LOCKS_NOT_GRANTED
SMC_NAME_CUR_STMT_NUM
SMC_NAME_CUR_STMT_PAGE_IO
SMC_NAME_CUR_STMT_PAGE_LOGICAL_READ
SMC_NAME_CUR_STMT_PAGE_PHYSICAL_READ
SMC_NAME_CUR_STMT_PAGE_WRITE
SMC_NAME_CUR_STMT_QUERY_PLAN_TEXT
SMC_NAME_CUR_STMT_START_TIME
SMC_NAME_CUR_STMT_TEXT_BYTE_OFFSET
SMC_NAME_DATA_CACHE_CONTENTION
SMC_NAME_DATA_CACHE_EFFICIENCY
SMC_NAME_DATA_CACHE_HIT
SMC_NAME_DATA_CACHE_HIT_PCT
SMC_NAME_DATA_CACHE_ID
SMC_NAME_DATA_CACHE_LARGE_IO_DENIED
SMC_NAME_DATA_CACHE_LARGE_IO_PERFORMED
SMC_NAME_DATA_CACHE_LARGE_IO_REQUESTED
SMC_NAME_DATA_CACHE_MISS
SMC_NAME_DATA_CACHE_NAME
SMC_NAME_DATA_CACHE_PREFETCH_EFFICIENCY
SMC_NAME_DATA_CACHE_REUSE
SMC_NAME_DATA_CACHE_REUSE_DIRTY
SMC_NAME_DATA_CACHE_REF_AND_REUSE
SMC_NAME_DATA_CACHE_SIZE
SMC_NAME_DB_ID
SMC_NAME_DB_NAME
SMC_NAME_DEADLOCK_CNT
SMC_NAME_DEMAND_LOCK
SMC_NAME_DEV_HIT
SMC_NAME_DEV_HIT_PCT
SMC_NAME_DEV_IO
SMC_NAME_DEV_MISS
SMC_NAME_DEV_NAME
SMC_NAME_DEV_READ
SMC_NAME_DEV_WRITE
SMC_NAME_ELAPSED_TIME
SMC_NAME_ENGINE_NUM
SMC_NAME_HOST_NAME
SMC_NAME_KPID
SMC_NAME_LOCK_CNT
SMC_NAME_LOCK_HIT_PCT
SMC_NAME_LOCK_RESULT
SMC_NAME_LOCK_RESULT_SUMMARY
SMC_NAME_LOCK_STATUS
SMC_NAME_LOCK_STATUS_CNT
SMC_NAME_LOCK_TYPE
SMC_NAME_LOCKS_BEING_BLOCKED_CNT
SMC_NAME_LOCKS_GRANTED_IMMED
SMC_NAME_LOCKS_GRANTED_WAITED
SMC_NAME_LOCKS_NOT_GRANTED
SMC_NAME_LOG_CONTENTION_PCT
SMC_NAME_LOGIN_NAME
SMC_NAME_MEM_CODE_SIZE
SMC_NAME_MEM_KERNEL_STRUCT_SIZE
SMC_NAME_MEM_PAGE_CACHE_SIZE
SMC_NAME_MEM_PROC_BUFFER
SMC_NAME_MEM_PROC_HEADER
SMC_NAME_MEM_SERVER_STRUCT_SIZE
SMC_NAME_MOST_ACT_DEV_IO
SMC_NAME_MOST_ACT_DEV_NAME
SMC_NAME_NET_BYTE_IO
SMC_NAME_NET_BYTES_RCVD
SMC_NAME_NET_BYTES_SENT
SMC_NAME_NET_DEFAULT_PKT_SIZE
SMC_NAME_NET_MAX_PKT_SIZE
SMC_NAME_NET_PKT_SIZE_RCVD
SMC_NAME_NET_PKT_SIZE_SENT
SMC_NAME_NET_PKTS_RCVD
SMC_NAME_NET_PKTS_SENT
SMC_NAME_NUM_ENGINES
SMC_NAME_NUM_PROCESSES
SMC_NAME_OBJ_ID
SMC_NAME_OBJ_NAME
SMC_NAME_OBJ_TYPE
SMC_NAME_OWNER_NAME
SMC_NAME_PAGE_HIT_PCT
SMC_NAME_PAGE_INDEX_LOGICAL_READ
SMC_NAME_PAGE_INDEX_PHYSICAL_READ
SMC_NAME_PAGE_IO
SMC_NAME_PAGE_LOGICAL_READ
SMC_NAME_PAGE_NUM
SMC_NAME_PAGE_PHYSICAL_READ
SMC_NAME_PAGE_WRITE
SMC_NAME_PROC_STATE
SMC_NAME_PROC_STATE_CNT
SMC_NAME_SPID
SMC_NAME_SQL_SERVER_NAME
SMC_NAME_SQL_SERVER_VERSION
SMC_NAME_STP_CPU_TIME
SMC_NAME_STP_ELAPSED_TIME
SMC_NAME_STP_EXECUTION_CLASS
SMC_NAME_STP_HIT_PCT
SMC_NAME_STP_LINE_NUM
SMC_NAME_STP_LINE_TEXT
SMC_NAME_STP_LOGICAL_READ
SMC_NAME_STP_NUM_TIMES_EXECUTED
SMC_NAME_STP_PHYSICAL_READ
SMC_NAME_STP_STMT_NUM
SMC_NAME_THREAD_EXCEEDED_MAX
SMC_NAME_THREAD_EXCEEDED_MAX_PCT
SMC_NAME_THREAD_MAX_USED
SMC_NAME_TIME_WAITED_ON_LOCK
SMC_NAME_TIMESTAMP
SMC_NAME_TIMESTAMP_DATIM
SMC_NAME_XACT
SMC_NAME_XACT_DELETE
SMC_NAME_XACT_DELETE_DEFERRED
SMC_NAME_XACT_DELETE_DIRECT
SMC_NAME_XACT_INSERT
SMC_NAME_XACT_INSERT_CLUSTERED
SMC_NAME_XACT_INSERT_HEAP
SMC_NAME_XACT_SELECT
SMC_NAME_XACT_UPDATE
SMC_NAME_XACT_UPDATE_DEFERRED
SMC_NAME_XACT_UPDATE_DIRECT
SMC_NAME_XACT_UPDATE_EXPENSIVE
SMC_NAME_XACT_UPDATE_IN_PLACE
SMC_NAME_XACT_UPDATE_NOT_IN_PLACE
Monitor Client Library Functions
Threads
Error handling
Error handler
Callback function
smc_close
smc_connect_alloc
smc_connect_drop
smc_connect_ex
smc_connect_props
smc_create_alarm_ex
smc_create_filter
smc_create_playback_session
smc_create_recording_session
smc_create_view
smc_drop_alarm
smc_drop_filter
smc_drop_view
smc_get_command_info
smc_get_dataitem_type
smc_get_dataitem_value
smc_get_row_count
smc_get_version_string
smc_initiate_playback
smc_initiate_recording
smc_refresh_ex
smc_terminate_playback
smc_terminate_recording
Building a Monitor Client Library Application
Building on UNIX platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Building on Windows platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Monitor Client Library Configuration Instructions
Loading Monitor Client Library
Using Studio Installer
Results of the load
Confirming your login account and permissions
Modifying the interfaces file
Setting up the user environment
Setting the SYBASE environment variable
Overriding the default location of the interfaces file
Using Monitor Client Library
Examples of Views
Cache performance summary
Current statement summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for session
Data cache statistics for sample interval
Device I/O for session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for session
Network activity for sample interval
Network performance summary
Procedure cache statistics for session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Datatypes and Structures
Summary of datatypes
Enum: SMC_ALARM_ACTION_TYPE
Enum: SMC_CLOSE_TYPE
Enum: SMC_DATAITEM_NAME
Enum: SMC_DATAITEM_STATTYPE
Structure: SMC_DATAITEM_STRUCT
Enum: SMC_DATAITEM_TYPE
Enum: SMC_ERR_SEVERITY
Enum: SMC_FILTER_TYPE
Enum: SMC_HS_ESTIM_OPT
Enum: SMC_HS_MISSDATA_OPT
Enum: SMC_HS_PLAYBACK_OPT
Enum: SMC_HS_SESS_DELETE_OPT
Enum: SMC_HS_SESS_ERR_OPT
Enum: SMC_HS_SESS_PROT_LEVEL
Enum: SMC_HS_SESS_SCRIPT_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_INFO_TYPE
Enum: SMC_LOCK_RESULT
Enum: SMC_LOCK_RESULT_SUMMARY
Enum: SMC_LOCK_STATUS
Enum: SMC_LOCK_TYPE
Enum: SMC_OBJ_TYPE
Enum: SMC_PROC_STATE
Enum: SMC_PROP_ACTION
Enum: SMC_PROP_TYPE
Enum: SMC_RETURN_CODE
Enum: SMC_SERVER_MODE
Enum: SMC_SOURCE
Union: SMC_VALUE_UNION
Backward Compatibility
Obsolete and replacement functions
New functions
Rules for functions and callbacks compatibility
Troubleshooting Information and Error Messages
Troubleshooting
Error messages
Communication failure: check if server is running.
Configuration failure: possibly missing interfaces file or bad login parameters.
Don’t know how to build example.h
error L2029: ‘SMC_CONNECT’ : unresolved external
error L2029: ‘SMC_CREATE_VIEW’ : unresolved external
fatal error C1083: Cannot open include file: ‘cstypes.h’: No such file or directory
fatal error C1083: Cannot open include file: ‘mcpublic.h’: No such file or directory
LINK: fatal error L4051: smcapi32.lib : cannot find library
Monitor Historical Server User's Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Adaptive Server Monitor components
Adaptive Server Monitor architecture
Adaptive Server Enterprise Monitor architecture
Historical Server concepts
Recording sessions
Playback sessions
Views
Data items and statistic types
Configuring Historical Server
Historical Server configuration concepts
The Historical Server control file and home directory
Accessing control file information
Do not edit the control file
The operating system start-up account
The Historical Server superuser account
Sybase Open Client/Server connections
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Results of installation on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Windows NT
Assumptions on Windows NT
Results of installation on Windows NT
Configuration procedures on Windows NT
Changing start-up parameter
Setting Historical Server start-up parameters
Function
Syntax
Parameters
Configuring multiple instances of Historical Server
When to create multiple instances of Historical Server
Configuring an additional Historical Server on UNIX platforms
Configuring an additional Historical Server on Windows NT
Task 1: add start-up parameters to the NT Registry
Task 2: update the NT Registry services list
Task 3: add connectivity information for Historical Server
Task 4: configure Historical Server client machines
Task 5: create a .bat file (optional)
Starting and Stopping Historical Server
Starting and stopping Historical Server on UNIX platforms
Starting Historical Server on UNIX
Stopping Historical Server on UNIX
Who can shut down Historical Server
Determining current activity on Historical Server
Deferred versus immediate shutdown
Detailed shutdown procedures
Starting and stopping Historical Server on NT
Starting Historical Server on NT
Inferring start-up parameters from the NT Registry
Verifying that Historical Server is running
Stopping Historical Server on Windows NT
Who can shut down Historical Server on Windows NT
Determining current activity on Windows NT
Deferred versus immediate shutdown on Windows NT
Detailed shutdown procedures on Windows NT
Shutdown methods to avoid on Windows NT
Command Reference
Command summary
Command syntax
Command status and errors
Script files as input to Historical Server
Connecting to Historical Server
Assumptions before connection
How to connect
Required permissions for Historical Server activities
Mutually exclusive sessions
Starting and ending a recording session definition
Starting and ending a playback session
Historical Server commands
hs_create_alarm
hs_create_filter
hs_create_playback_session
hs_create_playback_view
hs_create_recording_session
hs_create_view
hs_delete_data
hs_initiate_playback
hs_initiate_recording
hs_list
hs_playback_sample
hs_shutdown
hs_status
hs_terminate_playback
hs_terminate_recording
Data Files
Overview of Historical Server data files
Description of Historical Server files
Permissions on files
General file format
Control file
Header record
Session control record
View control record
Data item control record
Alarm control record
Filter control record
Data file
Error message file
Script file
Script file table names
Script file table column names
Passing script file commands
Script use example
Bulk copy example
Explanation
Example
Cut utility example
Data Items
Table of data items and definitions
Specifications for Defining Recording Session Views
Definition of key and result
Designing recording session views
Using the Process ID
Using the application name
Empty rows versus no rows in views
Table of valid key and result data item combinations
Examples of valid combinations
Examples of invalid combinations
Table of valid statistic types for data items
Specifications for Defining Playback Views
Summarization level details
Raw playback
Actual playback
Entire playback
Playback with user-defined intervals
Summary of summarization intervals
Designing playback views
Rules for specifying input sessions
Relationship of input views to playback views
Rules for defining views
Rules for defining raw playback views
Rules for defining non-raw playback views
Table of data item requirements for playback views
Additional information about some data items
Using “Timestamp”, “Timestamp Datim”, and “Elapsed Time”
Using Process ID
Using Procedure Elapsed Time and Procedure CPU Time
Examples of Recording Session Views
Cache performance summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for recording session
Data cache statistics for sample interval
Device I/O for recording session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for recording session
Network activity for sample interval
Network performance summary
Page I/O
Procedure cache statistics for recording session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Monitor Server User's Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Monitor components
Monitor architecture
Interaction with sp_sysmon
Configuring Monitor Server
Monitoring SQL Server version 11.0.x
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Results of installation on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Microsoft Windows NT
Assumptions on Windows NT
Results of installation on Windows NT
Configuration procedures on Windows NT
Setting up the automatic start-up service
Setting up the server start-up order
Changing the default configuration
Changing start-up information in the NT Registry
Changing the .bat file
Configuring another Monitor Server
Monitor Server start-up parameters
Function
Syntax
Parameters
Adjusting Monitor Server runtime configuration
Monitor Server configuration file
Initial scan interval
Heartbeat interval
Configuring Monitor Server heap space usage
Summary buffer size
Number of summary buffers per event summary request
Maximum number of event summaries per connection
Adaptive Server configuration issues that affect Monitor Server
Restrictions on length of Adaptive Server name
Configuring event buffers
Understanding event buffers and event loss
Determining a value for event buffers per engine parameter
Changing the event buffers per engine parameter
Configuring SQL text buffers
Understanding the SQL text feature
Determining a value for the max SQL text monitored parameter
Changing the max SQL text monitored Parameter
Starting, Verifying, and Stopping Monitor Server
Starting, verifying, and stopping Monitor Server on UNIX platforms
Starting Monitor Server on UNIX
Verifying that Monitor Server is running on UNIX
Stopping Monitor Server on UNIX
Starting, verifying, and stopping Monitor Server on Windows NT
Starting Monitor Server on Windows NT
How start-up parameters are inferred on Windows NT
Verifying that Monitor Server is running on Windows NT
Stopping Monitor Server on Windows NT
Orderly shutdowns and restarts
Orderly shutdowns
Automatic shutdowns
Orderly restarts
Connecting to clients
Monitor Server isql commands
Using the commands
sms_shutdown
sms_status
Troubleshooting Monitor Server
Error messages
Common problems
Monitor Server fails to start
Access violations
Check the NT Registry services entry (NT only)
Client errors
Maximum connection errors
ct_netlib errors (Windows NT)
Messages in Adaptive Server error log
Performance and Tuning Guide
About this book
Overview
Good performance
Response time
Throughput
Designing for performance
Tuning performance
Tuning levels
Application layer
Database layer
Adaptive Server layer
Devices layer
Network layer
Hardware layer
Operating – system layer
Identifying system limits
Setting tuning goals
Analyzing performance
Normal Forms
Locking
Special Considerations
Networks and Performance
Introduction
Potential performance problems
Basic questions on network performance
Techniques summary
Using sp_sysmon while changing network configuration
How Adaptive Server uses the network
Changing network packet sizes
Large versus default packet sizes for user connections
Number of packets is important
Evaluation tools with Adaptive Server
Evaluation tools outside of Adaptive Server
Server-based techniques for reducing network traffic
Impact of other server activities
Single user versus multiple users
Improving network performance
Isolate heavy network users
Set tcp no delay on TCP networks
Configure multiple network listeners
Using Engines and CPUs
Background concepts
How Adaptive Server processes client requests
Client task implementation
Single-CPU process model
Scheduling engines to the CPU
Scheduling tasks to the engine
Execution task scheduling
Scheduling client task processing time
Maintaining CPU availability during idle time
Adaptive Server SMP process model
Scheduling engines to CPUs
Scheduling Adaptive Server tasks to engines
Multiple network engines
Task priorities and run queues
Processing scenario
Housekeeper task improves CPU utilization
Side effects of the housekeeper task
Configuring the housekeeper task
Changing the percentage by which writes can be increased
Disabling the housekeeper task
Allowing the housekeeper task to work continuously
Measuring CPU usage
Single-CPU machines
Using sp_monitor to measure CPU usage
Using sp_sysmon to measure CPU usage
Operating - system commands and CPU usage
Determining when to configure additional engines
Taking engines offline
Enabling engine-to-CPU affinity
Multiprocessor application design guidelines
Distributing Engine Resources
Algorithm for successfully distributing engine resources
Algorithm guidelines
Environment analysis and planning
Analyzing
Example: phase 1 – execution object behavior
Example: phase 2 – the environment as a whole
Performing benchmark tests
Setting goals
Results analysis and tuning
Monitoring the environment over time
Manage preferred access to resources
Types of execution classes
Predefined execution classes
User-Defined execution classes
Execution class attributes
Base priority
Time slice
Task-to-engine affinity
Setting execution class attributes
Assigning execution classes
Engine groups and establishing task-to-engine affinity
How execution class bindings affect scheduling
Execution class bindings
Engine affinity can affect scheduling
Setting attributes for a session only
Getting information
Rules for determining precedence and scope
Multiple execution objects and ECs
Precedence rule
Scope rule
Resolving a precedence conflict
Examples: determining precedence
Example scenario using precedence rules
Planning
Configuration
Execution characteristics
Considerations for Engine Resource Distribution
Client applications: OLTP and DSS
Unintrusive client applications
I/O-bound client applications
Highly critical applications
Adaptive Server logins: high-priority users
Stored procedures: “hot spots”
Controlling Physical Data Placement
Object placement can improve performance
Symptoms of poor object placement
Underlying problems
Using sp_sysmon while changing data placement
Terminology and concepts
Guidelines for improving I/O performance
Spreading data across disks to avoid I/O contention
Avoiding physical contention in parallel join queries
Isolating server-wide I/O from database I/O
Where to place tempdb
Where to place sybsecurity
Keeping transaction logs on a separate disk
Mirroring a device on a separate disk
Device mirroring performance issues
Using serial mode
Creating objects on segments
Using segments
Separating tables and indexes
Splitting large tables across devices
Moving text storage to a separate device
Partitioning tables for performance
User transparency
Partitioned tables and parallel query processing
Distributing data across partitions
Improving insert performance with partitions
How partitions address page contention
Selecting heap tables to partition
Restrictions on partitioned tables
Partition-related configuration parameters
How Adaptive Server distributes partitions on devices
RAID devices and partitioned tables
Space planning for partitioned tables
Read-only tables
Read-mostly tables
Tables with random data modification
Commands for partitioning tables
alter table...partition syntax
alter table...unpartition Syntax
Changing the number of partitions
Distributing data evenly across partitions
Commands to create and drop clustered indexes
Using reorg rebuild on data-only-locked tables
Using drop index and create clustered index
Using constraints and alter table
Special concerns for partitioned tables and clustered indexes
Using parallel bcp to copy data into partitions
Parallel copy and locks
Getting information about partitions
Using bcp to correct partition balance
Checking data distribution on devices with sp_helpsegment
Effects of imbalance of data on segments and partitions
Determining the number of pages in a partition
Updating partition statistics
Syntax for update partition statistics
Steps for partitioning tables
Backing up the database after partitioning tables
Table does not exist
Table exists elsewhere in the database
Table exists on the segment
Redistributing data
Adding devices to a segment
Special procedures for difficult situations
Clustered indexes on large tables
Alternative for clustered indexes
Problems when devices for partitioned tables are full
Adding disks when devices are full
Adding disks when devices are nearly full
Maintenance issues and partitioned tables
Regular maintenance checks for partitioned tables
Database Design
Basic design
Physical database design for Adaptive Server
Logical Page Sizes
Normalization
Levels of normalization
Benefits of normalization
First Normal Form
Second Normal Form
Third Normal Form
Denormalizing for performance
Risks
Disadvantages
Performance advantages
Denormalization input
Techniques
Adding redundant columns
Adding derived columns
Collapsing tables
Duplicating tables
Splitting tables
Horizontal splitting
Vertical splitting
Managing denormalized data
Using triggers
Using application logic
Batch reconciliation
Data Storage
Performance gains through query optimization
Query processing and page reads
Adaptive Server pages
Page headers and page sizes
Varying logical page sizes
Data and index pages
Large Object (LOB) Pages
Extents
Pages that manage space allocation
Global allocation map pages
Allocation pages
Object allocation map pages
How OAM pages and allocation pages manage object storage
Page allocation keeps an object’s pages together
sysindexes table and data access
Space overheads
Number of columns and size
Variable-length columns in APL tables
Variable length columns in DOL tables
Number of rows per data page
Maximum numbers
Arguments for stored procedures
Retrieving data with enhanced limits
Heaps of data: tables without clustered indexes
Lock schemes and differences between heaps
Select operations on heaps
Allpages-locked heap tables
Data-only locked heap tables
Inserting data into an allpages-locked heap table
Conflicts during heap inserts
Inserting data into a data-only-locked heap table
If conflicts occur during heap inserts
Deleting data from a heap table
Deleting from an allpages-locked heap table
Deleting from a data-only locked heap table
Deleting the last row on a page
Updating data on a heap table
Allpages-locked heap tables
Data-only-locked heap tables
How Adaptive Server performs I/O for heap operations
Sequential prefetch, or large I/O
Caches and object bindings
Heaps, I/O, and cache strategies
Overview of cache strategies
LRU replacement strategy
When LRU strategy is used
MRU replacement strategy
Select operations and caching
Data modification and caching
Caching and inserts on heaps
Caching, update and delete operations on heaps
Asynchronous prefetch and I/O on heap tables
Heaps: pros and cons
Maintaining heaps
Methods
Using reorg rebuild to reclaim space
Reclaiming space by creating a clustered index
Reclaiming space using bcp
Transaction log: a special heap table
Indexing for Performance
How indexes affect performance
Detecting indexing problems
Symptoms of poor indexing
Lack of indexes is causing table scans
Index is not selective enough
Index does not support range queries
Too many indexes slow data modification
Index entries are too large
Exception for wide data rows and wide index rows
Fixing corrupted indexes
Repairing the system table index
Repairing a nonclustered index
Index limits and requirements
Choosing indexes
Index keys and logical keys
Guidelines for clustered indexes
Choosing clustered indexes
Candidates for nonclustered indexes
Other indexing guidelines
Choosing nonclustered indexes
Performance price for data modification
Choosing composite indexes
Key order and performance in composite indexes
Advantages and disadvantages of composite indexes
Techniques for choosing indexes
Choosing an index for a range query
Adding a point query with different indexing requirements
Index and statistics maintenance
Dropping indexes that hurt performance
Choosing space management properties for indexes
Additional indexing tips
Creating artificial columns
Keeping index entries short and avoiding overhead
Dropping and rebuilding indexes
How Indexes Work
Types of indexes
Index pages
Root level
Leaf level
Intermediate level
Index Size
Clustered indexes on allpages-locked tables
Clustered indexes and select operations
Clustered indexes and insert operations
Page splitting on full data pages
Exceptions to page splitting
Page splitting on index pages
Performance impacts of page splitting
Overflow pages
Clustered indexes and delete operations
Deleting the last row on a page
Index page merges
Nonclustered indexes
Leaf pages revisited
Nonclustered index structure
Nonclustered indexes and select operations
Nonclustered index performance
Nonclustered indexes and insert operations
Nonclustered indexes and delete operations
Clustered indexes on data-only-locked tables
Index covering
Covering matching index scans
Covering nonmatching index scans
Indexes and caching
Using separate caches for data and index pages
Index trips through the cache
Locking in Adaptive Server
How locking affects performance
Overview of locking
Granularity of locks and locking schemes
Allpages locking
Datapages locking
Datarows locking
Types of locks in Adaptive Server
Page and row locks
Table locks
Demand locks
Demand locking with serial execution
Demand locking with parallel execution
Range locking for serializable reads
Latches
Lock compatibility and lock sufficiency
How isolation levels affect locking
Isolation Level 0, read uncommitted
Isolation Level 1, read committed
Isolation Level 2, repeatable read
Isolation Level 3, serializable reads
Adaptive Server default isolation level
Lock types and duration during query processing
Lock types during create index commands
Locking for select queries at isolation Level 1
Table scans and isolation Levels 2 and 3
Table scans and table locks at isolation Level 3
Isolation Level 2 and Allpages-Locked tables
When update locks are not required
Locking during or processing
Processing or queries for Allpages-Locked tables
Processing or queries for Data-Only-Locked tables
Skipping uncommitted inserts during selects
Pseudo column-level locking
Select queries that do not reference the updated column
Using alternative predicates to skip nonqualifying rows
Qualifying old and new values for uncommitted updates
Suggestions to reduce contention
Using Locking Commands
Specifying the locking scheme for a table
Specifying a server-wide locking scheme
Specifying a locking scheme with create table
Changing a locking scheme with alter table
Before and after changing locking schemes
After alter table completes
Expense of switching to or from allpages locking
Sort performance during alter table
Specifying a locking scheme with select into
Controlling isolation levels
Setting isolation levels for a session
Syntax for query-level and table-level locking options
Using holdlock, noholdlock, or shared
Using the at isolation clause
Making locks more restrictive
Using read committed
Making locks less restrictive
Using read uncommitted
Using shared
Readpast locking
Cursors and locking
Using the shared keyword
Additional locking commands
lock table Command
Lock timeouts
Reporting on Locks
Locking tools
Getting information about blocked processes
Viewing locks
Viewing locks
Intrafamily blocking during network buffer merges
Deadlocks and concurrency
Server-side versus application-side deadlocks
Application deadlock example
Server task deadlocks
Deadlocks and parallel queries
Printing deadlock information to the error log
Avoiding deadlocks
Acquire locks on objects in the same order
Delaying deadlock checking
Identifying tables where concurrency is a problem
Lock management reporting
Locking Configuration and Tuning
Locking and performance
Using sp_sysmon and sp_object_stats
Reducing lock contention
Adding indexes to reduce contention
Keeping transactions short
Avoiding hot spots
Additional locking guidelines
Configuring locks and lock promotion thresholds
Configuring Adaptive Server’s lock limit
Estimating number of locks for data-only-locked tables
Configuring the lock hashtable (Lock Manager)
Setting lock promotion thresholds
Lock promotion and scan sessions
Lock promotion high water mark
Lock promotion low water mark
Lock promotion percent
Setting server-wide lock promotion thresholds
Setting the lock promotion threshold for a table or database
Precedence of settings
Dropping database and table settings
Using sp_sysmon while tuning lock promotion thresholds
Choosing the locking scheme for a table
Analyzing existing applications
Choosing a locking scheme based on contention statistics
Monitoring and managing tables after conversion
Applications not likely to benefit from data-only locking
Tables where clustered index performance must remain high
Tables with maximum-length rows
Setting Space Management Properties
Reducing index maintenance
Advantages of using fillfactor
Disadvantages of using fillfactor
Setting fillfactor values
fillfactor examples
No stored fillfactor values
Table-level or clustered index fillfactor value stored
Use of the sorted_data and fillfactor options
Reducing row forwarding
Default, minimum, and maximum values for exp_row_size
Default value
Specifying an expected row size with create table
Adding or changing an expected row size
Setting a default expected row size server-wide
Displaying the expected row size for a table
Choosing an expected row size for a table
Using optdiag to check for forwarded rows
Querying systabstats to check for forwarded rows
Conversion of max_rows_per_page to exp_row_size
Monitoring and managing tables that use expected row size
Leaving space for forwarded rows and inserts
Extent allocation operations and reservepagegap
Specifying a reserve page gap with create table
Specifying a reserve page gap with create index
Changing reservepagegap
reservepagegap examples
reservepagegap specified only for the table
reservepagegap specified for a clustered index
Choosing a value for reservepagegap
Monitoring reservepagegap settings
reservepagegap and sorted_data options to create index
Background on the sorted_data option
Matching options and goals
Using max_rows_per_page on allpages-locked tables
Reducing lock contention
Indexes and max_rows_per_page
select into and max_rows_per_page
Applying max_rows_per_page to existing data
Memory Use and Performance
How memory affects performance
How much memory to configure
Caches in Adaptive Server
Procedure cache
Getting information about the procedure cache size
proc buffers
proc headers
Monitoring procedure cache performance
Procedure cache errors
Procedure cache sizing
Estimating stored procedure size
Data cache
Default cache at installation time
Page aging in data cache
Effect of data cache on retrievals
Effect of data modifications on the cache
Data cache performance
Testing data cache performance
Cache hit ratio for a single query
Cache hit ratio information from sp_sysmon
Configuring the data cache to improve performance
Commands to configure named data caches
Tuning named caches
Cache configuration goals
Gather data, plan, and then implement
Evaluating cache needs
Large I/O and performance
The optimizer and cache choices
Choosing the right mix of I/O sizes for a cache
Reducing spinlock contention with cache partitions
Cache replacement strategies and policies
Strategies
Policies
Named data cache recommendations
Sizing caches for special objects, tempdb, and transaction logs
Determining cache sizes for special tables or indexes
Examining cache needs for tempdb
Examining cache needs for transaction logs
Choosing the I/O size for the transaction log
Configuring for large log I/O size
Additional tuning tips for log caches
Basing data pool sizes on query plans and I/O
Checking I/O size for queries
Configuring buffer wash size
Overhead of pool configuration and binding objects
Pool configuration overhead
Cache binding overhead
Maintaining data cache performance for large I/O
Diagnosing excessive I/O Counts
Using sp_sysmon to check large I/O performance
Speed of recovery
Tuning the recovery interval
Effects of the housekeeper task on recovery time
Auditing and performance
Sizing the audit queue
Auditing performance guidelines
Determining Sizes of Tables and Indexes
Why object sizes are important to query tuning
Tools for determining the sizes of tables and indexes
Effects of data modifications on object sizes
Using optdiag to display object sizes
Advantages of optdiag
Disadvantages of optdiag
Using sp_spaceused to display object size
Advantages of sp_spaceused
Disadvantages of sp_spaceused
Using sp_estspace to estimate object size
Advantages of sp_estspace
Disadvantages of sp_estspace
Using formulas to estimate object size
Factors that can affect storage size
Storage sizes for datatypes
Tables and indexes used in the formulas
Calculating table and clustered index sizes for allpages-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Compute the size of clustered index rows
Step 4: Compute the number of clustered index pages
Step 5: Compute the total number of index pages
Step 6: Calculate allocation overhead and total pages
Step 7: Calculate the size of the leaf index row
Step 8: Calculate the number of leaf pages in the index
Step 9: Calculate the size of the non-leaf rows
Step 10: Calculate the number of non-leaf pages
Step 11: Calculate the total number of non-leaf index pages
Step 12: Calculate allocation overhead and total pages
Calculating the sizes of data-only-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Calculate allocation overhead and total pages
Step 4: Calculate the size of the index row
Step 5: Calculate the number of leaf pages in the index
Step 6: Calculate the number of non-leaf pages in the index
Step 7: Calculate the total number of non-leaf index pages
Step 8: Calculate allocation overhead and total pages
Other factors affecting object size
Effects of space management properties
Using average sizes for variable fields
Very small rows
LOB pages
Advantages of using formulas to estimate object size
Disadvantages of using formulas to estimate object size
Maintenance Activities and Performance
Running reorg on tables and indexes
Creating and maintaining indexes
Configuring Adaptive Server to speed sorting
Dumping the database after creating an index
Creating an index on sorted data
Maintaining index and column statistics
Rebuilding indexes
Speeding index creation with sorted_data
Creating or altering a database
Backup and recovery
Local backups
Remote backups
Online backups
Using thresholds to prevent running out of log space
Minimizing recovery time
Recovery order
Bulk copy
Parallel bulk copy
Batches and bulk copy
Slow bulk copy
Improving bulk copy performance
Replacing the data in a large table
Adding large amounts of data to a table
Using partitions and multiple bulk copy processes
Impacts on other users
Database consistency checker
Using dbcc tune (cleanup)
Using dbcc tune on spinlocks
When not to use this command
Determining the space available for maintenance activities
Overview of space requirements
Tools for checking space usage and space available
Checking space used for tables and indexes
Checking space on segments
Checking space requirements for space management properties
Space management properties applied to the table
Space management properties applied to the index
Estimating the effects of space management properties
If there is not enough space
tempdb Performance Issues
How management of tempdb affects performance
Main solution areas for tempdb performance
Types and uses of temporary tables
Truly temporary tables
Regular user tables
Worktables
Initial allocation of tempdb
Sizing the tempdb
Placing tempdb
Dropping the master device from tempdb segments
Using multiple disks for parallel query performance
Binding tempdb to its own cache
Commands for cache binding
Temporary tables and locking
Minimizing logging in tempdb
With select into
By using shorter rows
Optimizing temporary tables
Creating indexes on temporary tables
Creating nested procedures with temporary tables
Breaking tempdb uses into multiple procedures
Adaptive Server Optimizer
Definition
Steps in query processing
Working with the optimizer
Object sizes are important to query tuning
Query optimization
Factors examined during optimization
Preprocessing can add clauses for optimizing
Converting clauses to search argument equivalents
Converting expressions into search arguments
Search argument transitive closure
Join transitive closure
Enabling join transitive closure
Predicate transformation and factoring
Example
Guidelines for creating search arguments
Search arguments and useful indexes
Search argument syntax
Nonequality operators
Examples of SARGs
How statistics are used for SARGS
Histogram cells
Density values
Range cell density and total density
How the optimizer uses densities and histograms
Using statistics on multiple search arguments
Default values for search arguments
SARGs using variables and parameters
Join syntax and join processing
How joins are processed
When statistics are not available for joins
Density values and joins
Multiple column joins
Search arguments and joins on a table
Datatype mismatches and query optimization
Overview of the datatype hierarchy and index issues
Comparison of numeric and decimal datatypes
Comparing numeric types to other datatypes
Datatypes for parameters and variables used as SARGs
Troubleshooting datatype mismatch problems fo SARGs
Compatible datatypes for join columns
Troubleshooting datatype mismatch problems for joins
Suggestions on datatypes and comparisons
Forcing a conversion to the other side of a join
Splitting stored procedures to improve costing
Basic units of costing
Advanced Optimizing Tools
Special optimizing techniques
Specifying optimizer choices
Specifying table order in joins
Risks of using forceplan
Things to try before using forceplan
Specifying the number of tables considered by the optimizer
Specifying an index for a query
Risks
Things to try before specifying an index
Specifying I/O size in a query
Index type and large I/O
When prefetch specification is not followed
set prefetch on
Specifying the cache strategy
In select, delete, and update statements
Controlling large I/O and cache strategies
Getting information on cache strategies
Enabling and disabling merge joins
Enabling and disabling join transitive closure
Suggesting a degree of parallelism for a query
Query level parallel clause examples
Concurrency optimization for small tables
Changing locking scheme
Query Tuning Tools
Overview
How tools may interact
Using showplan and noexec together
noexec and statistics io
How tools relate to query processing
Access Methods and Query Costing for Single Tables
Table scan cost
Cost of a scan on allpages-locked table
Cost of a scan on a data-only-locked tables
From rows to pages
How cluster ratios affect large I/O estimates
Data page cluster ratio
Index page cluster ratio
Evaluating the cost of index access
Query that returns a single row
Query that returns many rows
Range queries using clustered indexes (allpages locking)
Range queries with covering indexes
Range queries with noncovering indexes
Result-set size and index use
Costing for noncovering index scans
Costing for forwarded rows
Costing for queries using order by
Prefix subset and sorts
Key ordering and sorts
Specifying ascending or descending order for index keys
How the optimizer costs sort operations
Allpages-locked tables with clustered indexes
Sorts when index covers the query
Sorts and noncovering indexes
Backward scans and joins
Deadlocks and descending scans
Access Methods and Costing for or and in Clauses
or syntax
in (values_list) converts to or processing
Methods for processing or clauses
When table scans are used for or queries
Dynamic index (OR strategy)
Multiple matching index scans (special OR strategy)
How aggregates are optimized
Combining max and min aggregates
Queries that use both min and max
How update operations are performed
Direct updates
In-place updates
Cheap direct updates
Expensive direct updates
Deferred updates
When deferred updates are required
Deferred index inserts
Restrictions on update modes through joins
Joins and subqueries in update and delete statements
Deletes and updates in triggers versus referential integrity
Optimizing updates
Designing for direct updates
Effects of update types and indexes on update modes
Using sp_sysmon while tuning updates
Accessing Methods and Costing for Joins and Subqueries
Costing and optimizing joins
Processing
Index density and joins
Multicolumn densities
Datatype mismatches and joins
Join permutations
Outer joins and join permutations
Nested-loop joins
Cost formula
How inner and outer tables are determined
Access methods and costing for sort-merge joins
How a full-merge is performed
How a right-merge or left-merge is performed
How a sort-merge is performed
Mixed example
showplan messages for sort-merge joins
Costing for merge joins
Costing for a full-merge with unique values
Example: allpages-locked tables with clustered indexes
Costing for a full-merge with duplicate values
Costing sorts
Worktable size for sort-merge joins
When merge joins cannot be used
Use of worker processes
Recommendations for improved merge performance
Enabling and disabling merge joins
At the server level
At the session level
Reformatting strategy
Subquery optimization
Flattening in, any, and exists subqueries
When flattening can be done
Exceptions to flattening
Flattening methods
Join order and flattening methods
Flattened subqueries executed as regular joins
Flattened subqueries executed as existence joins
Flattened subqueries executed using unique reformatting
Flattened subqueries using duplicate elimination
Flattening expression subqueries
Materializing subquery results
Noncorrelated expression subqueries
Quantified predicate subqueries containing aggregates
Subquery introduced with an and clause
Subquery introduced with an or clause
Subquery results caching
Displaying subquery cache information
Optimizing subqueries
or clauses versus unions in joins
Parallel Query Processing
Types of queries that can benefit from parallel processing
Adaptive Server’s worker process model
Parallel query execution
Returning results from parallel queries
Types of parallel data access
Hash-based table scans
Partition-based scans
Hash-based index scans
Parallel processing for two tables in a join
showplan messages
Controlling the degree of parallelism
Configuration parameters for controlling parallelism
How limits apply to query plans
How the limits work in combination
Examples of setting parallel configuration parameters
Using set options to control parallelism for a session
set command examples
Controlling parallelism for a query
Query level parallel clause examples
Worker process availability and query execution
Other configuration parameters for parallel processing
Commands for working with partitioned tables
Balancing resources and performance
CPU resources
Disk resources and I/O
Tuning example: CPU and I/O saturation
Guidelines for parallel query configuration
Hardware guidelines
Working with your performance goals and hardware guidelines
Examples of parallel query tuning
Improving the performance of a table scan
Improving the performance of a nonclustered index scan
Guidelines for partitioning and parallel degree
Experimenting with data subsets
System level impacts
Locking issues
Device issues
Procedure cache effects
When parallel query results can differ
Queries that use set rowcount
Queries that set local variables
Achieving consistent results
Parallel Query Optimization
What is parallel query optimization?
Optimizing for response time versus total work
When is optimization performed?
Overhead costs
Factors that are not considered
Parallel access methods
Parallel partition scan
Requirements for consideration
Cost model
Parallel clustered index partition scan (allpages-locked tables)
Requirements for consideration
Cost model
Parallel hash-based table scan
Hash-based table scans on allpages-locked tables
Hash-based table scans on data-only-locked tables
Requirements for consideration
Cost model
Parallel hash-based index scan
Cost model and requirements
Parallel range-based scans
Requirements for consideration
Additional parallel strategies
Partitioned worktables
Parallel sorting
Summary of parallel access methods
Selecting parallel access methods
Degree of parallelism for parallel queries
Upper limit
Optimized degree
Worker processes for partition-based scans
Worker processes for hash-based scans
Worker processes for range-based scans
Nested-loop joins
Alternative plans
Computing the degree of parallelism for nested-loop joins
Parallel queries and existence joins
Examples
Partitioned heap table
Nonpartitioned heap table
Table with clustered index
Runtime adjustments to worker processes
Parallel query examples
Single-table scans
Table partition scan
Multitable joins
Parallel join optimization and join orders
Subqueries
Queries that require worktables
union queries
Queries with aggregates
select into statements
Runtime adjustment of worker processes
How Adaptive Server adjusts a query plan
Evaluating the effect of runtime adjustments
Recognizing and managing runtime adjustments
Using set process_limit_action
Using showplan
Reducing the likelihood of runtime adjustments
Checking runtime adjustments with sp_sysmon
Diagnosing parallel performance problems
Query does not run in parallel
Parallel performance is not as good as expected
Calling technical support for diagnosis
Resource limits for parallel queries
Parallel Sorting
Commands that benefits from parallel sorting
Requirements and resources overview
Overview of the parallel sorting strategy
Creating a distribution map
Dynamic range partitioning
Range sorting
Merging results
Configuring resources for parallel sorting
Worker process requirements for parallel sorts
Worker process requirements for creating indexes
Using with consumers while creating indexes
Worker process requirements for select query sorts
Worker processes for merge-join sorts
Other worktable sorts
Caches, sort buffers, and parallel sorts
Cache bindings
Number of sort buffers can affect sort performance
Sort buffer configuration guidelines
Using less than the configured number of sort buffers
Configuring the number of sort buffers parameter
Procedure for estimating merge levels and I/O
Configuring caches for large I/O during parallel sorting
Balancing sort buffers and large I/O configuration
Disk requirements
Space requirements for creating indexes
Space requirements for worktable sorts
Number of devices in the target segment
Recovery considerations
Tools for observing and tuning sort behavior
Using set sort_resources on
Examples
Using sp_sysmon to tune index creation
Tuning Asynchronous Prefetch
How asynchronous prefetch improves performance
Improving query performance by prefetching pages
Prefetching control mechanisms in a multiuser environment
Look-ahead set during recovery
Prefetching log pages
Prefetching data and index pages
Look-ahead set during sequential scans
Look-ahead set during nonclustered index access
Look-ahead set during dbcc checks
Allocation checking
checkdb and checktable
Look-ahead set minimum and maximum sizes
When prefetch is automatically disabled
Flooding pools
I/O system overloads
Unnecessary reads
Page chain fragmentation
Tuning Goals for asynchronous prefetch
Commands for configuration
Other Adaptive Server performance features
Large I/O
Sizing and limits for the 16k pool
Limits for the 2K pool
Fetch-and-discard (MRU) scans
Parallel scans and large I/Os
Hash-based table scans
Partition-based scans
Special settings for asynchronous prefetch limits
Setting limits for recovery
Setting limits for dbcc
Maintenance activities for high prefetch performance
Eliminating kinks in heap tables
Eliminating kinks in clustered index tables
Eliminating kinks in nonclustered indexes
Performance monitoring and asynchronous prefetch
Cursors and Performance
Definition
Set-oriented versus row-oriented programming
Example
Resources required at each stage
Memory use and execute cursors
Cursor modes
Index use and requirements for cursors
Allpages-locked tables
Data-only-locked tables
Table scans to avoid the Halloween problem
Comparing performance with and without cursors
Sample stored procedure without a cursor
Sample stored procedure with a cursor
Cursor versus noncursor performance comparison
Locking with read-only cursors
Isolation levels and cursors
Partitioned heap tables and cursors
Optimizing tips for cursors
Optimizing for cursor selects using a cursor
Using union instead of or clauses or in lists
Declaring the cursor’s intent
Specifying column names in the for update clause
Using set cursor rows
Keeping cursors open across commits and rollbacks
Opening multiple cursors on a single connection
Introduction to Abstract Plans
Definition
Managing abstract plans
Relationship between query text and query plans
Limits of options for influencing query plans
Full versus partial plans
Creating a partial plan
Abstract plan groups
How abstract plans are associated with queries
Abstract Query Plan Guide
Introduction
Abstract plan language
Queries, access methods, and abstract plans
Identifying tables
Identifying indexes
Specifying join order
Shorthand notation for joins
Join order examples
Match between execution methods and abstract plans
Specifying join order for queries using views
Specifying the join type
Specifying partial plans and hints
Grouping multiple hints
Inconsistent and illegal plans using hints
Creating abstract plans for subqueries
Materialized subqueries
Flattened subqueries
Example: changing the join order in a flattened subquery
Nested subqueries
Subquery identification and attachment
More subquery examples: reading ordering and attachment
Modifying subquery nesting
Abstract plans for materialized views
Abstract plans for queries containing aggregates
Specifying the reformatting strategy
OR strategy limitation
When the store operator is not specified
Tips on writing abstract plans
Comparing plans “before” and “after”
Effects of enabling server-wide capture mode
Time and space to copy plans
Abstract plans for stored procedures
Procedures and plan ownership
Procedures with variable execution paths and optimization
Ad Hoc queries and abstract plans
Creating and Using Abstract Plans
Using set commands to capture and associate plans
Enabling plan capture mode with set plan dump
Associating queries with stored plans
Using replace mode during plan capture
When to use replace mode
Using dump, load, and replace modes simultaneously
Using dump and load to the same group
Using dump and load to different groups
set plan exists check option
Using other set options with abstract plans
Using showplan
Using noexec
Using forceplan
Server-wide abstract plan capture and association Modes
Creating plans using SQL
Using create plan
Using the plan Clause
Managing Abstract Plans with System Procedures
System procedures for managing abstract plans
Managing an abstract plan group
Creating a group
Dropping a group
Getting information about a group
Renaming a group
Finding abstract plans
Managing individual abstract plans
Viewing a plan
Copying a plan to another group
Dropping an individual abstract plan
Comparing two abstract plans
Changing an existing plan
Managing all plans in a group
Copying all plans in a group
Comparing all plans in a group
Dropping all abstract plans in a group
Importing and exporting groups of plans
Exporting plans to a user table
Importing plans from a user table
Abstract Plan Language Reference
Keywords
Operands
Derived tables
Schema for examples
g_join
hints
i_scan
in
lru
m_g_join
mru
nested
nl_g_join
parallel
plan
prefetch
prop
scan
store
subq
t_scan
table
union
view
work_t
Using Statistics to Improve Performance
Importance of statistics
Updating
Adding statistics for unindexed columns
update statistics commands
Column statistics and statistics maintenance
Creating and updating column statistics
When additional statistics may be useful
Adding statistics for a column with update statistics
Adding statistics for minor columns with update index statistics
Adding statistics for all columns with update all statistics
Choosing step numbers for histograms
Disadvantages of too many steps
Choosing a step number
Scan types, sort requirements, and locking
Sorts for unindexed or non leading columns
Locking, scans, and sorts during update index statistics
Locking, scans and sorts during update all statistics
Using the with consumers clause
Reducing update statistics impact on concurrent processes
Using the delete statistics command
When row counts may be inaccurate
Using the set statistics Commands
Command syntax
Using simulated statistics
Checking subquery cache performance
Checking compile and execute time
Converting ticks to milliseconds
Reporting physical and logical I/O statistics
Total actual I/O cost value
Statistics for writes
Statistics for reads
Sample output with and without an index
statistics io output for cursors
Scan count
Queries reporting a scan count of 1
Queries reporting a scan count of more than 1
Queries reporting scan count of 0
Relationship between physical and logical reads
Logical reads, physical reads, and 2K I/O
Physical reads and large I/O
Reads and writes on worktables
Effects of caching on reads
statistics io and merge joins
Using set showplan
Using
Basic showplan messages
Query plan delimiter message
Step message
Query type message
FROM TABLE message
FROM TABLE and referential integrity
TO TABLE message
Update mode messages
Direct update mode
Deferred mode
Deferred index and deferred varcol messages
Optimized using messages
Simulated statistics message
Abstract plan messages
showplan messages for query clauses
GROUP BY message
Selecting into a worktable
Grouped aggregate message
Grouped aggregates and group by
compute by message
Ungrouped aggregate message
Ungrouped aggregates
compute messages
messages for order by and distinct
Worktable message for distinct
Worktable message for order by
Sorting messages
Step involves sorting message
GETSORTED message
Serial or parallel sort message
Messages describing access methods, caching, and I/O cost
Auxiliary scan descriptors message
Nested iteration message
Merge join messages
Worktable message
Table scan message
Clustered index message
Index name message
Scan direction messages
Positioning messages
Scanning messages
Index covering message
Keys message
Matching index scans message
Dynamic index message (OR strategy)
Reformatting Message
Trigger Log Scan Message
I/O Size Messages
Cache strategy messages
Total estimated I/O cost message
showplan messages for parallel queries
Executed in parallel messages
Coordinating process message
Worker processes message
Scan type message
Merge messages
Data merge messages
Runtime adjustment message
showplan messages for subqueries
Output for flattened or materialized subqueries
Flattened queries
Materialized queries
Structure of subquery showplan output
Subquery execution message
Nesting level delimiter message
Subquery plan start delimiter
Subquery plan end delimiter
Type of subquery
Subquery predicates
Internal subquery aggregates
Quantified predicate subqueries and the ANY aggregate
Expression subqueries and the ONCE aggregate
Subqueries with distinct and the ONCE-UNIQUE aggregate
Existence join message
Subqueries that perform existence tests
Statistics Tables and Displaying Statistics with optdiag
System tables that store statistics
systabstats table
sysstatistics table
Viewing statistics with the optdiag utility
optdiag syntax
optdiag header information
Table statistics
Sample output for table statistics
Data page CR count
Table-level derived statistics
Data page cluster ratio
Space utilization
Large I/O efficiency
Index statistics
Sample output for index statistics
Index-level derived statistics
Data page cluster ratio
Index page cluster ratio
Data row cluster ratio
Space utilization for an index
Large I/O efficiency for an index
Column statistics
Sample output for column statistics
Range cell and total density values
Range and in-between selectivity values
Histogram displays
Sample output for histograms
Understanding histogram output
Histograms for columns with highly duplicated values
Choosing the number of steps for highly duplicated values
Changing statistics with optdiag
Using the optdiag binary mode
When you must use binary mode
Updating selectivities with optdiag input mode
Editing histograms
Adding frequency count cells to a histogram
Skipping the load-time verification for step numbering
Rules checked during histogram loading
Re-creating indexes without losing statistics updates
Using simulated statistics
optdiag syntax for simulated statistics
Simulated statistics output
Requirements for loading and using simulated statistics
Using simulated statistics in the original database
Using simulated statistics in another database
Dropping simulated statistics
Running queries with simulated statistics
showplan messages for simulated statistics
Character data containing quotation marks
Effects of SQL commands on statistics
How query processing affects systabstats
Tuning with dbcc traceon
Tuning with dbcc traceon(302)
dbcc traceon(310)
Invoking the dbcc trace facility
General tips for tuning with dbcc traceon(302)
Checking for join columns and search arguments
Determining how the optimizer estimates I/O costs
Structure of dbcc traceon(302) output
Additional blocks and messages
Table information block
Identifying the table
Basic table data
Cluster ratio
Partition information
Base cost block
Concurrency optimization message
Clause block
Search clause identification
When search clauses are not optimizable
Values unknown at optimize time
Join clause identification
Sort avert messages
Column block
Selectivities when statistics exist and values are known
When the optimizer uses default values
Unknown values
If no statistics are available
Out-of-range messages
“Disjoint qualifications” message
Forcing messages
Unique index messages
Other messages in the column block
Index selection block
Scan and filter selectivity values
How scan and filter selectivity can differ
Other information in the index selection block
Best access block
dbcc traceon(310) and final query plan costs
Flattened subquery join order message
Worker process information
Final plan information
Sort-merge costs
Monitoring Performance with sp_sysmon
Using
When to run
Invoking
Fixed time intervals
Using begin_sample and end_sample
Specifying report sections for output
Specifying the application detail parameter
Redirecting output to a file
How to use the reports
Reading output
Rows
Columns
Interpreting the data
Per second and per transaction data
Percent of total and count data
Per engine data
Total or summary data
Sample interval and time reporting
Kernel utilization
Sample output
Engine busy utilization
CPU yields by engine
Network checks
Non–blocking
Blocking
Total network I/O checks
Average network I/Os per check
Disk I/O checks
Total disk I/O checks
Checks returning I/O
Average disk I/Os returned
Worker process management
Sample output
Worker process requests
Worker process usage
Memory requests for worker processes
Avg mem ever used by a WP
Parallel query management
Sample output
Parallel query usage
Merge lock requests
Sort buffer waits
Task management
Sample output
Connections opened
Task context switches by engine
Task context switches due to
Voluntary yields
Cache search misses
System disk writes
I/O pacing
Logical lock contention
Address lock contention
Latch contention
Log semaphore contention
PLC lock contention
Group commit sleeps
Last log page writes
Modify conflicts
I/O device contention
Network packet received
Network packet sent
Other causes
Application management
Requesting detailed application information
Sample output
Application statistics summary (all applications)
Priority changes
Allotted slices exhausted
Skipped tasks by engine
Engine scope changes
Per application or per application and login
Application activity
Application priority changes
Application I/Os completed
Resource limits violated
ESP management
Sample output
ESP requests
Avg. time to execute an ESP
Housekeeper task activity
Sample output
Buffer cache washes
Garbage collections
Statistics updates
Monitor access to executing SQL
Sample output
Waits on execution plans
Number of SQL text overflows
Maximum SQL text requested
Transaction profile
Sample output
Transaction summary
How to count multi database transactions
Transaction detail
Inserts
APL heap tables
APL clustered table
Data only lock table
Total rows inserted
Updates and update detail sections
Updates
Data-only-locked updates
Deletes
Total rows deleted
Transaction management
Sample output
ULC flushes to transaction log
By full ULC
By end transaction
By change of database
By system log record and by other
Total ULC flushes
ULC log records
Maximum ULC size
ULC semaphore requests
Log semaphore requests
Log semaphore contention and user log caches
Transaction log writes
Transaction log allocations
Avg # writes per log page
Index management
Sample output
Nonclustered maintenance
Inserts and updates requiring maintenance to indexes
Deletes requiring maintenance
Row ID updates from clustered split
Data-Only-Locked updates and deletes requiring maintenance
Page splits
Reducing page splits for ascending key inserts
Default data page splitting
Effects of ascending inserts
Setting ascending inserts mode for a table
Retries and deadlocks
Add index level
Page shrinks
Index scans
Metadata cache management
Sample output
Open object, index, and database usage
Object and index spinlock contention
Hash spinlock contention
Using sp_monitorconfig to find metadata cache usage statistics
Lock management
Sample output
Lock summary
Lock detail
Address locks
Last page locks on heaps
Table lock hashtable
Deadlocks by lock type
Deadlock detection
Deadlock searches
Searches skipped
Average deadlocks per search
Lock promotions
Lock time-out information
Data cache management
Sample output
Cache statistics summary (all caches)
Cache search summary
Cache turnover
Cache strategy summary
Large I/O usage
Large I/O effectiveness
Asynchronous prefetch activity report
Other asynchronous prefetch statistics
Dirty read behavior
Cache management by cache
Cache spinlock contention
Utilization
Cache search, hit, and miss information
Pool turnover
Buffer wash behavior
Cache strategy
Large I/O usage
Large I/O detail
Dirty read behavior
Procedure cache management
Sample output
Procedure requests
Procedure reads from disk
Procedure writes to disk
Procedure removals
Memory management
Sample output
Pages allocated
Pages released
Recovery management
Sample output
Checkpoints
Number of normal checkpoints
Number of free checkpoints
Total checkpoints
Average time per normal checkpoint
Average time per free checkpoint
Increasing the housekeeper batch limit
Disk I/O management
Sample output
Maximum outstanding I/Os
I/Os delayed by
Disk I/O structures
Server configuration limit
Engine configuration limit
Operating system limit
Requested and completed disk I/Os
Total requested disk I/Os
Completed disk I/Os
Device activity detail
Reads and writes
Total I/Os
Device semaphore granted and waited
Network I/O management
Sample output
Total network I/Os requests
Network I/Os delayed
Total TDS packets received
Total bytes received
Average bytes received per packet
Total TDS packets sent
Total bytes sent
Average bytes sent per packet
Reducing packet overhead
Quick Reference Guide
Reference Manual
About this book
System and User-Defined Datatypes
Datatype categories
Range and storage size
Declaring the datatype of a column, variable, or parameter
Declaring the datatype for a column in a table
Declaring the datatype for a local variable in a batch or procedure
Declaring the datatype for a parameter in a stored procedure
Determining the datatype of a literal
Datatype of mixed-mode expressions
Determining the datatype hierarchy
Determining precision and scale
Converting one datatype to another
Automatic conversion of fixed-length NULL columns
Handling overflow and truncation errors
Standards and compliance
Exact numeric datatypes
Function
Integer types
Decimal datatypes
Standards and compliance
Approximate numeric datatypes
Function
Understanding approximate numeric datatypes
Range, precision, and storage size
Entering approximate numeric data
Values that may be entered by Open Client clients
Standards
Money datatypes
Function
Accuracy
Range and storage size
Entering monetary values
Standards
Timestamp datatype
Function
Creating a timestamp column
Date and time datatypes
Function
Range and storage requirements
Entering datetime and smalldatetime data
Standards and compliance
Character datatypes
Function
Length and storage size
Entering character data
Treatment of blanks
Manipulating character data
Standards
Binary datatypes
Function
Valid binary and varbinary entries
Entries of more than the max column size
Treatment of trailing zeroes
Platform dependence
Standards
bit datatype
Function
Entering data into bit columns
Storage size
Restrictions
Standards
sysname datatype
Function
Using the sysname datatype
Standards
text and image datatypes
Function
Data structures used for storing text and image data
Format of text data pages
Text nodes
Initializing text and image columns
Saving space by allowing NULL
Getting information from sysindexes
Using readtext and writetext
Determining how much space a column uses
Restrictions on text and image columns
Selecting text and image data
Converting text and image datatypes
Pattern matching in text data
Duplicate rows
Standards
User-defined datatypes
Function
Creating frequently used datatypes in the model database
Creating a user-defined datatypes
Renaming a user-defined datatype
Dropping a user-defined datatype
Getting help on datatypes
Standards and compliance
Transact-SQL Functions
Types of functions
Aggregate functions
Aggregates used with group by
Aggregate functions and NULL values
Vector and scalar aggregates
Aggregate functions as row aggregates
Datatype conversion functions
Converting character data to a non-character type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to and from money types
Converting date/time information
Converting between numeric types
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Conversions between binary and integer types
Converting between binary and numeric or decimal types
Converting image columns to binary types
Converting other types to bit
Converting NULL value
Date functions
Date parts
Mathematical functions
Security functions
String functions
Limits on string functions
System functions
Text and image functions
abs
acos
ascii
asin
atan
atn2
avg
ceiling
char
charindex
char_length
col_length
col_name
compare
convert
cos
cot
count
curunreservedpgs
data_pgs
datalength
dateadd
datediff
datename
datepart
db_id
db_name
degrees
difference
exp
floor
get_appcontext
getdate
hextoint
host_id
host_name
index_col
index_colorder
inttohex
isnull
is_sec_service_on
lct_admin
license_enabled
list_appcontext
lockscheme
log
log10
lower
ltrim
max
min
mut_excl_roles
object_id
object_name
pagesize
patindex
pi
power
proc_role
ptn_data_pgs
radians
rand
replicate
reserved_pgs
reverse
right
rm_appcontext
role_contain
role_id
role_name
round
rowcnt
rtrim
set_appcontext
show_role
show_sec_services
sign
sin
sortkey
soundex
space
sqrt
str
stuff
substring
sum
suser_id
suser_name
syb_quit()
syb_sendmsg
tan
textptr
textvalid
to_unichar
tsequal
uhighsurr
ulowsurr
upper
uscalar
used_pgs
user
user_id
user_name
valid_name
valid_user
Global Variables
Adaptive Server’s global variables
Expressions, Identifiers, and Wildcard Characters
Expressions
Size of expressions
Arithmetic and character expressions
Relational and logical expressions
Operator precedence
Arithmetic operators
Bitwise operators
String concatenation operator
Comparison operators
Nonstandard operators
Using any, all and in
Negating and testing
Ranges
Using nulls in expressions
Comparisons that return TRUE
Difference between FALSE and UNKNOWN
Using “NULL” as a character string
NULL compared to the empty string
Connecting expressions
Using parentheses in expressions
Comparing character expressions
Using the empty string
Including quotation marks in character expressions
Using the continuation character
Identifiers
Tables beginning with # (temporary tables)
Case sensitivity and identifiers
Uniqueness of object names
Using delimited identifiers
Identifying tables or columns by their qualified object name
Using delimited identifiers within an object name
Omitting the owner name
Referencing your own objects in the current database
Referencing objects owned by the database owner
Using qualified identifiers consistently
Determining whether an identifier is valid
Renaming database objects
Using multibyte character sets
Pattern matching with wildcard characters
Using not like
Case and accent insensitivity
Using wildcard characters
The percent sign (%) wildcard character
The underscore (_) wildcard character
Bracketed ([ ]) characters
The caret (^) wildcard character
Using multibyte wildcard characters
Using wildcard characters as literal characters
Using square brackets ( [ ] ) as escape characters
Using the escape clause
Using wildcard characters with datetime data
Reserved Words
Transact-SQL reserved words
SQL92 reserved words
Potential SQL92 reserved words
SQLSTATE Codes and Messages
Warnings
Exceptions
Cardinality violations
Data exceptions
Integrity constraint violations
Invalid cursor states
Syntax errors and access rule violations
Transaction rollbacks
with check option violation
Commands
Overview
alter database
alter role
alter table
begin...end
begin transaction
break
case
checkpoint
close
coalesce
commit
compute clause
connect to...disconnect
continue
create database
create default
create existing table
create function (SQLJ)
create index
create plan
create procedure
create procedure (SQLJ)
create proxy_table
create role
create rule
create schema
create table
create trigger
create view
dbcc
deallocate cursor
declare
declare cursor
delete
delete statistics
disk init
disk mirror
disk refit
disk reinit
disk remirror
disk unmirror
drop database
drop default
drop function (SQLJ)
drop index
drop procedure
drop role
drop rule
drop table
drop trigger
drop view
dump database
dump transaction
execute
fetch
goto label
grant
group by and having clauses
if...else
insert
kill
load database
load transaction
lock table
nullif
online database
open
order by clause
prepare transaction
print
quiesce database
raiserror
readtext
reconfigure
remove java
reorg
return
revoke
rollback
rollback trigger
save transaction
select
set
setuser
shutdown
truncate table
union operator
update
update all statistics
update partition statistics
update statistics
use
waitfor
where clause
while
writetext
System Procedures
Introduction to system procedures
Permissions on system procedures
Executing system procedures
Entering parameter values
Messages
System procedure tables
List of system procedures
sp_activeroles
sp_addalias
sp_addauditrecord
sp_addaudittable
sp_addengine
sp_addexeclass
sp_addextendedproc
sp_addexternlogin
sp_addgroup
sp_addlanguage
sp_addlogin
sp_addmessage
sp_addobjectdef
sp_add_qpgroup
sp_addremotelogin
sp_add_resource_limit
sp_addsegment
sp_addserver
sp_addthreshold
sp_add_time_range
sp_addtype
sp_addumpdevice
sp_adduser
sp_altermessage
sp_audit
sp_autoconnect
sp_bindcache
sp_bindefault
sp_bindexeclass
sp_bindmsg
sp_bindrule
sp_cacheconfig
sp_cachestrategy
sp_changedbowner
sp_changegroup
sp_checknames
sp_checkreswords
sp_checksource
sp_chgattribute
sp_clearpsexe
sp_clearstats
sp_client_addr
sp_cmp_all_qplans
sp_cmp_qplans
sp_commonkey
sp_companion
sp_configure
sp_copy_all_qplans
sp_copy_qplan
sp_countmetadata
sp_cursorinfo
sp_dboption
sp_dbrecovery_order
sp_dbremap
sp_defaultloc
sp_depends
sp_deviceattr
sp_diskdefault
sp_displayaudit
sp_displaylevel
sp_displaylogin
sp_displayroles
sp_dropalias
sp_drop_all_qplans
sp_dropdevice
sp_dropengine
sp_dropexeclass
sp_dropextendedproc
sp_dropexternlogin
sp_dropglockpromote
sp_dropgroup
sp_dropkey
sp_droplanguage
sp_droplogin
sp_dropmessage
sp_dropobjectdef
sp_drop_qpgroup
sp_drop_qplan
sp_dropremotelogin
sp_drop_resource_limit
sp_droprowlockpromote
sp_dropsegment
sp_dropserver
sp_dropthreshold
sp_drop_time_range
sp_droptype
sp_dropuser
sp_dumpoptimize
sp_engine
sp_estspace
sp_export_qpgroup
sp_extendsegment
sp_extengine
sp_familylock
sp_find_qplan
sp_fixindex
sp_flushstats
sp_forceonline_db
sp_forceonline_object
sp_forceonline_page
sp_foreignkey
sp_freedll
sp_getmessage
sp_grantlogin
sp_ha_admin
sp_help
sp_helpartition
sp_helpcache
sp_helpconfig
sp_helpconstraint
sp_helpdb
sp_helpdevice
sp_helpextendedproc
sp_helpexternlogin
sp_helpgroup
sp_helpindex
sp_helpjava
sp_helpjoins
sp_helpkey
sp_helplanguage
sp_helplog
sp_helpobjectdef
sp_help_qpgroup
sp_help_qplan
sp_helpremotelogin
sp_help_resource_limit
sp_helprotect
sp_helpsegment
sp_helpserver
sp_helpsort
sp_helptext
sp_helpthreshold
sp_helpuser
sp_hidetext
sp_import_qpgroup
sp_indsuspect
sp_listsuspect_db
sp_listsuspect_object
sp_listsuspect_page
sp_lock
sp_locklogin
sp_logdevice
sp_loginconfig
sp_logininfo
sp_logiosize
sp_modifylogin
sp_modify_resource_limit
sp_modify_time_range
sp_modifystats
sp_modifythreshold
sp_monitor
sp_monitorconfig
sp_object_stats
sp_passthru
sp_password
sp_placeobject
sp_plan_dbccdb
sp_poolconfig
sp_primarykey
sp_processmail
sp_procqmode
sp_procxmode
sp_recompile
sp_remap
sp_remoteoption
sp_remotesql
sp_rename
sp_renamedb
sp_rename_qpgroup
sp_reportstats
sp_revokelogin
sp_role
sp_sendmsg
sp_serveroption
sp_setlangalias
sp_setpglockpromote
sp_setpsexe
sp_set_qplan
sp_setrowlockpromote
sp_setsuspect_granularity
sp_setsuspect_threshold
sp_showcontrolinfo
sp_showexeclass
sp_showplan
sp_showpsexe
sp_spaceused
sp_ssladmin
sp_syntax
sp_sysmon
sp_thresholdaction
sp_transactions
sp_unbindcache
sp_unbindcache_all
sp_unbindefault
sp_unbindexeclass
sp_unbindmsg
sp_unbindrule
sp_volchanged
sp_who
Catalog Stored Procedures
Overview
Specifying optional parameters
Pattern matching
System procedure tables
ODBC datatypes
sp_column_privileges
sp_columns
sp_databases
sp_datatype_info
sp_fkeys
sp_pkeys
sp_server_info
sp_special_columns
sp_sproc_columns
sp_statistics
sp_stored_procedures
sp_table_privileges
sp_tables
System Extended Stored Procedures
Overview
Permissions on system ESPs
DLLs associated with system ESPs
Using system ESPs
xp_cmdshell
xp_deletemail
xp_enumgroups
xp_findnextmsg
xp_logevent
xp_readmail
xp_sendmail
xp_startmail
xp_stopmail
dbcc Stored Procedures
Overview
Specifying the object name and date
Specifying the object name
Specifying the date
sp_dbcc_alterws
sp_dbcc_configreport
sp_dbcc_createws
sp_dbcc_deletedb
sp_dbcc_deletehistory
sp_dbcc_differentialreport
sp_dbcc_evaluatedb
sp_dbcc_faultreport
sp_dbcc_fullreport
sp_dbcc_runcheck
sp_dbcc_statisticsreport
sp_dbcc_summaryreport
sp_dbcc_updateconfig
System Tables
Locations of system tables
System tables in master
System tables in sybsecurity
System table in sybsystemdb
System tables in all databases
About the sybdiagdb database
About the syblicenseslog table
Rules for using system tables
Permissions on system tables
Locking schemes used for system tables
Reserved columns
Updating system tables
Triggers on system tables
Aggregate functions and virtual tables
sysalternates
sysattributes
sysauditoptions
sysaudits_01 – sysaudits_08
syscharsets
syscolumns
syscomments
sysconfigures
sysconstraints
syscoordinations
syscurconfigs
sysdatabases
sysdepends
sysdevices
sysengines
sysgams
sysindexes
sysjars
syskeys
syslanguages
syslisteners
syslocks
sysloginroles
syslogins
syslogs
syslogshold
sysmessages
sysmonitors
sysobjects
syspartitions
sysprocedures
sysprocesses
sysprotects
sysqueryplans
sysreferences
sysremotelogins
sysresourcelimits
sysroles
syssecmechs
syssegments
sysservers
syssessions
syssrvroles
sysstatistics
systabstats
systhresholds
systimeranges
systransactions
systypes
sysusages
sysusermessages
sysusers
sysxtypes
syblicenseslog
dbccdb Tables
dbccdb workspaces
dbccdb log
dbcc_config
dbcc_counters
dbcc_fault_params
dbcc_faults
dbcc_operation_log
dbcc_operation_results
dbcc_types
System Administration Guide
About this book
Audience
How to use this book
Related Documents
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software updates
Conventions used in this manual
Formatting SQL statements
SQL syntax conventions
Case
Obligatory options {you must choose at least one}
Optional options
Ellipsis
Expressions
If you need help
Overview of System Administration
Adaptive Server administration tasks
Roles required for system administration tasks
Database Owner
Database object owner
Using isql to perform system administration tasks
Starting isql
Entering statements
Saving and reusing statements
Using Sybase Central for system administration tasks
System tables
Querying the system tables
Keys in system tables
Updating system tables
System procedures
Using system procedures
System procedure tables
Creating system procedures
System extended stored procedures
Creating system ESPs
Logging error messages
Connecting to Adaptive Server
The interfaces file
Directory services
LDAP as a directory service
Multiple directory services
LDAP directory services versus the Sybase interfaces file
Security features available in Adaptive Server
System and Optional Databases
Overview of system databases
master database
Controlling object creation in master
Backing up master and keeping copies of system tables
model database
sybsystemprocs database
tempdb database
Creating temporary tables
sybsecurity database
sybsystemdb database
pubs2 and pubs3 sample databases
Maintaining the sample databases
pubs2 image data
dbccdb database
sybdiag database
System Administration for Beginners
Logical page sizes
Using “test” servers
Understanding new procedures and features
Planning resources
Achieving performance goals
Installing Sybase products
Check product compatibility
Install or upgrade Adaptive Server
Install additional third-party software
Configure and test client connections
Allocating physical resources
Dedicated vs. shared servers
Decision support and OLTP applications
Advance resource planning
Operating system configuration
Backup and recovery
Keep up-to-date backups of master
Keep offline copies of system tables
Automate backup procedures
Verify data consistency before backing up a database
Monitor the log size
Ongoing maintenance and troubleshooting
Starting and stopping Adaptive Server
Viewing and pruning the error log
Keeping records
Contact information
Configuration information
Maintenance schedules
System information
Disaster recovery plan
Getting more help
Diagnosing System Problems
How Adaptive Server uses error messages to respond to system problems
Error messages and message numbers
Variables in error message text
Adaptive Server error logging
Error log format
Severity levels
Levels 10–18
Level 10: Status information
Level 11: Specified database object not found
Level 12: Wrong datatype encountered
Level 13: User transaction syntax error
Level 14: Insufficient permission to execute command
Level 15: Syntax error in SQL statement
Level 16: Miscellaneous user error
Level 17: Insufficient resources
Level 18: Non-fatal internal error detected
Severity levels 19–26
Level 19: Adaptive Server fatal error in resource
Level 20: Adaptive Server fatal error in current process
Level 21: Adaptive Server fatal error in database processes
Level 22: Adaptive Server fatal error: Table integrity suspect
Level 24: Hardware error or system table corruption
Level 23: Fatal error: Database integrity suspect
Level 25: Adaptive Server internal error
Level 26: Rule error
Reporting errors
Backup Server error logging
Killing processes
Using sp_lock to examine blocking processes
Configuring Adaptive Server to save SQL batch text
Allocating memory for batch text
Configuring the amount of SQL text retained in memory
Enabling Adaptive Server to start saving SQL text
SQL commands not represented by text
Viewing the query plan of a SQL statement
Viewing previous statements
Viewing a nested procedure
Shutting down servers
Shutting down Adaptive Server
Shutting down a Backup Server
Checking for active dumps and loads
Using nowait on a Backup Server
Learning about known problems
Setting Configuration Parameters
Adaptive Server configuration parameters
What are configuration parameters?
The Adaptive Server configuration file
How to modify configuration parameters
Who can modify configuration parameters?
Unit specification using sp_configure
Getting help information on configuration parameters
Using sp_configure
Syntax elements
Parameter parsing
Using sp_configure with a configuration file
Naming tips for the configuration file
Using sp_configure to read or write the configuration file
Parameters for using configuration files
Editing the configuration file
Starting Adaptive Server with a configuration file
The parameter hierarchy
User-defined subsets of the parameter hierarchy: display levels
The effect of the display level on sp_configure output
The reconfigure command
Performance tuning with sp_configure and sp_sysmon
Output from sp_configure
The sysconfigures and syscurconfigs tables
Querying syscurconfigs and sysconfigures: an example
Details on configuration parameters
Renamed configuration parameters
Replaced configuration parameter
Backup and recovery
number of large i/o buffers
print recovery information
recovery interval in minutes
tape retention in days
Cache manager
global async prefetch limit
global cache partition number
memory alignment boundary
number of index trips
number of oam trips
procedure cache size
total data cache size
Component Integration Services administration
cis bulk insert array size
cis bulk insert batch size
cis connect timeout
cis cursor rows
cis packet size
cis rpc handling
enable cis
enable file access
enable full-text search
max cis remote connections
Disk I/O
allow sql server async i/o
disable disk mirroring
disk i/o structures
number of devices
page utilization percent
DTM administration
dtm detach timeout period
dtm lock timeout period
enable DTM
enable xact coordination
number of dtx participants
strict dtm enforcement
txn to pss ratio
xact coordination interval
Error log
event log computer name (Windows NT only)
event logging (Windows NT only)
log audit logon failure
log audit logon success
Extended stored procedures
esp execution priority
esp execution stacksize
esp unload dll
start mail session (Windows NT only)
xp_cmdshell context
General information
configuration file
Java services
enable java
enable enterprise java beans
size of global fixed heap
size of process object heap
size of shared class heap
Languages
default character set id
default language id
default sortorder id
disable character set conversions
Lock Manager
lock address spinlock ratio
number of locks
deadlock checking period
deadlock retries
lock spinlock ratio
lock hashtable size
lock scheme
lock wait period
read committed with lock
lock table spinlock ratio
Memory use
executable codesize + overhead
Metadata caches
number of open databases
number of open indexes
number of open objects
open index hash spinlock ratio
open index spinlock ratio
open object spinlock ratio
Network communication
allow remote access
allow sendmsg
default network packet size
max network packet size
max number network listeners
number of remote connections
number of remote logins
number of remote sites
remote server pre-read packets
syb_sendmsg port number
tcp no delay
O/S resources
max async i/os per engine
max async i/os per server
o/s file descriptors
shared memory starting address
Parallel queries
number of worker processes
max parallel degree
max scan parallel degree
memory per worker process
Physical memory
allocate max shared memory
dynamic allocation on demand
max memory
additional network memory
heap memory per user
lock shared memory
max SQL text monitored
total physical memory
total logical memory
Processors
number of engines at startup
max online engines
RepAgent thread administration
enable rep agent threads
SQL server administration
abstract plan cache
abstract plan dump
abstract plan load
abstract plan replace
allow backward scans
allow nested triggers
allow resource limits
allow updates to system tables
cpu accounting flush interval
cpu grace time
default database size
default fill factor percent
default exp_row_size percent
dump on conditions
enable sort-merge joins and JTC
enable row level access control
enable ssl
event buffers per engine
housekeeper free write percent
enable HA
enable housekeeper GC
identity burning set factor
identity grab size
i/o accounting flush interval
i/o polling process count
page lock promotion HWM
page lock promotion LWM
page lock promotion PCT
maximum dump conditions
number of alarms
number of aux scan descriptors
number of mailboxes
number of messages
number of pre-allocated extents
number of sort buffers
partition groups
partition spinlock ratio
print deadlock information
runnable process search count
size of auto identity column
SQL Perfmon Integration (Windows NT only)
sql server clock tick length
text prefetch size
time slice
upgrade version
row lock promotion HWM
row lock promotion LWM
row lock promotion PCT
license information
Security related
allow procedure grouping
auditing
audit queue size
current audit table
enable ssl
msg confidentiality reqd
msg integrity reqd
secure default login
select on syscomments.text column
suspend audit when device full
systemwide password expiration
unified login required (Windows NT only)
use security services (Windows NT only)
Unicode
default unicode sortorder
enable surrogate processing
enable unicode conversion
enable unicode normalization
size of unilib cache
User environment
number of user connections
permission cache entries
stack guard size
stack size
user log cache size
user log cache spinlock ratio
Limiting Access to Server Resources
What are resource limits?
Planning resource limits
Enabling resource limits
Defining time ranges
Determining the time ranges you need
Creating named time ranges
A time range example
Modifying a named time range
Dropping a named time range
When do time range changes take effect?
Identifying users and limits
Identifying heavy-usage users
Identifying heavy-usage applications
Choosing a limit type
Determining time of enforcement
Determining the scope of resource limits
Understanding limit types
Limiting I/O cost
Identifying I/O costs
Calculating the I/O cost of a cursor
The scope of the io_cost limit type
Limiting elapsed time
The scope of the elapsed_time limit type
Limiting the size of the result set
Determining row count limits
Applying row count limits to a cursor
The scope of the row_count limit type
Setting limits for tempdb space usage
Creating a resource limit
Resource limit examples
Examples
Getting information on existing limits
Example of listing all existing resource limits
Modifying resource limits
Examples of modifying a resource limit
Dropping resource limits
Examples of dropping a resource limit
Resource limit precedence
Time ranges
Resource limits
Configuring Character Sets, Sort Orders, and Languages
Understanding internationalization and localization
Advantages of internationalized systems
A sample internationalized system
Elements of an internationalized system
Selecting the character set for your server
Selecting the server default character set
Selecting the sort order
Using sort orders
Different types of sort orders
Selecting the default sort order
Selecting the default Unicode sort order
Selecting a language for system messages
Setting up your server: examples
A Spanish-version server
A U.S.–based company in Japan
A Japan–based company with multinational clients
Changing the character set, sort order, or message language
Changing the default character set
Changing the default sort order
Reconfiguring the character set, sort order, or message language
Preliminary steps
Setting the user’s default language
Recovery after reconfiguration
Using sp_indsuspect to find corrupt indexes
Rebuilding indexes after changing the sort order
Upgrading text data after changing character sets
Retrieving text values after changing character sets
Installing date strings for unsupported languages
Server versus client date interpretation
Internationalization and localization files
Types of internationalization files
Character sets directory structure
Types of localization files
Software messages directory structure
Message languages and global variables
Configuring Client/Server Character Set Conversions
Character set conversion in Adaptive Server
Supported character set conversions
Conversion for native character sets
Conversion in a Unicode system
Types of character set conversion
Adaptive Server direct conversions
Unicode conversions
Which type of conversion do I use?
Non-Unicode client/server systems
Unicode client/server systems
Configuring the server
Enabling and disabling character set conversion
Characters that cannot be converted
Error handling in character set conversion
Conversions and changes to data lengths
Configuring your system and application
Specifying the character set for utility programs
Display and file character set command-line options
Setting the display character set
Setting the file character set
Security Administration
Security features available in Adaptive Server
General process of security administration
Guidelines for setting up security
Using the “sa” login
Changing the “sa” Login Password
When to enable auditing
Assigning login names
An example of setting up security
Discretionary access controls
Identification and authentication controls
Identification and authentication controls with network based security
Division of roles
Role hierarchy
Mutual exclusivity
Secure Sockets Layer (SSL) in Adaptive Server
Internet communications overview
Public-key cryptography
SSL overview
SSL in Adaptive Server
SSL filter
Authentication via the certificate
Connection types
Enabling SSL
Obtaining a certificate
Creating server directory entries
Administering certificates
Performance
CipherSuites
Network-based security
Auditing
User-defined login security
Setting and changing the maximum login attempts
Locking and unlocking logins and roles
Displaying password information
Checking passwords for at least one digit
Setting and changing minimum password length
Setting the expiration interval for a password
Password expiration turned off for pre-12.x passwords
Message for impending password expiration
Circumventing password protection
Creating a password expiration interval for a new login
Creating a password expiration interval for a new role
Creation date added for passwords
Changing or removing password expiration interval for login or role
Managing Adaptive Server Logins and Database Users
Adding new users: An overview
Choosing and creating a password
Adding logins to Adaptive Server
Creating groups
Adding users to databases
Adding a “guest” user to a database
“guest” user permissions
“guest” user in user databases
“guest” user in pubs2 and pubs3
Creating visitor accounts
Adding remote users
Number of user and login IDs
Limits and Ranges of ID Numbers
Login connection limitations
Viewing Server Limits for Logins, Users, and Groups
Creating and assigning roles to users
Planning user-defined roles
Role hierarchies and mutual exclusivity
Configuring user-defined roles
Creating a user-defined role
Adding and removing passwords from a role
Defining and changing mutual exclusivity of roles
Defining and changing a role hierarchy
Setting up default activation at login
Activating and deactivating roles
Dropping users, groups and user-defined roles
Dropping users
Dropping groups
Dropping user-defined roles
Locking or dropping Adaptive Server login accounts
Locking and unlocking login accounts
Dropping login accounts
Locking logins that own thresholds
Changing user information
Changing passwords
Requiring new passwords
Null passwords
Changing user defaults
Changing a user’s group membership
Changing the user process information
Using aliases in databases
Adding aliases
Dropping aliases
Getting information about aliases
Getting information about users
Getting reports on users and processes
Getting information about login accounts
Getting information about database users
Finding user names and IDs
Displaying information about roles
Finding role IDs and names
Viewing active roles
Displaying a role hierarchy
Viewing user roles in a hierarchy
Determining mutual exclusivity
Determining role activation
Checking for roles in stored procedures
Monitoring license use
How licenses are counted
Configuring License Manager to monitor user licenses
Monitoring license use with the housekeeper task
Logging the number of user licenses
Getting information about usage: Chargeback accounting
Reporting current usage statistics
Displaying current accounting totals
Initiating a new accounting interval
Specifying the interval for adding accounting statistics
Managing User Permissions
Overview
Types of users and their privileges
System Administrator privileges
Permissions for creating databases
System Security Officer privileges
Operator privileges
Database Owner privileges
Permissions on system tables
Permissions on system procedures
Changing database ownership
Database object owner privileges
Privileges of other database users
Granting and revoking permissions on database objects
Granting and revoking object access permissions
Concrete identification
Special requirements for SQL92 standard compliance
Examples of granting object access permissions
Examples of revoking object access permissions
Granting and revoking object creation permissions
Examples of granting object creation permissions
Example of revoking object creation permissions
Combining grant and revoke statements
Understanding permission order and hierarchy
Granting and revoking roles
Granting roles
Understanding grant and roles
Revoking roles
Row-level access control
Access rules
Syntax for access rules
Using access and extended access rules
Access rule examples
Access rules and alter table command
Access rules and bcp
Access rules as user-defined Java functions
Using the Application Context Facility
Setting permissions for using application context functions
Creating and using application contexts
sys_session system application context
Solving a problem using an access rule and ACF
Using login triggers
Creating login triggers
Configuring login triggers
Executing a login trigger
Understanding login trigger output
Using login triggers for other applications
Login trigger restrictions
Issues and information
Disabling execute privilege on login triggers
Acquiring the permissions of another user
Using setuser
Using proxy authorization
Granting proxy authorization
Executing proxy authorization
Proxy authorization for applications
Reporting on permissions
Querying the sysprotects table for proxy authorization
Displaying information about users and processes
Reporting permissions on database objects or users
Reporting permissions on specific tables
Reporting permissions on specific columns
Using views and stored procedures as security mechanisms
Using views as security mechanisms
Using stored procedures as security mechanisms
Roles and stored procedures
Understanding ownership chains
Example of views and ownership chains
Example of procedures and ownership chains
Permissions on triggers
Auditing
Introduction to auditing in Adaptive Server
Correlating Adaptive Server and operating system audit records
The audit system
The sybsecurity database
The audit queue
Auditing configuration parameters
System procedures for auditing
Installing and setting up auditing
Installing the audit system
Tables and devices for the audit trail
Device for the syslogs transaction log table
Installing auditing with installsecurity
Moving the auditing database to multiple devices
Setting up audit trail management
Setting up threshold procedures
Setting auditing configuration parameters
Setting up transaction log management
Truncating the transaction log
Managing the transaction log with no truncation
Enabling and disabling auditing
Single-table auditing
Establishing and managing single-table auditing
Threshold procedure for single-table auditing
What happens when the current audit table is full?
Recovering when the current audit table is full
Setting global auditing options
Auditing options: Types and requirements
Examples of setting auditing options
Determining current auditing settings
Adding user-specified records to the audit trail
Examples of adding user-defined audit records
Querying the audit trail
Understanding the audit tables
Reading the extrainfo column
Managing Remote Servers
Overview
Managing remote servers
Adding a remote server
Examples of adding remote servers
Managing remote server names
Setting server connection options
Using the timeouts option
Using the net password encryption option
Using the rpc security model options
Getting information about servers
Dropping remote servers
Adding remote logins
Mapping users’ server IDs
Mapping remote logins to particular local names
Mapping all remote logins to one local name
Keeping remote login names for local servers
Example of remote user login mapping
Password checking for remote users
Effects of using the untrusted mode
Getting information about remote logins
Configuration parameters for remote logins
Allowing remote access
Controlling the number of active user connections
Controlling the number of remote sites
Controlling the number of active remote connections
Controlling number of preread packets
Using Kerberos, DCE, and Windows NT LAN Manager
Overview
How applications use security services
Login authentication
Message protection
Security services and Adaptive Server
Administering network-based security
Setting up configuration files for security
Preparinglibtcl.cfg to use network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
UNIX platform information
Desktop platform information
The objectid.dat file
Specifying security information for the server
UNIX tools for specifying the security mechanism
Desktop tools for specifying server attributes
Identifying users and servers to the security mechanism
Configuring Adaptive Server for security
Enabling network-based security
Using unified login
Requiring unified login
Establishing a secure default login
Mapping security mechanism login names to server names
Requiring message confidentiality with encryption
Requiring data integrity
Memory requirements for network-based security
Restarting the server to activate security services
Determining security mechanisms to support
Adding logins to support unified login
General procedure for adding logins
Establishing security for remote procedures
Security model A
Security model B
Unified login and the remote procedure models
Establishing the security model for RPCs
Setting server options for RPC security model B
Rules for setting up security model B for RPCs
Preparing to use security model B for RPCs
Example of setting up security model B for RPCs
Getting information about remote servers
Connecting to the server and using the security services
Example of using security services
Using security mechanisms for the client
Getting information about available security services
Determining supported security services and mechanisms
Determining enabled security services
Determining whether a security service Is enabled
Overview of Disk Resource Issues
Device allocation and object placement
Commands for managing disk resources
Considerations in storage management decisions
Recovery
Keeping logs on a separate device
Mirroring
Performance
Status and defaults at installation time
System tables that manage storage
The sysdevices table
The sysusages table
The syssegments table
The sysindexes table
Initializing Database Devices
What are database devices?
Using the disk init command
disk init syntax
disk init examples
Specifying a logical device name with disk init
Specifying a physical device name with disk init
Choosing a device number for disk init
Specifying the device size with disk init
Specifying the dsync setting with disk init (optional)
Performance implications of dsync
Limitations and restrictions of dsync
Other optional parameters for disk init
Getting information about devices
Dropping devices
Designating default devices
Choosing default and nondefault devices
Mirroring Database Devices
What is disk mirroring?
Deciding what to mirror
Mirroring using minimal physical disk space
Mirroring for nonstop recovery
Conditions that do not disable mirroring
Disk mirroring commands
Initializing mirrors
Unmirroring a device
Temporarily deactivating a device
Permanently disabling a mirror
Effects on system tables
Restarting mirrors
waitfor mirrorexit
Mirroring the master device
Getting information about devices and mirrors
Disk mirroring tutorial
Configuring Memory
Determining memory availability for Adaptive Server
How Adaptive Server allocates memory
Disk space allocation
Larger logical page sizes and buffers
Heap memory
Calculating heap memory
How Adaptive Server uses memory
How much memory does Adaptive Server need?
If you are upgrading
Configuration parameters that affect memory allocation
Dynamically allocating memory
If Adaptive Server cannot start
Dynamically decreasing memory configuration parameters
System procedures for configuring memory
Using sp_configure to set configuration parameters
How much memory is available for dynamic growth?
Using sp_helpconfig to get help on configuration parameters
Using sp_monitorconfig to find metadata cache usage statistics
Major uses of Adaptive Server memory
Data and procedure caches
Determining the procedure cache size
Determining the default data cache size
Monitoring cache space
User connections
Open databases, open indexes, and open objects
Number of locks
Database devices and disk I/O structures
Other parameters that use memory
Parallel processing
Worker processes
Partition groups
Remote servers
Number of remote sites
Other configuration parameters for RPCs
Referential integrity
Other parameters that affect memory
Configuring Data Caches
The data cache on Adaptive Server
Cache configuration commands
Information on data caches
Configuring data caches
Explicitly configuring the default cache
Changing the cache type
Configuring cache replacement policy
Dividing a data cache into memory pools
Matching log I/O Size for log caches
Binding objects to caches
Cache binding restrictions
Getting information about cache bindings
Checking cache overhead
How overhead affects total cache space
Dropping cache bindings
Changing the wash area for a memory pool
When the wash area is too small
When the wash area is too large
Changing the asynchronous prefetch limit for a pool
Resizing named data caches
Increasing the size of a cache
Decreasing the size of a cache
Dropping data caches
Changing the size of memory pools
Moving space from the memory pool
Moving space from other memory pools
Adding cache partitions
Setting the number of cache partitions with sp_configure
Setting the number of local cache partitions
Precedence
Dropping a memory pool
When pools cannot be dropped due to pages use
Cache binding effects on memory and query plans
Flushing pages from cache
Locking to perform bindings
Cache binding effects on stored procedures and triggers
Configuring data caches with the configuration file
Cache and pool entries in the configuration file
Cache configuration guidelines
Configuration file errors
Managing Multiprocessor Servers
Parallel processing
Definitions
Target architecture
Configuring an SMP environment
Managing engines
Resetting the number of engines
Choosing the right number of engines
Starting and stopping engines
Monitoring engine status
Starting and stopping engines with sp_engine
Taking engines offline with dbcc engine
Managing user connections
Configuration parameters that affect SMP systems
Configuring spinlock ratio parameters
Creating and Managing User Databases
Commands for creating and managing user databases
Permissions for managing user databases
Using the create database command
create database syntax
How create database works
Adding users to databases
Assigning space and devices to databases
Default database size and devices
Estimating the required space
Placing the transaction log on a separate device
Estimating the transaction log size
Default log size and device
Moving the transaction log to another device
Using the for load option for database recovery
Using the with override option with create database
Changing database ownership
Using the alter database command
alter database syntax
Using the drop database command
System tables that manage space allocation
The sysusages table
The segmap column
The lstart, size, and vstart columns
Getting information about database storage
Database device names and options
Checking the amount of space used
Checking space used in a database
Checking summary information for a table
Checking information for a table and its indexes
Querying system table for space usage information
Setting Database Options
What are database options?
Using the sp_dboption procedure
Database option descriptions
abort tran on log full
allow nulls by default
auto identity
dbo use only
ddl in tran
identity in nonunique index
no chkpt on recovery
no free space acctg
read only
select into/bulkcopy/pllsort
single user
trunc log on chkpt
unique auto_identity index
Changing database options
Viewing the options on a database
Creating and Using Segments
What is a segment?
System-defined segments
Commands and procedures for managing segments
Why use segments?
Controlling space usage
Improving performance
Separating tables, indexes, and logs
Splitting tables
Moving a table to another device
Creating segments
Changing the scope of segments
Extending the scope of segments
Automatically extending the scope of a segment
Reducing the scope of a segment
Assigning database objects to segments
Creating new objects on segments
Placing existing objects on segments
Placing text pages on a separate device
Creating clustered indexes on segments
Dropping segments
Getting information about segments
sp_helpsegment
sp_helpdb
sp_help and sp_helpindex
Segments and system tables
A segment tutorial
Segments and clustered indexes
Using the reorg Command
reorg subcommands
When to run a reorg command
Using the optdiag utility to assess the need for a reorg
Space reclamation without the reorg command
Moving forwarded rows to home pages
Using reorg compact to remove row forwarding
Reclaiming unused space from deletes and updates
Reclaiming unused space and undoing row forwarding
Rebuilding a table
Prerequisites for running reorg rebuild
Changing space management settings before using reorg rebuild
Using the reorg rebuild command on indexes
Syntax
Comments
Limitations
How indexes are rebuilt with reorg rebuild indexname
Space requirements for rebuilding an index
Performance characteristics
Status messages
resume and time options for reorganizing large tables
Specifying no_of_minutes in the time option
Checking Database Consistency
What is the database consistency checker?
Understanding page and object allocation concepts
Understanding the object allocation map (OAM)
Understanding page linkage
What checks can be performed with dbcc?
Checking consistency of databases and tables
dbcc checkstorage
Advantages of using dbcc checkstorage
Comparison of dbcc checkstorage and other dbcc commands
Understanding the dbcc checkstorage operation
Performance and scalability
dbcc checktable
dbcc checkdb
Checking page allocation
dbcc checkalloc
dbcc indexalloc
dbcc tablealloc
Correcting allocation errors using the fix | nofix option
Generating reports with dbcc tablealloc and dbcc indexalloc
Checking consistency of system tables
Strategies for using consistency checking commands
Comparing the performance of dbcc commands
Using large I/O and asynchronous prefetch
Scheduling database maintenance at your site
Database use
Backup schedule
Size of tables and importance of data
Understanding the output from dbcc commands
Errors generated by database consistency problems
Comparison of soft and hard faults
Soft faults
Hard faults
Verifying faults with dbcc checkverify
How dbcc checkverify works
When to use dbcc checkverify
How to use dbcc checkverify
Dropping a damaged database
Preparing to use dbcc checkstorage
Planning resources
Examples of sp_plan_dbccdb output
Planning workspace size
Configuring Adaptive Server for dbcc checkstorage
Configuring worker processes
Setting up a named cache for dbcc
Configuring an 8 page I/O buffer pool
Allocating disk space for dbccdb
Segments for workspaces
Creating the dbccdb database
Updating the dbcc_config table
Maintaining dbccdb
Reevaluating and updating dbccdb configuration
Cleaning up dbccdb
Removing workspaces
Performing consistency checks on dbccdb
Generating reports from dbccdb
To report a summary of dbcc checkstorage operations
To report configuration, statistics and fault information
To see configuration information for a target database
To compare results of dbcc checkstorage operations
To report faults found in a database object
To report statistics information from dbcc_counter
Developing a Backup and Recovery Plan
Keeping track of database changes
Getting information about the transaction log
Synchronizing a database and its log: checkpoints
Setting the recovery interval
Automatic checkpoint procedure
Checkpoint after user database upgrade
Truncating the log after automatic checkpoints
Free checkpoints
Manually requesting a checkpoint
Automatic recovery after a system failure or shutdown
Determining whether messages are displayed during recovery
User-defined database recovery order
Using sp_dbrecovery_order
Changing or deleting the recovery position of a database
Listing the user-assigned recovery order of databases
Fault isolation during recovery
Persistence of offline pages
Configuring recovery fault isolation
Isolating suspect pages
Raising the number of suspect pages allowed
Getting information about offline databases and pages
Bringing offline pages online
Index-level fault isolation for data-only-locked tables
Side effects of offline pages
Recovery strategies using recovery fault isolation
Reload strategy
Repair strategy
Assessing the extent of corruption
Using the dump and load commands
Making routine database dumps: dump database
Making routine transaction log dumps: dump transaction
Copying the log after device failure: dump tran with no_truncate
Restoring the entire database: load database
Applying changes to the database: load transaction
Making the database available to users: online database
Moving a database to another Adaptive Server
Upgrading a user database
Using the special dump transaction options
Using the special load options to identify dump files
Restoring a database from backups
Suspending and resuming updates to databases
Guidelines for using quiesce database
Maintaining server roles in a primary and secondary relationship
Starting the secondary server with the -q option
“in quiesce” database log record value updated
Updating the dump sequence number
Backing up primary devices with quiesce database
Recovery of databases for warm standby method
Making archived copies during the quiescent state
Designating responsibility for backups
Using the Backup Server for backup and recovery
Relationship between Adaptive Server and Backup Servers
Communicating with the Backup Server
Mounting a new volume
Starting and stopping Backup Server
Configuring your server for remote access
Choosing backup media
Protecting backup tapes from being overwritten
Dumping to files or disks
Creating logical device names for local dump devices
Listing the current device names
Adding a backup device
Redefining a logical device name
Scheduling backups of user databases
Scheduling routine backups
Other times to back up a database
Dumping a user database after upgrading
Dumping a database after creating an index
Dumping a database after unlogged operations
Dumping a database when the log has been truncated
Scheduling backups of master
Dumping master after each change
Saving scripts and system tables
Truncating the master database transaction log
Avoiding volume changes and recovery
Scheduling backups of the model database
Truncating the model database’s transaction log
Scheduling backups of the sybsystemprocs database
Configuring Adaptive Server for simultaneous loads
Gathering backup statistics
Backing Up and Restoring User Databases
Dump and load command syntax
Specifying the database and dump device
Rules for specifying database names
Rules for specifying dump devices
Tape device determination by backup server
Tape sevice configuration file
Specifying the compress option
Backup Server dump files and compressed dumps
Loading databases and transaction logs dumped with compress option
Specifying a remote Backup Server
Specifying tape density, block size, and capacity
Overriding the default density
Overriding the default block size
Specifying a higher block size value
Specifying tape capacity for dump commands
Non-rewinding tape functionality for Backup Server
Dump label changes
Tape operations
Dump version compatibility
Specifying the volume name
Loading from a multifile volume
Identifying a dump
Improving dump or load performance
Compatibility with prior versions
Labels stored in integer format
Configuring system resources
Setting shared memory usage
Setting maximum number of stripes
Setting maximum number of network connections
Setting maximum number of service threads
Specifying additional dump devices: the stripe on clause
Dumping to multiple devices
Loading from multiple devices
Using fewer devices to load than to dump
Specifying the characteristics of individual devices
Tape handling options
Specifying whether to dismount the tape
Rewinding the tape
Protecting dump files from being overwritten
Reinitializing a volume before a dump
Dumping multiple databases to a single volume
Overriding the default message destination
Bringing databases online with standby_access
When do I use with standby_access?
Bring databases online with standby_access
Getting information about dump files
Requesting dump header information
Determining the database, device, file name, and date
Copying the log after a device failure
Truncating a log that is not on a separate segment
Truncating the log in early development environments
Truncating a log that has no free space
Dangers of using with truncate_only and with no_log
Providing enough log space
The syslogshold table
Responding to volume change requests
sp_volchanged syntax
Volume change prompts for dumps
Volume change prompts for loads
Recovering a database: step-by-step instructions
Getting a current dump of the transaction log
Examining the space usage
Dropping the databases
Dropping the failed devices
Initializing new devices
Re-creating the databases
Loading the database
Loading the transaction logs
Loading a transaction log to a point in time
Bringing the databases online
Replicated databases
Loading database dumps from older versions
How to upgrade a dump to Adaptive Server
The database offline status bit
Version identifiers
Cache bindings and loading databases
Databases and cache bindings
Database objects and cache bindings
Checking on cache bindings
Cross-database constraints and loading databases
Restoring the System Databases
What does recovering a system database entail?
Symptoms of a damaged master database
Recovering the master database
About the recovery process
Summary of recovery procedure
Step 1: Find copies of system tables
Step 2: Build a new master device
Step 3: Start Adaptive Server in master-recover mode
Step 4: Re-create device allocations for master
Determining which allocations are on the master device
Creating additional allocations
Step 5: Check your Backup Server sysservers information
Step 6: Verify that your Backup Server is running
Step 7: Load a backup of master
Step 8: Update the number of devices configuration parameter
Step 9: Restart Adaptive Server in master-recover mode
Step 10: Check system tables to verify current backup of master
Step 11: Restart Adaptive Server
Step 12: Restore server user IDs
Step 13: Restore the model database
Step 14: Check Adaptive Server
Step 15: Back up master
Recovering the model database
Restoring the generic model database
Restoring model from a backup
Restoring model with no backup
Recovering the sybsystemprocs database
Restoring sybsystemprocs with installmaster
Restoring sybsystemprocs with load database
Restoring system tables with disk reinit and disk refit
Restoring sysdevices with disk reinit
Restoring sysusages and sysdatabase with disk refit
Managing Free Space with Thresholds
Monitoring free space with the last-chance threshold
Crossing the threshold
Controlling how often sp_thresholdaction executes
Rollback records and the last-chance threshold
Calculating the space for rollback records
Using lct_admin to determine the free log space
Determining the current space for rollback records
Effect of rollback records on the last-chance threshold
User-defined thresholds
Last-chance threshold and user log caches for shared log and data segments
Reaching last-chance threshold suspends transactions
Using lct_admin abort to abort suspended transactions
lct_admin abort syntax
Getting the process ID for the oldest open transaction
Using alter database when the master database reaches the last-chance threshold
Automatically aborting or suspending processes
Using abort tran on log full to abort transactions
Waking suspended processes
Adding, changing, and deleting thresholds
Displaying information about existing thresholds
Thresholds and system tables
Adding a free-space threshold
Changing a free-space threshold
Specifying a new last-chance threshold procedure
Dropping a threshold
Creating a free-space threshold for the log segment
Adding a log threshold at 45 percent of log size
Testing and adjusting the new threshold
Creating additional thresholds on other segments
Determining threshold placement
Creating threshold procedures
Declaring procedure parameters
Generating error log messages
Dumping the transaction log
A simple threshold procedure
A more complex procedure
Deciding where to put a threshold procedure
Disabling free-space accounting for data segments
System Tables Diagram
Transact-SQL User's Guide
About this book
SQL Building Blocks
SQL in Adaptive Server
Queries, data modification, and commands
Tables, columns, and rows
The relational operations
Compiled objects
Saving source text
Restoring source text
Verifying and encrypting source text
Naming conventions
SQL data characters
SQL language characters
Identifiers
Using multibyte character sets
Delimited identifiers
Uniqueness and qualification conventions
Identifying remote servers
Expressions in Adaptive Server
Arithmetic and character expressions
Operator precedence
Arithmetic operators
Bitwise operators
The String concatenation operator
The comparison operators
Nonstandard operators
Comparing character expressions
Using the empty string
Including quotation marks in character expressions
Relational and logical expressions
Using any, all, and in
Connecting expressions with and and or
Transact-SQL extensions
The compute clause
Control-of-flow language
Stored procedures
Extended stored procedures
Triggers
Defaults and rules
Error handling and set options
Additional Adaptive Server extensions to SQL
Compliance to ANSI standards
Federal Information Processing Standards (FIPS) flagger
Chained transactions and isolation levels
Identifiers
Delimited identifiers
SQL standard-style comments
Right truncation of character strings
Permissions required for update and delete statements
Arithmetic errors
Synonymous keywords
Treatment of nulls
Adaptive Server login accounts
Group membership
Role membership
Getting information about your Adaptive Server account
Changing your password
Understanding remote logins
Changing your password on a remote server
How to use Transact-SQL with the isql utility
Default databases
Using network-based security services with isql
Logging out of isql
Using the pubs2 and pubs3 sample databases
What is in the sample databases?
Queries: Selecting Data from a Table
What are queries?
select syntax
Choosing columns: the select clause
Choosing all columns: select *
Choosing specific columns
Rearranging the order of columns
Renaming columns in query results
Expressions
Quoted strings in column headings
Character strings in query results
Computed values in the select list
Arithmetic operator precedence
Selecting text and image values
Using readtext
Select list summary
Eliminating duplicate query results with distinct
Specifying tables: the from clause
Selecting rows: the where clause
Comparison operators
Ranges (between and not between)
Lists (in and not in)
Pattern matching
Matching character strings: like
Using not like
not like and ^ may give different results
Using wildcard characters as literal characters
Interaction of wildcard characters and square brackets
Trailing blanks and %
Using wildcard characters in columns
Character strings and quotation marks
“Unknown” values: NULL
Testing a column for null values
Difference between FALSE and UNKNOWN
Substituting a value for NULLs
Expressions that evaluate to NULL
Concatenating strings and NULL
System-generated NULLs
Connecting conditions with logical operators
Logical operator precedence
Using Aggregates, Grouping, and Sorting
Using aggregate functions
Aggregate functions and datatypes
count vs. count (*)
Using aggregate functions with distinct
Null values and the aggregate functions
Organizing query results into groups: the group by clause
group by syntax
group by and SQL standards
Nesting groups with group by
Referencing other columns in queries using group by
Expressions and group by
Nesting aggregates with group by
Null values and group by
where clause and group by
group by and all
Using aggregates without group by
Selecting groups of data: the having clause
How the having, group by, and where clauses interact
Using having without group by
Sorting query results: the order by clause
order by and group by
order by and group by used with select distinct
Summarizing groups of data: the compute clause
Row aggregates and compute
Rules for compute clauses
Specifying more than one column after compute
Using more than one compute clause
Applying an aggregate to more than one column
Using different aggregates in the same compute clause
Grand values: compute without by
Combining queries: the union operator
Guidelines for union queries
Using union with other Transact-SQL commands
Joins: Retrieving Data from Several Tables
How joins work
Join syntax
Joins and the relational model
How joins are structured
The from clause
The where clause
Join operators
Datatypes in join columns
Joins and text and image columns
How joins are processed
Equijoins and natural joins
Joins with additional conditions
Joins not based on equality
Self-joins and correlation names
The not-equal join
Not-equal joins and subqueries
Joining more than two tables
Outer joins
Inner and outer tables
Outer join restrictions
Views used with outer joins
ANSI Inner and outer joins
Correlation name and column referencing rules for ANSI joins
ANSI inner joins
ANSI outer joins
Should the predicate be in the on or where clause?
Nested ANSI outer joins
Converting outer joins with join-order dependency
Transact-SQL outer joins
How null values affect joins
Determining which table columns to join
Subqueries: Using Queries Within Other Queries
How subqueries work
Subquery syntax
Subquery restrictions
Example of using a subquery
Qualifying column names
Subqueries with correlation names
Multiple levels of nesting
Subqueries in update, delete, and insert statements
Subqueries in conditional statements
Using subqueries instead of expressions
Types of subqueries
Expression subqueries
Using scalar aggregate functions to guarantee a single value
group by and having in expression subqueries
Using distinct with expression subqueries
Quantified predicate subqueries
Subqueries with any and all
Subqueries used with in
Subqueries used with not in
Subqueries using not in with NULL
Subqueries used with exists
Subqueries used with not exists
Finding intersection and difference with exists
Using correlated subqueries
Correlated subqueries containing Transact-SQL outer joins
Correlated subqueries with correlation names
Correlated subqueries with comparison operators
Correlated subqueries in a having clause
Using and Creating Datatypes
How Transact-SQL datatypes work
Using system-supplied datatypes
Exact numeric types: integers
Exact numeric types: decimal numbers
Approximate numeric datatypes
Money datatypes
Date and time datatypes
Character datatypes
Unichar datatype
text datatype
Binary datatypes
image datatype
The bit datatype
The timestamp datatype
The sysname datatype
Converting between datatypes
Mixed-mode arithmetic and datatype hierarchy
Working with money datatypes
Determining precision and scale
Creating user-defined datatypes
Specifying length, precision, and scale
Specifying null type
Associating rules and defaults with user-defined datatypes
Creating a user-defined datatype with the IDENTITY property
Creating IDENTITY columns from other user-defined datatypes
Dropping a user-defined datatype
Getting information about datatypes
Creating Databases and Tables
What are databases and tables?
Enforcing data integrity in databases
Permissions within databases
Using and creating databases
Choosing a database: use
Creating a user database: create database
The on clause
The log on clause
The for load option
Altering the sizes of databases
Dropping databases
Creating tables
Maximum number of columns per table
Example of creating a table
Choosing table names
create table syntax
Allowing null values
Constraints and rules used with null values
Defaults and null values
Nulls require variable length datatypes
text and image columns
Using IDENTITY columns
Creating IDENTITY columns with user-defined datatypes
Referencing IDENTITY columns
Referring to IDENTITY columns with syb_identity
Creating “hidden” IDENTITY columns automatically
Using temporary tables
Ensuring that the temporary table name is unique
Manipulating temporary tables in stored procedures
General rules on temporary tables
Creating tables in different databases
Managing identity gaps in tables
Parameters for controlling identity gaps
Comparison of identity burning set factor and identity_gap
Example of using identity burning set factor
Example of using identity_gap
Setting the table-specific identity gap
Setting identity gap with create table
Setting identity gap with select into
Changing the table-specific identity gap
Displaying table-specific identity gap information
Gaps due to insertions, deletions, identity grab size, and rollbacks
If table inserts reach the IDENTITY column’s maximum value
Defining integrity constraints for tables
Specifying table-level or column-level constraints
Creating error messages for constraints
After creating a check constraint
Specifying default column values
Specifying unique and primary key constraints
Specifying referential integrity constraints
Table-level or column-level referential integrity constraints
Maximum number of references allowed for a table
Using create schema for cross-referencing constraints
General rules for creating referential integrity constraints
Specifying check constraints
Designing applications that use referential integrity
How to design and create a table
Make a design sketch
Create the user-defined datatypes
Choose the columns that accept null values
Define the table
Creating new tables from query results: select into
Checking for errors
Using select into with IDENTITY columns
Selecting an IDENTITY column into a new table
Selecting the IDENTITY column more than once
Adding a new IDENTITY column with select into
Defining a column whose value must be computed
IDENTITY columns selected into tables with unions or joins
Altering existing tables
Objects using select * do not list changes to table
Using alter table on remote tables
Adding columns
Adding columns appends column IDs
Adding NOT NULL columns
Adding constraints
Dropping columns
Dropping columns renumbers the column ID
Dropping constraints
Modifying columns
Which datatypes can I convert?
Modifying tables may prevent successful bulk copy of previous dump
Decreasing column length may truncate data
Modifying datetime columns
Modifying the NULL default value of a column
Modifying columns that have precision or scale
Modifying text and image columns
Adding, dropping, and modifying IDENTITY columns
Adding IDENTITY columns
Dropping IDENTITY columns
Modifying IDENTITY columns
Data copying
Changing exp_row_size
Modifying locking schemes and table schema
Altering columns with user defined datatypes
Adding a column with user-defined datatypes
Dropping a column with user-defined datatypes
Modifying a column with user-defined datatypes
Errors and warnings from alter table
Errors and warnings generated by alter table modify
Scripts generated by if exists()...alter table
Renaming tables and other objects
Renaming dependent Objects
Dropping tables
Assigning permissions to users
Getting information about databases and tables
Getting help on databases
Getting help on database objects
Using sp_help on database objects
Using sp_helpconstraint to find a table’s constraint information
Finding out how much space a table uses
Listing tables, columns, and datatypes
Finding an object name and ID
Adding, Changing, and Deleting Data
Introduction
Permissions
Referential integrity
Transactions
Using the sample databases
Datatype entry rules
char, nchar, unichar, univarchar, varchar, nvarchar, and text
datetime and smalldatetime
Entering times
Entering dates
Searching for dates and times
binary, varbinary, and image
money and smallmoney
float, real, and double precision
decimal and numeric
int, smallint, and tinyint
timestamp
Adding new data
insert syntax
Adding new rows with values
Inserting data into specific columns
Restricting column data: rules
Using the NULL character string
NULL is not an empty string
Inserting NULLs into columns that do not allow them
Adding rows without values in all columns
Changing a column’s value to NULL
Adaptive Server-generated values for IDENTITY columns
Explicitly inserting data into an IDENTITY column
Retrieving IDENTITY column values with @@identity
Reserving a block of IDENTITY column values
Reaching the IDENTITY column’s maximum value
Adding new rows with select
Computed columns
Inserting data into some columns
Inserting data from the same table
Changing existing data
update syntax
Using the set clause with update
Assigning variables in the set clause
Using the where clause with update
Using the from clause with update
Updates with joins
Updating IDENTITY columns
Changing text and image data
Deleting data
Using the from clause with delete
Deleting from IDENTITY columns
Deleting all rows from a table
truncate table syntax
Views: Limiting Access to Data
How views work
Advantages of views
Security
Logical data independence
View examples
Creating views
create view syntax
Using the select statement with create view
View definition with projection
View definition with a computed column
View definition with an aggregate or built-in function
View definition with a join
Views used with outer joins
Views derived from other views
distinct views
Views that include IDENTITY columns
After creating a view
Validating a view’s selection criteria using with check option
Views derived from other views
Retrieving data through views
View resolution
Redefining views
Renaming views
Altering or dropping underlying objects
Modifying data through views
Restrictions on updating views
Computed columns in a view definition
group by or compute in a view definition
NULL values in underlying objects
Views created using with check option
Multitable views
Views with IDENTITY columns
Dropping views
Using views as security mechanisms
Getting information about views
Getting help on views with sp_help
Using sp_helptext to display view information
Using sp_depends to list dependent objects
Listing all views in a database
Finding an object name and ID
Using the Built-In Functions in Queries
System functions that return database information
Examples of using system functions
col_length
datalength
isnull
user_name
String functions used for character strings or expressions
Examples of using string functions
charindex, patindex
str
stuff
soundex, difference
substring
Examples of other string functions
Concatenation
Concatenation and the empty string
Nested string functions
Text functions used for text and image data
Readtext
Examples of using text functions
Aggregate functions
Mathematical functions
Examples of using mathematical functions
Date functions
Get current date: getdate
Find date parts as numbers or names
Calculate intervals or increment dates
Add date interval: dateadd
Datatype conversion functions
Supported conversions
Using the general purpose conversion function: convert
Conversion rules
Converting character data to a noncharacter type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to or from money types
Converting date and time information
Converting between numeric types
Converting binary-like data
Converting hexadecimal data
Converting image data to binary or varbinary
Converting between binary and numeric or decimal types
Conversion errors
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Security functions
Creating Indexes on Tables
How indexes work
Comparing the two ways to create indexes
Guidelines for using indexes
When to index
When not to index
Creating indexes
create index syntax
Indexing more than one column: composite indexes
Using the unique option
Including IDENTITY columns in nonunique indexes
Ascending and descending index-column values
Using fillfactor, max_rows_per_page, and reservepagegap
Using clustered or nonclustered indexes
Creating clustered indexes on segments
Creating clustered indexes on partitioned tables
Specifying index options
Using the ignore_dup_key option
Using the ignore_dup_row and allow_dup_row options
Using the sorted_data option
Using the on segment_name option
Dropping indexes
Determining what indexes exist on a table
Updating statistics about indexes
Updating partition statistics
Defining Defaults and Rules for Data
How defaults and rules work
Creating defaults
create default syntax
Binding defaults
Unbinding defaults
How defaults affect NULL values
After creating a default
Dropping defaults
Creating rules
create rule syntax
Binding rules
Rules bound to columns
Rules bound to user-defined datatypes
Precedence of rules
Rules and NULL values
After defining a rule
Unbinding rules
Dropping rules
Getting information about defaults and rules
Using Batches and Control-of-Flow Language
Introduction
Rules associated with batches
Examples of using batches
Batches submitted as files
Using control-of-flow language
if...else
case expression
Using case expression for alternative representation
case and division by zero
Using rand() functions in case expressions
case expression results
case expression requires at least one non-null result
case
case and value comparisons
coalesce
nullif
begin...end
while and break...continue
declare and local variables
goto
return
print
raiserror
Creating messages for print and raiserror
waitfor
Comments
Slash-asterisk style comments
Double-hyphen style comments
Local variables
Declaring local variables
Local variables and select statements
Local variables and update statements
Local variables and subqueries
Local variables and while loops and if…else blocks
Variables and null values
Global variables
Transactions and global variables
Checking for errors with @@error
Checking IDENTITY values with @@identity
Checking the transaction nesting level with @@trancount
Checking the transaction state with @@transtate
Checking the nesting level with @@nestlevel
Checking the status from the last fetch
Global variables affected by set options
Language and character set information in global variables
Global variables for monitoring system activity
Server information stored in global variables
Global variables and text and image data
Using Stored Procedures
How stored procedures work
Examples of creating and using stored procedures
Stored procedures and permissions
Stored Procedures and Performance
Creating and executing stored procedures
Parameters
Default parameters
Using default parameters in stored procedures
NULL as the default parameter
Wildcard characters in the default parameter
Using more than one parameter
Procedure groups
Using with recompile in create procedure
Using with recompile in execute
Nesting procedures within procedures
Using temporary tables in stored procedures
Setting options in stored procedures
Arguments for stored procedures
Length of expressions, variables, and SP arguments
After creating a stored procedure
Executing stored procedures
Executing procedures after a time delay
Executing procedures remotely
Returning information from stored procedures
Return status
Reserved return status values
User-generated return values
Checking roles in procedures
Return parameters
Passing values in parameters
The output keyword
Restrictions associated with stored procedures
Qualifying names inside procedures
Renaming stored procedures
Renaming objects referenced by procedures
Using stored procedures as security mechanisms
Dropping stored procedures
System procedures
Executing system procedures
Permissions on system procedures
Types of system procedures
System procedures for auditing
System procedures used for security administration
System procedures used for remote servers
System procedures for managing databases
System procedures used for data definition and database objects
System procedures used for user-defined messages
System procedures for languages
System procedures used for device management
System procedures used for backup and recovery
System procedures used for configuration and tuning
System procedures used for system administration
System procedures for upgrade
Other Sybase-supplied procedures
Catalog stored procedures
System extended stored procedures
dbcc procedures
Getting information about stored procedures
Getting a report with sp_help
Viewing the source text of a procedure with sp_helptext
Identifying dependent objects with sp_depends
Identifying permissions with sp_helprotect
Using Extended Stored Procedures
Overview
XP Server
Dynamic Link Library Support
Open Server API
Example of creating and using ESPs
ESPs and Permissions
ESPs and Performance
Setting Priority
Freeing Memory
Creating functions for ESPs
Files for ESP Development
Open Server data structures
SRV_PROC
CS_SERVERMSG
CS_DATAFMT
Open Server return codes
Outline of a simple ESP function
Multithreading
ESP function example
Building the DLL
Search order for DLLs
Sample makefile (UNIX)
Sample makefile (Windows NT)
Sample definitions file
Registering ESPs
Using create procedure
Using sp_addextendedproc
Removing ESPs
Renaming ESPs
Executing ESPs
System ESPs
Getting information about ESPs
ESP exceptions and messages
Starting XP Server manually
Triggers: Enforcing Referential Integrity
How triggers work
Using triggers vs. integrity constraints
Creating triggers
create trigger syntax
SQL statements that are not allowed in triggers
Using triggers to maintain referential integrity
Testing data modifications against the trigger test tables
Insert trigger example
Delete trigger examples
Cascading delete example
Restricted delete examples
Update trigger examples
Restricted update triggers
Updating a foreign key
Multirow considerations
Insert trigger example using multiple rows
Delete trigger example using multiple rows
Update trigger example using multiple rows
Conditional insert trigger example using multiple rows
Rolling back triggers
Nesting triggers
Trigger self-recursion
Rules associated with triggers
Triggers and permissions
Trigger restrictions
Implicit and explicit null values
Triggers and performance
set commands in triggers
Renaming and triggers
Trigger tips
Disabling triggers
Dropping triggers
Getting information about triggers
sp_help
sp_helptext
sp_depends
Cursors: Accessing Data Row by Row
How cursors work
How Adaptive Server processes cursors
Declaring cursors
declare cursor syntax
Types of cursors
Cursor scope
Cursor scans and the cursor result set
Making cursors updatable
Determining which columns can be updated
Opening cursors
Fetching data rows using cursors
fetch syntax
Checking the cursor status
Getting multiple rows with each fetch
Checking the number of rows fetched
Updating and deleting rows using cursors
Updating cursor result set rows
Deleting cursor result set rows
Closing and deallocating cursors
An example using a cursor
Using cursors in stored procedures
Cursors and locking
Cursor locking options
Getting information about cursors
Using browse mode instead of cursors
Browsing a table
Browse-mode restrictions
Timestamping a new table for browsing
Timestamping an existing table
Comparing timestamp values
Join cursor processing and data modifications
Updates and deletes that can affect the cursor position
Cursor positioning after a delete or update command without joins
Effects of updates and deletes on join cursors
Effects of join column buffering on join cursors
Effects of column buffering during cursor scans
Recommendations
Transactions: Maintaining Data Consistency and Recovery
How transactions work
Transactions and consistency
Transactions and recovery
Using transactions
Allowing data definition commands in transactions
System procedures that are not allowed in transactions
Beginning and committing transactions
Rolling back and saving transactions
Checking the state of transactions
Nested transactions
Example of a transaction
Selecting the transaction mode and isolation level
Choosing a transaction mode
Transaction modes and nested transactions
Finding the status of the current transaction mode
Choosing an isolation level
Default isolation levels for Adaptive Server and SQL92
Dirty reads
Repeatable reads
Finding the status of the current isolation level
Changing the isolation level for a query
Isolation level precedences
Cursors and isolation levels
Stored procedures and isolation levels
Triggers and isolation levels
Compliance with SQL standards
Using the lock table command to improve performance
Syntax of the lock table command
Using the wait/nowait options of the lock table command
Using transactions in stored procedures and triggers
Errors and transaction rollbacks
Transaction modes and stored procedures
Setting transaction modes for stored procedures
Using cursors in transactions
Issues to consider when using transactions
Backup and recovery of transactions
Locking Commands and Options
Setting a time limit on waiting for locks
wait/nowait option of the lock table command
Setting a session-level lock-wait limit
Setting a server-wide lock-wait limit
Information on the number of lock-wait timeouts
Readpast locking for queue processing
Readpast syntax
Incompatible locks during readpast queries
Allpages-locked tables and readpast queries
Effects of isolation levels select queries with readpast
Session-level transaction isolation levels and readpast
Query-level isolation levels and readpast
Data modification commands with readpast and isolation levels
text and image columns and readpast
Readpast-locking examples
The pubs2 Database
Tables in the pubs2 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
roysched table
discounts table
blurbs table
au_pix table
Diagram of the pubs2 database
The pubs3 Database
Tables in the pubs3 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
store_employees table
roysched table
discounts table
blurbs table
Diagram of the pubs3 database
Troubleshooting and Error Messages Guide
About this book
Audience
What This Guide Contains
Related Documents
Changes to This Book
Your Comments About this Book
Style Conventions
Style Conventions in Text
SQL Syntax Conventions
Electronic Information Sources
If You Need Help
System Database Recovery
Ensuring Recoverability
Finding the Appropriate Recovery Scenario
master Database Is Corrupt and Adaptive Server Does Not Start
Valid Dump of the master Database Exists
Valid Dump of the master Database Does Not Exist
master Database Is Corrupt and Adaptive Server Starts
Valid Dump of the master Database Exists
Valid Dump of the master Database Does Not Exist
Master Device Is Lost and Valid Dump Exists
Valid Dump with Default Sort Order
ASE 12.5 and Later
ASE 12.0.x and Earlier
Valid Dump with Non-Default Sort Order
Master Device Is Lost and Valid Dump Does Not Exist
The model Database Is Lost or Corrupted
ASE 12.5.x and Later
ASE 12.0.x and Earlier
Non-Master Device Containing Pieces of tempdb Is Lost
Master Device Is Going Bad
Adaptive Server Does Not Start After Altering Configuration
Manually Rebuilding Adaptive Server with bcp
Checklist
Considerations
Steps for Rebuilding Adaptive Server
Copy the System Tables to Files
Get Configuration Information and Shut Down the Server
Create New Master Device and Edit the run_server File
Bring Up the Server in Single-User Mode
Copy the Files into the System Tables
Shut Down/Bring Up Adaptive Server in Single-User Mode
Run the Install Scripts for master and model
Shut Down/Bring Up the Server in Multi-User Mode
Verify the Results and Test Applications
If You Cannot Use bcp or a Dump
Encyclopedia of Tasks
Disaster Recovery Tasks
How to Build a New Master Device
ASE 12.5 and Later
ASE 12.0.x and Earlier
How to Rebuild master Database and Leave Master Device Intact
ASE 12.5 and Later
ASE 12.0.x and Earlier
How to Start Adaptive Server in Single-User Mode
Returning Adaptive Server to Multiuser Mode
How to Run the installmaster and installmodel Scripts
How to Load the master Database from Backup
How to Restore System Table Information in master Database
Restoring Device and Database Information in the System Catalog
Re-establishing Adaptive Server Logins
How to Alter the number of devices Parameter Manually
How to Alter tempdb
How to Alter the model Database
How to Reset Adaptive Server to Its Default Configuration
How to Set A Default Backup Server Manually in Adaptive Server
How to Fix Problems Encountered by Disk Refit
Problem 1: Duplicate Keys
Problem 2: Deleted Database dbid
Problem 3: Allocation Pages from Deleted Database
Problem 4: Incomplete sysusages Entries
Queries to Find Suspect sysusages Entries
Avoiding Disaster through Good DBA Practices
Online Recovery and Recovery Fault Isolation
Background
Online Recovery Concepts
Recovery from Backups
Suiciding the Log
Recovery With RFI
Using RFI
What To Do When Online Recovery Fails
Restoring from Backups
Partial online recovery using RFI
Suiciding the Log
RFI Example
How to Manually Change Sort Order or Default Character Set
Manual Process
How to Load a Sort Order or Additional Character Set
How to Change the Sort Order
How to Change the Default Character Set
How to Find a Sort Order File Name
Method 1: If You Know the Sort Order Description
Method 2: If You Know the Sort Order ID
How to Find a Sort Order ID
How to Find a Character Set ID
How to View Your Existing Sort Order and Character Sets
Useful dbcc Commands
Standard dbcc Commands
Other dbcc Commands
dbcc page
dbcc pglinkage
dbcc log
dbcc traceflags
dbcc traceon
dbcc traceoff
dbcc memusage
How to Analyze dbcc checkstorage Faults
Fault Analysis
dbcc checkstorage startup and drop table
Faults Due to sp_placeobject
Troubleshooting XP Server Issues
Background
Correcting Common XP Server Problems
Information to Collect Before Calling Technical Support
Other Useful Tasks
How to Fix a Corrupted Index on System Tables
Read These Warnings First
Repairing the System Table Index
Workaround for sysobjects Nonclustered Indexes
How to Rescue Data from a Corrupted Table
Back Up Data to a New Table
Back Up Data to an Operating System File
How to Start Adaptive Server with Trace Flags
Modifying the RUN_server File to Include Trace Flags for UNIX
Modifying the RUN_server File to Include Trace Flags for Digital OpenVMS
Using the Load Command With Trace Flags in Novell NetWare
Using Trace Flags in OS/2
Using Server Configuration to Include Trace Flags in Windows NT
How to Reload a Suspect User Database
How to Drop a Database When drop database Fails
How to Fix and Prevent Allocation Errors
Understanding Allocation Errors
Fixing Allocation Errors
Fixing Allocation Errors when Object ID and Index ID are Known
Detecting Allocation Errors as Early as Possible
Syntax for dbcc checkalloc with the fix Option
How to Find an Object Name from a Page Number
How to Interpret sp_who Output
Device Administration Issues
How to Choose Between Raw Partitions and UNIX Files
Correct Use of Raw Partitions
Getting Information About Your Partition
Other Situations to Avoid
How to Move a Sybase Device or Database With Disk Mirroring
How to Gather Information About Read/Write Errors
Before You Create and Execute sp_diskblock
How to Mark a Database “suspect'”
Before You Create and Execute sp_marksuspect
After You Execute sp_marksuspect
How to Reset a Database's “suspect” Status
Before You Create and Execute sp_resetstatus
After You Execute sp_resetstatus
Alternative Method of Resetting a Database's “suspect” Status
How to Find a Device's Virtual Device Number
Before You Create and Execute sp_vdevno
How to Detect and Clear Long-Running Transactions
Causes of Long-Running Transactions
Detecting Long-Running Transactions
Clearing Long-Running Transactions
How to Reduce the Size of tempdb
Reset tempdb to Default Size
Verify and Alter tempdb on Desired Devices
How to Remap All Objects in a Database
The Remapping Script
How to Prepare for Analyzing an Optimizer Problem
Terminology
Questions to Ask First
Steps to Take Before Analysis
How to Gather the Information
Understanding the Information You Have Gathered
How to Determine Which Physical Devices a Database is On
How to Identify and Fix a Corrupted Table
How to Monitor the Error Log
Checking the Operating System Error Log
Location of the Operating System Error Log
Types of Problems to Check
How to Obtain a CSMD Dump
How to Configure a Shared Memory Dump on Conditions
Error Message Writeups
Error Message Severity Levels
Variables in Error Message Text
Finding Object Names from Error Message Text
How to Determine Your Adaptive Server Version
Field Order in Version String
Creating Error Messages
Reporting Errors
Faxing Error Log Fragments
Reproducing Problems
Error Message Writeups
Parser Errors
Sequencer Errors
Query Processor Errors
Access Method Errors
Memory Manager Errors
Buffer Manager Errors
Open Database Manager Errors
Page Manager Errors
Lock Manager Errors
Sort Manager Errors
Initialization Errors
Create Utilities Errors
High Availability Utility Errors
Character Set Conversion Errors
dbcc Errors
Insert Errors
Create Utilities Errors (continued)
Procedure Manager Errors
dump and load Errors
Commit and Abort Errors
Recovery Errors
Error and Exception Handling Errors
drop Errors
Transaction Errors
dataserver Errors
dump and load Errors (continued)
truncate table Errors
Bulk Copy Utility Errors
alter table Errors
alter database Errors
Disk Errors
ASTC Errors
Open Client Errors
Configuration Errors
Process Kill Errors
Timestamp Errors
Text Manager Errors
Distributed Database Network Errors
Parser Errors (continued)
Threshold Errors
Auditing Errors
Sequencer Errors (continued)
dbcc Errors (continued)
RPC Errors
Descriptor Manager Errors
sysindexes Manager Errors
Process Status Structure Errors
Site Buffer Manager Errors
Disk Manager Errors
Log Transfer Errors
Configuration Errors (Continued)
Sequencer Errors (continued)
Remote Create Errors
Fault Isolation Utility Errors
Create Utilities Errors (continued)
Sequencer Errors (continued)
System Procedure Errors
Kernel Errors
Backup Server Error Messages
Commonly Encountered Errors
“No language handler installed” Message
LOGCONN Errors in Adaptive Server After Using Backup Server
load {database | transaction} with listonly Locks Database
Some Messages from Backup Server Are Lost
dump database on Digital OpenVMS Alpha/Digital UNIX Raises Error
Error 5704 in the OpenVMS Backup Server error log
Unable to use Async IO when dumping to disk on HP-UX
Maximum Number of DBPROCESSes Already Allocated
Error Conditions Without Messages
Errors in Backup Server Error Log
Net-Library routine net_dict_open failed in srv__open_dictionary
Net-Library routine net_listen failed in srv_start_net
Net-Library routine net_init failed in srv__init_net
No driver of the requested protocol class is available
Net-lib protocol driver call to connect two endpoints failed
Open Server Error Messages Related to Backup Server
Error 5704.10.0
Error 16240.20.0
A Listing of All Backup Server Error Messages
Error Number Format
List of Error Messages
Backup Server Error Messages 1.1.2 - 1.63.2
Backup Server Error Messages 2.1.2 - 3.55.2
Backup Server Error Messages 4.1.2 - 4.75.3
Backup Server Error Messages 4.76.3 - 4.147.2
Backup Server Error Messages 5.1.2 - 6.89.2
Backup Server Error Messages 7.1.2 - 8.17.2
Component Integration Services Error Messages
Component Integration Services Error Messages
Adaptive Server Error Messages
Working with Error Messages
Server Error Messages 1 - 199
Server Error Messages 200 - 299
Server Error Messages 300 - 399
Server Error Messages 400 - 499
Server Error Messages 500 - 599
Server Error Messages 600 - 699
Server Error Messages 700 - 799
Server Error Messages 800 - 899
Server Error Messages 900 - 999
Server Error Messages 1000-1099
Server Error Messages 1100-1199
Server Error Messages 1200-1299
Server Error Messages 1300-1399
Server Error Messages 1500-1599
Server Error Messages 1600-1699
Server Error Messages 1700-1799
Server Error Messages 1800-1899
Server Error Messages 1900-1999
Server Error Messages 2000–2099
Server Error Messages 2100–2199
Server Error Messages 2200–2299
Server Error Messages 2300–2399
Server Error Messages 2400–2499
Server Error Messages 2500–2599
Server Error Messages 2600–2699
Server Error Messages 2700–2799
Server Error Messages 2800–2899
Server Error Messages 2900–2999
Server Error Messages 3000 - 3099
Server Error Messages 3100 - 3199
Server Error Messages 3200 - 3299
Server Error Messages 3300 - 3399
Server Error Messages 3400 - 3499
Server Error Messages 3500 - 3599
Server Error Messages 3600 - 3699
Server Error Messages 3700 - 3799
Server Error Messages 3800 - 3899
Server Error Messages 3900 – 3999
Server Error Messages 4000 – 4099
Server Error Messages 4200 - 4299
Server Error Messages 4300 - 4399
Server Error Messages 4400 - 4499
Server Error Messages 4500 - 4599
Server Error Messages 4600 - 4699
Server Error Messages 4700 - 4799
Server Error Messages 4800 - 4899
Server Error Messages 4900 - 4999
Server Error Messages 5000 - 5099
Server Error Messages 5100 - 5199
Server Error Messages 5200 - 5299
Server Error Messages 5600 - 5699
Server Error Messages 5700 - 5799
Server Error Messages 5800 - 5899
Server Error Messages 5900 - 5999
Server Error Messages 6000 - 6099
Server Error Messages 6100 - 6199
Server Error Messages 6200 - 6299
Server Error Messages 6400 - 6499
Server Error Messages 6500 - 6599
Server Error Messages 6700 - 6799
Server Error Messages 6900 - 6999
Server Error Messages 7000 - 7099
Server Error Messages 7100 - 7199
Server Error Messages 7200 - 7299
Server Error Messages 7300 - 7399
Server Error Messages 7400 - 7499
Server Error Messages 7600 - 7699
Server Error Messages 7700 - 7799
Server Error Messages 7900 - 7999
Server Error Messages 8000 - 8099
Server Error Messages 8200 - 8299
Server Error Messages 8400 - 8499
Server Error Messages 8500 - 8599
Server Error Messages 8600 - 8699
Server Error Messages 8700 - 8799
Server Error Messages 8800 - 8899
Server Error Messages 8900 - 8999
Server Error Messages 9000 - 9099
Server Error Messages 9100 - 9199
Server Error Messages 9200 - 9299
Server Error Messages 9300 - 9399
Server Error Messages 9500 – 9599
Server Error Messages 9600 - 9699
Server Error Messages 9700 - 9799
Server Error Messages 9800 - 9899
Server Error Messages 9900 - 9999
Server Error Messages 10100 - 10199
Server Error Messages 10200 - 10299
Server Error Messages 10300 - 10399
Server Error Messages 10400 - 10499
Server Error Messages 10500 - 10599
Server Error Messages 10600 - 10699
Server Error Messages 10700 - 10799
Server Error Messages 10800 - 10899
Server Error Messages 10900 - 10999
Server Error Messages 11000 - 11099
Server Error Messages 11100 - 11199
Server Error Messages 11200 - 11299
Server Error Messages 11300 - 11399
Server Error Messages 11400 - 11499
Server Error Messages 11500 - 11599
Server Error Messages 11600 - 11699
Server Error Messages 11700 - 11799
Server Error Messages 11900 - 11999
Server Error Messages 12000 - 12099
Server Error Messages 12100 - 12199
Server Error Messages 12200 - 12299
Server Error Messages 12300 - 12399
Server Error Messages 12400 - 12499
Server Error Messages 12500 - 12599
Server Error Messages 12700 - 12799
Server Error Messages 12800 - 12899
Server Error Messages 12900 - 12999
Server Error Messages 13000 - 13099
Server Error Messages 13100 - 13199
Server Error Messages 13200 - 13299
Server Error Messages 13900 - 13999
Server Error Messages 14000 - 14099
Server Error Messages 14100 - 14199
Server Error Messages 14200 - 14299
Server Error Messages 14300 - 14399
Server Error Messages 14400 - 14499
Server Error Messages 17000 - 18999
Glossary
Using Adaptive Server Distributed Transaction Management Features
About this book
Overview
Distributed Transaction Management features
Affected transaction types
Distributed transactions coordinated by external transaction managers
Behavior for transaction manager-coordinated transactions
RPC and CIS transactions
New behavior for RPC and CIS transactions
SYB2PC transactions
Enabling DTM Features
Installing a license key
Enabling DTM features
enable dtm parameter
enable xact coordination parameter
Configuring transaction resources
Calculating required transaction descriptors
Setting the number of transaction descriptors
Using Adaptive Server Transaction Coordination Services
Overview of transaction coordination services
Hierarchical transaction coordination
X/Open XA-compliant behavior in DTP environments
Requirements and behavior
Configuring participant server resources
number of dtx participants parameter
Optimizing number of dtx participants for your system
Using transaction coordination services in heterogeneous environments
strict dtm enforcement parameter
Monitoring coordinated transactions and participants
DTM Administration and Troubleshooting
Transactions and threads of control
Implications for system administrators
dtm detach timeout period parameter
Lock manager changes to support detached transactions
Getting information about distributed transactions
Transaction identification in systransactions
Transaction keys
Viewing active transactions with sp_transactions
Identifying local, remote, and external transactions
Identifying the transaction coordinator
Viewing the transaction thread of control
Understanding transaction state information
Transaction failover information
Determining the commit node and gtrid with sp_transactions
Commit and parent nodes
Global transaction ID
Crash recovery procedures for distributed transactions
Transactions coordinated with MSDTC
Transactions coordinated by Adaptive Server or X/Open XA
Transactions coordinated with SYB2PC
Heuristically completing transactions
Completing prepared transactions
Forgetting heuristically completed transactions
Manually clearing the commit status
Completing transactions that are not prepared
Determining the commit status for Adaptive Server transactions
Using Sybase Failover in a High Availability System
About this book
What is High Availability?
What is High Availability?
Requirements for Failover
Resource Requirements
Applications Running with Sybase’s Failover
How Does Sybase’s Failover Work with High Availability?
Single System Presentation
Special Considerations for Sybase Failover
Using Failover with Disk Mirroring
installhasvss Script
SYB_HACMP Server Entry
Define User-Defined Data types in Adaptive Servers Before Configuring Them for Failover
Adaptive Server and Two-Phase Commit Transactions
Adaptive Server probes
Failover and Failback
What is Failover?
Client Connections During Failover
User Logins in Failover
What is Failback?
Performing Failback
Cluster Locks in a High Availability Node
Asymmetric and Symmetric Setup
Asymmetric and Symmetric Configuration
Asymmetric Companion Configuration
Performance of Adaptive Server in an Asymmetric Configuration
Symmetric Companion Configuration
Performance of Adaptive Server in a Symmetric Configuration
Determining the Name of the Companion Server with @@hacmpservername
Auditing in A High Availability System
Setting Auditing Options
Audit Trails and Sybase Failover
sybsecurity and Sybase Failover
Modes of Failover
What are Modes?
Determining the Companion’s Mode
Determining the Mode with @@cmpstate
The Different Modes of a Companion Server
Domains
Proxy Databases, User Databases, and Proxy System Tables
Proxy Databases
How are Proxy Databases Created?
When Are Proxy Databases Created?
Size of the Proxy Databases
Behavior of Commands and System Procedures in Proxy Databases
Changes to Commands in Proxy Databases
Changes to System Procedures in Proxy Databases
Issuing User-defined Stored Procedures in Proxy Databases
Manually Updating the Proxy Databases
Proxy System Tables in master
Running do_advisory
What is the do_advisory Option?
How Do I Run the do_advisory Option?
Quorum Attributes
Configuring Adaptive Server for Failover on HP
Configure Hardware and Operating System for High Availability
Prepare Adaptive Server to Work with The HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Set the Value of $SYBASE the Same on a Local File System
The sybha Executable
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Configuring HP for Failover
Create the Package Configuration
Edit the ASE_HA.sh Script
Create the Package Control Script
Verify and Distribute the Configuration
Start Up Both the Primary and Secondary Companions
Configure Companion Servers for Failover
Run sp_companion With do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Administering Sybase Failover
Failing Back to the Primary Companion and Resuming Normal Companion Mode
Suspending Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Dropping Companion Mode
Troubleshooting Sybase Failover on HP
Error Message 18750
Recovering from a Failed prepare_failback
Location of Error Logs
Configuring Adaptive Server for Failover on IBM AIX
Configure Hardware and Operating System for High Availability
Requirements for Running Sybase’s Failover on IBM AIX
Special Considerations for Running Adaptive Server on HACMP for AIX
Prepare Adaptive Server to Work with the HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Set $SYBASE the Same on a Local File system
The sybha Executable
Verify Configuration Parameters
Add Thresholds to the Master Log
Create New Default Device Other Than Master
Add The Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Configure the IBM AIX Subsystem for Sybase Failover
Modify the ASE_HA.sh Script
Configure the Resource Groups in HACMP
Configure Companion Servers for Failover
Run sp_companion With do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Bring Up Primary Companion as a Monitored Resource
Administering Sybase Failover
Failing Back to the Primary Node
Manually Failing Back
Suspending Companion Mode
Restarting Shutdown Companion During Suspended Mode
Resuming Normal Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover on HACMP for AIX
Error Message 18750
Recovering From a Failed prepare_failback
Location of Failover Logs
Configuring Adaptive Server for Failover on HP Tru64 TruCluster Server 5.x
Configure Hardware and Operating System for High Availability
Requirements for Running Sybase’s Failover on HP TruCluster
Prepare Adaptive Server to Work with The HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
sybha Executable
Verify Configuration Parameters
Add Thresholds to the Master Log
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Assign ha_role to SA
Run installhasvss to Install HA Stored Procedures
Configure the HP Tru64 Subsystem for Sybase’s Failover
Modify the ASE_HA.sh Script
Modify the ASE_HA.cap profile
Configure Companion Servers for Failover
Run sp_companion with do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Bring Up Primary Companion as a Monitored Resource
Administering Sybase Failover
Failing Back to the Primary Node
Manually Failing Back
Suspending Companion Mode
Restarting Shutdown Companion During Suspended Mode
Resuming Normal Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover on TruCluster Server for HP Tru64
Error Message 18750
Recovering from a Failed prepare_failback
Location of Failover Logs
Configuring Adaptive Server for Failover on Sun
Hardware and operating system requirements
Prepare Adaptive Server to Work with the HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Make the Value of $SYBASE the Same for Both Companions
The sybha Executable
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Add Thresholds to the Master Log
Configuring the Sun Cluster Subsystem for Sybase Failover
Configure Companion Servers for Failover
Run sp_companion with do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Administrating Sybase’s Failover
Failing Back to the Primary Companion
Suspending Normal Companion Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover for Sun Cluster
Recovering from a Failed prepare_failback
Location of the Logs
Configuring Adaptive Server for Failover on Sun Cluster 3.0
Hardware and operating system requirements
Adaptive Server and high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to interfaces file for client connections during failover
Making the value of $SYBASE the same for both companions
Executing sybha
Creating new default devices
Adding the local server to sysservers
Adding secondary companion to sysservers
Assigning ha_role to SA
Installing HA stored procedures
Verifying configuration parameters
Adding thresholds to the master log
Adding user and login for monitoring
Configuring the Sun Cluster subsystem
Configuring Adaptive Server for high availability on Sun Cluster 3.0
Primary server
Secondary server
Configuring companion servers for failover
Setting the HA services library within Adaptive Server
Running sp_companion with do_advisory
Before initiating sp_companion
Configuring for asymmetric configuration
Configuring for symmetric configuration
Administering Sybase Failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Verifying high availability on Sun Cluster 3.0
Troubleshooting
Recovering from a failed prepare_failback
Prevent failover of secondary companion
Changing resource and resource group state
Location of the logs
Configuring Adaptive Server for Failover on Veritas
Hardware and operating system requirements
Adaptive Server and high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to the interfaces file for client connections during failover
Making the value of $SYBASE identical for both companions
Organizing the components of the runserver file
Executing sybha
Creating new default devices
Adding the local server to sysservers
Adding a secondary companion to sysservers
Installing HA stored procedures
Assigning ha_role
Verifying configuration parameters
Adding thresholds to the master log
Configuring the Veritas subsystem
Copying the Sybase agent scripts
Configuring companion servers
Running sp_companion with do_advisory
Verifying the cluster software
Configuring for asymmetric configuration
Configuring for symmetric configuration
Administering Sybase Failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Troubleshooting
Recovering from a failed prepare_failback
Configuring Adaptive Server for Failover on Windows NT
Configure Hardware and Operating System for High Availability
Prepare Adaptive Server for HA Configuration
Install Adaptive Servers
Changing the Domain Administration Account
Add Entries for Both Adaptive Servers to sql.ini
Add Entries to sql.ini for Client Connections During Failover
Create New Default Device Other Than Master
Add Primary Companion as a Local Server
Add Secondary Companion to sysservers
Run insthasv to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Run sp_companion with do_advisory Option
Configuring Windows NT for Failover
Configure for Asymmetric Configuration from the Command Line
Configure for Symmetric Setup from the Command Line
Configure Windows NT for Failover Using Cluster Administrator
Configuring and Securing Microsoft Cluster Server
Check the MSCS Configuration
Securing the MSCS Cluster
Troubleshooting Sybase Failover on Windows NT
Error Message 18750
Recovering from a Failed prepare_failback
Troubleshooting Second Point of Failures
Troubleshooting with dbcc ha_admin
Re-Installing installmaster and installhasvss
Re-Installing installmaster
Re-Installing installhasvss
Using dbcc ha_admin to Address Second Point of Failures for Failover and prepare_failback
Error Messages 18805, 18769, 18836
Changes to Commands, System Procedures, System Databases, and New dbcc Commands, and Functions
Changes to System Procedures in Adaptive Server Configured for Failover
System Procedures Hold Table Lock When Modifying System Tables
Changes to System Procedures in A Failover Configuration
dbcc Options for High Availability Systems
dbcc dbrepair Option for Sybase Failover
Open Client Functionality in a Failover Configuration
CTLIB Application Changes
Glossary
Utility Guide
About this book
Building Servers Using dataserver
Introduction
Building a new master device
Environments when using dataserver
build mode
start mode
Upgrading to a server with larger page sizes
Viewing the current server limits
Using the isql Utility
Before you begin
Starting and stopping isql
How to use Transact-SQL in isql
Formatting isql output
Correcting input
set options that affect output
Changing the command terminator
Performance statistics interaction with command terminator values
Setting the network packet size
Input and output files
UNIX command-line redirection
Using bcp to Transfer Data to and from Adaptive Server
Methods for moving data
Importing and exporting data with bcp
bcp requirements
bcp modes
bcp performance
Using fast or slow bcp
Copying in data with fast bcp
Bulk copying data into partitioned tables
Monitoring bcp sessions with dbcc checktable and sp_helpsegment
Reducing logging by increasing page allocations
Using parallel bulk copy to copy data into a specific partition
bcp in and locks
Parallel bulk copy methods
Parallel bulk copy syntax
Using parallel bulk copy on partitioned tables
Parallel bulk copy and IDENTITY columns
Using the bcp options
Using the default formats
Native format
Character format
Changing terminators from the command line
Changing the defaults: interactive bcp
Responding to bcp prompts
File storage type
Prefix length
Field length
Field and row terminators
Choosing Terminators
Using format files
Elements of the bcp format file
Examples: copying out data interactively
Copying out data with field lengths
Copying out data with delimiters
Comma-delimited, newline-delimited with format file
Tab-delimited with format file
Examples: copying in data interactively
Copying in data with field lengths
Copying in data with delimiters
Copying in data with a format file
Using bcp with alternate languages
Copy in and batch files
Improving recoverability
Batches and partitioned tables
Copy out and text and image data
Specifying a network packet size
Copy in and error files
Copy out and error files
Data integrity: defaults, rules, and triggers
Defaults and datatypes
Rules and triggers
How bcp differs from other utilities
Using dsedit
Getting started with dsedit
Starting dsedit
Opening an editing session
Adding, viewing, and editing server entries
Modifying server entries in Windows NT
Modifying server entries in UNIX platforms
Adding or editing network transport addresses
SPX/IPX addresses
Copying server entries
Troubleshooting dsedit
The dsedit utility does not start
Error message: “Unable to open X display”
Cannot add, modify, or delete server entries
Using dscp
Getting started with dscp
Using a dscp session
Working with server entries
Adding and modifying server entries
Copying server entries
Listing and viewing contents of server entries
Deleting server entries
Exiting dscp
Quick reference for dscp utility commands
Utility Commands Reference
Getting started
*_dce and *_r utilities
Utilities quick reference
Installation or configuration utilities
Utilities for languages, character sets, and sort orders
Utilities to start servers
Database creation and manipulation utilities
Utilities to gather information
backupserver
bcp
buildmaster
certauth
certpk12
certreq
charset
cobpre
cpre
dataserver
dataxtr
ddlgen
defncopy
dscp
dsedit
extractjava
installjava
isql
langinstall
optdiag
pwdcrypt
showserver
sqldbgr
sqlloc
sqllocres
sqlsrvr
sqlupgrade
sqlupgraderes
srvbuild
srvbuildres
startserver
xpserver
XA Interface Integration Guide for CICS, Encina, and TUXEDO
About this book
Introduction
Requirements
The Sybase XA Environment
Definitions
Overview of the X/Open DTP model
Components of the model
How the components communicate
How the components interact
Recovery
The Sybase XA environment
Components of the Sybase XA environment
Connections in the Sybase XA environment
Identifying connections via LRMs
Where is the connection information stored?
Establishing connections
Distributing work across LRMs
Configuring the XA Environment
Configuring Adaptive Server
Open string parameters for DTM XA Interface
Open string parameters
dtm_tm_role required for username
Log file and trace flag parameters
Labels for logfile entries
xa_open() function behavior
XA configuration file for DTM XA Interface
Environment variable for specifying configuration file
[all] section for defining common LRM parameters
Parameter definitions for [all] section
Editing the XA configuration file
Additional capabilities, properties, and options
Using the DTM XA Interface with CICS
Building the switch-load file
Compiling the switch-load file on IBM RISC System/6000 AIX
Compiling the switch-load file on HP9000 Series 800 HP-UX
Compiling the switch-load file on Sun Solaris 2.x (SPARC)
Adding a Sybase stanza to the CICS region XAD definition
Using the DTM XA Interface with Encina
Assigning an open string with monadmin create rm
Initializing LRMs with mon_RegisterRmi
Linking applications with DTM XA Interface libraries
Establishing connections
Using the DTM XA Interface with TUXEDO
Linking
Setting up the UBBCONFIG file
Creating the TUXEDO configuration file
Building the TMS
Build COBOL runtime environment
Application Programming Guidelines
X/Open DTP versus traditional Sybase transaction processing
Transaction and connection management
Transaction management
Connection management
The current connection
Nontransactional connections
Deallocate cursor function with Client-Library
Dynamic SQL
Getting a Client-Library connection handle
Multiple-thread environment issues
Caveats of thread use
Embedded SQL thread-safe code
Tightly coupled transactions
Linking with CT Library
Sample embedded SQL COBOL fragment
Sample embedded SQL C fragment
What's New in Adaptive Server Enterprise?
About this book
New Features in Adaptive Server Version 12.5
New features in version 12.5
Relaxed server limits
Varying logical page sizes
Number of columns and column size
Maximum length of expressions, variables, and stored procedure arguments
Number of logins
Performance implications of new limits
Dynamic reconfiguration
Dynamic memory allocation
Changes to how memory is allocated
SQLJ stored procedures and functions (Java)
XML in the database
Union in views
Internet directory services (LDAP)
Secure Socket Layers (SSL)
Enterprise Java Beans (EJB Server)
External file system support
Row-level access control
Suspending and resuming updates to databases
Java.net support
Compressed backups
Unichar support
Changes to CIS
SQL debug utility
Migration utility
System Changes in Adaptive Server Version 12.5
System changes in version 12.5
Changes to configuration parameters
New configuration parameters
Changes to configuration parameters
Changes to Transact-SQL commands
New Transact-SQL commands
Changed Transact-SQL commands
New and changed set command options
New Transact-SQL functions
New and changed system procedures
New system procedures
Changed system procedures
New utility programs
Changes to current utility programs
Changes to databases and system tables
New databases
New system tables
Changed system tables
Changed status in existing columns
New reserved words
New global variables
Changes to the documentation
Changes that may effect existing applications
New Transact SQL keywords
Wide column and data truncation
Changes that effect Client Server applications
Using Open Client with Adaptive Server’s new limits
If you use a earlier version of Open Client with Adaptive Server
Maximum number of expressions in a select statement
New Features and System Changes in Adaptive Server Version 12.0
New features in version 12
Sybase’s Failover for a high availability system
Rebuilding indexes
New Backup Server features
High performance backup and restore
Non-rewinding tapes
UNIX file system support
Modifying an existing table’s schema with alter table
Suspending database updates with quiesce database
Taking Adaptive Server engines offline
User settable process information
Identity number gap for tables
Diagnostic database
Java in Adaptive Server Enterprise
Capabilities of Java in Adaptive Server
Java user-defined functions
Java classes as datatypes
Number of tables in a query
Query processing and optimization enhancements
Merge joins
Query costing improvements
ANSI joins
Dynamic execution of Transact-SQL
text and image datatype enhancements
Abstract plans
Disabling triggers
Cache partitions
Distributed Transaction Management
Enhancements to Component Integration Services (CIS)
Network security
Performance considerations
Security features supported in Adaptive Server 12
User-defined login security
Increased maximum number of users and logins
Setting and changing the maximum login attempts
Locking and unlocking logins and roles
Displaying password information
Checking passwords for at least one character
Setting and changing minimum password length
Setting the expiration interval for a password
Concrete identification
System changes in version 12
Changes to configuration parameters
New configuration parameters
Changes to configuration parameters
Changes to Transact-SQL commands
New Transact-SQL commands
Changed Transact-SQL commands
New and changed set command options
New Transact-SQL functions
New and changed system procedures
New system procedures
Changed system procedures
New utility programs
Changes to Databases and System Tables
New Databases
New system tables
Changed System Tables
New reserved words
Changes to the documentation
Changes that may affect existing applications
New Transact-SQL Keywords for 12
dsync On By Default for UNIX File Devices
New Features in Adaptive Server Version 11.9.2
New locking schemes
Changes to table-level locking
Changes to statistics and query optimization
Enhancements to the create index command
Changes and additions to Transact-SQL syntax
New readpast concurrency option
New lock table command
Specifying a wait time for locks
Repeatable read transaction isolation
Configurable database recovery order
Fault verification for dbcc checkstorage faults
License use monitor
Task-to-engine affinity
Dynamic SQL performance improvements
Direct updates through joins
Component Integration Services changes
Character set changes
Changes that may affect existing applications
Effects of changing to data-only-locking
Query optimization changes and forced query plans
Index forcing and data-only-locked tables
Performance after loading pre-11.9 databases
Ordering of results with data-only locked tables
Delay of cursor compilation until cursor open
Visible effects of delayed cursor optimization
New Features in Adaptive Server Release 11.5
New features in release 11.5
Asynchronous prefetch
Auditing enhancements
New system procedures
case expression
Component Integration Services
New commands
New system procedures
Modified system procedures
create index enhancements
dbcc enhancements
Advantages of using dbcc checkstorage
System and stored procedures for creating dbccdb
Stored procedures for maintaining dbccdb
Stored procedures for generating reports on dbccdb
Descending index scan optimization
Directory services
Engine affinity and execution precedence
New system procedures
Expanded error logging
New system procedures
Modified system procedures
Extended Stored Procedures (ESPs)
XP Server
System-defined ESPs
New system procedures for ESPs
Supporting commands
Increased referential integrity limits
Metadata cache management
Monitor access to SQL batch text
Allocating memory for batch text
New columns in sysprocesses
Parallel bulk copy
Parallel queries and enhanced partitioning
Point-in-time recovery
Proxy authorization
Recovery fault isolation
New system procedures
Side effects of recovery fault isolation
Relaxed LRU cache replacement policy
Resource limits
New system procedures
Supporting commands
Source text verification and encryption
Sybase Central
sp_sysmon
Two-phase commit enhancements
spt_comittab moved to sybsystemdb
Commit identifier changed to a random value
User-defined roles
Windows NT event log integration
Supporting system ESPs and system procedures
Windows NT MAPI support
Supporting system ESPs and system procedures
Windows NT Performance Monitor integration
Supporting system procedure
New Features in SQL Server Release 11.0
New features in release 11.0
User-defined caches
Configuring caches
Binding objects to user-defined caches
Cache strategies
Large I/O
Changing the log I/O size
New query tuning options
Data storage changes
Maximum number of rows per page
Page allocation
Partitioned tables
Transaction log changes
User log caches
syslogshold table
Isolation level 0
Lock manager changes
Table, page, and address lock tables
Deadlock checking
New engine freelock lists
Increasing the engine freelock lists
Housekeeper task
SQL Server configuration
Lock escalation
Multiple network engines
Improvements to showplan
Query and data modification changes
Subquery changes
Update changes
Upgrading database dumps
Tape device determination by Backup Server
IDENTITY column changes
New text and image global variables
System changes in release 11.0
New online database command
Changes to existing commands
New set options
New system procedures
Changes to system procedures
New system tables
Changes to existing system tables
Changes that may affect existing applications
New Transact-SQL keywords in release 11.0
Changes to SQL Server configuration
The reconfigure command
buildmaster -r no longer supported
New names for existing configuration parameters
New configuration parameters
New deadlock checking period parameter
New page utilization percent parameter
Compiled object sizes have grown
SQL Server code size has grown
Subquery changes
Different results
Changes in subquery restrictions
Handling NULL results
Improved performance
Changes to showplan output in release 11.0
New caching strategies may affect performance
Upgrading database dumps
Partitions and physical data placement
Release Bulletin ASE 12.5 on Digital UNIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Emulated instructions warning on DEC
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on HP-UX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Running EJB Server on HP 32-bit machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Error message after running truncate table command
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on IBM AIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Re-entrant libraries required for SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Monitor Server counters increment improperly
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Linux
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
/etc/rc.d/init.d/sybase incorrectly defines $SYBASE variables
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
Harmless error messages when starting Linux with SSL enabled
SSL listener port hangs
Highlighted known Sybase Central problems
Unnecessary characters appear when executing Sybase Central
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
Turning off the O_SYNC flag
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Engine not exiting after ueshutdown()
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 11.9.2
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Silicon Graphics IRIX
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Compatibility with other products
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
dsedit does not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Backup Server hangs when issued an RCP to dump a database
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic and host variables not allowed in DDL statements
shutdown no wait causes a stacktrace
uninstall does not work with Studio Installer
Product compatibilities
Documentation updates and clarifications
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Reference Manual Volume 1: Building Blocks
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Sun Solaris
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Using Adaptive Server with transaction services
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrading Monitor Server
OAM counts mismatch on sysobjects after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Asynchronous large I/O on UNIX file systems
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Release Bulletin ASE 12.5 on Windows
Accessing current release bulletin information
Component summary
Installation kit
Server components
PC-client components
Operating system updates
Special installation instructions
Known installation issues
Studio Installer fails to load on Pentium 4 machines
Input cursor not always visible in Studio Installer
Cannot use Services to start and stop server on mapped network drive
Using Adaptive Server with MTS and DTC
Special upgrade instructions
Migrating data between Adaptive Servers with different logical page sizes
Known upgrade issues
Upgrade can cause system path to exceed maximum limit
OAM counts mismatch on sysobjects after upgrade
Using diagserver after upgrade
Changed functionality in this version
Changes affecting applications after upgrade
Increased optimization time for queries with many join keys
ANSI outer join syntax recommended
Known problems
Rebuilding system databases on upgraded servers
Understanding sizes
Highlighted known LDAP-related problems
Enabling lightweight directory services
Sybase Central does not support directory services
langinstall and charset utilities do not support LDAP
Highlighted known RPC-related problems
RPC compatibility with older versions of Adaptive Server
Channel setup failure message when issuing RPCs
Highlighted known SSL problems
Component Integration Services connection fails using SSL
Network memory requirements for using SSL for incoming connections
Lack of memory causes ssl_handshake failures
SSL listener port hangs
Highlighted known Sybase Central problems
Error when viewing table properties in Sybase Central
Highlighted known alter table problems
Sporadic error message from alter table on DOL tables
alter table and sysstatistics flaw
alter table and triggers with if update() clauses
Highlighted known select problems
select statements that include order by clauses
Truncation error using select with power() function and numeric argument
create schema causes lock contention
Problems using named pipes in the sql.ini file
unichar does not work across platforms
sortkey() truncates result sets from wide columns
Restrictions on login trigger
Dynamic configuration in Adaptive Server and PerfMon
Dynamic and host variables not allowed in DDL statements
Product compatibilities
Documentation updates and clarifications
Full Text Search Specialty Data Store User's Guide
Hardware and software requirements
Upgrading from Adaptive Server version 12.0
New functionality in this version
Known problems
Product compatibility
Performance and Tuning Guide
Performance issues with using larger logical pages
Bulk copy utility
Union and view operators
Prefetch size and replacement strategy
Quick Reference Guide
Range of values for smallint and int
Reference Manual Volume 1: Building Blocks
Range of values for smallint
Size of expressions and global variables
data_pgs command includes dbid parameter
Varchars, cursors, and trailing spaces
Reference Manual Volume 2: Commands
Minimum size that alter database extends a database
prefetch_size values
Using alter table in if...else command
Cursor scope description in declare cursor command incomplete
Use of readpast may cause duplicates
revoke command with cascade option
Comments in select and select into regarding nullability are inaccurate
truncate table command
Reference Manual Volume 3: Procedures
sp_audit and SSL
sp_audit incorrectly states that cmdtext works for roles
sp_estspace
Additional parameter for sp_unbindrule
sp_modifystats
Obtaining status information for commands invoked by xp_cmdshell
Reference Manual Volume 4: Tables
Datatype information for columns
Tracking create dates for columns
System Administration Guide
Configuration parameters for user-defined login security
dbcc checkstorage
Data structures used for storing text and image data
Heap memory
Unicode sort orders
sp_help and sp_depend display access rule information
Setting limits for tempdb space usage
Unicode sort orders
Transact-SQL User’s Guide
System test can fail if too many aggregates in compute clause
DDL commands allowed in transactions
Utility Guide
bcp out and partitioned tables
Using bcp to transfer data to and from Adaptive Server
bcp and row-level access rules
What’s New in Sybase Adaptive Server Enterprise?
Changed Transact-SQL commands
Changed system procedures
Changed status in existing columns
Technical support
Other sources of information
Sybase certifications on the Web
Installation Guide for ASE 12.5 on Digital UNIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
No such device; operation not supported
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for HP-UX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for IBM AIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Linux
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-Client product descriptions
Sybase installation directory
Installation Requirements
System requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
bccdb database
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation Definitions
Pre-installation tasks
Installing the Linux dummy-network interface
Installing server components
Installing using Red Hat Package Manager (RPM)
Registering Adaptive Server features
Configuring the servers
Installing the documentation
Online documentation
Installing the documentation
Removing Sybase servers
Post-Installation Tasks
Setting environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-Client products
Installing a Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Starting servers when the operating system restarts
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Upgrading Sybase Servers
Overview
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Preparing database and devices
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Restoring replication after upgrade
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verifying that servers are running
Restore functionality in Adaptive Server
Reenabling replication server
Removing old log records
Reenabling replication
Reenabling auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to boot
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after the installer creates files
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Editing a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Troubleshooting resource file installations
Creating Raw Partitions
Overview
Creating the partitions
Binding the partitions for raw disk I/O
Accessing raw devices from Adaptive Sever
Installation Guide for Silicon Graphics IRIX
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Compatibility with other licensed products
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Sun Solaris
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
dsync option on by default for database device files
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Starting SySAM as an automatic service
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Configuring EJB Server
Viewing the installation status output screen
Post-Installation Tasks
Environment variables
Setting environment variables
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuring XP Server after initial installation
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Starting servers
Using the Runserver file
Using the startserver command
Using the monserver command
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Setting server start-up parameters
Starting servers when the operating system restarts
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Check RUN_server file location
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase Servers
Removing an existing Adaptive Server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Unable to use X-Windows
Fatal Error: Cannot Map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server failed to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Installation Guide for Windows
About this book
Overview
User roles
Product descriptions
Installation and setup utilities
PC-client product descriptions
Sybase installation directory
Installation Requirements
System requirements
Product disk space requirements
Language module sizes
Adaptive Server specifications
Adaptive Server devices and system databases
master device
sybsystemdb device and database
sysprocsdev device
Optional devices and databases
sybsecurity device and database
Sample databases
sybsyntax database
dbccdb database
Determining the location, type, and size of a database device
Sybase Software Asset Management (SySAM)
SySAM overview
Adaptive Server features licensed through SySAM
How SySAM works
Adaptive Server check-out procedure
Starting Adaptive Server with optional features
Types of SySAM systems
SySAM in the network environment
Redundant servers
SySAM administration
Verify the software is running
Starting the software manually
Starting SySAM as an automatic service
Adding feature licenses
Installing Sybase Servers
Overview
Installation definitions
Pre-installation tasks
Installing server components
Installation methods
Installing components with Studio Installer
Configuring the servers
Post-Installation Tasks
Environment variables
Setting environment variables
Reset variables temporarily
Reset variables permanently
Setting EJB server environment
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
jConnect 4.5, 5.5, and Java utilities
Using open database connectivity
Installing stored procedures
Installing character sets
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Installing Sybase PC-Client Products
Overview
Installing PC-client products
Installing the Java Runtime Environment
Installing the Java Development Kit
Installing InfoMaker
Installing PowerDynamo
Configuring network connections for client products
Adding a server entry to the libtcl.cfg file
Adding a server to the sql.ini file
Enabling TCP connections
Testing the Sybase Central installation
Starting and Stopping Servers
Overview
Requirements for starting servers
Checking the server status
Starting servers
Starting and stopping servers using the Control Panel
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Setting server start-up parameters
Server start-up parameters
Changing start-up parameters
Starting servers as an automatic service
Upgrading Sybase Servers
Overview of the upgrade process
System catalog changes during upgrade
Catalog changes that might affect existing applications
Pre-upgrade tasks
Check system and upgrade requirements
Note server and device names and locations
Test current applications and stored procedures
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Verify that users are logged off
Check database integrity
Back up databases
Dump transaction logs
Prepare the database and devices for the upgrade
Create a sybsystemdb database
sybsystemprocs
Turn off database options
Disable auditing
Disable disk mirroring
Preparing to upgrade servers with replicated databases
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD Transaction Log
Disabling the secondary truncation point
Upgrading to Adaptive Server 12.5
Upgrading the server
Testing the Adaptive Server upgrade
Post-upgrade tasks
Verify that servers are running
Restore functionality in Adaptive Server
Reenable Replication Server
Remove old log records
Reenable replication
Restoring replication after upgrade
Reenable auditing
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Recovering from a failed upgrade
Removing Sybase Servers
Uninstalling Sybase products
Uninstalling Adaptive Server 12.5
To remove an old server
Troubleshooting
Overview
Error log locations
For installation utilities
For Sybase servers
Solutions to common installation problems
Adaptive Server failed to start
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Rerunning the upgrade
Recording the upgrade manually
If the cause of the failure is known
If the cause of the failure is unknown
Troubleshooting SySAM
Authorization code input error
Alternative Installation Methods
Resource file installation
Installing from a resource file
Editing a sample resource file
Resource file variables
Running the sybatch utility
Installing files in NOGUI mode
Completing the installation process
Installing components in cmdfile
Configuration Guide for UNIX
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication
Lightweight Directory Access Protocol
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Using a runserver file
Using the startserver command
Using the monserver command
Starting servers when the operating system restarts
For Compaq Tru64
For HP-UX
For IBM RS/6000
For SGI
For Sun Solaris
For Macintosh OS X
The boot sequence
BootROM
BootX
Kernel initialization
System initialization
The rc.boot and rc scripts
Start-up items
Sybase-provided StartupItems
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Configuring the Operating System
Setting environment variables
DSLISTEN
DSQUERY
PATH
Using the stty setting
Restoring correct permissions
File descriptors and user connections
For Compaq Tru64
For HP-UX
For Sun Solaris and SGI
For Macintosh OS X
Displaying current soft and hard limits
Increasing the soft limit
Increasing the hard limit
Sample program
Adjusting the client connection timeout period
For Compaq Tru64
For HP-UX
For IBM RS/6000
For Sun Solaris
For Macintosh OS X
Checking for hardware errors
For Compaq Tru64
For HP-UX
For IBM RS/6000
For SGI
For Sun Solaris
For Macintosh OS X
Monitoring the use of operating system resources
For Compaq Tru64
For HP-UX
For IBM RS/6000
For Sun Solaris
For SGI
For Macintosh OS X
A sample C shell maintenance script
Adaptive Server Default Configuration
Default settings
Setting Up Communications Across the Network
How clients connect to Adaptive Server
Creating an interfaces file
Contents of an interfaces file
How Adaptive Server listens for client connections
How a client uses an interfaces file
Heterogeneous and homogeneous environments
Understanding the format of the interfaces file
Components of an interfaces file entry
Format by platform
Creating interfaces files for SPX
Utilities for editing the interfaces file
Creating a master interfaces file
Using dsedit or dscp to create a master interfaces file
Using a text editor to create a master interfaces file
Configuring interfaces files for multiple networks
Configuring the server for multiple network handlers
Sample interfaces files for multiple network handlers
Configuring the client connections
Using one network-independent DSQUERY name
Using different DSQUERY names
Configuring for query port backup
Troubleshooting
Server fails to start
Error when executing an ESP
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg and libtcl64.cfg files
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the interfaces file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default language and character set
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
Setting error log paths
Setting the Adaptive Server error log path
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
Setting the maximum capacity for a tape drive
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Using disk drives
Monitoring disk usage
Adding Optional Functionality to Adaptive Server
Adding auditing
Audit system devices and databases
Overview of audit installation
Pre-installation tasks for auditing devices
Installing auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuration Guide for Windows NT
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication (the interfaces file)
Lightweight Directory Access Protocol
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Starting and stopping servers using Sybase Central
Starting and stopping servers using the Control Panel
Starting servers as an automatic service
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Monitoring servers
Sybase Central
The Control Panel
Default Adaptive Server Configuration
Starting Server Config for Adaptive Server
Configuring Adaptive Server
Setting Adaptive Server parameters
Changing the default Backup Server
Changing the default XP Server
Configuring Backup Server
Configuring Monitor Server
Supporting access to large memory
Network Communications Using sql.ini
How clients connect to Adaptive Server
How Adaptive Server listens for client connections
How a client accesses Adaptive Server
Enabling client access to a server
Changing the server entries in sql.ini
Components in the sql.ini file
Server name
Network driver
Service type
Server address
Address format
IP address
Named Pipes format
Windows Sockets format
NWLink IPX/SPX format
Sharing network configuration information
Creating a master sql.ini file
Using NT Registry as a directory service
Verifying server connections
Configuring ODBC connections
Configuring the ODBC driver
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg and libtcl64.cfg files
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the sql.ini file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default character set for servers
Default character set after installation
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Logging errors and events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
NT event-logging
Setting up NT event-logging for use by Adaptive Server
Types of information logged
Managing the logs
Setting error log paths
Setting the Adaptive Server error log path
Setting the Backup Server error log path
Setting the Monitor Server error log path
Enabling and disabling NT event logging
Using Server Config
Using sp_configure
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Logging user-defined events
Using a remote log
Using a central logging site
Logging messages from multiple Adaptive Servers
Setting up a local central logging site
To create and define a Registry key
Viewing the messages
In the NT event log
In the Adaptive Server error log
Using Security Services with NT LAN Manager
Security services with NT LAN Manager
How login authentication works
Administering security services using LAN Manager
Modifying configuration files for a unified login
Setting up drivers for network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
Checking the LAN Manager’s local name
Specifying security information for Adaptive Server
Identifying users and servers to LAN Manager
Configuring Adaptive Server for LAN Manager security
Enabling and disabling external security services
Managing unified login
Requiring unified login
Establishing a secure default login
Mapping LAN Manager login names to server names
Requiring data integrity check
Ensuring adequate memory for security services
Initiating the new security services
Adding logins to support unified login
General procedure for adding logins
Defining the connection to a server for security services
Specifying the principal name
Specifying network-based user authentication
Specifying the name assigned to LAN Manager
Determining the status of security services
Configuration parameters used in security services
Checking data integrity
Checking message sequence
Detecting interception or replay
Specifying a login
Controlling user authentication
Managing login security on an NT computer
Overview of security features
Adaptive Server security
Combined Adaptive Server and NT login security
Standard mode
Integrated mode
Mixed mode
Managing the login security features
Permitting trusted connections
NT Registry parameters
Administering login security using system procedures
Assigning trusted connection permissions
Displaying the current Registry values
Displaying permissions and user names
Revoking permissions granted with sp_grantlogin
Configuring login security
Create NT users and groups
Configure mapping and Default Domain values
Set login security mode
Add network login names to syslogins
Assign roles
Changing login security options
Using E-mail with Adaptive Server
Sybmail messages
Sending messages
Receiving messages
Preparing NT Mail for Sybmail
Connecting to a post office
Creating a mailbox for Adaptive Server
Creating a mail profile for Adaptive Server
Creating an Adaptive Server login for Sybmail
Sybmail and extended stored procedures
Managing a mail session
Starting a session
Starting Sybmail without parameters
Stopping a mail session
Stored and extended procedures for handling messages
Sending messages
Text messages
Query result messages
Receiving messages
Finding the next message
Reading a specific message
Deleting a message
Processing incoming mail
Using Sybmail security
Setting execution privileges
Setting the execution context
Naming both the user and the database
Naming the user but not the database
Naming the database but not the user
Naming neither the user nor the database
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
NT tape drive names
Setting the maximum capacity for a tape drive
Using a hard disk
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Optimizing Adaptive Server performance and tuning
Using dedicated Adaptive Server operation
Using disk drives
Monitoring disk usage
Monitoring Adaptive Server statistics with NT Performance Monitor
Adding Optional Functionality to Adaptive Server
Installing auditing
Audit system devices and databases
The sybsecurity device and database
Tables and devices for the audit trail
Device for syslogs systems table
Pre-installation tasks for auditing devices
Installing Auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Troubleshooting Network Connections
The dsedit Server Ping Utility
Running Server Ping
Troubleshooting connection failures
When a test fails
Using returned messages to diagnose a failure
Failure to connect to Adaptive Server
Failure to load Net-Library DLLs
Failure of other applications
Before calling Sybase Technical Support
Adaptive Server Registry Keys
ASE Replicator User's Guide
About this book
Introduction to ASE Replicator
Understanding replication
Table replication
Stored procedure replication
Transaction replication
Guaranteed delivery
Understanding ASE Replicator
ASE Replicator components
ASE Replicator process
Distribution Database
Publisher component
Distributor component
ASE Replicator processing
ASE Replicator objects
Database connections
Publications and subscriptions
Articles
Fields
ASE Replicator limitations
Setting Up and Starting ASE Replicator
Setting up ASE Replicator
Configuring the primary Adaptive Server
Enabling and configuring CIS
Setting up the ASE Replicator system user
Defining a local name and remote alias for the primary Adaptive Server
Defining a remote server name for the ASE Replicator process
Configuring the tempdb database
Creating the Distribution Database
Configuring the replicate servers and databases
Identifying the remote server
Setting up a separate a Maintenance User login
Granting permissions in the replicate database
Initializing the ASE Replicator process
Running the aserep script the first time
Setting up the sp_helpddb system procedure
Starting ASE Replicator
Using the aserep script
Using the RUN script
Setting up a replication system
Administering ASE Replicator
Administering the ASE Replicator process
Configuring ASE Replicator
Shutting down the ASE Replicator process
Suspending replication
Resuming replication
Monitoring ASE Replicator
Managing database connections
Creating a database connection
Creating a primary database connection
Creating a replicate database connection
Deleting a database connection
Deleting a primary database connection
Deleting a replicate database connection
Configuring a database connection
Configuring a primary database connection
Configuring a replicate database connection
Suspending and resuming database connections
Suspending database connections
Resuming database connections
Getting information about database connections
Getting connection metadata and status information
Getting statistics information for connections
Getting connection configuration information
Getting primary connection configuration information
Getting replicate connection configuration information
Managing publications and subscriptions
Creating publications and subscriptions
Deleting publications and subscriptions
Suspending and resuming subscriptions
Getting information about publications and subscriptions
Getting metadata and status information for publications and subscriptions
Getting statistics information for subscriptions
Managing primary and replicate articles
Creating primary articles
Creating replicate articles
Deleting primary articles
Deleting replicate articles
Materializing and validating replicate articles
Getting information about primary articles
Getting primary article metadata information
Getting information about published fields in primary articles
Getting information about primary articles in publications
Getting information about unpublished objects
Getting information about primary articles with no subscribers
Getting information about replicate articles
Getting replicate article metadata information
Getting information about fields in replicate articles
Getting information about replicate articles in subscriptions
ASE Replicator configuration parameters
General configuration parameters
admin_port
ase_charset
ase_host
ase_port
batch_size
batch_timeout
ddb_name
log_directory
log_trace_verbose
log_wrap
monitor_delay
queue_size
scan_sleep_increment
scan_sleep_max
stat_trunc_interval
stat_write_timeout
status_monitoring
truncate_numops
Connection configuration parameters
gen_id
lti_version
mode
numrecs
queue_size
scan_sleep_increment
scan_sleep_max
timeout
ASE Replicator Procedures
sp_addprimaryart
sp_addprimaryconn
sp_addpub
sp_addreplicateart
sp_addreplicateconn
sp_addsub
sp_configprimaryconn
sp_configrep
sp_configreplicateconn
sp_dropprimaryart
sp_dropprimaryconn
sp_droppub
sp_dropreplicateart
sp_dropreplicateconn
sp_dropsub
sp_helpconn
sp_helplastcommit
sp_helplocator
sp_helpprimaryart
sp_helpprimaryconn
sp_helppub
sp_helprep
sp_helpreplicateart
sp_helpreplicateconn
sp_helpsub
sp_materializesub
sp_resumeprimaryconn
sp_resumerep
sp_resumereplicateconn
sp_resumesub
sp_shutdownrep
sp_suspendprimaryconn
sp_suspendrep
sp_suspendreplicateconn
sp_suspendsub
sp_tracerep
sp_validatesub
Troubleshooting ASE Replicator
Problems that prevent replication from starting
Primary server configuration problems
Remote server configuration problems
ASE Replicator configuration problems
User login or permission problems
Problems that cause ongoing replication to fail
Schema changes in primary or replicate tables
Altering a published primary object
Altering a replicate object
Datatypes, constraints, and column properties
Replicating approximate numeric datatypes
Replicating the value of the timestamp datatype
Replicating IDENTITY columns
Incompatible datatypes
Incompatible primary key constraints
Different null types
Distribution Database Schema
Distribution Database base objects
Distribution Database datatypes
Base tables in the Distribution Database
Distribution Database system table
Connections table
Connection properties table
Publications table
Primary articles table
Primary article fields table
Primary articles/publications relation table
Subscriptions table
Replicate articles table
Replicate article fields table
Transaction log table
Configuration table
Trace table
Statistics table
Base procedures in the Distribution Database
Distribution Database shadow tables
Shadow tables for primary tables without large objects
Shadow tables for primary tables with large objects
Shadow tables for primary procedures
Distribution Database replicate objects
Distribution procedures
Replicate article proxy tables
Glossary
Component Integration Services User's Guide
About this book
Audience
How to use this book
Adaptive Server Enterprise documents
Other sources of information
Conventions
If you need help
Introduction
New features in Adaptive Server Enterprise 12.5
Who can use Component Integration Services
Steps needed to use Component Integration Services
Understanding Component Integration Services
Basic concepts
Access methods
Server classes
Object types
Interface to remote servers
Defining the storage location of individual objects
Creating proxy tables
Proxy tables
Using the create table command
Using the create existing table command
Datatype Conversions
Example of Remote Table Definition
Using the create proxy_table command
Remote Procedures as proxy tables
New server limits
Remote server capabilities
create new proxy table
create existing proxy table
create proxy_table
alter proxy table
select, insert, delete, update
RPC handling
Cascading proxy tables
Proxy databases
User proxy databases
User Proxy Database Schema Synchronization
System proxy databases
System proxy database creation
Schema synchronization when current database has a system proxy database
Stored procedure execution within a system proxy database
Additional behavior of the system proxy database
DDL commands behavior affected by proxy databases
File system access
Directory access
Recursion through subordinate directories
File access
Security considerations
ANSI joins
When the remote server supports only ANSI joins
When the remote server supports both ANSI joins and T-SQL joins
When the remote server supports only DB2-ANSI
When an ANSI query is received for a server that does not support ANSI syntax
50-Table join limit
Union in views
Referential integrity
Remote servers
Defining remote servers
Server class ASEnterprise
Server class ASAnywhere
Server class ASIQ
Server class sql_server
Server class db2
Server class direct_connect
Server class sds
Connection management
LDAP directory services
Secure communication with SSL
Trusted root files
Security issues
Remote server logins
Trusted mode
Mapping of external logins
Remote server connection failover
Remote server capabilities
Query processing
Processing steps
Query parsing
Query normalization
Query preprocessing
Decision point
Component Integration Services plan generation
Adaptive Server optimization and plan generation
Component Integration Services remote location optimizer
Query execution
Distributed query optimization
Component Integration Services access methods
Query plan execution
create table command
create existing table command
alter table command
create index command
drop table command
drop index command
truncate table command
Passthrough mode
The connect to command
sp_autoconnect
sp_passthru
sp_remotesql
Quoted identifier support
auto identity option
Triggers
RPC handling and Component Integration Services
Site handler and outbound RPCs
Component Integration Services and outbound RPCs
Text parameters for RPCs
Text parameter support for XJS/390
Transaction management
Two-phase commit
Server classes and ASTC
Strict DTM enforcement
Enable xact coordination
Enable CIS
CIS set commands
Attach and detach
Pre-12.x servers
Transactional RPCs
Restrictions on transaction management
Using update statistics
Finding index names
Java in the database
@@textsize
@@stringsize
Constraints on Java class columns
Error messages
SQLJ in Adaptive Server Enterprise
Changes to CIS
Java Abstract Datatypes (ADTs)
Datatypes
Unicode support
create table
create existing table
create proxy_table
alter table
select, insert, update and delete statements
Datatype conversions
text and image datatypes
Restrictions on text and image columns
Limits of @@textsize
Odd bytes padded
Converting text and image datatypes
Pattern matching with text data
Entering text and image values
readtext using bytes
text and image with bulk copy
Error logging
text and image data with server class sql_server
text and image data with server class direct_connect (access_server)
db2 server issues
Fine-grained access control
The select into command
select into syntax
Execute immediate
Configuration and tuning
Using sp_configure
sysconfigures table
Changing the configuration parameters
Component Integration Services configuration parameters
Dynamic reconfiguration
Global variables for status
SQL reference
dbcc commands
dbcc options
Trace flags
Transact-SQL commands
alter database
alter table
begin transaction
case
close
commit transaction
connect to...disconnect
create database
create existing table
create index
create proxy_table
create table
create trigger
deallocate cursor
declare cursor
delete
drop database
drop index
drop table
execute
fetch
Functions
insert
open
prepare transaction
readtext
rollback transaction
select
set
setuser
truncate table
update
update statistics
writetext
Tutorial
Getting Started with Component Integration Services
Adding a Remote Server
Overview of the Procedure
Step 1: Add the Remote Server to the Interfaces File
Step 2: Create Server Entries in System Tables
Step 3: Add an Alternate Login and Password
Verifying Connectivity
Mapping Remote Objects to Local Proxy Tables
Overview of the Procedure
Step 1: Define the Storage Location of a Remote Object
Step 2: Map Remote Table Schema to Adaptive Server
Join Between Two Remote Tables
Overview of the Procedure
Step 1: Add the Remote Servers to the Interfaces File
Step 2: Define the Remote Servers
Step 4: Map the Remote Tables to Adaptive Server
Step 5: Perform the Join
Troubleshooting
Problems Accessing Component Integration Services
Problems Using Component Integration Services
Unable to Access Remote Server
Requested Server Name Not Found
Driver Call to Connect Two Endpoints Failed
Login Failed
Unable to Access Remote Object
Problem Retrieving Data From Remote Objects
Object Is Altered Outside Component Integration Services
Index Is Added or Dropped Outside CIS
If You Need Help
Full-Text Search Specialty Data Store User's Guide
About this book
Audience
How to Use This Book
Adaptive Server Enterprise Documents
Other Sources of Information
Conventions
Directory Paths
Formatting SQL Statements
SQL Syntax Conventions
Case
Obligatory Options {You Must Choose At Least One}
Optional Options [You Don’t Have to Choose Any]
Ellipsis: Do It Again (and Again)...
If You Need Help
Introduction
What Is the Full-Text Search Specialty Data Store?
Capabilities of the Full-Text Search Engine
High Availablility
Understanding the Full-Text Search Engine
Components of the Full-Text Search Engine
The Source Table
The Verity Collections
Filters
The text_db Database
The vesaux Table
The vesauxcol Table
The Index Table
The text_events Table
Relationships Between the Components
How a Full-Text Search Works
Configuring Adaptive Server for Full-Text Searches
Configuring Adaptive Server for a Full-Text Search Engine
Enabling Configuration Parameters
Running the installtextserver Script
Editing the installtextserver Script
Running the installtextserver Script
Running the installmessages Script
Running the installevent Script
Editing the installevent Script
Running the installevent Script
Name the local server
Creating and Maintaining the Text Indexes
Setting Up Source Tables for Indexing
Adding an IDENTITY Column to a Source Table
Adding a Unique Index to an IDENTITY Column
Creating the Text Index and Index Table
Specifying Multiple Columns When Creating a Text Index
Bringing the Database Online for Full-Text Searches
Propagating Changes to the Text Index
Replicating Text Indexes
Example: Enabling a New Database for Text Searches
Step 1. Verify that the text_events Table Exists
Step 2. Check for an IDENTITY Column
Step 3. Create a Unique Index on the IDENTITY Column
Step 4. Create the Text Index and Index Table
Step 5. Bring the Database Online for a Full-Text Search
Setting Up Verity Functions
Enabling Query-By-Example, Summarization, and Clustering
Editing the Master style.prm File
Editing Individual style.prm Files
Setting Up a Column to Use As a Sort Specification
Using Filters on Text That Contains Tags
Creating a Custom Thesaurus (Enhanced Version Only)
Examining the Default Thesaurus (Optional)
Creating the Control File
Control File Syntax
Creating the Thesaurus
Replacing the Default Thesaurus with the Custom Thesaurus
Creating Topics (Enhanced Version Only)
Creating an Outline File
Creating a Topic Set Directory
Creating a Knowledge Base Map
Defining the Location of the Knowledge Base Map
Executing Queries Against Defined Topics
Troubleshooting Topics
Writing Full-Text Search Queries
Components of a Full-Text Search Query
Default Behaviour
Pseudo Columns in the Index Table
Using the score Column to Relevance-Rank Search Results
Using the sort_by Column to Specify a Sort Order
Using the summary Column to Summarize Documents
Using Pseudo Columns to Request Clustered Result Sets
Preparing to Use Clustering
Writing Queries Requesting a Clustered Result Set
Full-Text Search Operators
Considerations When Using Verity Operators
Using the Verity Operators
accrue
and, or
complement
in
like
near, near/n
or
phrase
paragraph
product
sentence
stem
sum
thesaurus
topic (Enhanced Version Only)
wildcard
word
yesno
Operator Modifiers
System Administration
Starting the Full-Text Search Engine on UNIX
Creating the Runserver File
Starting the Full-Text Search Engine on Windows NT
Starting the Full-Text Search Engine As a Service
Shutting Down the Full-Text Search Engine
Modifying the Configuration Parameters
Modifying Values in the Enhanced Version
Available Configuration Parameters
Setting the Default Language
.Setting the Default Character Set
Setting the Default Sort Order
Setting Trace Flags
Setting Open Server Trace Flags
Setting Case Sensitivity
Backup and Recovery for the Enhanced Full-Text Search Engine
Customizable Backup and Restore
Backing Up Verity Collections
Restoring Collections and Text Indexes from Backup
Performance and Tuning
Updating Existing Indexes
Increasing Query Performance
Limiting the Number of Rows
Ensuring the Correct Join Order for Queries
Reconfiguring Adaptive Server
cis cursor rows
cis packet size
Reconfiguring the Full-Text Search Engine
batch_size
min_sessions and max_sessions
Using sp_text_notify
Configuring Multiple Full-Text Search Engines
Creating Multiple Full-Text Search Engines at Start-Up
Adding Full-Text Search Engines
Configuring Additional Full-Text Search Engines
Multiple Users
Verity Topics
What are Topics?
Topic Organization
Weight Assignments
Using a Topic Outline File
Making Topics Available
Setup Process
Knowledge Bases of Topics
Combining Topics into a Knowledge Base
Structure of Topics
Top-Level Topics
Subtopics
Evidence Topics
Topic and Subtopic Relationships
Maximum Number of Topics
Topic Naming Issues
Topic Name Length
Case Sensitivity
Verity Query Language
Query Language Summary
Evidence Operators
Proximity Operators
Relational Operators
Concept Operators
Boolean Operators
Modifiers
Operator Precedence Rules
Sample Topic Outlines
Operator Reference
ACCRUE Operator
ALL Operator
AND Operator
ANY Operator
CONTAINS Operator
ENDS Operator
= (EQUALS) Operator
FILTER Operator
> (GREATER THAN) Operator
>= (GREATER THAN OR EQUAL TO) Operator
< (LESS THAN) Operator
<= (LESS THAN OR EQUAL TO) Operator
IN Operator
MATCHES Operator
NEAR Operator
NEAR/N Operator
OR Operator
PARAGRAPH Operator
PHRASE Operator
SENTENCE Operator
SOUNDEX Operator
STARTS Operator
STEM Operator
SUBSTRING Operator
THESAURUS Operator
WILDCARD Operator
Using Wildcard Special Characters
Searching for Non-alphanumeric Characters
Searching for Wildcard Characters as Literals
Searching for Special Characters as Literals
WORD Operator
Modifier Reference
CASE Modifier
MANY Modifier
NOT Modifier
ORDER Modifier
Weights and Document Importance
Topic Weights
Which Operators Accept Weights
How Weights Affect Importance
Assigning Weights
Automatic Weight Assignments
Tips for Assigning Weights
Changing Weights
Topic Scoring and Document Importance
Designing Topics
Preparing Your Topic Design
Understanding Your Information Needs
Understanding Your Documents
Using Scanned Data
Categorizing Document Samples
Topic Design Strategies
Top-Down Design
Bottom-Up Design
Designing the Initial Topic
Outlining a Topic
Top-Down Topic Outline Example
Step One: Establishing an Information Hierarchy
Step Two: Establishing Individual Search Categories
Step Three: Establishing the Topics to be Built
Bottom-Up Topic Outline Example
Step One: Identifying Low-level Topics
Step Two: Categorizing Related Subtopics
Step Three: Establishing Top-Level Topics
System Procedures
sp_check_text_index
sp_clean_text_events
sp_clean_text_indexes
sp_create_text_index
sp_drop_text_index
sp_help_text_index
sp_optimize_text_index
sp_redo_text_events
sp_refresh_text_index
sp_show_text_online
sp_text_cluster
sp_text_configure
sp_text_dump_database
sp_text_kill
sp_text_load_index
sp_text_notify
sp_text_online
Sample Files
Default textsvr.cfg Configuration File
The sample_text_main.sql Script
Sample Files Illustrating Full-Text Search Engine Features
Custom Thesaurus
Topics
Clustering, Summarization, and Query-by-Example
getsend Sample Program
Unicode Support
Glossary
Glossary
Java in Adaptive Server Enterprise
About this book
An Introduction to Java in the Database
Advantages of Java in the database
Capabilities of Java in the database
Invoking Java methods in the database
Invoking Java methods directly in SQL
Invoking Java methods as SQLJ stored procedures and functions
Storing Java classes as datatypes
Storing and querying XML in the database
Standards
Java in the database: questions and answers
What are the key features?
How can I store Java instructions in the database?
How is Java executed in the database?
Client- and server-side JDBC
How can I use Java and SQL together?
What is the Java API?
How can I access the Java API from SQL?
Which Java classes are supported in the Java API?
Can I install my own Java classes?
Can I access data using Java?
Can I use the same classes on client and server?
How do I use Java classes in SQL?
Where can I find information about Java in the database?
What you cannot do with Java in the database
Sample Java classes
Preparing for and Maintaining Java in the Database
The Java runtime environment
Java classes in the database
Sybase runtime Java classes
User-defined Java classes
JDBC drivers
The Java VM
Configuring memory for Java in the database
Enabling the server for Java
Disabling the server for Java
Creating Java classes and JARs
Writing the Java code
Compiling Java code
Saving classes in a JAR file
Installing uncompressed JARs
Installing compressed JARs
Installing Java classes in the database
Using installjava
Retaining the JAR file
Updating installed classes
Referencing other Java-SQL classes
Viewing information about installed classes and JARs
Downloading installed classes and JARs
Removing classes and JARs
Retaining classes
Using Java Classes in SQL
General concepts
Java considerations
Java-SQL names
Using Java classes as datatypes
Creating and altering tables with Java-SQL columns
Altering partitioned tables
Selecting, inserting, updating, and deleting Java objects
Invoking Java methods in SQL
Sample methods
Exceptions in Java-SQL methods
Representing Java instances
Assignment properties of Java-SQL data items
Datatype mapping between Java and SQL fields
Character sets for data and identifiers
Subtypes in Java-SQL data
Widening conversions
Narrowing conversions
Runtime versus compile-time datatypes
The treatment of nulls in Java-SQL data
References to fields and methods of null instances
Null values as arguments to Java-SQL methods
Null values when using the SQL convert function
Java-SQL string data
Zero-length strings
Type and void methods
Java void instance methods
Java void static methods
Equality and ordering operations
Evaluation order and Java method calls
Columns
Variables and parameters
Static variables in Java-SQL classes
Java classes in multiple databases
Scope
Cross-database references
Inter-class transfers
Passing inter-class arguments
Temporary and work databases
Java classes
Data Access Using JDBC
Overview
JDBC concepts and terminology
Differences between client- and server-side JDBC
Permissions
Using JDBC to access data
Overview of the JDBCExamples class
The main( ) and serverMain( ) methods
Using main( )
Using serverMain( )
Obtaining a JDBC connection: the Connecter( ) method
Routing the action to other methods: the doAction( ) method
Executing imperative SQL operations: the doSQL( ) method
Executing an update statement: the UpdateAction( ) method
Executing a select statement: the selectAction( ) method
Calling a SQL stored procedure: the callAction( ) method
Error handling in the native JDBC driver
The JDBCExamples class
The main( ) method
The internalMain( ) method
The connecter( ) method
The doAction( ) method
The doSQL( ) method
The updateAction( ) method
The selectAction( ) method
The callAction( ) method
SQLJ Functions and Stored Procedures
Overview
Compliance with SQLJ Part 1 specifications
General issues
Security and permissions
SQLJExamples
Invoking Java methods in Adaptive Server
Using Sybase Central to manage SQLJ functions and procedures
SQLJ user-defined functions
Handling null argument values
Handling nulls when creating the function
Handling nulls in the function call
Deleting a SQLJ function name
SQLJ stored procedures
Modifying SQL data
Using input and output parameters
Returning result sets
Deleting a SQLJ stored procedure name
Viewing information about SQLJ functions and procedures
Advanced topics
Mapping Java and SQL datatypes
Using the command main method
SQLJ and Sybase implementation: a comparison
SQLJExamples class
Introduction to XML in the Database
Introduction
Source code and javadoc
References
An overview of XML
A sample XML document
HTML display of Order data
XML document types
XSL: formatting XML information
Character sets and XML data
XML parsers
Selecting Data with XQL
Accessing the XML parser
Setting the CLASSPATH environment variable
Installing XQL in Adaptive Server
Converting a raw XML document to a parsed version
Inserting XML documents
Updating XML documents
Deleting XML documents
Memory requirements for running the query engine inside Adaptive Server
Using XQL
Query structures that affect performance
Examples
Other usages of the XQL package
com.sybase.xml.xql.XqlDriver syntax
Sample queries
Validating your document
Using XQL to develop standalone applications
Example standalone application
Example JDBC client
Example EJB example
XQL methods
Methods in com.sybase.xml.xql.Xql
parse(String xmlDoc)
parse(InputStream xml_document, boolean validate)
query(String query, String xmlDoc)
query(String query, InputStream xmlDoc)
query(String query, SybXmlStream xmlDoc)
query(String query, JXml jxml)
sybase.aseutils.SybXmlStream
com.sybase.xml.xql.store.SybMemXmlStream
com.sybase.xml.xql.store.SybFileXmlStream
setParser(String parserName)
reSetParser
Specialized XML Processing
The OrderXml class for order documents
OrderXml(String) constructor
OrderXml(date, customerid, server)
void order2Sql(String ordersTableName, String server)
static void createOrderTable (String ordersTableName, String server)
void setOrderElement (String elementName, String newValue)
String getItemElement (int itemNumber, String elementName)
void setItemElement (int itemNumber, String elementName, String newValue
String getItemAttribute (int itemNumber, elementName, attributeName)
void setItemAttribute (int itemNumber, elementName, attributeName, newValue)
void appendItem (newItemid, newItemName, newQuantity, newUnit)
void deleteItem(int itemNumber)
Storing XML documents
Mapping and storage
Advantages and disadvantages of storage options
Client or server considerations
Creating and populating SQL tables for order data
Tables for element storage
Tables for document and hybrid storage
Using the element storage technique
Composing order documents from SQL data
Generating an order on the client
Generating an order on the server
Translating data from an XML order into SQL
Translating the XML document on the client
Translating the XML document on the server
Using the document storage technique
Storing XML order documents in SQL columns
Inserting an order document from a client file
Inserting a generated order document on the server
Accessing the elements of stored XML order documents
Client access to order elements
Server access to order elements
Appending and deleting items in the XML document
Using the hybrid storage technique
XML for SQL Result Sets
The ResultSetXML class
ResultSetXml(String)
Constructor: ResultSetXml (query, cdataColumns, colNames, server)
ResultXml example
String toSqlScript (resultTableName, columnPrefix, goOption)
String getColumn(int rowNumber, int columnNumber)
String getColumn(int rowNumber, String columnName)
void setColumn (int rowNumber, int columnNumber, newValue)
void setColumn (int rowNumber, String columnName, newValue)
Boolean allString (int ColumnNumber, String compOp, String comparand)
Boolean someString (int columnNumber, String compOp, String comparand)
A customizable example for different result sets
The ResultSet document type
The XML DTD for the ResultSetXml document type
Using the element storage technique
Composing a ResultSet XML document from the SQL data
Generating a ResultSet in the client
Generating a result set in Adaptive Server
Translating the XML ResultSet document in the client
Translating the XML ResultSet Document in Adaptive Server
Using the document storage technique
Storing an XML ResultSet document in a SQL column
Accessing the columns of stored ResultSet documents
A client-side call
A server-side script
Quantified comparisons in stored ResultSet documents
Debugging Java in the Database
Introduction to debugging Java
How the debugger works
Requirements for using the Java debugger
What you can do with the debugger
Using the debugger
Starting the debugger and connecting to the database
Compiling classes for debugging
Attaching to a Java VM
The Source window
The debugger windows
Options
Setting breakpoints
Breaking on a line number
Breaking on a static method
Using counts with breakpoints
Using conditions with breakpoints
Breaking when execution is not interrupted
Disconnecting from the database
A debugging tutorial
Before you begin
Start the Java debugger and connect to the database
Attach to a Java VM
Load source code into the debugger
Step through source code
Examples
Inspecting and modifying variables
Inspecting local variables
Modifying local variables
Inspecting static variables
Network Access Using java.net
Overview
java.net classes
Setting up java.net
Example usage
Using socket classes
Saving text out of Adaptive Server
Using the URL class
Using the MailTo class URL to mail a document
Obtaining an HTTP document
Accessing an external document with XQL
User notes
Where to go for help
Reference Topics
Assignments
Assignment rules at compile-time
Assignment rules at runtime
Allowed conversions
Transferring Java-SQL objects to clients
Supported Java API packages, classes, and methods
Supported Java packages and classes
Unsupported Java packages and classes
Unsupported java.sql methods and interfaces
Invoking SQL from Java
Special considerations
Transact-SQL commands from Java methods
Datatype mapping between Java and SQL
Java-SQL identifiers
Java-SQL class and package names
Java-SQL column declarations
Java-SQL variable declarations
Java-SQL column references
Java-SQL member references
Java-SQL method calls
Glossary
Migrating to Adaptive Server Enterprise 12.5
Introduction and Guide to Resources
In This Chapter
Chapters in the Migration Guide
Relating Documentation to Migration Phase
Other Sources of Information
Sybase Certifications on the Web
Migration Web Page
Classes
Consulting Services
If You Need Help
Analyze: Documenting Business Requirements
In This Chapter
Diagramming the System
Operational Business Requirements
Availability Requirements
Database Change Metrics
Database Dump Details
Maintenance Procedures
Service Level Requirements
Transaction Profile
Current Performance Metrics
Additional Business Requirements
Analyze: Documenting Your Environment
In This Chapter
Hardware Configuration
General Server Hardware
CPU Resources per Machine
Disk Configuration
Network Configuration
Tape Configuration
Physical Memory Utilization
Software Configuration
Operating System
Applications
Sybase Configuration
General Information
Database Devices
Databases and Segments
Dump Devices
Adaptive Server Objects
Gather Scripts to Create Objects
If You Don’t Have Scripts
Query Sybase System Tables
Use System Stored Procedures
Use Sybase Tools
Plan: Writing a Plan and Getting Ready to Migrate
In this Chapter
Review Documentation
Review the Upgrade Process
Special Cases: Migrating to 64-bit Operating System or Larger Page Size
Determine Migration Approach
Parallel With Replication
Cutover Without Replication
Phased Cutover
Write a Migration Plan
Build the Adaptive Server Environment
Update Hardware Resources
Verify Operating System Version and EBF Level
Review Adaptive Server Interoperability with Other Sybase Products
Update Applications and System Administration Procedures
Create Migration Scripts
Implement: Making Required Application Changes
In This Chapter
If Your Version is 11.5
Changes to Locking
Data-only Locking
Changes to Table-Level Locking
Workarounds
Changes to Error Checking
Permissions on Objects in Procedures Checked at Run-time
Stored Procedure Existence Checks in Command Batches
Ordering of Integrity and Permissions Checks
Changes in Error Numbers
11.9.2 Query Processing Changes
New and Changed Statistics
Aggregate Optimization
Costing Large I/O
The optdiag Utility
Trace Flag 302
If Your Version is 11.5 or 11.9.x
ANSI Joins
dsync Function
12.0 Query Processing Changes
Predicate Transformation and Factoring
50 Tables in a Query
Abstract Query Plans
Increased Optimization Time
Like Optimization Enhancements
If Your Version is 11.5, 11.9.x, or 12.0
Changes to Transact-SQL
The enable xact coordination Configuration Parameter
New Reserved Words
Wide Columns and Data Truncation
Change in Truncation Behavior
Using New Wide Data Sizes with Open Client
Wide Columns and Optimizer Statistics
Wide Columns with col_length() and datalength()
Implement: Making Database Administration Changes
In This Chapter
If Your Version is 11.5
New Rollback Records
Optimizer Changes
Updating Statistics After Upgrade
Trace Flag 326
If Your Version is 11.5 or 11.9.x
Documentation Changes
Information Moved to Different Manual
Discontinued Documents
Backup Server
Stripes
Network Connections
File Descriptors
Non-Rewinding Tapes
Starting Backup Server
Dump Format
Suspending Updates to Databases for Copying
New Unix File System Device Support
Changes to dbids
CIS Proxy Databases
ASE Plug-in for Sybase Central
The sybsyntax Utility
If Your Version is 11.5, 11.9.x, or 12.0
Changes to Documentation
System Database Sizes
The sybsystemprocs Database
sybsystemdb
Changes to System Tables
BCP with syslogins
New Database and Table Limits
Maximum Number of Users and Logins
New Table Limits
New Reserved Words
Configuration Parameters
stack size
RPC Problem with “enable xact coordination”
Increased Memory
New Storage for text and image Data
buildmaster Command Obsolete
Test: Ensuring Stability and Performance
In This Chapter
The Goal of Testing
Setting Up the Test Environment
Make Backups
Use Scripts to Create the Test System
Create Your Databases by Loading Backups
If the Test Environment Is Not an Exact Duplicate
Prioritizing Applications to be Tested
Establishing Performance Criteria
Developing Fallback Procedures
Summary of Testing Techniques
Writing Performance Scripts
Write Benchmark Scripts
Drivers
General Error Handling
Deadlock Handling
Result Handling
Time Measurement
Runtime Data Generation
Test Cycle: Summary of Tests
Test Cycle: Testing for Performance
Pre-Upgrade Single-User Tests
Optimizer
I/O
Pre-Upgrade Multi-User Tests
Untimed Benchmarks
Timed Benchmarks
Test System Upgrade
Post-Upgrade Single-User Tests
Post-Upgrade Multi-User Tests
Untimed Benchmarks
Timed Benchmarks
Worksheets for Your Current Environment
Adaptive Server Operational Worksheets
Operational Business Requirements
Backup and Restore Procedures
Database Dump Details
Maintenance Procedure Details
Data Architecture Worksheet
Client Application Components
Production Performance Metrics
Transaction Profile
Adaptive Server Infrastructure Worksheets
Host Configuration
Hardware
Physical Memory Usage
Disk I/O Configuration
Network Configuration
Tape Configuration
Operating System Configuration
Adaptive Server Configuration
Database Devices
Databases and Segments
Dump Devices
Sample Migration Task Lists
Sample Task List Template
General Migration Task List Example
Migration Analysis
Document Current Configuration
Gather Business Requirements
Conduct Compatibility Analysis
Develop Migration Strategy
Migration Preparation
Write Test Plans and Test Scripts
Prepare Applications For Migration
Design and Develop Server Migration Scripts
Design and Develop Database Migration Scripts
Design and Develop Data Migration Scripts
Perform Other Pre-migration Tasks
Implement Migration (Using Install/Load Technique)
Create Target Environment
Perform Server Migration
Perform Database Migration
Perform Data Migration
Complete Server and Data Migration
Perform Application Migration
Implement Migration (Using Upgrade Technique)
Upgrade Adaptive Server
Complete Migration
Perform Application Migration
Migration Quality Assurance
Perform System Tests
Perform Integration Tests
Perform Stress Tests
Perform User Acceptance Tests
Perform Production Data Refresh
Parallel Migration Task List Example
Define Test/Acceptance Criteria—Regression Test Suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Set Up Target Production Environment
Set Up Replication Server
Run Regression Test Suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Upgrade Server B (Shadow)
Run Post-upgrade Regression Test Suites on ASE 12.5 (Server B)
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-End Phase 1 and 2 Regression Test Suite
Other Testing
Run User Acceptance Tests on ASE 12.5 (Server B)
Shift Production Users to Adaptive Server 12.5 (Server B)
Perform Final Steps
Cutover Migration Task List Example
Set Up ASE 12.5 Environment on Development System
Define Test/Acceptance Criteria—Regression Test Suites
Front-end simulation regression test suite
Front-end regression test suite
Define Fallback Procedures on Test System
“Baseline” Older Environment on Test System
Run Regression Test Suites on Older Release Test System
Front-end simulation regression test suite
Front-end Regression Test Suite
Upgrade Test System to Release 12.5
Run Regression Test Suites on Release 12.5 Test System
Back-End Regression Test Suite—Production Loads
Front-End Simulation Regression Test Suite
Front-End Regression Test Suite
Other Testing
Run User/Acceptance Tests on Release 12.5 Test System
Execute Fallback Procedures on Test System
Upgrade Production Server to ASE 12.5
Perform Final Steps
Staged Cutover Task Overview
Tasks
Migration Issue Checklists
Logical Data Architecture
Logical Application Architecture
Logical Technology Architecture
Logical Support Architecture
Migration Strategy Design
Pre-Upgrade Checklist
Pre-Upgrade Checklist
Monitor Client Library Programmer's Guide
About this book
Getting started with Monitor Client Library
Overview
What is Adaptive Server Enterprise Monitor
Adaptive Server Enterprise Monitor components
Adaptive Server Enterprise Monitor architecture
Writing a Basic Monitor Client Library program
Application logic flow
Step 1: define error handling
Step 2: connect to a server
Allocating a connection structure
Setting connection structure properties
Required connection properties
Connecting to a server
Step 3: create a view
Data items
Statistical types
Creating views for a connection
Step 4: create filters
Step 5: set alarms
Step 6: request performance data and process results
Step 7: close and deallocate connections
Closing and deallocating connections
Reopening connections
Playing back recorded data
A sample Monitor Client Library program
Example program
Data Items and Statistical Types
Overview
Result and key data items
Data items and views
Rows with no data versus no rows in views
Server-level status
Combining data items
Result and key combinations
Connection summaries
Current statement and application name data items
Data item definitions
Deciphering the names of data items
SMC_NAME_ACT_STP_DB_ID
SMC_NAME_ACT_STP_DB_NAME
SMC_NAME_ACT_STP_ID
SMC_NAME_ACT_STP_NAME
SMC_NAME_ACT_STP_OWNER_NAME
SMC_NAME_APPLICATION_NAME
SMC_NAME_APP_EXECUTION_CLASS
SMC_NAME_BLOCKING_SPID
SMC_NAME_CONNECT_TIME
SMC_NAME_CPU_BUSY_PCT
SMC_NAME_CPU_PCT
SMC_NAME_CPU_TIME
SMC_NAME_CPU_YIELD
SMC_NAME_CUR_APP_NAME
SMC_NAME_CUR_ENGINE
SMC_NAME_CUR_EXECUTION_CLASS
SMC_NAME_CUR_PROC_STATE
SMC_NAME_CUR_STMT_ACT_STP_DB_ID
SMC_NAME_CUR_STMT_ACT_STP_DB_NAME
SMC_NAME_CUR_STMT_ACT_STP_ID
SMC_NAME_CUR_STMT_ACT_STP_NAME
SMC_NAME_CUR_STMT_ACT_STP_OWNER_NAME
SMC_NAME_CUR_STMT_ACT_STP_TEXT
SMC_NAME_CUR_STMT_BATCH_ID
SMC_NAME_CUR_STMT_BATCH_TEXT
SMC_NAME_CUR_STMT_BATCH_TEXT_ENABLED
SMC_NAME_CUR_STMT_CONTEXT_ID
SMC_NAME_CUR_STMT_CPU_TIME
SMC_NAME_CUR_STMT_ELAPSED_TIME
SMC_NAME_CUR_STMT_LINE_NUM
SMC_NAME_CUR_STMT_LOCKS_GRANTED_IMMED
SMC_NAME_CUR_STMT_LOCKS_GRANTED_WAITED
SMC_NAME_CUR_STMT_LOCKS_NOT_GRANTED
SMC_NAME_CUR_STMT_NUM
SMC_NAME_CUR_STMT_PAGE_IO
SMC_NAME_CUR_STMT_PAGE_LOGICAL_READ
SMC_NAME_CUR_STMT_PAGE_PHYSICAL_READ
SMC_NAME_CUR_STMT_PAGE_WRITE
SMC_NAME_CUR_STMT_QUERY_PLAN_TEXT
SMC_NAME_CUR_STMT_START_TIME
SMC_NAME_CUR_STMT_TEXT_BYTE_OFFSET
SMC_NAME_DATA_CACHE_CONTENTION
SMC_NAME_DATA_CACHE_EFFICIENCY
SMC_NAME_DATA_CACHE_HIT
SMC_NAME_DATA_CACHE_HIT_PCT
SMC_NAME_DATA_CACHE_ID
SMC_NAME_DATA_CACHE_LARGE_IO_DENIED
SMC_NAME_DATA_CACHE_LARGE_IO_PERFORMED
SMC_NAME_DATA_CACHE_LARGE_IO_REQUESTED
SMC_NAME_DATA_CACHE_MISS
SMC_NAME_DATA_CACHE_NAME
SMC_NAME_DATA_CACHE_PREFETCH_EFFICIENCY
SMC_NAME_DATA_CACHE_REUSE
SMC_NAME_DATA_CACHE_REUSE_DIRTY
SMC_NAME_DATA_CACHE_REF_AND_REUSE
SMC_NAME_DATA_CACHE_SIZE
SMC_NAME_DB_ID
SMC_NAME_DB_NAME
SMC_NAME_DEADLOCK_CNT
SMC_NAME_DEMAND_LOCK
SMC_NAME_DEV_HIT
SMC_NAME_DEV_HIT_PCT
SMC_NAME_DEV_IO
SMC_NAME_DEV_MISS
SMC_NAME_DEV_NAME
SMC_NAME_DEV_READ
SMC_NAME_DEV_WRITE
SMC_NAME_ELAPSED_TIME
SMC_NAME_ENGINE_NUM
SMC_NAME_HOST_NAME
SMC_NAME_KPID
SMC_NAME_LOCK_CNT
SMC_NAME_LOCK_HIT_PCT
SMC_NAME_LOCK_RESULT
SMC_NAME_LOCK_RESULT_SUMMARY
SMC_NAME_LOCK_STATUS
SMC_NAME_LOCK_STATUS_CNT
SMC_NAME_LOCK_TYPE
SMC_NAME_LOCKS_BEING_BLOCKED_CNT
SMC_NAME_LOCKS_GRANTED_IMMED
SMC_NAME_LOCKS_GRANTED_WAITED
SMC_NAME_LOCKS_NOT_GRANTED
SMC_NAME_LOG_CONTENTION_PCT
SMC_NAME_LOGIN_NAME
SMC_NAME_MEM_CODE_SIZE
SMC_NAME_MEM_KERNEL_STRUCT_SIZE
SMC_NAME_MEM_PAGE_CACHE_SIZE
SMC_NAME_MEM_PROC_BUFFER
SMC_NAME_MEM_PROC_HEADER
SMC_NAME_MEM_SERVER_STRUCT_SIZE
SMC_NAME_MOST_ACT_DEV_IO
SMC_NAME_MOST_ACT_DEV_NAME
SMC_NAME_NET_BYTE_IO
SMC_NAME_NET_BYTES_RCVD
SMC_NAME_NET_BYTES_SENT
SMC_NAME_NET_DEFAULT_PKT_SIZE
SMC_NAME_NET_MAX_PKT_SIZE
SMC_NAME_NET_PKT_SIZE_RCVD
SMC_NAME_NET_PKT_SIZE_SENT
SMC_NAME_NET_PKTS_RCVD
SMC_NAME_NET_PKTS_SENT
SMC_NAME_NUM_ENGINES
SMC_NAME_NUM_PROCESSES
SMC_NAME_OBJ_ID
SMC_NAME_OBJ_NAME
SMC_NAME_OBJ_TYPE
SMC_NAME_OWNER_NAME
SMC_NAME_PAGE_HIT_PCT
SMC_NAME_PAGE_INDEX_LOGICAL_READ
SMC_NAME_PAGE_INDEX_PHYSICAL_READ
SMC_NAME_PAGE_IO
SMC_NAME_PAGE_LOGICAL_READ
SMC_NAME_PAGE_NUM
SMC_NAME_PAGE_PHYSICAL_READ
SMC_NAME_PAGE_WRITE
SMC_NAME_PROC_STATE
SMC_NAME_PROC_STATE_CNT
SMC_NAME_SPID
SMC_NAME_SQL_SERVER_NAME
SMC_NAME_SQL_SERVER_VERSION
SMC_NAME_STP_CPU_TIME
SMC_NAME_STP_ELAPSED_TIME
SMC_NAME_STP_EXECUTION_CLASS
SMC_NAME_STP_HIT_PCT
SMC_NAME_STP_LINE_NUM
SMC_NAME_STP_LINE_TEXT
SMC_NAME_STP_LOGICAL_READ
SMC_NAME_STP_NUM_TIMES_EXECUTED
SMC_NAME_STP_PHYSICAL_READ
SMC_NAME_STP_STMT_NUM
SMC_NAME_THREAD_EXCEEDED_MAX
SMC_NAME_THREAD_EXCEEDED_MAX_PCT
SMC_NAME_THREAD_MAX_USED
SMC_NAME_TIME_WAITED_ON_LOCK
SMC_NAME_TIMESTAMP
SMC_NAME_TIMESTAMP_DATIM
SMC_NAME_XACT
SMC_NAME_XACT_DELETE
SMC_NAME_XACT_DELETE_DEFERRED
SMC_NAME_XACT_DELETE_DIRECT
SMC_NAME_XACT_INSERT
SMC_NAME_XACT_INSERT_CLUSTERED
SMC_NAME_XACT_INSERT_HEAP
SMC_NAME_XACT_SELECT
SMC_NAME_XACT_UPDATE
SMC_NAME_XACT_UPDATE_DEFERRED
SMC_NAME_XACT_UPDATE_DIRECT
SMC_NAME_XACT_UPDATE_EXPENSIVE
SMC_NAME_XACT_UPDATE_IN_PLACE
SMC_NAME_XACT_UPDATE_NOT_IN_PLACE
Monitor Client Library Functions
Threads
Error handling
Error handler
Callback function
smc_close
smc_connect_alloc
smc_connect_drop
smc_connect_ex
smc_connect_props
smc_create_alarm_ex
smc_create_filter
smc_create_playback_session
smc_create_recording_session
smc_create_view
smc_drop_alarm
smc_drop_filter
smc_drop_view
smc_get_command_info
smc_get_dataitem_type
smc_get_dataitem_value
smc_get_row_count
smc_get_version_string
smc_initiate_playback
smc_initiate_recording
smc_refresh_ex
smc_terminate_playback
smc_terminate_recording
Building a Monitor Client Library Application
Building on UNIX platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Building on Windows platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Monitor Client Library Configuration Instructions
Loading Monitor Client Library
Using Studio Installer
Results of the load
Confirming your login account and permissions
Modifying the interfaces file
Setting up the user environment
Setting the SYBASE environment variable
Overriding the default location of the interfaces file
Using Monitor Client Library
Examples of Views
Cache performance summary
Current statement summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for session
Data cache statistics for sample interval
Device I/O for session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for session
Network activity for sample interval
Network performance summary
Procedure cache statistics for session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Datatypes and Structures
Summary of datatypes
Enum: SMC_ALARM_ACTION_TYPE
Enum: SMC_CLOSE_TYPE
Enum: SMC_DATAITEM_NAME
Enum: SMC_DATAITEM_STATTYPE
Structure: SMC_DATAITEM_STRUCT
Enum: SMC_DATAITEM_TYPE
Enum: SMC_ERR_SEVERITY
Enum: SMC_FILTER_TYPE
Enum: SMC_HS_ESTIM_OPT
Enum: SMC_HS_MISSDATA_OPT
Enum: SMC_HS_PLAYBACK_OPT
Enum: SMC_HS_SESS_DELETE_OPT
Enum: SMC_HS_SESS_ERR_OPT
Enum: SMC_HS_SESS_PROT_LEVEL
Enum: SMC_HS_SESS_SCRIPT_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_INFO_TYPE
Enum: SMC_LOCK_RESULT
Enum: SMC_LOCK_RESULT_SUMMARY
Enum: SMC_LOCK_STATUS
Enum: SMC_LOCK_TYPE
Enum: SMC_OBJ_TYPE
Enum: SMC_PROC_STATE
Enum: SMC_PROP_ACTION
Enum: SMC_PROP_TYPE
Enum: SMC_RETURN_CODE
Enum: SMC_SERVER_MODE
Enum: SMC_SOURCE
Union: SMC_VALUE_UNION
Backward Compatibility
Obsolete and replacement functions
New functions
Rules for functions and callbacks compatibility
Troubleshooting Information and Error Messages
Troubleshooting
Error messages
Communication failure: check if server is running.
Configuration failure: possibly missing interfaces file or bad login parameters.
Don’t know how to build example.h
error L2029: ‘SMC_CONNECT’ : unresolved external
error L2029: ‘SMC_CREATE_VIEW’ : unresolved external
fatal error C1083: Cannot open include file: ‘cstypes.h’: No such file or directory
fatal error C1083: Cannot open include file: ‘mcpublic.h’: No such file or directory
LINK: fatal error L4051: smcapi32.lib : cannot find library
Monitor Historical Server User's Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Adaptive Server Monitor components
Adaptive Server Monitor architecture
Adaptive Server Enterprise Monitor architecture
Historical Server concepts
Recording sessions
Playback sessions
Views
Data items and statistic types
Configuring Historical Server
Historical Server configuration concepts
The Historical Server control file and home directory
Accessing control file information
Do not edit the control file
The operating system start-up account
The Historical Server superuser account
Sybase Open Client/Server connections
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Results of installation on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Windows NT
Assumptions on Windows NT
Results of installation on Windows NT
Configuration procedures on Windows NT
Changing start-up parameter
Setting Historical Server start-up parameters
Function
Syntax
Parameters
Configuring multiple instances of Historical Server
When to create multiple instances of Historical Server
Configuring an additional Historical Server on UNIX platforms
Configuring an additional Historical Server on Windows NT
Task 1: add start-up parameters to the NT Registry
Task 2: update the NT Registry services list
Task 3: add connectivity information for Historical Server
Task 4: configure Historical Server client machines
Task 5: create a .bat file (optional)
Starting and Stopping Historical Server
Starting and stopping Historical Server on UNIX platforms
Starting Historical Server on UNIX
Stopping Historical Server on UNIX
Who can shut down Historical Server
Determining current activity on Historical Server
Deferred versus immediate shutdown
Detailed shutdown procedures
Starting and stopping Historical Server on NT
Starting Historical Server on NT
Inferring start-up parameters from the NT Registry
Verifying that Historical Server is running
Stopping Historical Server on Windows NT
Who can shut down Historical Server on Windows NT
Determining current activity on Windows NT
Deferred versus immediate shutdown on Windows NT
Detailed shutdown procedures on Windows NT
Shutdown methods to avoid on Windows NT
Command Reference
Command summary
Command syntax
Command status and errors
Script files as input to Historical Server
Connecting to Historical Server
Assumptions before connection
How to connect
Required permissions for Historical Server activities
Mutually exclusive sessions
Starting and ending a recording session definition
Starting and ending a playback session
Historical Server commands
hs_create_alarm
hs_create_filter
hs_create_playback_session
hs_create_playback_view
hs_create_recording_session
hs_create_view
hs_delete_data
hs_initiate_playback
hs_initiate_recording
hs_list
hs_playback_sample
hs_shutdown
hs_status
hs_terminate_playback
hs_terminate_recording
Data Files
Overview of Historical Server data files
Description of Historical Server files
Permissions on files
General file format
Control file
Header record
Session control record
View control record
Data item control record
Alarm control record
Filter control record
Data file
Error message file
Script file
Script file table names
Script file table column names
Passing script file commands
Script use example
Bulk copy example
Explanation
Example
Cut utility example
Data Items
Table of data items and definitions
Specifications for Defining Recording Session Views
Definition of key and result
Designing recording session views
Using the Process ID
Using the application name
Empty rows versus no rows in views
Table of valid key and result data item combinations
Examples of valid combinations
Examples of invalid combinations
Table of valid statistic types for data items
Specifications for Defining Playback Views
Summarization level details
Raw playback
Actual playback
Entire playback
Playback with user-defined intervals
Summary of summarization intervals
Designing playback views
Rules for specifying input sessions
Relationship of input views to playback views
Rules for defining views
Rules for defining raw playback views
Rules for defining non-raw playback views
Table of data item requirements for playback views
Additional information about some data items
Using “Timestamp”, “Timestamp Datim”, and “Elapsed Time”
Using Process ID
Using Procedure Elapsed Time and Procedure CPU Time
Examples of Recording Session Views
Cache performance summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for recording session
Data cache statistics for sample interval
Device I/O for recording session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for recording session
Network activity for sample interval
Network performance summary
Page I/O
Procedure cache statistics for recording session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Monitor Server User's Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Monitor components
Monitor architecture
Interaction with sp_sysmon
Configuring Monitor Server
Monitoring SQL Server version 11.0.x
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Results of installation on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Microsoft Windows NT
Assumptions on Windows NT
Results of installation on Windows NT
Configuration procedures on Windows NT
Setting up the automatic start-up service
Setting up the server start-up order
Changing the default configuration
Changing start-up information in the NT Registry
Changing the .bat file
Configuring another Monitor Server
Monitor Server start-up parameters
Function
Syntax
Parameters
Adjusting Monitor Server runtime configuration
Monitor Server configuration file
Initial scan interval
Heartbeat interval
Configuring Monitor Server heap space usage
Summary buffer size
Number of summary buffers per event summary request
Maximum number of event summaries per connection
Adaptive Server configuration issues that affect Monitor Server
Restrictions on length of Adaptive Server name
Configuring event buffers
Understanding event buffers and event loss
Determining a value for event buffers per engine parameter
Changing the event buffers per engine parameter
Configuring SQL text buffers
Understanding the SQL text feature
Determining a value for the max SQL text monitored parameter
Changing the max SQL text monitored Parameter
Starting, Verifying, and Stopping Monitor Server
Starting, verifying, and stopping Monitor Server on UNIX platforms
Starting Monitor Server on UNIX
Verifying that Monitor Server is running on UNIX
Stopping Monitor Server on UNIX
Starting, verifying, and stopping Monitor Server on Windows NT
Starting Monitor Server on Windows NT
How start-up parameters are inferred on Windows NT
Verifying that Monitor Server is running on Windows NT
Stopping Monitor Server on Windows NT
Orderly shutdowns and restarts
Orderly shutdowns
Automatic shutdowns
Orderly restarts
Connecting to clients
Monitor Server isql commands
Using the commands
sms_shutdown
sms_status
Troubleshooting Monitor Server
Error messages
Common problems
Monitor Server fails to start
Access violations
Check the NT Registry services entry (NT only)
Client errors
Maximum connection errors
ct_netlib errors (Windows NT)
Messages in Adaptive Server error log
Performance and Tuning Guide
About this book
Overview
Good performance
Response time
Throughput
Designing for performance
Tuning performance
Tuning levels
Application layer
Database layer
Adaptive Server layer
Devices layer
Network layer
Hardware layer
Operating – system layer
Identifying system limits
Setting tuning goals
Analyzing performance
Normal Forms
Locking
Special Considerations
Networks and Performance
Introduction
Potential performance problems
Basic questions on network performance
Techniques summary
Using sp_sysmon while changing network configuration
How Adaptive Server uses the network
Changing network packet sizes
Large versus default packet sizes for user connections
Number of packets is important
Evaluation tools with Adaptive Server
Evaluation tools outside of Adaptive Server
Server-based techniques for reducing network traffic
Impact of other server activities
Single user versus multiple users
Improving network performance
Isolate heavy network users
Set tcp no delay on TCP networks
Configure multiple network listeners
Using Engines and CPUs
Background concepts
How Adaptive Server processes client requests
Client task implementation
Single-CPU process model
Scheduling engines to the CPU
Scheduling tasks to the engine
Execution task scheduling
Scheduling client task processing time
Maintaining CPU availability during idle time
Adaptive Server SMP process model
Scheduling engines to CPUs
Scheduling Adaptive Server tasks to engines
Multiple network engines
Task priorities and run queues
Processing scenario
Housekeeper task improves CPU utilization
Side effects of the housekeeper task
Configuring the housekeeper task
Changing the percentage by which writes can be increased
Disabling the housekeeper task
Allowing the housekeeper task to work continuously
Measuring CPU usage
Single-CPU machines
Using sp_monitor to measure CPU usage
Using sp_sysmon to measure CPU usage
Operating - system commands and CPU usage
Determining when to configure additional engines
Taking engines offline
Enabling engine-to-CPU affinity
Multiprocessor application design guidelines
Distributing Engine Resources
Algorithm for successfully distributing engine resources
Algorithm guidelines
Environment analysis and planning
Analyzing
Example: phase 1 – execution object behavior
Example: phase 2 – the environment as a whole
Performing benchmark tests
Setting goals
Results analysis and tuning
Monitoring the environment over time
Manage preferred access to resources
Types of execution classes
Predefined execution classes
User-Defined execution classes
Execution class attributes
Base priority
Time slice
Task-to-engine affinity
Setting execution class attributes
Assigning execution classes
Engine groups and establishing task-to-engine affinity
How execution class bindings affect scheduling
Execution class bindings
Engine affinity can affect scheduling
Setting attributes for a session only
Getting information
Rules for determining precedence and scope
Multiple execution objects and ECs
Precedence rule
Scope rule
Resolving a precedence conflict
Examples: determining precedence
Example scenario using precedence rules
Planning
Configuration
Execution characteristics
Considerations for Engine Resource Distribution
Client applications: OLTP and DSS
Unintrusive client applications
I/O-bound client applications
Highly critical applications
Adaptive Server logins: high-priority users
Stored procedures: “hot spots”
Controlling Physical Data Placement
Object placement can improve performance
Symptoms of poor object placement
Underlying problems
Using sp_sysmon while changing data placement
Terminology and concepts
Guidelines for improving I/O performance
Spreading data across disks to avoid I/O contention
Avoiding physical contention in parallel join queries
Isolating server-wide I/O from database I/O
Where to place tempdb
Where to place sybsecurity
Keeping transaction logs on a separate disk
Mirroring a device on a separate disk
Device mirroring performance issues
Using serial mode
Creating objects on segments
Using segments
Separating tables and indexes
Splitting large tables across devices
Moving text storage to a separate device
Partitioning tables for performance
User transparency
Partitioned tables and parallel query processing
Distributing data across partitions
Improving insert performance with partitions
How partitions address page contention
Selecting heap tables to partition
Restrictions on partitioned tables
Partition-related configuration parameters
How Adaptive Server distributes partitions on devices
RAID devices and partitioned tables
Space planning for partitioned tables
Read-only tables
Read-mostly tables
Tables with random data modification
Commands for partitioning tables
alter table...partition syntax
alter table...unpartition Syntax
Changing the number of partitions
Distributing data evenly across partitions
Commands to create and drop clustered indexes
Using reorg rebuild on data-only-locked tables
Using drop index and create clustered index
Using constraints and alter table
Special concerns for partitioned tables and clustered indexes
Using parallel bcp to copy data into partitions
Parallel copy and locks
Getting information about partitions
Using bcp to correct partition balance
Checking data distribution on devices with sp_helpsegment
Effects of imbalance of data on segments and partitions
Determining the number of pages in a partition
Updating partition statistics
Syntax for update partition statistics
Steps for partitioning tables
Backing up the database after partitioning tables
Table does not exist
Table exists elsewhere in the database
Table exists on the segment
Redistributing data
Adding devices to a segment
Special procedures for difficult situations
Clustered indexes on large tables
Alternative for clustered indexes
Problems when devices for partitioned tables are full
Adding disks when devices are full
Adding disks when devices are nearly full
Maintenance issues and partitioned tables
Regular maintenance checks for partitioned tables
Database Design
Basic design
Physical database design for Adaptive Server
Logical Page Sizes
Normalization
Levels of normalization
Benefits of normalization
First Normal Form
Second Normal Form
Third Normal Form
Denormalizing for performance
Risks
Disadvantages
Performance advantages
Denormalization input
Techniques
Adding redundant columns
Adding derived columns
Collapsing tables
Duplicating tables
Splitting tables
Horizontal splitting
Vertical splitting
Managing denormalized data
Using triggers
Using application logic
Batch reconciliation
Data Storage
Performance gains through query optimization
Query processing and page reads
Adaptive Server pages
Page headers and page sizes
Varying logical page sizes
Data and index pages
Large Object (LOB) Pages
Extents
Pages that manage space allocation
Global allocation map pages
Allocation pages
Object allocation map pages
How OAM pages and allocation pages manage object storage
Page allocation keeps an object’s pages together
sysindexes table and data access
Space overheads
Number of columns and size
Variable-length columns in APL tables
Variable length columns in DOL tables
Number of rows per data page
Maximum numbers
Arguments for stored procedures
Retrieving data with enhanced limits
Heaps of data: tables without clustered indexes
Lock schemes and differences between heaps
Select operations on heaps
Allpages-locked heap tables
Data-only locked heap tables
Inserting data into an allpages-locked heap table
Conflicts during heap inserts
Inserting data into a data-only-locked heap table
If conflicts occur during heap inserts
Deleting data from a heap table
Deleting from an allpages-locked heap table
Deleting from a data-only locked heap table
Deleting the last row on a page
Updating data on a heap table
Allpages-locked heap tables
Data-only-locked heap tables
How Adaptive Server performs I/O for heap operations
Sequential prefetch, or large I/O
Caches and object bindings
Heaps, I/O, and cache strategies
Overview of cache strategies
LRU replacement strategy
When LRU strategy is used
MRU replacement strategy
Select operations and caching
Data modification and caching
Caching and inserts on heaps
Caching, update and delete operations on heaps
Asynchronous prefetch and I/O on heap tables
Heaps: pros and cons
Maintaining heaps
Methods
Using reorg rebuild to reclaim space
Reclaiming space by creating a clustered index
Reclaiming space using bcp
Transaction log: a special heap table
Indexing for Performance
How indexes affect performance
Detecting indexing problems
Symptoms of poor indexing
Lack of indexes is causing table scans
Index is not selective enough
Index does not support range queries
Too many indexes slow data modification
Index entries are too large
Exception for wide data rows and wide index rows
Fixing corrupted indexes
Repairing the system table index
Repairing a nonclustered index
Index limits and requirements
Choosing indexes
Index keys and logical keys
Guidelines for clustered indexes
Choosing clustered indexes
Candidates for nonclustered indexes
Other indexing guidelines
Choosing nonclustered indexes
Performance price for data modification
Choosing composite indexes
Key order and performance in composite indexes
Advantages and disadvantages of composite indexes
Techniques for choosing indexes
Choosing an index for a range query
Adding a point query with different indexing requirements
Index and statistics maintenance
Dropping indexes that hurt performance
Choosing space management properties for indexes
Additional indexing tips
Creating artificial columns
Keeping index entries short and avoiding overhead
Dropping and rebuilding indexes
How Indexes Work
Types of indexes
Index pages
Root level
Leaf level
Intermediate level
Index Size
Clustered indexes on allpages-locked tables
Clustered indexes and select operations
Clustered indexes and insert operations
Page splitting on full data pages
Exceptions to page splitting
Page splitting on index pages
Performance impacts of page splitting
Overflow pages
Clustered indexes and delete operations
Deleting the last row on a page
Index page merges
Nonclustered indexes
Leaf pages revisited
Nonclustered index structure
Nonclustered indexes and select operations
Nonclustered index performance
Nonclustered indexes and insert operations
Nonclustered indexes and delete operations
Clustered indexes on data-only-locked tables
Index covering
Covering matching index scans
Covering nonmatching index scans
Indexes and caching
Using separate caches for data and index pages
Index trips through the cache
Locking in Adaptive Server
How locking affects performance
Overview of locking
Granularity of locks and locking schemes
Allpages locking
Datapages locking
Datarows locking
Types of locks in Adaptive Server
Page and row locks
Table locks
Demand locks
Demand locking with serial execution
Demand locking with parallel execution
Range locking for serializable reads
Latches
Lock compatibility and lock sufficiency
How isolation levels affect locking
Isolation Level 0, read uncommitted
Isolation Level 1, read committed
Isolation Level 2, repeatable read
Isolation Level 3, serializable reads
Adaptive Server default isolation level
Lock types and duration during query processing
Lock types during create index commands
Locking for select queries at isolation Level 1
Table scans and isolation Levels 2 and 3
Table scans and table locks at isolation Level 3
Isolation Level 2 and Allpages-Locked tables
When update locks are not required
Locking during or processing
Processing or queries for Allpages-Locked tables
Processing or queries for Data-Only-Locked tables
Skipping uncommitted inserts during selects
Pseudo column-level locking
Select queries that do not reference the updated column
Using alternative predicates to skip nonqualifying rows
Qualifying old and new values for uncommitted updates
Suggestions to reduce contention
Using Locking Commands
Specifying the locking scheme for a table
Specifying a server-wide locking scheme
Specifying a locking scheme with create table
Changing a locking scheme with alter table
Before and after changing locking schemes
After alter table completes
Expense of switching to or from allpages locking
Sort performance during alter table
Specifying a locking scheme with select into
Controlling isolation levels
Setting isolation levels for a session
Syntax for query-level and table-level locking options
Using holdlock, noholdlock, or shared
Using the at isolation clause
Making locks more restrictive
Using read committed
Making locks less restrictive
Using read uncommitted
Using shared
Readpast locking
Cursors and locking
Using the shared keyword
Additional locking commands
lock table Command
Lock timeouts
Reporting on Locks
Locking tools
Getting information about blocked processes
Viewing locks
Viewing locks
Intrafamily blocking during network buffer merges
Deadlocks and concurrency
Server-side versus application-side deadlocks
Application deadlock example
Server task deadlocks
Deadlocks and parallel queries
Printing deadlock information to the error log
Avoiding deadlocks
Acquire locks on objects in the same order
Delaying deadlock checking
Identifying tables where concurrency is a problem
Lock management reporting
Locking Configuration and Tuning
Locking and performance
Using sp_sysmon and sp_object_stats
Reducing lock contention
Adding indexes to reduce contention
Keeping transactions short
Avoiding hot spots
Additional locking guidelines
Configuring locks and lock promotion thresholds
Configuring Adaptive Server’s lock limit
Estimating number of locks for data-only-locked tables
Configuring the lock hashtable (Lock Manager)
Setting lock promotion thresholds
Lock promotion and scan sessions
Lock promotion high water mark
Lock promotion low water mark
Lock promotion percent
Setting server-wide lock promotion thresholds
Setting the lock promotion threshold for a table or database
Precedence of settings
Dropping database and table settings
Using sp_sysmon while tuning lock promotion thresholds
Choosing the locking scheme for a table
Analyzing existing applications
Choosing a locking scheme based on contention statistics
Monitoring and managing tables after conversion
Applications not likely to benefit from data-only locking
Tables where clustered index performance must remain high
Tables with maximum-length rows
Setting Space Management Properties
Reducing index maintenance
Advantages of using fillfactor
Disadvantages of using fillfactor
Setting fillfactor values
fillfactor examples
No stored fillfactor values
Table-level or clustered index fillfactor value stored
Use of the sorted_data and fillfactor options
Reducing row forwarding
Default, minimum, and maximum values for exp_row_size
Default value
Specifying an expected row size with create table
Adding or changing an expected row size
Setting a default expected row size server-wide
Displaying the expected row size for a table
Choosing an expected row size for a table
Using optdiag to check for forwarded rows
Querying systabstats to check for forwarded rows
Conversion of max_rows_per_page to exp_row_size
Monitoring and managing tables that use expected row size
Leaving space for forwarded rows and inserts
Extent allocation operations and reservepagegap
Specifying a reserve page gap with create table
Specifying a reserve page gap with create index
Changing reservepagegap
reservepagegap examples
reservepagegap specified only for the table
reservepagegap specified for a clustered index
Choosing a value for reservepagegap
Monitoring reservepagegap settings
reservepagegap and sorted_data options to create index
Background on the sorted_data option
Matching options and goals
Using max_rows_per_page on allpages-locked tables
Reducing lock contention
Indexes and max_rows_per_page
select into and max_rows_per_page
Applying max_rows_per_page to existing data
Memory Use and Performance
How memory affects performance
How much memory to configure
Caches in Adaptive Server
Procedure cache
Getting information about the procedure cache size
proc buffers
proc headers
Monitoring procedure cache performance
Procedure cache errors
Procedure cache sizing
Estimating stored procedure size
Data cache
Default cache at installation time
Page aging in data cache
Effect of data cache on retrievals
Effect of data modifications on the cache
Data cache performance
Testing data cache performance
Cache hit ratio for a single query
Cache hit ratio information from sp_sysmon
Configuring the data cache to improve performance
Commands to configure named data caches
Tuning named caches
Cache configuration goals
Gather data, plan, and then implement
Evaluating cache needs
Large I/O and performance
The optimizer and cache choices
Choosing the right mix of I/O sizes for a cache
Reducing spinlock contention with cache partitions
Cache replacement strategies and policies
Strategies
Policies
Named data cache recommendations
Sizing caches for special objects, tempdb, and transaction logs
Determining cache sizes for special tables or indexes
Examining cache needs for tempdb
Examining cache needs for transaction logs
Choosing the I/O size for the transaction log
Configuring for large log I/O size
Additional tuning tips for log caches
Basing data pool sizes on query plans and I/O
Checking I/O size for queries
Configuring buffer wash size
Overhead of pool configuration and binding objects
Pool configuration overhead
Cache binding overhead
Maintaining data cache performance for large I/O
Diagnosing excessive I/O Counts
Using sp_sysmon to check large I/O performance
Speed of recovery
Tuning the recovery interval
Effects of the housekeeper task on recovery time
Auditing and performance
Sizing the audit queue
Auditing performance guidelines
Determining Sizes of Tables and Indexes
Why object sizes are important to query tuning
Tools for determining the sizes of tables and indexes
Effects of data modifications on object sizes
Using optdiag to display object sizes
Advantages of optdiag
Disadvantages of optdiag
Using sp_spaceused to display object size
Advantages of sp_spaceused
Disadvantages of sp_spaceused
Using sp_estspace to estimate object size
Advantages of sp_estspace
Disadvantages of sp_estspace
Using formulas to estimate object size
Factors that can affect storage size
Storage sizes for datatypes
Tables and indexes used in the formulas
Calculating table and clustered index sizes for allpages-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Compute the size of clustered index rows
Step 4: Compute the number of clustered index pages
Step 5: Compute the total number of index pages
Step 6: Calculate allocation overhead and total pages
Step 7: Calculate the size of the leaf index row
Step 8: Calculate the number of leaf pages in the index
Step 9: Calculate the size of the non-leaf rows
Step 10: Calculate the number of non-leaf pages
Step 11: Calculate the total number of non-leaf index pages
Step 12: Calculate allocation overhead and total pages
Calculating the sizes of data-only-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Calculate allocation overhead and total pages
Step 4: Calculate the size of the index row
Step 5: Calculate the number of leaf pages in the index
Step 6: Calculate the number of non-leaf pages in the index
Step 7: Calculate the total number of non-leaf index pages
Step 8: Calculate allocation overhead and total pages
Other factors affecting object size
Effects of space management properties
Using average sizes for variable fields
Very small rows
LOB pages
Advantages of using formulas to estimate object size
Disadvantages of using formulas to estimate object size
Maintenance Activities and Performance
Running reorg on tables and indexes
Creating and maintaining indexes
Configuring Adaptive Server to speed sorting
Dumping the database after creating an index
Creating an index on sorted data
Maintaining index and column statistics
Rebuilding indexes
Speeding index creation with sorted_data
Creating or altering a database
Backup and recovery
Local backups
Remote backups
Online backups
Using thresholds to prevent running out of log space
Minimizing recovery time
Recovery order
Bulk copy
Parallel bulk copy
Batches and bulk copy
Slow bulk copy
Improving bulk copy performance
Replacing the data in a large table
Adding large amounts of data to a table
Using partitions and multiple bulk copy processes
Impacts on other users
Database consistency checker
Using dbcc tune (cleanup)
Using dbcc tune on spinlocks
When not to use this command
Determining the space available for maintenance activities
Overview of space requirements
Tools for checking space usage and space available
Checking space used for tables and indexes
Checking space on segments
Checking space requirements for space management properties
Space management properties applied to the table
Space management properties applied to the index
Estimating the effects of space management properties
If there is not enough space
tempdb Performance Issues
How management of tempdb affects performance
Main solution areas for tempdb performance
Types and uses of temporary tables
Truly temporary tables
Regular user tables
Worktables
Initial allocation of tempdb
Sizing the tempdb
Placing tempdb
Dropping the master device from tempdb segments
Using multiple disks for parallel query performance
Binding tempdb to its own cache
Commands for cache binding
Temporary tables and locking
Minimizing logging in tempdb
With select into
By using shorter rows
Optimizing temporary tables
Creating indexes on temporary tables
Creating nested procedures with temporary tables
Breaking tempdb uses into multiple procedures
Adaptive Server Optimizer
Definition
Steps in query processing
Working with the optimizer
Object sizes are important to query tuning
Query optimization
Factors examined during optimization
Preprocessing can add clauses for optimizing
Converting clauses to search argument equivalents
Converting expressions into search arguments
Search argument transitive closure
Join transitive closure
Enabling join transitive closure
Predicate transformation and factoring
Example
Guidelines for creating search arguments
Search arguments and useful indexes
Search argument syntax
Nonequality operators
Examples of SARGs
How statistics are used for SARGS
Histogram cells
Density values
Range cell density and total density
How the optimizer uses densities and histograms
Using statistics on multiple search arguments
Default values for search arguments
SARGs using variables and parameters
Join syntax and join processing
How joins are processed
When statistics are not available for joins
Density values and joins
Multiple column joins
Search arguments and joins on a table
Datatype mismatches and query optimization
Overview of the datatype hierarchy and index issues
Comparison of numeric and decimal datatypes
Comparing numeric types to other datatypes
Datatypes for parameters and variables used as SARGs
Troubleshooting datatype mismatch problems fo SARGs
Compatible datatypes for join columns
Troubleshooting datatype mismatch problems for joins
Suggestions on datatypes and comparisons
Forcing a conversion to the other side of a join
Splitting stored procedures to improve costing
Basic units of costing
Advanced Optimizing Tools
Special optimizing techniques
Specifying optimizer choices
Specifying table order in joins
Risks of using forceplan
Things to try before using forceplan
Specifying the number of tables considered by the optimizer
Specifying an index for a query
Risks
Things to try before specifying an index
Specifying I/O size in a query
Index type and large I/O
When prefetch specification is not followed
set prefetch on
Specifying the cache strategy
In select, delete, and update statements
Controlling large I/O and cache strategies
Getting information on cache strategies
Enabling and disabling merge joins
Enabling and disabling join transitive closure
Suggesting a degree of parallelism for a query
Query level parallel clause examples
Concurrency optimization for small tables
Changing locking scheme
Query Tuning Tools
Overview
How tools may interact
Using showplan and noexec together
noexec and statistics io
How tools relate to query processing
Access Methods and Query Costing for Single Tables
Table scan cost
Cost of a scan on allpages-locked table
Cost of a scan on a data-only-locked tables
From rows to pages
How cluster ratios affect large I/O estimates
Data page cluster ratio
Index page cluster ratio
Evaluating the cost of index access
Query that returns a single row
Query that returns many rows
Range queries using clustered indexes (allpages locking)
Range queries with covering indexes
Range queries with noncovering indexes
Result-set size and index use
Costing for noncovering index scans
Costing for forwarded rows
Costing for queries using order by
Prefix subset and sorts
Key ordering and sorts
Specifying ascending or descending order for index keys
How the optimizer costs sort operations
Allpages-locked tables with clustered indexes
Sorts when index covers the query
Sorts and noncovering indexes
Backward scans and joins
Deadlocks and descending scans
Access Methods and Costing for or and in Clauses
or syntax
in (values_list) converts to or processing
Methods for processing or clauses
When table scans are used for or queries
Dynamic index (OR strategy)
Multiple matching index scans (special OR strategy)
How aggregates are optimized
Combining max and min aggregates
Queries that use both min and max
How update operations are performed
Direct updates
In-place updates
Cheap direct updates
Expensive direct updates
Deferred updates
When deferred updates are required
Deferred index inserts
Restrictions on update modes through joins
Joins and subqueries in update and delete statements
Deletes and updates in triggers versus referential integrity
Optimizing updates
Designing for direct updates
Effects of update types and indexes on update modes
Using sp_sysmon while tuning updates
Accessing Methods and Costing for Joins and Subqueries
Costing and optimizing joins
Processing
Index density and joins
Multicolumn densities
Datatype mismatches and joins
Join permutations
Outer joins and join permutations
Nested-loop joins
Cost formula
How inner and outer tables are determined
Access methods and costing for sort-merge joins
How a full-merge is performed
How a right-merge or left-merge is performed
How a sort-merge is performed
Mixed example
showplan messages for sort-merge joins
Costing for merge joins
Costing for a full-merge with unique values
Example: allpages-locked tables with clustered indexes
Costing for a full-merge with duplicate values
Costing sorts
Worktable size for sort-merge joins
When merge joins cannot be used
Use of worker processes
Recommendations for improved merge performance
Enabling and disabling merge joins
At the server level
At the session level
Reformatting strategy
Subquery optimization
Flattening in, any, and exists subqueries
When flattening can be done
Exceptions to flattening
Flattening methods
Join order and flattening methods
Flattened subqueries executed as regular joins
Flattened subqueries executed as existence joins
Flattened subqueries executed using unique reformatting
Flattened subqueries using duplicate elimination
Flattening expression subqueries
Materializing subquery results
Noncorrelated expression subqueries
Quantified predicate subqueries containing aggregates
Subquery introduced with an and clause
Subquery introduced with an or clause
Subquery results caching
Displaying subquery cache information
Optimizing subqueries
or clauses versus unions in joins
Parallel Query Processing
Types of queries that can benefit from parallel processing
Adaptive Server’s worker process model
Parallel query execution
Returning results from parallel queries
Types of parallel data access
Hash-based table scans
Partition-based scans
Hash-based index scans
Parallel processing for two tables in a join
showplan messages
Controlling the degree of parallelism
Configuration parameters for controlling parallelism
How limits apply to query plans
How the limits work in combination
Examples of setting parallel configuration parameters
Using set options to control parallelism for a session
set command examples
Controlling parallelism for a query
Query level parallel clause examples
Worker process availability and query execution
Other configuration parameters for parallel processing
Commands for working with partitioned tables
Balancing resources and performance
CPU resources
Disk resources and I/O
Tuning example: CPU and I/O saturation
Guidelines for parallel query configuration
Hardware guidelines
Working with your performance goals and hardware guidelines
Examples of parallel query tuning
Improving the performance of a table scan
Improving the performance of a nonclustered index scan
Guidelines for partitioning and parallel degree
Experimenting with data subsets
System level impacts
Locking issues
Device issues
Procedure cache effects
When parallel query results can differ
Queries that use set rowcount
Queries that set local variables
Achieving consistent results
Parallel Query Optimization
What is parallel query optimization?
Optimizing for response time versus total work
When is optimization performed?
Overhead costs
Factors that are not considered
Parallel access methods
Parallel partition scan
Requirements for consideration
Cost model
Parallel clustered index partition scan (allpages-locked tables)
Requirements for consideration
Cost model
Parallel hash-based table scan
Hash-based table scans on allpages-locked tables
Hash-based table scans on data-only-locked tables
Requirements for consideration
Cost model
Parallel hash-based index scan
Cost model and requirements
Parallel range-based scans
Requirements for consideration
Additional parallel strategies
Partitioned worktables
Parallel sorting
Summary of parallel access methods
Selecting parallel access methods
Degree of parallelism for parallel queries
Upper limit
Optimized degree
Worker processes for partition-based scans
Worker processes for hash-based scans
Worker processes for range-based scans
Nested-loop joins
Alternative plans
Computing the degree of parallelism for nested-loop joins
Parallel queries and existence joins
Examples
Partitioned heap table
Nonpartitioned heap table
Table with clustered index
Runtime adjustments to worker processes
Parallel query examples
Single-table scans
Table partition scan
Multitable joins
Parallel join optimization and join orders
Subqueries
Queries that require worktables
union queries
Queries with aggregates
select into statements
Runtime adjustment of worker processes
How Adaptive Server adjusts a query plan
Evaluating the effect of runtime adjustments
Recognizing and managing runtime adjustments
Using set process_limit_action
Using showplan
Reducing the likelihood of runtime adjustments
Checking runtime adjustments with sp_sysmon
Diagnosing parallel performance problems
Query does not run in parallel
Parallel performance is not as good as expected
Calling technical support for diagnosis
Resource limits for parallel queries
Parallel Sorting
Commands that benefits from parallel sorting
Requirements and resources overview
Overview of the parallel sorting strategy
Creating a distribution map
Dynamic range partitioning
Range sorting
Merging results
Configuring resources for parallel sorting
Worker process requirements for parallel sorts
Worker process requirements for creating indexes
Using with consumers while creating indexes
Worker process requirements for select query sorts
Worker processes for merge-join sorts
Other worktable sorts
Caches, sort buffers, and parallel sorts
Cache bindings
Number of sort buffers can affect sort performance
Sort buffer configuration guidelines
Using less than the configured number of sort buffers
Configuring the number of sort buffers parameter
Procedure for estimating merge levels and I/O
Configuring caches for large I/O during parallel sorting
Balancing sort buffers and large I/O configuration
Disk requirements
Space requirements for creating indexes
Space requirements for worktable sorts
Number of devices in the target segment
Recovery considerations
Tools for observing and tuning sort behavior
Using set sort_resources on
Examples
Using sp_sysmon to tune index creation
Tuning Asynchronous Prefetch
How asynchronous prefetch improves performance
Improving query performance by prefetching pages
Prefetching control mechanisms in a multiuser environment
Look-ahead set during recovery
Prefetching log pages
Prefetching data and index pages
Look-ahead set during sequential scans
Look-ahead set during nonclustered index access
Look-ahead set during dbcc checks
Allocation checking
checkdb and checktable
Look-ahead set minimum and maximum sizes
When prefetch is automatically disabled
Flooding pools
I/O system overloads
Unnecessary reads
Page chain fragmentation
Tuning Goals for asynchronous prefetch
Commands for configuration
Other Adaptive Server performance features
Large I/O
Sizing and limits for the 16k pool
Limits for the 2K pool
Fetch-and-discard (MRU) scans
Parallel scans and large I/Os
Hash-based table scans
Partition-based scans
Special settings for asynchronous prefetch limits
Setting limits for recovery
Setting limits for dbcc
Maintenance activities for high prefetch performance
Eliminating kinks in heap tables
Eliminating kinks in clustered index tables
Eliminating kinks in nonclustered indexes
Performance monitoring and asynchronous prefetch
Cursors and Performance
Definition
Set-oriented versus row-oriented programming
Example
Resources required at each stage
Memory use and execute cursors
Cursor modes
Index use and requirements for cursors
Allpages-locked tables
Data-only-locked tables
Table scans to avoid the Halloween problem
Comparing performance with and without cursors
Sample stored procedure without a cursor
Sample stored procedure with a cursor
Cursor versus noncursor performance comparison
Locking with read-only cursors
Isolation levels and cursors
Partitioned heap tables and cursors
Optimizing tips for cursors
Optimizing for cursor selects using a cursor
Using union instead of or clauses or in lists
Declaring the cursor’s intent
Specifying column names in the for update clause
Using set cursor rows
Keeping cursors open across commits and rollbacks
Opening multiple cursors on a single connection
Introduction to Abstract Plans
Definition
Managing abstract plans
Relationship between query text and query plans
Limits of options for influencing query plans
Full versus partial plans
Creating a partial plan
Abstract plan groups
How abstract plans are associated with queries
Abstract Query Plan Guide
Introduction
Abstract plan language
Queries, access methods, and abstract plans
Identifying tables
Identifying indexes
Specifying join order
Shorthand notation for joins
Join order examples
Match between execution methods and abstract plans
Specifying join order for queries using views
Specifying the join type
Specifying partial plans and hints
Grouping multiple hints
Inconsistent and illegal plans using hints
Creating abstract plans for subqueries
Materialized subqueries
Flattened subqueries
Example: changing the join order in a flattened subquery
Nested subqueries
Subquery identification and attachment
More subquery examples: reading ordering and attachment
Modifying subquery nesting
Abstract plans for materialized views
Abstract plans for queries containing aggregates
Specifying the reformatting strategy
OR strategy limitation
When the store operator is not specified
Tips on writing abstract plans
Comparing plans “before” and “after”
Effects of enabling server-wide capture mode
Time and space to copy plans
Abstract plans for stored procedures
Procedures and plan ownership
Procedures with variable execution paths and optimization
Ad Hoc queries and abstract plans
Creating and Using Abstract Plans
Using set commands to capture and associate plans
Enabling plan capture mode with set plan dump
Associating queries with stored plans
Using replace mode during plan capture
When to use replace mode
Using dump, load, and replace modes simultaneously
Using dump and load to the same group
Using dump and load to different groups
set plan exists check option
Using other set options with abstract plans
Using showplan
Using noexec
Using forceplan
Server-wide abstract plan capture and association Modes
Creating plans using SQL
Using create plan
Using the plan Clause
Managing Abstract Plans with System Procedures
System procedures for managing abstract plans
Managing an abstract plan group
Creating a group
Dropping a group
Getting information about a group
Renaming a group
Finding abstract plans
Managing individual abstract plans
Viewing a plan
Copying a plan to another group
Dropping an individual abstract plan
Comparing two abstract plans
Changing an existing plan
Managing all plans in a group
Copying all plans in a group
Comparing all plans in a group
Dropping all abstract plans in a group
Importing and exporting groups of plans
Exporting plans to a user table
Importing plans from a user table
Abstract Plan Language Reference
Keywords
Operands
Derived tables
Schema for examples
g_join
hints
i_scan
in
lru
m_g_join
mru
nested
nl_g_join
parallel
plan
prefetch
prop
scan
store
subq
t_scan
table
union
view
work_t
Using Statistics to Improve Performance
Importance of statistics
Updating
Adding statistics for unindexed columns
update statistics commands
Column statistics and statistics maintenance
Creating and updating column statistics
When additional statistics may be useful
Adding statistics for a column with update statistics
Adding statistics for minor columns with update index statistics
Adding statistics for all columns with update all statistics
Choosing step numbers for histograms
Disadvantages of too many steps
Choosing a step number
Scan types, sort requirements, and locking
Sorts for unindexed or non leading columns
Locking, scans, and sorts during update index statistics
Locking, scans and sorts during update all statistics
Using the with consumers clause
Reducing update statistics impact on concurrent processes
Using the delete statistics command
When row counts may be inaccurate
Using the set statistics Commands
Command syntax
Using simulated statistics
Checking subquery cache performance
Checking compile and execute time
Converting ticks to milliseconds
Reporting physical and logical I/O statistics
Total actual I/O cost value
Statistics for writes
Statistics for reads
Sample output with and without an index
statistics io output for cursors
Scan count
Queries reporting a scan count of 1
Queries reporting a scan count of more than 1
Queries reporting scan count of 0
Relationship between physical and logical reads
Logical reads, physical reads, and 2K I/O
Physical reads and large I/O
Reads and writes on worktables
Effects of caching on reads
statistics io and merge joins
Using set showplan
Using
Basic showplan messages
Query plan delimiter message
Step message
Query type message
FROM TABLE message
FROM TABLE and referential integrity
TO TABLE message
Update mode messages
Direct update mode
Deferred mode
Deferred index and deferred varcol messages
Optimized using messages
Simulated statistics message
Abstract plan messages
showplan messages for query clauses
GROUP BY message
Selecting into a worktable
Grouped aggregate message
Grouped aggregates and group by
compute by message
Ungrouped aggregate message
Ungrouped aggregates
compute messages
messages for order by and distinct
Worktable message for distinct
Worktable message for order by
Sorting messages
Step involves sorting message
GETSORTED message
Serial or parallel sort message
Messages describing access methods, caching, and I/O cost
Auxiliary scan descriptors message
Nested iteration message
Merge join messages
Worktable message
Table scan message
Clustered index message
Index name message
Scan direction messages
Positioning messages
Scanning messages
Index covering message
Keys message
Matching index scans message
Dynamic index message (OR strategy)
Reformatting Message
Trigger Log Scan Message
I/O Size Messages
Cache strategy messages
Total estimated I/O cost message
showplan messages for parallel queries
Executed in parallel messages
Coordinating process message
Worker processes message
Scan type message
Merge messages
Data merge messages
Runtime adjustment message
showplan messages for subqueries
Output for flattened or materialized subqueries
Flattened queries
Materialized queries
Structure of subquery showplan output
Subquery execution message
Nesting level delimiter message
Subquery plan start delimiter
Subquery plan end delimiter
Type of subquery
Subquery predicates
Internal subquery aggregates
Quantified predicate subqueries and the ANY aggregate
Expression subqueries and the ONCE aggregate
Subqueries with distinct and the ONCE-UNIQUE aggregate
Existence join message
Subqueries that perform existence tests
Statistics Tables and Displaying Statistics with optdiag
System tables that store statistics
systabstats table
sysstatistics table
Viewing statistics with the optdiag utility
optdiag syntax
optdiag header information
Table statistics
Sample output for table statistics
Data page CR count
Table-level derived statistics
Data page cluster ratio
Space utilization
Large I/O efficiency
Index statistics
Sample output for index statistics
Index-level derived statistics
Data page cluster ratio
Index page cluster ratio
Data row cluster ratio
Space utilization for an index
Large I/O efficiency for an index
Column statistics
Sample output for column statistics
Range cell and total density values
Range and in-between selectivity values
Histogram displays
Sample output for histograms
Understanding histogram output
Histograms for columns with highly duplicated values
Choosing the number of steps for highly duplicated values
Changing statistics with optdiag
Using the optdiag binary mode
When you must use binary mode
Updating selectivities with optdiag input mode
Editing histograms
Adding frequency count cells to a histogram
Skipping the load-time verification for step numbering
Rules checked during histogram loading
Re-creating indexes without losing statistics updates
Using simulated statistics
optdiag syntax for simulated statistics
Simulated statistics output
Requirements for loading and using simulated statistics
Using simulated statistics in the original database
Using simulated statistics in another database
Dropping simulated statistics
Running queries with simulated statistics
showplan messages for simulated statistics
Character data containing quotation marks
Effects of SQL commands on statistics
How query processing affects systabstats
Tuning with dbcc traceon
Tuning with dbcc traceon(302)
dbcc traceon(310)
Invoking the dbcc trace facility
General tips for tuning with dbcc traceon(302)
Checking for join columns and search arguments
Determining how the optimizer estimates I/O costs
Structure of dbcc traceon(302) output
Additional blocks and messages
Table information block
Identifying the table
Basic table data
Cluster ratio
Partition information
Base cost block
Concurrency optimization message
Clause block
Search clause identification
When search clauses are not optimizable
Values unknown at optimize time
Join clause identification
Sort avert messages
Column block
Selectivities when statistics exist and values are known
When the optimizer uses default values
Unknown values
If no statistics are available
Out-of-range messages
“Disjoint qualifications” message
Forcing messages
Unique index messages
Other messages in the column block
Index selection block
Scan and filter selectivity values
How scan and filter selectivity can differ
Other information in the index selection block
Best access block
dbcc traceon(310) and final query plan costs
Flattened subquery join order message
Worker process information
Final plan information
Sort-merge costs
Monitoring Performance with sp_sysmon
Using
When to run
Invoking
Fixed time intervals
Using begin_sample and end_sample
Specifying report sections for output
Specifying the application detail parameter
Redirecting output to a file
How to use the reports
Reading output
Rows
Columns
Interpreting the data
Per second and per transaction data
Percent of total and count data
Per engine data
Total or summary data
Sample interval and time reporting
Kernel utilization
Sample output
Engine busy utilization
CPU yields by engine
Network checks
Non–blocking
Blocking
Total network I/O checks
Average network I/Os per check
Disk I/O checks
Total disk I/O checks
Checks returning I/O
Average disk I/Os returned
Worker process management
Sample output
Worker process requests
Worker process usage
Memory requests for worker processes
Avg mem ever used by a WP
Parallel query management
Sample output
Parallel query usage
Merge lock requests
Sort buffer waits
Task management
Sample output
Connections opened
Task context switches by engine
Task context switches due to
Voluntary yields
Cache search misses
System disk writes
I/O pacing
Logical lock contention
Address lock contention
Latch contention
Log semaphore contention
PLC lock contention
Group commit sleeps
Last log page writes
Modify conflicts
I/O device contention
Network packet received
Network packet sent
Other causes
Application management
Requesting detailed application information
Sample output
Application statistics summary (all applications)
Priority changes
Allotted slices exhausted
Skipped tasks by engine
Engine scope changes
Per application or per application and login
Application activity
Application priority changes
Application I/Os completed
Resource limits violated
ESP management
Sample output
ESP requests
Avg. time to execute an ESP
Housekeeper task activity
Sample output
Buffer cache washes
Garbage collections
Statistics updates
Monitor access to executing SQL
Sample output
Waits on execution plans
Number of SQL text overflows
Maximum SQL text requested
Transaction profile
Sample output
Transaction summary
How to count multi database transactions
Transaction detail
Inserts
APL heap tables
APL clustered table
Data only lock table
Total rows inserted
Updates and update detail sections
Updates
Data-only-locked updates
Deletes
Total rows deleted
Transaction management
Sample output
ULC flushes to transaction log
By full ULC
By end transaction
By change of database
By system log record and by other
Total ULC flushes
ULC log records
Maximum ULC size
ULC semaphore requests
Log semaphore requests
Log semaphore contention and user log caches
Transaction log writes
Transaction log allocations
Avg # writes per log page
Index management
Sample output
Nonclustered maintenance
Inserts and updates requiring maintenance to indexes
Deletes requiring maintenance
Row ID updates from clustered split
Data-Only-Locked updates and deletes requiring maintenance
Page splits
Reducing page splits for ascending key inserts
Default data page splitting
Effects of ascending inserts
Setting ascending inserts mode for a table
Retries and deadlocks
Add index level
Page shrinks
Index scans
Metadata cache management
Sample output
Open object, index, and database usage
Object and index spinlock contention
Hash spinlock contention
Using sp_monitorconfig to find metadata cache usage statistics
Lock management
Sample output
Lock summary
Lock detail
Address locks
Last page locks on heaps
Table lock hashtable
Deadlocks by lock type
Deadlock detection
Deadlock searches
Searches skipped
Average deadlocks per search
Lock promotions
Lock time-out information
Data cache management
Sample output
Cache statistics summary (all caches)
Cache search summary
Cache turnover
Cache strategy summary
Large I/O usage
Large I/O effectiveness
Asynchronous prefetch activity report
Other asynchronous prefetch statistics
Dirty read behavior
Cache management by cache
Cache spinlock contention
Utilization
Cache search, hit, and miss information
Pool turnover
Buffer wash behavior
Cache strategy
Large I/O usage
Large I/O detail
Dirty read behavior
Procedure cache management
Sample output
Procedure requests
Procedure reads from disk
Procedure writes to disk
Procedure removals
Memory management
Sample output
Pages allocated
Pages released
Recovery management
Sample output
Checkpoints
Number of normal checkpoints
Number of free checkpoints
Total checkpoints
Average time per normal checkpoint
Average time per free checkpoint
Increasing the housekeeper batch limit
Disk I/O management
Sample output
Maximum outstanding I/Os
I/Os delayed by
Disk I/O structures
Server configuration limit
Engine configuration limit
Operating system limit
Requested and completed disk I/Os
Total requested disk I/Os
Completed disk I/Os
Device activity detail
Reads and writes
Total I/Os
Device semaphore granted and waited
Network I/O management
Sample output
Total network I/Os requests
Network I/Os delayed
Total TDS packets received
Total bytes received
Average bytes received per packet
Total TDS packets sent
Total bytes sent
Average bytes sent per packet
Reducing packet overhead
Quick Reference Guide
Reference Manual
About this book
System and User-Defined Datatypes
Datatype categories
Range and storage size
Declaring the datatype of a column, variable, or parameter
Declaring the datatype for a column in a table
Declaring the datatype for a local variable in a batch or procedure
Declaring the datatype for a parameter in a stored procedure
Determining the datatype of a literal
Datatype of mixed-mode expressions
Determining the datatype hierarchy
Determining precision and scale
Converting one datatype to another
Automatic conversion of fixed-length NULL columns
Handling overflow and truncation errors
Standards and compliance
Exact numeric datatypes
Function
Integer types
Decimal datatypes
Standards and compliance
Approximate numeric datatypes
Function
Understanding approximate numeric datatypes
Range, precision, and storage size
Entering approximate numeric data
Values that may be entered by Open Client clients
Standards
Money datatypes
Function
Accuracy
Range and storage size
Entering monetary values
Standards
Timestamp datatype
Function
Creating a timestamp column
Date and time datatypes
Function
Range and storage requirements
Entering datetime and smalldatetime data
Standards and compliance
Character datatypes
Function
Length and storage size
Entering character data
Treatment of blanks
Manipulating character data
Standards
Binary datatypes
Function
Valid binary and varbinary entries
Entries of more than the max column size
Treatment of trailing zeroes
Platform dependence
Standards
bit datatype
Function
Entering data into bit columns
Storage size
Restrictions
Standards
sysname datatype
Function
Using the sysname datatype
Standards
text and image datatypes
Function
Data structures used for storing text and image data
Format of text data pages
Text nodes
Initializing text and image columns
Saving space by allowing NULL
Getting information from sysindexes
Using readtext and writetext
Determining how much space a column uses
Restrictions on text and image columns
Selecting text and image data
Converting text and image datatypes
Pattern matching in text data
Duplicate rows
Standards
User-defined datatypes
Function
Creating frequently used datatypes in the model database
Creating a user-defined datatypes
Renaming a user-defined datatype
Dropping a user-defined datatype
Getting help on datatypes
Standards and compliance
Transact-SQL Functions
Types of functions
Aggregate functions
Aggregates used with group by
Aggregate functions and NULL values
Vector and scalar aggregates
Aggregate functions as row aggregates
Datatype conversion functions
Converting character data to a non-character type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to and from money types
Converting date/time information
Converting between numeric types
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Conversions between binary and integer types
Converting between binary and numeric or decimal types
Converting image columns to binary types
Converting other types to bit
Converting NULL value
Date functions
Date parts
Mathematical functions
Security functions
String functions
Limits on string functions
System functions
Text and image functions
abs
acos
ascii
asin
atan
atn2
avg
ceiling
char
charindex
char_length
col_length
col_name
compare
convert
cos
cot
count
curunreservedpgs
data_pgs
datalength
dateadd
datediff
datename
datepart
db_id
db_name
degrees
difference
exp
floor
get_appcontext
getdate
hextoint
host_id
host_name
index_col
index_colorder
inttohex
isnull
is_sec_service_on
lct_admin
license_enabled
list_appcontext
lockscheme
log
log10
lower
ltrim
max
min
mut_excl_roles
object_id
object_name
pagesize
patindex
pi
power
proc_role
ptn_data_pgs
radians
rand
replicate
reserved_pgs
reverse
right
rm_appcontext
role_contain
role_id
role_name
round
rowcnt
rtrim
set_appcontext
show_role
show_sec_services
sign
sin
sortkey
soundex
space
sqrt
str
stuff
substring
sum
suser_id
suser_name
syb_quit()
syb_sendmsg
tan
textptr
textvalid
to_unichar
tsequal
uhighsurr
ulowsurr
upper
uscalar
used_pgs
user
user_id
user_name
valid_name
valid_user
Global Variables
Adaptive Server’s global variables
Expressions, Identifiers, and Wildcard Characters
Expressions
Size of expressions
Arithmetic and character expressions
Relational and logical expressions
Operator precedence
Arithmetic operators
Bitwise operators
String concatenation operator
Comparison operators
Nonstandard operators
Using any, all and in
Negating and testing
Ranges
Using nulls in expressions
Comparisons that return TRUE
Difference between FALSE and UNKNOWN
Using “NULL” as a character string
NULL compared to the empty string
Connecting expressions
Using parentheses in expressions
Comparing character expressions
Using the empty string
Including quotation marks in character expressions
Using the continuation character
Identifiers
Tables beginning with # (temporary tables)
Case sensitivity and identifiers
Uniqueness of object names
Using delimited identifiers
Identifying tables or columns by their qualified object name
Using delimited identifiers within an object name
Omitting the owner name
Referencing your own objects in the current database
Referencing objects owned by the database owner
Using qualified identifiers consistently
Determining whether an identifier is valid
Renaming database objects
Using multibyte character sets
Pattern matching with wildcard characters
Using not like
Case and accent insensitivity
Using wildcard characters
The percent sign (%) wildcard character
The underscore (_) wildcard character
Bracketed ([ ]) characters
The caret (^) wildcard character
Using multibyte wildcard characters
Using wildcard characters as literal characters
Using square brackets ( [ ] ) as escape characters
Using the escape clause
Using wildcard characters with datetime data
Reserved Words
Transact-SQL reserved words
SQL92 reserved words
Potential SQL92 reserved words
SQLSTATE Codes and Messages
Warnings
Exceptions
Cardinality violations
Data exceptions
Integrity constraint violations
Invalid cursor states
Syntax errors and access rule violations
Transaction rollbacks
with check option violation
Commands
Overview
alter database
alter role
alter table
begin...end
begin transaction
break
case
checkpoint
close
coalesce
commit
compute clause
connect to...disconnect
continue
create database
create default
create existing table
create function (SQLJ)
create index
create plan
create procedure
create procedure (SQLJ)
create proxy_table
create role
create rule
create schema
create table
create trigger
create view
dbcc
deallocate cursor
declare
declare cursor
delete
delete statistics
disk init
disk mirror
disk refit
disk reinit
disk remirror
disk unmirror
drop database
drop default
drop function (SQLJ)
drop index
drop procedure
drop role
drop rule
drop table
drop trigger
drop view
dump database
dump transaction
execute
fetch
goto label
grant
group by and having clauses
if...else
insert
kill
load database
load transaction
lock table
nullif
online database
open
order by clause
prepare transaction
print
quiesce database
raiserror
readtext
reconfigure
remove java
reorg
return
revoke
rollback
rollback trigger
save transaction
select
set
setuser
shutdown
truncate table
union operator
update
update all statistics
update partition statistics
update statistics
use
waitfor
where clause
while
writetext
System Procedures
Introduction to system procedures
Permissions on system procedures
Executing system procedures
Entering parameter values
Messages
System procedure tables
List of system procedures
sp_activeroles
sp_addalias
sp_addauditrecord
sp_addaudittable
sp_addengine
sp_addexeclass
sp_addextendedproc
sp_addexternlogin
sp_addgroup
sp_addlanguage
sp_addlogin
sp_addmessage
sp_addobjectdef
sp_add_qpgroup
sp_addremotelogin
sp_add_resource_limit
sp_addsegment
sp_addserver
sp_addthreshold
sp_add_time_range
sp_addtype
sp_addumpdevice
sp_adduser
sp_altermessage
sp_audit
sp_autoconnect
sp_bindcache
sp_bindefault
sp_bindexeclass
sp_bindmsg
sp_bindrule
sp_cacheconfig
sp_cachestrategy
sp_changedbowner
sp_changegroup
sp_checknames
sp_checkreswords
sp_checksource
sp_chgattribute
sp_clearpsexe
sp_clearstats
sp_client_addr
sp_cmp_all_qplans
sp_cmp_qplans
sp_commonkey
sp_companion
sp_configure
sp_copy_all_qplans
sp_copy_qplan
sp_countmetadata
sp_cursorinfo
sp_dboption
sp_dbrecovery_order
sp_dbremap
sp_defaultloc
sp_depends
sp_deviceattr
sp_diskdefault
sp_displayaudit
sp_displaylevel
sp_displaylogin
sp_displayroles
sp_dropalias
sp_drop_all_qplans
sp_dropdevice
sp_dropengine
sp_dropexeclass
sp_dropextendedproc
sp_dropexternlogin
sp_dropglockpromote
sp_dropgroup
sp_dropkey
sp_droplanguage
sp_droplogin
sp_dropmessage
sp_dropobjectdef
sp_drop_qpgroup
sp_drop_qplan
sp_dropremotelogin
sp_drop_resource_limit
sp_droprowlockpromote
sp_dropsegment
sp_dropserver
sp_dropthreshold
sp_drop_time_range
sp_droptype
sp_dropuser
sp_dumpoptimize
sp_engine
sp_estspace
sp_export_qpgroup
sp_extendsegment
sp_extengine
sp_familylock
sp_find_qplan
sp_fixindex
sp_flushstats
sp_forceonline_db
sp_forceonline_object
sp_forceonline_page
sp_foreignkey
sp_freedll
sp_getmessage
sp_grantlogin
sp_ha_admin
sp_help
sp_helpartition
sp_helpcache
sp_helpconfig
sp_helpconstraint
sp_helpdb
sp_helpdevice
sp_helpextendedproc
sp_helpexternlogin
sp_helpgroup
sp_helpindex
sp_helpjava
sp_helpjoins
sp_helpkey
sp_helplanguage
sp_helplog
sp_helpobjectdef
sp_help_qpgroup
sp_help_qplan
sp_helpremotelogin
sp_help_resource_limit
sp_helprotect
sp_helpsegment
sp_helpserver
sp_helpsort
sp_helptext
sp_helpthreshold
sp_helpuser
sp_hidetext
sp_import_qpgroup
sp_indsuspect
sp_listsuspect_db
sp_listsuspect_object
sp_listsuspect_page
sp_lock
sp_locklogin
sp_logdevice
sp_loginconfig
sp_logininfo
sp_logiosize
sp_modifylogin
sp_modify_resource_limit
sp_modify_time_range
sp_modifystats
sp_modifythreshold
sp_monitor
sp_monitorconfig
sp_object_stats
sp_passthru
sp_password
sp_placeobject
sp_plan_dbccdb
sp_poolconfig
sp_primarykey
sp_processmail
sp_procqmode
sp_procxmode
sp_recompile
sp_remap
sp_remoteoption
sp_remotesql
sp_rename
sp_renamedb
sp_rename_qpgroup
sp_reportstats
sp_revokelogin
sp_role
sp_sendmsg
sp_serveroption
sp_setlangalias
sp_setpglockpromote
sp_setpsexe
sp_set_qplan
sp_setrowlockpromote
sp_setsuspect_granularity
sp_setsuspect_threshold
sp_showcontrolinfo
sp_showexeclass
sp_showplan
sp_showpsexe
sp_spaceused
sp_ssladmin
sp_syntax
sp_sysmon
sp_thresholdaction
sp_transactions
sp_unbindcache
sp_unbindcache_all
sp_unbindefault
sp_unbindexeclass
sp_unbindmsg
sp_unbindrule
sp_volchanged
sp_who
Catalog Stored Procedures
Overview
Specifying optional parameters
Pattern matching
System procedure tables
ODBC datatypes
sp_column_privileges
sp_columns
sp_databases
sp_datatype_info
sp_fkeys
sp_pkeys
sp_server_info
sp_special_columns
sp_sproc_columns
sp_statistics
sp_stored_procedures
sp_table_privileges
sp_tables
System Extended Stored Procedures
Overview
Permissions on system ESPs
DLLs associated with system ESPs
Using system ESPs
xp_cmdshell
xp_deletemail
xp_enumgroups
xp_findnextmsg
xp_logevent
xp_readmail
xp_sendmail
xp_startmail
xp_stopmail
dbcc Stored Procedures
Overview
Specifying the object name and date
Specifying the object name
Specifying the date
sp_dbcc_alterws
sp_dbcc_configreport
sp_dbcc_createws
sp_dbcc_deletedb
sp_dbcc_deletehistory
sp_dbcc_differentialreport
sp_dbcc_evaluatedb
sp_dbcc_faultreport
sp_dbcc_fullreport
sp_dbcc_runcheck
sp_dbcc_statisticsreport
sp_dbcc_summaryreport
sp_dbcc_updateconfig
System Tables
Locations of system tables
System tables in master
System tables in sybsecurity
System table in sybsystemdb
System tables in all databases
About the sybdiagdb database
About the syblicenseslog table
Rules for using system tables
Permissions on system tables
Locking schemes used for system tables
Reserved columns
Updating system tables
Triggers on system tables
Aggregate functions and virtual tables
sysalternates
sysattributes
sysauditoptions
sysaudits_01 – sysaudits_08
syscharsets
syscolumns
syscomments
sysconfigures
sysconstraints
syscoordinations
syscurconfigs
sysdatabases
sysdepends
sysdevices
sysengines
sysgams
sysindexes
sysjars
syskeys
syslanguages
syslisteners
syslocks
sysloginroles
syslogins
syslogs
syslogshold
sysmessages
sysmonitors
sysobjects
syspartitions
sysprocedures
sysprocesses
sysprotects
sysqueryplans
sysreferences
sysremotelogins
sysresourcelimits
sysroles
syssecmechs
syssegments
sysservers
syssessions
syssrvroles
sysstatistics
systabstats
systhresholds
systimeranges
systransactions
systypes
sysusages
sysusermessages
sysusers
sysxtypes
syblicenseslog
dbccdb Tables
dbccdb workspaces
dbccdb log
dbcc_config
dbcc_counters
dbcc_fault_params
dbcc_faults
dbcc_operation_log
dbcc_operation_results
dbcc_types
System Administration Guide
About this book
Audience
How to use this book
Related Documents
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software updates
Conventions used in this manual
Formatting SQL statements
SQL syntax conventions
Case
Obligatory options {you must choose at least one}
Optional options
Ellipsis
Expressions
If you need help
Overview of System Administration
Adaptive Server administration tasks
Roles required for system administration tasks
Database Owner
Database object owner
Using isql to perform system administration tasks
Starting isql
Entering statements
Saving and reusing statements
Using Sybase Central for system administration tasks
System tables
Querying the system tables
Keys in system tables
Updating system tables
System procedures
Using system procedures
System procedure tables
Creating system procedures
System extended stored procedures
Creating system ESPs
Logging error messages
Connecting to Adaptive Server
The interfaces file
Directory services
LDAP as a directory service
Multiple directory services
LDAP directory services versus the Sybase interfaces file
Security features available in Adaptive Server
System and Optional Databases
Overview of system databases
master database
Controlling object creation in master
Backing up master and keeping copies of system tables
model database
sybsystemprocs database
tempdb database
Creating temporary tables
sybsecurity database
sybsystemdb database
pubs2 and pubs3 sample databases
Maintaining the sample databases
pubs2 image data
dbccdb database
sybdiag database
System Administration for Beginners
Logical page sizes
Using “test” servers
Understanding new procedures and features
Planning resources
Achieving performance goals
Installing Sybase products
Check product compatibility
Install or upgrade Adaptive Server
Install additional third-party software
Configure and test client connections
Allocating physical resources
Dedicated vs. shared servers
Decision support and OLTP applications
Advance resource planning
Operating system configuration
Backup and recovery
Keep up-to-date backups of master
Keep offline copies of system tables
Automate backup procedures
Verify data consistency before backing up a database
Monitor the log size
Ongoing maintenance and troubleshooting
Starting and stopping Adaptive Server
Viewing and pruning the error log
Keeping records
Contact information
Configuration information
Maintenance schedules
System information
Disaster recovery plan
Getting more help
Diagnosing System Problems
How Adaptive Server uses error messages to respond to system problems
Error messages and message numbers
Variables in error message text
Adaptive Server error logging
Error log format
Severity levels
Levels 10–18
Level 10: Status information
Level 11: Specified database object not found
Level 12: Wrong datatype encountered
Level 13: User transaction syntax error
Level 14: Insufficient permission to execute command
Level 15: Syntax error in SQL statement
Level 16: Miscellaneous user error
Level 17: Insufficient resources
Level 18: Non-fatal internal error detected
Severity levels 19–26
Level 19: Adaptive Server fatal error in resource
Level 20: Adaptive Server fatal error in current process
Level 21: Adaptive Server fatal error in database processes
Level 22: Adaptive Server fatal error: Table integrity suspect
Level 24: Hardware error or system table corruption
Level 23: Fatal error: Database integrity suspect
Level 25: Adaptive Server internal error
Level 26: Rule error
Reporting errors
Backup Server error logging
Killing processes
Using sp_lock to examine blocking processes
Configuring Adaptive Server to save SQL batch text
Allocating memory for batch text
Configuring the amount of SQL text retained in memory
Enabling Adaptive Server to start saving SQL text
SQL commands not represented by text
Viewing the query plan of a SQL statement
Viewing previous statements
Viewing a nested procedure
Shutting down servers
Shutting down Adaptive Server
Shutting down a Backup Server
Checking for active dumps and loads
Using nowait on a Backup Server
Learning about known problems
Setting Configuration Parameters
Adaptive Server configuration parameters
What are configuration parameters?
The Adaptive Server configuration file
How to modify configuration parameters
Who can modify configuration parameters?
Unit specification using sp_configure
Getting help information on configuration parameters
Using sp_configure
Syntax elements
Parameter parsing
Using sp_configure with a configuration file
Naming tips for the configuration file
Using sp_configure to read or write the configuration file
Parameters for using configuration files
Editing the configuration file
Starting Adaptive Server with a configuration file
The parameter hierarchy
User-defined subsets of the parameter hierarchy: display levels
The effect of the display level on sp_configure output
The reconfigure command
Performance tuning with sp_configure and sp_sysmon
Output from sp_configure
The sysconfigures and syscurconfigs tables
Querying syscurconfigs and sysconfigures: an example
Details on configuration parameters
Renamed configuration parameters
Replaced configuration parameter
Backup and recovery
number of large i/o buffers
print recovery information
recovery interval in minutes
tape retention in days
Cache manager
global async prefetch limit
global cache partition number
memory alignment boundary
number of index trips
number of oam trips
procedure cache size
total data cache size
Component Integration Services administration
cis bulk insert array size
cis bulk insert batch size
cis connect timeout
cis cursor rows
cis packet size
cis rpc handling
enable cis
enable file access
enable full-text search
max cis remote connections
Disk I/O
allow sql server async i/o
disable disk mirroring
disk i/o structures
number of devices
page utilization percent
DTM administration
dtm detach timeout period
dtm lock timeout period
enable DTM
enable xact coordination
number of dtx participants
strict dtm enforcement
txn to pss ratio
xact coordination interval
Error log
event log computer name (Windows NT only)
event logging (Windows NT only)
log audit logon failure
log audit logon success
Extended stored procedures
esp execution priority
esp execution stacksize
esp unload dll
start mail session (Windows NT only)
xp_cmdshell context
General information
configuration file
Java services
enable java
enable enterprise java beans
size of global fixed heap
size of process object heap
size of shared class heap
Languages
default character set id
default language id
default sortorder id
disable character set conversions
Lock Manager
lock address spinlock ratio
number of locks
deadlock checking period
deadlock retries
lock spinlock ratio
lock hashtable size
lock scheme
lock wait period
read committed with lock
lock table spinlock ratio
Memory use
executable codesize + overhead
Metadata caches
number of open databases
number of open indexes
number of open objects
open index hash spinlock ratio
open index spinlock ratio
open object spinlock ratio
Network communication
allow remote access
allow sendmsg
default network packet size
max network packet size
max number network listeners
number of remote connections
number of remote logins
number of remote sites
remote server pre-read packets
syb_sendmsg port number
tcp no delay
O/S resources
max async i/os per engine
max async i/os per server
o/s file descriptors
shared memory starting address
Parallel queries
number of worker processes
max parallel degree
max scan parallel degree
memory per worker process
Physical memory
allocate max shared memory
dynamic allocation on demand
max memory
additional network memory
heap memory per user
lock shared memory
max SQL text monitored
total physical memory
total logical memory
Processors
number of engines at startup
max online engines
RepAgent thread administration
enable rep agent threads
SQL server administration
abstract plan cache
abstract plan dump
abstract plan load
abstract plan replace
allow backward scans
allow nested triggers
allow resource limits
allow updates to system tables
cpu accounting flush interval
cpu grace time
default database size
default fill factor percent
default exp_row_size percent
dump on conditions
enable sort-merge joins and JTC
enable row level access control
enable ssl
event buffers per engine
housekeeper free write percent
enable HA
enable housekeeper GC
identity burning set factor
identity grab size
i/o accounting flush interval
i/o polling process count
page lock promotion HWM
page lock promotion LWM
page lock promotion PCT
maximum dump conditions
number of alarms
number of aux scan descriptors
number of mailboxes
number of messages
number of pre-allocated extents
number of sort buffers
partition groups
partition spinlock ratio
print deadlock information
runnable process search count
size of auto identity column
SQL Perfmon Integration (Windows NT only)
sql server clock tick length
text prefetch size
time slice
upgrade version
row lock promotion HWM
row lock promotion LWM
row lock promotion PCT
license information
Security related
allow procedure grouping
auditing
audit queue size
current audit table
enable ssl
msg confidentiality reqd
msg integrity reqd
secure default login
select on syscomments.text column
suspend audit when device full
systemwide password expiration
unified login required (Windows NT only)
use security services (Windows NT only)
Unicode
default unicode sortorder
enable surrogate processing
enable unicode conversion
enable unicode normalization
size of unilib cache
User environment
number of user connections
permission cache entries
stack guard size
stack size
user log cache size
user log cache spinlock ratio
Limiting Access to Server Resources
What are resource limits?
Planning resource limits
Enabling resource limits
Defining time ranges
Determining the time ranges you need
Creating named time ranges
A time range example
Modifying a named time range
Dropping a named time range
When do time range changes take effect?
Identifying users and limits
Identifying heavy-usage users
Identifying heavy-usage applications
Choosing a limit type
Determining time of enforcement
Determining the scope of resource limits
Understanding limit types
Limiting I/O cost
Identifying I/O costs
Calculating the I/O cost of a cursor
The scope of the io_cost limit type
Limiting elapsed time
The scope of the elapsed_time limit type
Limiting the size of the result set
Determining row count limits
Applying row count limits to a cursor
The scope of the row_count limit type
Setting limits for tempdb space usage
Creating a resource limit
Resource limit examples
Examples
Getting information on existing limits
Example of listing all existing resource limits
Modifying resource limits
Examples of modifying a resource limit
Dropping resource limits
Examples of dropping a resource limit
Resource limit precedence
Time ranges
Resource limits
Configuring Character Sets, Sort Orders, and Languages
Understanding internationalization and localization
Advantages of internationalized systems
A sample internationalized system
Elements of an internationalized system
Selecting the character set for your server
Selecting the server default character set
Selecting the sort order
Using sort orders
Different types of sort orders
Selecting the default sort order
Selecting the default Unicode sort order
Selecting a language for system messages
Setting up your server: examples
A Spanish-version server
A U.S.–based company in Japan
A Japan–based company with multinational clients
Changing the character set, sort order, or message language
Changing the default character set
Changing the default sort order
Reconfiguring the character set, sort order, or message language
Preliminary steps
Setting the user’s default language
Recovery after reconfiguration
Using sp_indsuspect to find corrupt indexes
Rebuilding indexes after changing the sort order
Upgrading text data after changing character sets
Retrieving text values after changing character sets
Installing date strings for unsupported languages
Server versus client date interpretation
Internationalization and localization files
Types of internationalization files
Character sets directory structure
Types of localization files
Software messages directory structure
Message languages and global variables
Configuring Client/Server Character Set Conversions
Character set conversion in Adaptive Server
Supported character set conversions
Conversion for native character sets
Conversion in a Unicode system
Types of character set conversion
Adaptive Server direct conversions
Unicode conversions
Which type of conversion do I use?
Non-Unicode client/server systems
Unicode client/server systems
Configuring the server
Enabling and disabling character set conversion
Characters that cannot be converted
Error handling in character set conversion
Conversions and changes to data lengths
Configuring your system and application
Specifying the character set for utility programs
Display and file character set command-line options
Setting the display character set
Setting the file character set
Security Administration
Security features available in Adaptive Server
General process of security administration
Guidelines for setting up security
Using the “sa” login
Changing the “sa” Login Password
When to enable auditing
Assigning login names
An example of setting up security
Discretionary access controls
Identification and authentication controls
Identification and authentication controls with network based security
Division of roles
Role hierarchy
Mutual exclusivity
Secure Sockets Layer (SSL) in Adaptive Server
Internet communications overview
Public-key cryptography
SSL overview
SSL in Adaptive Server
SSL filter
Authentication via the certificate
Connection types
Enabling SSL
Obtaining a certificate
Creating server directory entries
Administering certificates
Performance
CipherSuites
Network-based security
Auditing
User-defined login security
Setting and changing the maximum login attempts
Locking and unlocking logins and roles
Displaying password information
Checking passwords for at least one digit
Setting and changing minimum password length
Setting the expiration interval for a password
Password expiration turned off for pre-12.x passwords
Message for impending password expiration
Circumventing password protection
Creating a password expiration interval for a new login
Creating a password expiration interval for a new role
Creation date added for passwords
Changing or removing password expiration interval for login or role
Managing Adaptive Server Logins and Database Users
Adding new users: An overview
Choosing and creating a password
Adding logins to Adaptive Server
Creating groups
Adding users to databases
Adding a “guest” user to a database
“guest” user permissions
“guest” user in user databases
“guest” user in pubs2 and pubs3
Creating visitor accounts
Adding remote users
Number of user and login IDs
Limits and Ranges of ID Numbers
Login connection limitations
Viewing Server Limits for Logins, Users, and Groups
Creating and assigning roles to users
Planning user-defined roles
Role hierarchies and mutual exclusivity
Configuring user-defined roles
Creating a user-defined role
Adding and removing passwords from a role
Defining and changing mutual exclusivity of roles
Defining and changing a role hierarchy
Setting up default activation at login
Activating and deactivating roles
Dropping users, groups and user-defined roles
Dropping users
Dropping groups
Dropping user-defined roles
Locking or dropping Adaptive Server login accounts
Locking and unlocking login accounts
Dropping login accounts
Locking logins that own thresholds
Changing user information
Changing passwords
Requiring new passwords
Null passwords
Changing user defaults
Changing a user’s group membership
Changing the user process information
Using aliases in databases
Adding aliases
Dropping aliases
Getting information about aliases
Getting information about users
Getting reports on users and processes
Getting information about login accounts
Getting information about database users
Finding user names and IDs
Displaying information about roles
Finding role IDs and names
Viewing active roles
Displaying a role hierarchy
Viewing user roles in a hierarchy
Determining mutual exclusivity
Determining role activation
Checking for roles in stored procedures
Monitoring license use
How licenses are counted
Configuring License Manager to monitor user licenses
Monitoring license use with the housekeeper task
Logging the number of user licenses
Getting information about usage: Chargeback accounting
Reporting current usage statistics
Displaying current accounting totals
Initiating a new accounting interval
Specifying the interval for adding accounting statistics
Managing User Permissions
Overview
Types of users and their privileges
System Administrator privileges
Permissions for creating databases
System Security Officer privileges
Operator privileges
Database Owner privileges
Permissions on system tables
Permissions on system procedures
Changing database ownership
Database object owner privileges
Privileges of other database users
Granting and revoking permissions on database objects
Granting and revoking object access permissions
Concrete identification
Special requirements for SQL92 standard compliance
Examples of granting object access permissions
Examples of revoking object access permissions
Granting and revoking object creation permissions
Examples of granting object creation permissions
Example of revoking object creation permissions
Combining grant and revoke statements
Understanding permission order and hierarchy
Granting and revoking roles
Granting roles
Understanding grant and roles
Revoking roles
Row-level access control
Access rules
Syntax for access rules
Using access and extended access rules
Access rule examples
Access rules and alter table command
Access rules and bcp
Access rules as user-defined Java functions
Using the Application Context Facility
Setting permissions for using application context functions
Creating and using application contexts
sys_session system application context
Solving a problem using an access rule and ACF
Using login triggers
Creating login triggers
Configuring login triggers
Executing a login trigger
Understanding login trigger output
Using login triggers for other applications
Login trigger restrictions
Issues and information
Disabling execute privilege on login triggers
Acquiring the permissions of another user
Using setuser
Using proxy authorization
Granting proxy authorization
Executing proxy authorization
Proxy authorization for applications
Reporting on permissions
Querying the sysprotects table for proxy authorization
Displaying information about users and processes
Reporting permissions on database objects or users
Reporting permissions on specific tables
Reporting permissions on specific columns
Using views and stored procedures as security mechanisms
Using views as security mechanisms
Using stored procedures as security mechanisms
Roles and stored procedures
Understanding ownership chains
Example of views and ownership chains
Example of procedures and ownership chains
Permissions on triggers
Auditing
Introduction to auditing in Adaptive Server
Correlating Adaptive Server and operating system audit records
The audit system
The sybsecurity database
The audit queue
Auditing configuration parameters
System procedures for auditing
Installing and setting up auditing
Installing the audit system
Tables and devices for the audit trail
Device for the syslogs transaction log table
Installing auditing with installsecurity
Moving the auditing database to multiple devices
Setting up audit trail management
Setting up threshold procedures
Setting auditing configuration parameters
Setting up transaction log management
Truncating the transaction log
Managing the transaction log with no truncation
Enabling and disabling auditing
Single-table auditing
Establishing and managing single-table auditing
Threshold procedure for single-table auditing
What happens when the current audit table is full?
Recovering when the current audit table is full
Setting global auditing options
Auditing options: Types and requirements
Examples of setting auditing options
Determining current auditing settings
Adding user-specified records to the audit trail
Examples of adding user-defined audit records
Querying the audit trail
Understanding the audit tables
Reading the extrainfo column
Managing Remote Servers
Overview
Managing remote servers
Adding a remote server
Examples of adding remote servers
Managing remote server names
Setting server connection options
Using the timeouts option
Using the net password encryption option
Using the rpc security model options
Getting information about servers
Dropping remote servers
Adding remote logins
Mapping users’ server IDs
Mapping remote logins to particular local names
Mapping all remote logins to one local name
Keeping remote login names for local servers
Example of remote user login mapping
Password checking for remote users
Effects of using the untrusted mode
Getting information about remote logins
Configuration parameters for remote logins
Allowing remote access
Controlling the number of active user connections
Controlling the number of remote sites
Controlling the number of active remote connections
Controlling number of preread packets
Using Kerberos, DCE, and Windows NT LAN Manager
Overview
How applications use security services
Login authentication
Message protection
Security services and Adaptive Server
Administering network-based security
Setting up configuration files for security
Preparinglibtcl.cfg to use network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
UNIX platform information
Desktop platform information
The objectid.dat file
Specifying security information for the server
UNIX tools for specifying the security mechanism
Desktop tools for specifying server attributes
Identifying users and servers to the security mechanism
Configuring Adaptive Server for security
Enabling network-based security
Using unified login
Requiring unified login
Establishing a secure default login
Mapping security mechanism login names to server names
Requiring message confidentiality with encryption
Requiring data integrity
Memory requirements for network-based security
Restarting the server to activate security services
Determining security mechanisms to support
Adding logins to support unified login
General procedure for adding logins
Establishing security for remote procedures
Security model A
Security model B
Unified login and the remote procedure models
Establishing the security model for RPCs
Setting server options for RPC security model B
Rules for setting up security model B for RPCs
Preparing to use security model B for RPCs
Example of setting up security model B for RPCs
Getting information about remote servers
Connecting to the server and using the security services
Example of using security services
Using security mechanisms for the client
Getting information about available security services
Determining supported security services and mechanisms
Determining enabled security services
Determining whether a security service Is enabled
Overview of Disk Resource Issues
Device allocation and object placement
Commands for managing disk resources
Considerations in storage management decisions
Recovery
Keeping logs on a separate device
Mirroring
Performance
Status and defaults at installation time
System tables that manage storage
The sysdevices table
The sysusages table
The syssegments table
The sysindexes table
Initializing Database Devices
What are database devices?
Using the disk init command
disk init syntax
disk init examples
Specifying a logical device name with disk init
Specifying a physical device name with disk init
Choosing a device number for disk init
Specifying the device size with disk init
Specifying the dsync setting with disk init (optional)
Performance implications of dsync
Limitations and restrictions of dsync
Other optional parameters for disk init
Getting information about devices
Dropping devices
Designating default devices
Choosing default and nondefault devices
Mirroring Database Devices
What is disk mirroring?
Deciding what to mirror
Mirroring using minimal physical disk space
Mirroring for nonstop recovery
Conditions that do not disable mirroring
Disk mirroring commands
Initializing mirrors
Unmirroring a device
Temporarily deactivating a device
Permanently disabling a mirror
Effects on system tables
Restarting mirrors
waitfor mirrorexit
Mirroring the master device
Getting information about devices and mirrors
Disk mirroring tutorial
Configuring Memory
Determining memory availability for Adaptive Server
How Adaptive Server allocates memory
Disk space allocation
Larger logical page sizes and buffers
Heap memory
Calculating heap memory
How Adaptive Server uses memory
How much memory does Adaptive Server need?
If you are upgrading
Configuration parameters that affect memory allocation
Dynamically allocating memory
If Adaptive Server cannot start
Dynamically decreasing memory configuration parameters
System procedures for configuring memory
Using sp_configure to set configuration parameters
How much memory is available for dynamic growth?
Using sp_helpconfig to get help on configuration parameters
Using sp_monitorconfig to find metadata cache usage statistics
Major uses of Adaptive Server memory
Data and procedure caches
Determining the procedure cache size
Determining the default data cache size
Monitoring cache space
User connections
Open databases, open indexes, and open objects
Number of locks
Database devices and disk I/O structures
Other parameters that use memory
Parallel processing
Worker processes
Partition groups
Remote servers
Number of remote sites
Other configuration parameters for RPCs
Referential integrity
Other parameters that affect memory
Configuring Data Caches
The data cache on Adaptive Server
Cache configuration commands
Information on data caches
Configuring data caches
Explicitly configuring the default cache
Changing the cache type
Configuring cache replacement policy
Dividing a data cache into memory pools
Matching log I/O Size for log caches
Binding objects to caches
Cache binding restrictions
Getting information about cache bindings
Checking cache overhead
How overhead affects total cache space
Dropping cache bindings
Changing the wash area for a memory pool
When the wash area is too small
When the wash area is too large
Changing the asynchronous prefetch limit for a pool
Resizing named data caches
Increasing the size of a cache
Decreasing the size of a cache
Dropping data caches
Changing the size of memory pools
Moving space from the memory pool
Moving space from other memory pools
Adding cache partitions
Setting the number of cache partitions with sp_configure
Setting the number of local cache partitions
Precedence
Dropping a memory pool
When pools cannot be dropped due to pages use
Cache binding effects on memory and query plans
Flushing pages from cache
Locking to perform bindings
Cache binding effects on stored procedures and triggers
Configuring data caches with the configuration file
Cache and pool entries in the configuration file
Cache configuration guidelines
Configuration file errors
Managing Multiprocessor Servers
Parallel processing
Definitions
Target architecture
Configuring an SMP environment
Managing engines
Resetting the number of engines
Choosing the right number of engines
Starting and stopping engines
Monitoring engine status
Starting and stopping engines with sp_engine
Taking engines offline with dbcc engine
Managing user connections
Configuration parameters that affect SMP systems
Configuring spinlock ratio parameters
Creating and Managing User Databases
Commands for creating and managing user databases
Permissions for managing user databases
Using the create database command
create database syntax
How create database works
Adding users to databases
Assigning space and devices to databases
Default database size and devices
Estimating the required space
Placing the transaction log on a separate device
Estimating the transaction log size
Default log size and device
Moving the transaction log to another device
Using the for load option for database recovery
Using the with override option with create database
Changing database ownership
Using the alter database command
alter database syntax
Using the drop database command
System tables that manage space allocation
The sysusages table
The segmap column
The lstart, size, and vstart columns
Getting information about database storage
Database device names and options
Checking the amount of space used
Checking space used in a database
Checking summary information for a table
Checking information for a table and its indexes
Querying system table for space usage information
Setting Database Options
What are database options?
Using the sp_dboption procedure
Database option descriptions
abort tran on log full
allow nulls by default
auto identity
dbo use only
ddl in tran
identity in nonunique index
no chkpt on recovery
no free space acctg
read only
select into/bulkcopy/pllsort
single user
trunc log on chkpt
unique auto_identity index
Changing database options
Viewing the options on a database
Creating and Using Segments
What is a segment?
System-defined segments
Commands and procedures for managing segments
Why use segments?
Controlling space usage
Improving performance
Separating tables, indexes, and logs
Splitting tables
Moving a table to another device
Creating segments
Changing the scope of segments
Extending the scope of segments
Automatically extending the scope of a segment
Reducing the scope of a segment
Assigning database objects to segments
Creating new objects on segments
Placing existing objects on segments
Placing text pages on a separate device
Creating clustered indexes on segments
Dropping segments
Getting information about segments
sp_helpsegment
sp_helpdb
sp_help and sp_helpindex
Segments and system tables
A segment tutorial
Segments and clustered indexes
Using the reorg Command
reorg subcommands
When to run a reorg command
Using the optdiag utility to assess the need for a reorg
Space reclamation without the reorg command
Moving forwarded rows to home pages
Using reorg compact to remove row forwarding
Reclaiming unused space from deletes and updates
Reclaiming unused space and undoing row forwarding
Rebuilding a table
Prerequisites for running reorg rebuild
Changing space management settings before using reorg rebuild
Using the reorg rebuild command on indexes
Syntax
Comments
Limitations
How indexes are rebuilt with reorg rebuild indexname
Space requirements for rebuilding an index
Performance characteristics
Status messages
resume and time options for reorganizing large tables
Specifying no_of_minutes in the time option
Checking Database Consistency
What is the database consistency checker?
Understanding page and object allocation concepts
Understanding the object allocation map (OAM)
Understanding page linkage
What checks can be performed with dbcc?
Checking consistency of databases and tables
dbcc checkstorage
Advantages of using dbcc checkstorage
Comparison of dbcc checkstorage and other dbcc commands
Understanding the dbcc checkstorage operation
Performance and scalability
dbcc checktable
dbcc checkdb
Checking page allocation
dbcc checkalloc
dbcc indexalloc
dbcc tablealloc
Correcting allocation errors using the fix | nofix option
Generating reports with dbcc tablealloc and dbcc indexalloc
Checking consistency of system tables
Strategies for using consistency checking commands
Comparing the performance of dbcc commands
Using large I/O and asynchronous prefetch
Scheduling database maintenance at your site
Database use
Backup schedule
Size of tables and importance of data
Understanding the output from dbcc commands
Errors generated by database consistency problems
Comparison of soft and hard faults
Soft faults
Hard faults
Verifying faults with dbcc checkverify
How dbcc checkverify works
When to use dbcc checkverify
How to use dbcc checkverify
Dropping a damaged database
Preparing to use dbcc checkstorage
Planning resources
Examples of sp_plan_dbccdb output
Planning workspace size
Configuring Adaptive Server for dbcc checkstorage
Configuring worker processes
Setting up a named cache for dbcc
Configuring an 8 page I/O buffer pool
Allocating disk space for dbccdb
Segments for workspaces
Creating the dbccdb database
Updating the dbcc_config table
Maintaining dbccdb
Reevaluating and updating dbccdb configuration
Cleaning up dbccdb
Removing workspaces
Performing consistency checks on dbccdb
Generating reports from dbccdb
To report a summary of dbcc checkstorage operations
To report configuration, statistics and fault information
To see configuration information for a target database
To compare results of dbcc checkstorage operations
To report faults found in a database object
To report statistics information from dbcc_counter
Developing a Backup and Recovery Plan
Keeping track of database changes
Getting information about the transaction log
Synchronizing a database and its log: checkpoints
Setting the recovery interval
Automatic checkpoint procedure
Checkpoint after user database upgrade
Truncating the log after automatic checkpoints
Free checkpoints
Manually requesting a checkpoint
Automatic recovery after a system failure or shutdown
Determining whether messages are displayed during recovery
User-defined database recovery order
Using sp_dbrecovery_order
Changing or deleting the recovery position of a database
Listing the user-assigned recovery order of databases
Fault isolation during recovery
Persistence of offline pages
Configuring recovery fault isolation
Isolating suspect pages
Raising the number of suspect pages allowed
Getting information about offline databases and pages
Bringing offline pages online
Index-level fault isolation for data-only-locked tables
Side effects of offline pages
Recovery strategies using recovery fault isolation
Reload strategy
Repair strategy
Assessing the extent of corruption
Using the dump and load commands
Making routine database dumps: dump database
Making routine transaction log dumps: dump transaction
Copying the log after device failure: dump tran with no_truncate
Restoring the entire database: load database
Applying changes to the database: load transaction
Making the database available to users: online database
Moving a database to another Adaptive Server
Upgrading a user database
Using the special dump transaction options
Using the special load options to identify dump files
Restoring a database from backups
Suspending and resuming updates to databases
Guidelines for using quiesce database
Maintaining server roles in a primary and secondary relationship
Starting the secondary server with the -q option
“in quiesce” database log record value updated
Updating the dump sequence number
Backing up primary devices with quiesce database
Recovery of databases for warm standby method
Making archived copies during the quiescent state
Designating responsibility for backups
Using the Backup Server for backup and recovery
Relationship between Adaptive Server and Backup Servers
Communicating with the Backup Server
Mounting a new volume
Starting and stopping Backup Server
Configuring your server for remote access
Choosing backup media
Protecting backup tapes from being overwritten
Dumping to files or disks
Creating logical device names for local dump devices
Listing the current device names
Adding a backup device
Redefining a logical device name
Scheduling backups of user databases
Scheduling routine backups
Other times to back up a database
Dumping a user database after upgrading
Dumping a database after creating an index
Dumping a database after unlogged operations
Dumping a database when the log has been truncated
Scheduling backups of master
Dumping master after each change
Saving scripts and system tables
Truncating the master database transaction log
Avoiding volume changes and recovery
Scheduling backups of the model database
Truncating the model database’s transaction log
Scheduling backups of the sybsystemprocs database
Configuring Adaptive Server for simultaneous loads
Gathering backup statistics
Backing Up and Restoring User Databases
Dump and load command syntax
Specifying the database and dump device
Rules for specifying database names
Rules for specifying dump devices
Tape device determination by backup server
Tape sevice configuration file
Specifying the compress option
Backup Server dump files and compressed dumps
Loading databases and transaction logs dumped with compress option
Specifying a remote Backup Server
Specifying tape density, block size, and capacity
Overriding the default density
Overriding the default block size
Specifying a higher block size value
Specifying tape capacity for dump commands
Non-rewinding tape functionality for Backup Server
Dump label changes
Tape operations
Dump version compatibility
Specifying the volume name
Loading from a multifile volume
Identifying a dump
Improving dump or load performance
Compatibility with prior versions
Labels stored in integer format
Configuring system resources
Setting shared memory usage
Setting maximum number of stripes
Setting maximum number of network connections
Setting maximum number of service threads
Specifying additional dump devices: the stripe on clause
Dumping to multiple devices
Loading from multiple devices
Using fewer devices to load than to dump
Specifying the characteristics of individual devices
Tape handling options
Specifying whether to dismount the tape
Rewinding the tape
Protecting dump files from being overwritten
Reinitializing a volume before a dump
Dumping multiple databases to a single volume
Overriding the default message destination
Bringing databases online with standby_access
When do I use with standby_access?
Bring databases online with standby_access
Getting information about dump files
Requesting dump header information
Determining the database, device, file name, and date
Copying the log after a device failure
Truncating a log that is not on a separate segment
Truncating the log in early development environments
Truncating a log that has no free space
Dangers of using with truncate_only and with no_log
Providing enough log space
The syslogshold table
Responding to volume change requests
sp_volchanged syntax
Volume change prompts for dumps
Volume change prompts for loads
Recovering a database: step-by-step instructions
Getting a current dump of the transaction log
Examining the space usage
Dropping the databases
Dropping the failed devices
Initializing new devices
Re-creating the databases
Loading the database
Loading the transaction logs
Loading a transaction log to a point in time
Bringing the databases online
Replicated databases
Loading database dumps from older versions
How to upgrade a dump to Adaptive Server
The database offline status bit
Version identifiers
Cache bindings and loading databases
Databases and cache bindings
Database objects and cache bindings
Checking on cache bindings
Cross-database constraints and loading databases
Restoring the System Databases
What does recovering a system database entail?
Symptoms of a damaged master database
Recovering the master database
About the recovery process
Summary of recovery procedure
Step 1: Find copies of system tables
Step 2: Build a new master device
Step 3: Start Adaptive Server in master-recover mode
Step 4: Re-create device allocations for master
Determining which allocations are on the master device
Creating additional allocations
Step 5: Check your Backup Server sysservers information
Step 6: Verify that your Backup Server is running
Step 7: Load a backup of master
Step 8: Update the number of devices configuration parameter
Step 9: Restart Adaptive Server in master-recover mode
Step 10: Check system tables to verify current backup of master
Step 11: Restart Adaptive Server
Step 12: Restore server user IDs
Step 13: Restore the model database
Step 14: Check Adaptive Server
Step 15: Back up master
Recovering the model database
Restoring the generic model database
Restoring model from a backup
Restoring model with no backup
Recovering the sybsystemprocs database
Restoring sybsystemprocs with installmaster
Restoring sybsystemprocs with load database
Restoring system tables with disk reinit and disk refit
Restoring sysdevices with disk reinit
Restoring sysusages and sysdatabase with disk refit
Managing Free Space with Thresholds
Monitoring free space with the last-chance threshold
Crossing the threshold
Controlling how often sp_thresholdaction executes
Rollback records and the last-chance threshold
Calculating the space for rollback records
Using lct_admin to determine the free log space
Determining the current space for rollback records
Effect of rollback records on the last-chance threshold
User-defined thresholds
Last-chance threshold and user log caches for shared log and data segments
Reaching last-chance threshold suspends transactions
Using lct_admin abort to abort suspended transactions
lct_admin abort syntax
Getting the process ID for the oldest open transaction
Using alter database when the master database reaches the last-chance threshold
Automatically aborting or suspending processes
Using abort tran on log full to abort transactions
Waking suspended processes
Adding, changing, and deleting thresholds
Displaying information about existing thresholds
Thresholds and system tables
Adding a free-space threshold
Changing a free-space threshold
Specifying a new last-chance threshold procedure
Dropping a threshold
Creating a free-space threshold for the log segment
Adding a log threshold at 45 percent of log size
Testing and adjusting the new threshold
Creating additional thresholds on other segments
Determining threshold placement
Creating threshold procedures
Declaring procedure parameters
Generating error log messages
Dumping the transaction log
A simple threshold procedure
A more complex procedure
Deciding where to put a threshold procedure
Disabling free-space accounting for data segments
System Tables Diagram
Transact-SQL User's Guide
About this book
SQL Building Blocks
SQL in Adaptive Server
Queries, data modification, and commands
Tables, columns, and rows
The relational operations
Compiled objects
Saving source text
Restoring source text
Verifying and encrypting source text
Naming conventions
SQL data characters
SQL language characters
Identifiers
Using multibyte character sets
Delimited identifiers
Uniqueness and qualification conventions
Identifying remote servers
Expressions in Adaptive Server
Arithmetic and character expressions
Operator precedence
Arithmetic operators
Bitwise operators
The String concatenation operator
The comparison operators
Nonstandard operators
Comparing character expressions
Using the empty string
Including quotation marks in character expressions
Relational and logical expressions
Using any, all, and in
Connecting expressions with and and or
Transact-SQL extensions
The compute clause
Control-of-flow language
Stored procedures
Extended stored procedures
Triggers
Defaults and rules
Error handling and set options
Additional Adaptive Server extensions to SQL
Compliance to ANSI standards
Federal Information Processing Standards (FIPS) flagger
Chained transactions and isolation levels
Identifiers
Delimited identifiers
SQL standard-style comments
Right truncation of character strings
Permissions required for update and delete statements
Arithmetic errors
Synonymous keywords
Treatment of nulls
Adaptive Server login accounts
Group membership
Role membership
Getting information about your Adaptive Server account
Changing your password
Understanding remote logins
Changing your password on a remote server
How to use Transact-SQL with the isql utility
Default databases
Using network-based security services with isql
Logging out of isql
Using the pubs2 and pubs3 sample databases
What is in the sample databases?
Queries: Selecting Data from a Table
What are queries?
select syntax
Choosing columns: the select clause
Choosing all columns: select *
Choosing specific columns
Rearranging the order of columns
Renaming columns in query results
Expressions
Quoted strings in column headings
Character strings in query results
Computed values in the select list
Arithmetic operator precedence
Selecting text and image values
Using readtext
Select list summary
Eliminating duplicate query results with distinct
Specifying tables: the from clause
Selecting rows: the where clause
Comparison operators
Ranges (between and not between)
Lists (in and not in)
Pattern matching
Matching character strings: like
Using not like
not like and ^ may give different results
Using wildcard characters as literal characters
Interaction of wildcard characters and square brackets
Trailing blanks and %
Using wildcard characters in columns
Character strings and quotation marks
“Unknown” values: NULL
Testing a column for null values
Difference between FALSE and UNKNOWN
Substituting a value for NULLs
Expressions that evaluate to NULL
Concatenating strings and NULL
System-generated NULLs
Connecting conditions with logical operators
Logical operator precedence
Using Aggregates, Grouping, and Sorting
Using aggregate functions
Aggregate functions and datatypes
count vs. count (*)
Using aggregate functions with distinct
Null values and the aggregate functions
Organizing query results into groups: the group by clause
group by syntax
group by and SQL standards
Nesting groups with group by
Referencing other columns in queries using group by
Expressions and group by
Nesting aggregates with group by
Null values and group by
where clause and group by
group by and all
Using aggregates without group by
Selecting groups of data: the having clause
How the having, group by, and where clauses interact
Using having without group by
Sorting query results: the order by clause
order by and group by
order by and group by used with select distinct
Summarizing groups of data: the compute clause
Row aggregates and compute
Rules for compute clauses
Specifying more than one column after compute
Using more than one compute clause
Applying an aggregate to more than one column
Using different aggregates in the same compute clause
Grand values: compute without by
Combining queries: the union operator
Guidelines for union queries
Using union with other Transact-SQL commands
Joins: Retrieving Data from Several Tables
How joins work
Join syntax
Joins and the relational model
How joins are structured
The from clause
The where clause
Join operators
Datatypes in join columns
Joins and text and image columns
How joins are processed
Equijoins and natural joins
Joins with additional conditions
Joins not based on equality
Self-joins and correlation names
The not-equal join
Not-equal joins and subqueries
Joining more than two tables
Outer joins
Inner and outer tables
Outer join restrictions
Views used with outer joins
ANSI Inner and outer joins
Correlation name and column referencing rules for ANSI joins
ANSI inner joins
ANSI outer joins
Should the predicate be in the on or where clause?
Nested ANSI outer joins
Converting outer joins with join-order dependency
Transact-SQL outer joins
How null values affect joins
Determining which table columns to join
Subqueries: Using Queries Within Other Queries
How subqueries work
Subquery syntax
Subquery restrictions
Example of using a subquery
Qualifying column names
Subqueries with correlation names
Multiple levels of nesting
Subqueries in update, delete, and insert statements
Subqueries in conditional statements
Using subqueries instead of expressions
Types of subqueries
Expression subqueries
Using scalar aggregate functions to guarantee a single value
group by and having in expression subqueries
Using distinct with expression subqueries
Quantified predicate subqueries
Subqueries with any and all
Subqueries used with in
Subqueries used with not in
Subqueries using not in with NULL
Subqueries used with exists
Subqueries used with not exists
Finding intersection and difference with exists
Using correlated subqueries
Correlated subqueries containing Transact-SQL outer joins
Correlated subqueries with correlation names
Correlated subqueries with comparison operators
Correlated subqueries in a having clause
Using and Creating Datatypes
How Transact-SQL datatypes work
Using system-supplied datatypes
Exact numeric types: integers
Exact numeric types: decimal numbers
Approximate numeric datatypes
Money datatypes
Date and time datatypes
Character datatypes
Unichar datatype
text datatype
Binary datatypes
image datatype
The bit datatype
The timestamp datatype
The sysname datatype
Converting between datatypes
Mixed-mode arithmetic and datatype hierarchy
Working with money datatypes
Determining precision and scale
Creating user-defined datatypes
Specifying length, precision, and scale
Specifying null type
Associating rules and defaults with user-defined datatypes
Creating a user-defined datatype with the IDENTITY property
Creating IDENTITY columns from other user-defined datatypes
Dropping a user-defined datatype
Getting information about datatypes
Creating Databases and Tables
What are databases and tables?
Enforcing data integrity in databases
Permissions within databases
Using and creating databases
Choosing a database: use
Creating a user database: create database
The on clause
The log on clause
The for load option
Altering the sizes of databases
Dropping databases
Creating tables
Maximum number of columns per table
Example of creating a table
Choosing table names
create table syntax
Allowing null values
Constraints and rules used with null values
Defaults and null values
Nulls require variable length datatypes
text and image columns
Using IDENTITY columns
Creating IDENTITY columns with user-defined datatypes
Referencing IDENTITY columns
Referring to IDENTITY columns with syb_identity
Creating “hidden” IDENTITY columns automatically
Using temporary tables
Ensuring that the temporary table name is unique
Manipulating temporary tables in stored procedures
General rules on temporary tables
Creating tables in different databases
Managing identity gaps in tables
Parameters for controlling identity gaps
Comparison of identity burning set factor and identity_gap
Example of using identity burning set factor
Example of using identity_gap
Setting the table-specific identity gap
Setting identity gap with create table
Setting identity gap with select into
Changing the table-specific identity gap
Displaying table-specific identity gap information
Gaps due to insertions, deletions, identity grab size, and rollbacks
If table inserts reach the IDENTITY column’s maximum value
Defining integrity constraints for tables
Specifying table-level or column-level constraints
Creating error messages for constraints
After creating a check constraint
Specifying default column values
Specifying unique and primary key constraints
Specifying referential integrity constraints
Table-level or column-level referential integrity constraints
Maximum number of references allowed for a table
Using create schema for cross-referencing constraints
General rules for creating referential integrity constraints
Specifying check constraints
Designing applications that use referential integrity
How to design and create a table
Make a design sketch
Create the user-defined datatypes
Choose the columns that accept null values
Define the table
Creating new tables from query results: select into
Checking for errors
Using select into with IDENTITY columns
Selecting an IDENTITY column into a new table
Selecting the IDENTITY column more than once
Adding a new IDENTITY column with select into
Defining a column whose value must be computed
IDENTITY columns selected into tables with unions or joins
Altering existing tables
Objects using select * do not list changes to table
Using alter table on remote tables
Adding columns
Adding columns appends column IDs
Adding NOT NULL columns
Adding constraints
Dropping columns
Dropping columns renumbers the column ID
Dropping constraints
Modifying columns
Which datatypes can I convert?
Modifying tables may prevent successful bulk copy of previous dump
Decreasing column length may truncate data
Modifying datetime columns
Modifying the NULL default value of a column
Modifying columns that have precision or scale
Modifying text and image columns
Adding, dropping, and modifying IDENTITY columns
Adding IDENTITY columns
Dropping IDENTITY columns
Modifying IDENTITY columns
Data copying
Changing exp_row_size
Modifying locking schemes and table schema
Altering columns with user defined datatypes
Adding a column with user-defined datatypes
Dropping a column with user-defined datatypes
Modifying a column with user-defined datatypes
Errors and warnings from alter table
Errors and warnings generated by alter table modify
Scripts generated by if exists()...alter table
Renaming tables and other objects
Renaming dependent Objects
Dropping tables
Assigning permissions to users
Getting information about databases and tables
Getting help on databases
Getting help on database objects
Using sp_help on database objects
Using sp_helpconstraint to find a table’s constraint information
Finding out how much space a table uses
Listing tables, columns, and datatypes
Finding an object name and ID
Adding, Changing, and Deleting Data
Introduction
Permissions
Referential integrity
Transactions
Using the sample databases
Datatype entry rules
char, nchar, unichar, univarchar, varchar, nvarchar, and text
datetime and smalldatetime
Entering times
Entering dates
Searching for dates and times
binary, varbinary, and image
money and smallmoney
float, real, and double precision
decimal and numeric
int, smallint, and tinyint
timestamp
Adding new data
insert syntax
Adding new rows with values
Inserting data into specific columns
Restricting column data: rules
Using the NULL character string
NULL is not an empty string
Inserting NULLs into columns that do not allow them
Adding rows without values in all columns
Changing a column’s value to NULL
Adaptive Server-generated values for IDENTITY columns
Explicitly inserting data into an IDENTITY column
Retrieving IDENTITY column values with @@identity
Reserving a block of IDENTITY column values
Reaching the IDENTITY column’s maximum value
Adding new rows with select
Computed columns
Inserting data into some columns
Inserting data from the same table
Changing existing data
update syntax
Using the set clause with update
Assigning variables in the set clause
Using the where clause with update
Using the from clause with update
Updates with joins
Updating IDENTITY columns
Changing text and image data
Deleting data
Using the from clause with delete
Deleting from IDENTITY columns
Deleting all rows from a table
truncate table syntax
Views: Limiting Access to Data
How views work
Advantages of views
Security
Logical data independence
View examples
Creating views
create view syntax
Using the select statement with create view
View definition with projection
View definition with a computed column
View definition with an aggregate or built-in function
View definition with a join
Views used with outer joins
Views derived from other views
distinct views
Views that include IDENTITY columns
After creating a view
Validating a view’s selection criteria using with check option
Views derived from other views
Retrieving data through views
View resolution
Redefining views
Renaming views
Altering or dropping underlying objects
Modifying data through views
Restrictions on updating views
Computed columns in a view definition
group by or compute in a view definition
NULL values in underlying objects
Views created using with check option
Multitable views
Views with IDENTITY columns
Dropping views
Using views as security mechanisms
Getting information about views
Getting help on views with sp_help
Using sp_helptext to display view information
Using sp_depends to list dependent objects
Listing all views in a database
Finding an object name and ID
Using the Built-In Functions in Queries
System functions that return database information
Examples of using system functions
col_length
datalength
isnull
user_name
String functions used for character strings or expressions
Examples of using string functions
charindex, patindex
str
stuff
soundex, difference
substring
Examples of other string functions
Concatenation
Concatenation and the empty string
Nested string functions
Text functions used for text and image data
Readtext
Examples of using text functions
Aggregate functions
Mathematical functions
Examples of using mathematical functions
Date functions
Get current date: getdate
Find date parts as numbers or names
Calculate intervals or increment dates
Add date interval: dateadd
Datatype conversion functions
Supported conversions
Using the general purpose conversion function: convert
Conversion rules
Converting character data to a noncharacter type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to or from money types
Converting date and time information
Converting between numeric types
Converting binary-like data
Converting hexadecimal data
Converting image data to binary or varbinary
Converting between binary and numeric or decimal types
Conversion errors
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Security functions
Creating Indexes on Tables
How indexes work
Comparing the two ways to create indexes
Guidelines for using indexes
When to index
When not to index
Creating indexes
create index syntax
Indexing more than one column: composite indexes
Using the unique option
Including IDENTITY columns in nonunique indexes
Ascending and descending index-column values
Using fillfactor, max_rows_per_page, and reservepagegap
Using clustered or nonclustered indexes
Creating clustered indexes on segments
Creating clustered indexes on partitioned tables
Specifying index options
Using the ignore_dup_key option
Using the ignore_dup_row and allow_dup_row options
Using the sorted_data option
Using the on segment_name option
Dropping indexes
Determining what indexes exist on a table
Updating statistics about indexes
Updating partition statistics
Defining Defaults and Rules for Data
How defaults and rules work
Creating defaults
create default syntax
Binding defaults
Unbinding defaults
How defaults affect NULL values
After creating a default
Dropping defaults
Creating rules
create rule syntax
Binding rules
Rules bound to columns
Rules bound to user-defined datatypes
Precedence of rules
Rules and NULL values
After defining a rule
Unbinding rules
Dropping rules
Getting information about defaults and rules
Using Batches and Control-of-Flow Language
Introduction
Rules associated with batches
Examples of using batches
Batches submitted as files
Using control-of-flow language
if...else
case expression
Using case expression for alternative representation
case and division by zero
Using rand() functions in case expressions
case expression results
case expression requires at least one non-null result
case
case and value comparisons
coalesce
nullif
begin...end
while and break...continue
declare and local variables
goto
return
print
raiserror
Creating messages for print and raiserror
waitfor
Comments
Slash-asterisk style comments
Double-hyphen style comments
Local variables
Declaring local variables
Local variables and select statements
Local variables and update statements
Local variables and subqueries
Local variables and while loops and if…else blocks
Variables and null values
Global variables
Transactions and global variables
Checking for errors with @@error
Checking IDENTITY values with @@identity
Checking the transaction nesting level with @@trancount
Checking the transaction state with @@transtate
Checking the nesting level with @@nestlevel
Checking the status from the last fetch
Global variables affected by set options
Language and character set information in global variables
Global variables for monitoring system activity
Server information stored in global variables
Global variables and text and image data
Using Stored Procedures
How stored procedures work
Examples of creating and using stored procedures
Stored procedures and permissions
Stored Procedures and Performance
Creating and executing stored procedures
Parameters
Default parameters
Using default parameters in stored procedures
NULL as the default parameter
Wildcard characters in the default parameter
Using more than one parameter
Procedure groups
Using with recompile in create procedure
Using with recompile in execute
Nesting procedures within procedures
Using temporary tables in stored procedures
Setting options in stored procedures
Arguments for stored procedures
Length of expressions, variables, and SP arguments
After creating a stored procedure
Executing stored procedures
Executing procedures after a time delay
Executing procedures remotely
Returning information from stored procedures
Return status
Reserved return status values
User-generated return values
Checking roles in procedures
Return parameters
Passing values in parameters
The output keyword
Restrictions associated with stored procedures
Qualifying names inside procedures
Renaming stored procedures
Renaming objects referenced by procedures
Using stored procedures as security mechanisms
Dropping stored procedures
System procedures
Executing system procedures
Permissions on system procedures
Types of system procedures
System procedures for auditing
System procedures used for security administration
System procedures used for remote servers
System procedures for managing databases
System procedures used for data definition and database objects
System procedures used for user-defined messages
System procedures for languages
System procedures used for device management
System procedures used for backup and recovery
System procedures used for configuration and tuning
System procedures used for system administration
System procedures for upgrade
Other Sybase-supplied procedures
Catalog stored procedures
System extended stored procedures
dbcc procedures
Getting information about stored procedures
Getting a report with sp_help
Viewing the source text of a procedure with sp_helptext
Identifying dependent objects with sp_depends
Identifying permissions with sp_helprotect
Using Extended Stored Procedures
Overview
XP Server
Dynamic Link Library Support
Open Server API
Example of creating and using ESPs
ESPs and Permissions
ESPs and Performance
Setting Priority
Freeing Memory
Creating functions for ESPs
Files for ESP Development
Open Server data structures
SRV_PROC
CS_SERVERMSG
CS_DATAFMT
Open Server return codes
Outline of a simple ESP function
Multithreading
ESP function example
Building the DLL
Search order for DLLs
Sample makefile (UNIX)
Sample makefile (Windows NT)
Sample definitions file
Registering ESPs
Using create procedure
Using sp_addextendedproc
Removing ESPs
Renaming ESPs
Executing ESPs
System ESPs
Getting information about ESPs
ESP exceptions and messages
Starting XP Server manually
Triggers: Enforcing Referential Integrity
How triggers work
Using triggers vs. integrity constraints
Creating triggers
create trigger syntax
SQL statements that are not allowed in triggers
Using triggers to maintain referential integrity
Testing data modifications against the trigger test tables
Insert trigger example
Delete trigger examples
Cascading delete example
Restricted delete examples
Update trigger examples
Restricted update triggers
Updating a foreign key
Multirow considerations
Insert trigger example using multiple rows
Delete trigger example using multiple rows
Update trigger example using multiple rows
Conditional insert trigger example using multiple rows
Rolling back triggers
Nesting triggers
Trigger self-recursion
Rules associated with triggers
Triggers and permissions
Trigger restrictions
Implicit and explicit null values
Triggers and performance
set commands in triggers
Renaming and triggers
Trigger tips
Disabling triggers
Dropping triggers
Getting information about triggers
sp_help
sp_helptext
sp_depends
Cursors: Accessing Data Row by Row
How cursors work
How Adaptive Server processes cursors
Declaring cursors
declare cursor syntax
Types of cursors
Cursor scope
Cursor scans and the cursor result set
Making cursors updatable
Determining which columns can be updated
Opening cursors
Fetching data rows using cursors
fetch syntax
Checking the cursor status
Getting multiple rows with each fetch
Checking the number of rows fetched
Updating and deleting rows using cursors
Updating cursor result set rows
Deleting cursor result set rows
Closing and deallocating cursors
An example using a cursor
Using cursors in stored procedures
Cursors and locking
Cursor locking options
Getting information about cursors
Using browse mode instead of cursors
Browsing a table
Browse-mode restrictions
Timestamping a new table for browsing
Timestamping an existing table
Comparing timestamp values
Join cursor processing and data modifications
Updates and deletes that can affect the cursor position
Cursor positioning after a delete or update command without joins
Effects of updates and deletes on join cursors
Effects of join column buffering on join cursors
Effects of column buffering during cursor scans
Recommendations
Transactions: Maintaining Data Consistency and Recovery
How transactions work
Transactions and consistency
Transactions and recovery
Using transactions
Allowing data definition commands in transactions
System procedures that are not allowed in transactions
Beginning and committing transactions
Rolling back and saving transactions
Checking the state of transactions
Nested transactions
Example of a transaction
Selecting the transaction mode and isolation level
Choosing a transaction mode
Transaction modes and nested transactions
Finding the status of the current transaction mode
Choosing an isolation level
Default isolation levels for Adaptive Server and SQL92
Dirty reads
Repeatable reads
Finding the status of the current isolation level
Changing the isolation level for a query
Isolation level precedences
Cursors and isolation levels
Stored procedures and isolation levels
Triggers and isolation levels
Compliance with SQL standards
Using the lock table command to improve performance
Syntax of the lock table command
Using the wait/nowait options of the lock table command
Using transactions in stored procedures and triggers
Errors and transaction rollbacks
Transaction modes and stored procedures
Setting transaction modes for stored procedures
Using cursors in transactions
Issues to consider when using transactions
Backup and recovery of transactions
Locking Commands and Options
Setting a time limit on waiting for locks
wait/nowait option of the lock table command
Setting a session-level lock-wait limit
Setting a server-wide lock-wait limit
Information on the number of lock-wait timeouts
Readpast locking for queue processing
Readpast syntax
Incompatible locks during readpast queries
Allpages-locked tables and readpast queries
Effects of isolation levels select queries with readpast
Session-level transaction isolation levels and readpast
Query-level isolation levels and readpast
Data modification commands with readpast and isolation levels
text and image columns and readpast
Readpast-locking examples
The pubs2 Database
Tables in the pubs2 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
roysched table
discounts table
blurbs table
au_pix table
Diagram of the pubs2 database
The pubs3 Database
Tables in the pubs3 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
store_employees table
roysched table
discounts table
blurbs table
Diagram of the pubs3 database
Troubleshooting and Error Messages Guide
About this book
Audience
What This Guide Contains
Related Documents
Changes to This Book
Your Comments About this Book
Style Conventions
Style Conventions in Text
SQL Syntax Conventions
Electronic Information Sources
If You Need Help
System Database Recovery
Ensuring Recoverability
Finding the Appropriate Recovery Scenario
master Database Is Corrupt and Adaptive Server Does Not Start
Valid Dump of the master Database Exists
Valid Dump of the master Database Does Not Exist
master Database Is Corrupt and Adaptive Server Starts
Valid Dump of the master Database Exists
Valid Dump of the master Database Does Not Exist
Master Device Is Lost and Valid Dump Exists
Valid Dump with Default Sort Order
ASE 12.5 and Later
ASE 12.0.x and Earlier
Valid Dump with Non-Default Sort Order
Master Device Is Lost and Valid Dump Does Not Exist
The model Database Is Lost or Corrupted
ASE 12.5.x and Later
ASE 12.0.x and Earlier
Non-Master Device Containing Pieces of tempdb Is Lost
Master Device Is Going Bad
Adaptive Server Does Not Start After Altering Configuration
Manually Rebuilding Adaptive Server with bcp
Checklist
Considerations
Steps for Rebuilding Adaptive Server
Copy the System Tables to Files
Get Configuration Information and Shut Down the Server
Create New Master Device and Edit the run_server File
Bring Up the Server in Single-User Mode
Copy the Files into the System Tables
Shut Down/Bring Up Adaptive Server in Single-User Mode
Run the Install Scripts for master and model
Shut Down/Bring Up the Server in Multi-User Mode
Verify the Results and Test Applications
If You Cannot Use bcp or a Dump
Encyclopedia of Tasks
Disaster Recovery Tasks
How to Build a New Master Device
ASE 12.5 and Later
ASE 12.0.x and Earlier
How to Rebuild master Database and Leave Master Device Intact
ASE 12.5 and Later
ASE 12.0.x and Earlier
How to Start Adaptive Server in Single-User Mode
Returning Adaptive Server to Multiuser Mode
How to Run the installmaster and installmodel Scripts
How to Load the master Database from Backup
How to Restore System Table Information in master Database
Restoring Device and Database Information in the System Catalog
Re-establishing Adaptive Server Logins
How to Alter the number of devices Parameter Manually
How to Alter tempdb
How to Alter the model Database
How to Reset Adaptive Server to Its Default Configuration
How to Set A Default Backup Server Manually in Adaptive Server
How to Fix Problems Encountered by Disk Refit
Problem 1: Duplicate Keys
Problem 2: Deleted Database dbid
Problem 3: Allocation Pages from Deleted Database
Problem 4: Incomplete sysusages Entries
Queries to Find Suspect sysusages Entries
Avoiding Disaster through Good DBA Practices
Online Recovery and Recovery Fault Isolation
Background
Online Recovery Concepts
Recovery from Backups
Suiciding the Log
Recovery With RFI
Using RFI
What To Do When Online Recovery Fails
Restoring from Backups
Partial online recovery using RFI
Suiciding the Log
RFI Example
How to Manually Change Sort Order or Default Character Set
Manual Process
How to Load a Sort Order or Additional Character Set
How to Change the Sort Order
How to Change the Default Character Set
How to Find a Sort Order File Name
Method 1: If You Know the Sort Order Description
Method 2: If You Know the Sort Order ID
How to Find a Sort Order ID
How to Find a Character Set ID
How to View Your Existing Sort Order and Character Sets
Useful dbcc Commands
Standard dbcc Commands
Other dbcc Commands
dbcc page
dbcc pglinkage
dbcc log
dbcc traceflags
dbcc traceon
dbcc traceoff
dbcc memusage
How to Analyze dbcc checkstorage Faults
Fault Analysis
dbcc checkstorage startup and drop table
Faults Due to sp_placeobject
Troubleshooting XP Server Issues
Background
Correcting Common XP Server Problems
Information to Collect Before Calling Technical Support
Other Useful Tasks
How to Fix a Corrupted Index on System Tables
Read These Warnings First
Repairing the System Table Index
Workaround for sysobjects Nonclustered Indexes
How to Rescue Data from a Corrupted Table
Back Up Data to a New Table
Back Up Data to an Operating System File
How to Start Adaptive Server with Trace Flags
Modifying the RUN_server File to Include Trace Flags for UNIX
Modifying the RUN_server File to Include Trace Flags for Digital OpenVMS
Using the Load Command With Trace Flags in Novell NetWare
Using Trace Flags in OS/2
Using Server Configuration to Include Trace Flags in Windows NT
How to Reload a Suspect User Database
How to Drop a Database When drop database Fails
How to Fix and Prevent Allocation Errors
Understanding Allocation Errors
Fixing Allocation Errors
Fixing Allocation Errors when Object ID and Index ID are Known
Detecting Allocation Errors as Early as Possible
Syntax for dbcc checkalloc with the fix Option
How to Find an Object Name from a Page Number
How to Interpret sp_who Output
Device Administration Issues
How to Choose Between Raw Partitions and UNIX Files
Correct Use of Raw Partitions
Getting Information About Your Partition
Other Situations to Avoid
How to Move a Sybase Device or Database With Disk Mirroring
How to Gather Information About Read/Write Errors
Before You Create and Execute sp_diskblock
How to Mark a Database “suspect'”
Before You Create and Execute sp_marksuspect
After You Execute sp_marksuspect
How to Reset a Database's “suspect” Status
Before You Create and Execute sp_resetstatus
After You Execute sp_resetstatus
Alternative Method of Resetting a Database's “suspect” Status
How to Find a Device's Virtual Device Number
Before You Create and Execute sp_vdevno
How to Detect and Clear Long-Running Transactions
Causes of Long-Running Transactions
Detecting Long-Running Transactions
Clearing Long-Running Transactions
How to Reduce the Size of tempdb
Reset tempdb to Default Size
Verify and Alter tempdb on Desired Devices
How to Remap All Objects in a Database
The Remapping Script
How to Prepare for Analyzing an Optimizer Problem
Terminology
Questions to Ask First
Steps to Take Before Analysis
How to Gather the Information
Understanding the Information You Have Gathered
How to Determine Which Physical Devices a Database is On
How to Identify and Fix a Corrupted Table
How to Monitor the Error Log
Checking the Operating System Error Log
Location of the Operating System Error Log
Types of Problems to Check
How to Obtain a CSMD Dump
How to Configure a Shared Memory Dump on Conditions
Error Message Writeups
Error Message Severity Levels
Variables in Error Message Text
Finding Object Names from Error Message Text
How to Determine Your Adaptive Server Version
Field Order in Version String
Creating Error Messages
Reporting Errors
Faxing Error Log Fragments
Reproducing Problems
Error Message Writeups
Parser Errors
Sequencer Errors
Query Processor Errors
Access Method Errors
Memory Manager Errors
Buffer Manager Errors
Open Database Manager Errors
Page Manager Errors
Lock Manager Errors
Sort Manager Errors
Initialization Errors
Create Utilities Errors
High Availability Utility Errors
Character Set Conversion Errors
dbcc Errors
Insert Errors
Create Utilities Errors (continued)
Procedure Manager Errors
dump and load Errors
Commit and Abort Errors
Recovery Errors
Error and Exception Handling Errors
drop Errors
Transaction Errors
dataserver Errors
dump and load Errors (continued)
truncate table Errors
Bulk Copy Utility Errors
alter table Errors
alter database Errors
Disk Errors
ASTC Errors
Open Client Errors
Configuration Errors
Process Kill Errors
Timestamp Errors
Text Manager Errors
Distributed Database Network Errors
Parser Errors (continued)
Threshold Errors
Auditing Errors
Sequencer Errors (continued)
dbcc Errors (continued)
RPC Errors
Descriptor Manager Errors
sysindexes Manager Errors
Process Status Structure Errors
Site Buffer Manager Errors
Disk Manager Errors
Log Transfer Errors
Configuration Errors (Continued)
Sequencer Errors (continued)
Remote Create Errors
Fault Isolation Utility Errors
Create Utilities Errors (continued)
Sequencer Errors (continued)
System Procedure Errors
Kernel Errors
Backup Server Error Messages
Commonly Encountered Errors
“No language handler installed” Message
LOGCONN Errors in Adaptive Server After Using Backup Server
load {database | transaction} with listonly Locks Database
Some Messages from Backup Server Are Lost
dump database on Digital OpenVMS Alpha/Digital UNIX Raises Error
Error 5704 in the OpenVMS Backup Server error log
Unable to use Async IO when dumping to disk on HP-UX
Maximum Number of DBPROCESSes Already Allocated
Error Conditions Without Messages
Errors in Backup Server Error Log
Net-Library routine net_dict_open failed in srv__open_dictionary
Net-Library routine net_listen failed in srv_start_net
Net-Library routine net_init failed in srv__init_net
No driver of the requested protocol class is available
Net-lib protocol driver call to connect two endpoints failed
Open Server Error Messages Related to Backup Server
Error 5704.10.0
Error 16240.20.0
A Listing of All Backup Server Error Messages
Error Number Format
List of Error Messages
Backup Server Error Messages 1.1.2 - 1.63.2
Backup Server Error Messages 2.1.2 - 3.55.2
Backup Server Error Messages 4.1.2 - 4.75.3
Backup Server Error Messages 4.76.3 - 4.147.2
Backup Server Error Messages 5.1.2 - 6.89.2
Backup Server Error Messages 7.1.2 - 8.17.2
Component Integration Services Error Messages
Component Integration Services Error Messages
Adaptive Server Error Messages
Working with Error Messages
Server Error Messages 1 - 199
Server Error Messages 200 - 299
Server Error Messages 300 - 399
Server Error Messages 400 - 499
Server Error Messages 500 - 599
Server Error Messages 600 - 699
Server Error Messages 700 - 799
Server Error Messages 800 - 899
Server Error Messages 900 - 999
Server Error Messages 1000-1099
Server Error Messages 1100-1199
Server Error Messages 1200-1299
Server Error Messages 1300-1399
Server Error Messages 1500-1599
Server Error Messages 1600-1699
Server Error Messages 1700-1799
Server Error Messages 1800-1899
Server Error Messages 1900-1999
Server Error Messages 2000–2099
Server Error Messages 2100–2199
Server Error Messages 2200–2299
Server Error Messages 2300–2399
Server Error Messages 2400–2499
Server Error Messages 2500–2599
Server Error Messages 2600–2699
Server Error Messages 2700–2799
Server Error Messages 2800–2899
Server Error Messages 2900–2999
Server Error Messages 3000 - 3099
Server Error Messages 3100 - 3199
Server Error Messages 3200 - 3299
Server Error Messages 3300 - 3399
Server Error Messages 3400 - 3499
Server Error Messages 3500 - 3599
Server Error Messages 3600 - 3699
Server Error Messages 3700 - 3799
Server Error Messages 3800 - 3899
Server Error Messages 3900 – 3999
Server Error Messages 4000 – 4099
Server Error Messages 4200 - 4299
Server Error Messages 4300 - 4399
Server Error Messages 4400 - 4499
Server Error Messages 4500 - 4599
Server Error Messages 4600 - 4699
Server Error Messages 4700 - 4799
Server Error Messages 4800 - 4899
Server Error Messages 4900 - 4999
Server Error Messages 5000 - 5099
Server Error Messages 5100 - 5199
Server Error Messages 5200 - 5299
Server Error Messages 5600 - 5699
Server Error Messages 5700 - 5799
Server Error Messages 5800 - 5899
Server Error Messages 5900 - 5999
Server Error Messages 6000 - 6099
Server Error Messages 6100 - 6199
Server Error Messages 6200 - 6299
Server Error Messages 6400 - 6499
Server Error Messages 6500 - 6599
Server Error Messages 6700 - 6799
Server Error Messages 6900 - 6999
Server Error Messages 7000 - 7099
Server Error Messages 7100 - 7199
Server Error Messages 7200 - 7299
Server Error Messages 7300 - 7399
Server Error Messages 7400 - 7499
Server Error Messages 7600 - 7699
Server Error Messages 7700 - 7799
Server Error Messages 7900 - 7999
Server Error Messages 8000 - 8099
Server Error Messages 8200 - 8299
Server Error Messages 8400 - 8499
Server Error Messages 8500 - 8599
Server Error Messages 8600 - 8699
Server Error Messages 8700 - 8799
Server Error Messages 8800 - 8899
Server Error Messages 8900 - 8999
Server Error Messages 9000 - 9099
Server Error Messages 9100 - 9199
Server Error Messages 9200 - 9299
Server Error Messages 9300 - 9399
Server Error Messages 9500 – 9599
Server Error Messages 9600 - 9699
Server Error Messages 9700 - 9799
Server Error Messages 9800 - 9899
Server Error Messages 9900 - 9999
Server Error Messages 10100 - 10199
Server Error Messages 10200 - 10299
Server Error Messages 10300 - 10399
Server Error Messages 10400 - 10499
Server Error Messages 10500 - 10599
Server Error Messages 10600 - 10699
Server Error Messages 10700 - 10799
Server Error Messages 10800 - 10899
Server Error Messages 10900 - 10999
Server Error Messages 11000 - 11099
Server Error Messages 11100 - 11199
Server Error Messages 11200 - 11299
Server Error Messages 11300 - 11399
Server Error Messages 11400 - 11499
Server Error Messages 11500 - 11599
Server Error Messages 11600 - 11699
Server Error Messages 11700 - 11799
Server Error Messages 11900 - 11999
Server Error Messages 12000 - 12099
Server Error Messages 12100 - 12199
Server Error Messages 12200 - 12299
Server Error Messages 12300 - 12399
Server Error Messages 12400 - 12499
Server Error Messages 12500 - 12599
Server Error Messages 12700 - 12799
Server Error Messages 12800 - 12899
Server Error Messages 12900 - 12999
Server Error Messages 13000 - 13099
Server Error Messages 13100 - 13199
Server Error Messages 13200 - 13299
Server Error Messages 13900 - 13999
Server Error Messages 14000 - 14099
Server Error Messages 14100 - 14199
Server Error Messages 14200 - 14299
Server Error Messages 14300 - 14399
Server Error Messages 14400 - 14499
Server Error Messages 17000 - 18999
Glossary
Using Adaptive Server Distributed Transaction Management Features
About this book
Overview
Distributed Transaction Management features
Affected transaction types
Distributed transactions coordinated by external transaction managers
Behavior for transaction manager-coordinated transactions
RPC and CIS transactions
New behavior for RPC and CIS transactions
SYB2PC transactions
Enabling DTM Features
Installing a license key
Enabling DTM features
enable dtm parameter
enable xact coordination parameter
Configuring transaction resources
Calculating required transaction descriptors
Setting the number of transaction descriptors
Using Adaptive Server Transaction Coordination Services
Overview of transaction coordination services
Hierarchical transaction coordination
X/Open XA-compliant behavior in DTP environments
Requirements and behavior
Configuring participant server resources
number of dtx participants parameter
Optimizing number of dtx participants for your system
Using transaction coordination services in heterogeneous environments
strict dtm enforcement parameter
Monitoring coordinated transactions and participants
DTM Administration and Troubleshooting
Transactions and threads of control
Implications for system administrators
dtm detach timeout period parameter
Lock manager changes to support detached transactions
Getting information about distributed transactions
Transaction identification in systransactions
Transaction keys
Viewing active transactions with sp_transactions
Identifying local, remote, and external transactions
Identifying the transaction coordinator
Viewing the transaction thread of control
Understanding transaction state information
Transaction failover information
Determining the commit node and gtrid with sp_transactions
Commit and parent nodes
Global transaction ID
Crash recovery procedures for distributed transactions
Transactions coordinated with MSDTC
Transactions coordinated by Adaptive Server or X/Open XA
Transactions coordinated with SYB2PC
Heuristically completing transactions
Completing prepared transactions
Forgetting heuristically completed transactions
Manually clearing the commit status
Completing transactions that are not prepared
Determining the commit status for Adaptive Server transactions
Using Sybase Failover in a High Availability System
About this book
What is High Availability?
What is High Availability?
Requirements for Failover
Resource Requirements
Applications Running with Sybase’s Failover
How Does Sybase’s Failover Work with High Availability?
Single System Presentation
Special Considerations for Sybase Failover
Using Failover with Disk Mirroring
installhasvss Script
SYB_HACMP Server Entry
Define User-Defined Data types in Adaptive Servers Before Configuring Them for Failover
Adaptive Server and Two-Phase Commit Transactions
Adaptive Server probes
Failover and Failback
What is Failover?
Client Connections During Failover
User Logins in Failover
What is Failback?
Performing Failback
Cluster Locks in a High Availability Node
Asymmetric and Symmetric Setup
Asymmetric and Symmetric Configuration
Asymmetric Companion Configuration
Performance of Adaptive Server in an Asymmetric Configuration
Symmetric Companion Configuration
Performance of Adaptive Server in a Symmetric Configuration
Determining the Name of the Companion Server with @@hacmpservername
Auditing in A High Availability System
Setting Auditing Options
Audit Trails and Sybase Failover
sybsecurity and Sybase Failover
Modes of Failover
What are Modes?
Determining the Companion’s Mode
Determining the Mode with @@cmpstate
The Different Modes of a Companion Server
Domains
Proxy Databases, User Databases, and Proxy System Tables
Proxy Databases
How are Proxy Databases Created?
When Are Proxy Databases Created?
Size of the Proxy Databases
Behavior of Commands and System Procedures in Proxy Databases
Changes to Commands in Proxy Databases
Changes to System Procedures in Proxy Databases
Issuing User-defined Stored Procedures in Proxy Databases
Manually Updating the Proxy Databases
Proxy System Tables in master
Running do_advisory
What is the do_advisory Option?
How Do I Run the do_advisory Option?
Quorum Attributes
Configuring Adaptive Server for Failover on HP
Configure Hardware and Operating System for High Availability
Prepare Adaptive Server to Work with The HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Set the Value of $SYBASE the Same on a Local File System
The sybha Executable
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Configuring HP for Failover
Create the Package Configuration
Edit the ASE_HA.sh Script
Create the Package Control Script
Verify and Distribute the Configuration
Start Up Both the Primary and Secondary Companions
Configure Companion Servers for Failover
Run sp_companion With do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Administering Sybase Failover
Failing Back to the Primary Companion and Resuming Normal Companion Mode
Suspending Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Dropping Companion Mode
Troubleshooting Sybase Failover on HP
Error Message 18750
Recovering from a Failed prepare_failback
Location of Error Logs
Configuring Adaptive Server for Failover on IBM AIX
Configure Hardware and Operating System for High Availability
Requirements for Running Sybase’s Failover on IBM AIX
Special Considerations for Running Adaptive Server on HACMP for AIX
Prepare Adaptive Server to Work with the HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Set $SYBASE the Same on a Local File system
The sybha Executable
Verify Configuration Parameters
Add Thresholds to the Master Log
Create New Default Device Other Than Master
Add The Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Configure the IBM AIX Subsystem for Sybase Failover
Modify the ASE_HA.sh Script
Configure the Resource Groups in HACMP
Configure Companion Servers for Failover
Run sp_companion With do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Bring Up Primary Companion as a Monitored Resource
Administering Sybase Failover
Failing Back to the Primary Node
Manually Failing Back
Suspending Companion Mode
Restarting Shutdown Companion During Suspended Mode
Resuming Normal Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover on HACMP for AIX
Error Message 18750
Recovering From a Failed prepare_failback
Location of Failover Logs
Configuring Adaptive Server for Failover on HP Tru64 TruCluster Server 5.x
Configure Hardware and Operating System for High Availability
Requirements for Running Sybase’s Failover on HP TruCluster
Prepare Adaptive Server to Work with The HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
sybha Executable
Verify Configuration Parameters
Add Thresholds to the Master Log
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Assign ha_role to SA
Run installhasvss to Install HA Stored Procedures
Configure the HP Tru64 Subsystem for Sybase’s Failover
Modify the ASE_HA.sh Script
Modify the ASE_HA.cap profile
Configure Companion Servers for Failover
Run sp_companion with do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Bring Up Primary Companion as a Monitored Resource
Administering Sybase Failover
Failing Back to the Primary Node
Manually Failing Back
Suspending Companion Mode
Restarting Shutdown Companion During Suspended Mode
Resuming Normal Companion Mode
Resuming Normal Companion Mode from Suspended Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover on TruCluster Server for HP Tru64
Error Message 18750
Recovering from a Failed prepare_failback
Location of Failover Logs
Configuring Adaptive Server for Failover on Sun
Hardware and operating system requirements
Prepare Adaptive Server to Work with the HA Subsystem
Install Adaptive Servers
Add Entries for Both Adaptive Servers to the Interfaces File
Add Entries to interfaces File for Client Connections During Failover
Make the Value of $SYBASE the Same for Both Companions
The sybha Executable
Create New Default Device Other Than Master
Add the Local Server to sysservers
Add Secondary Companion to sysservers
Run installhasvss to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Add Thresholds to the Master Log
Configuring the Sun Cluster Subsystem for Sybase Failover
Configure Companion Servers for Failover
Run sp_companion with do_advisory Option
Configure for Asymmetric Configuration
Configure for Symmetric Configuration
Administrating Sybase’s Failover
Failing Back to the Primary Companion
Suspending Normal Companion Mode
Resuming Normal Companion Mode
Dropping Companion Mode
Troubleshooting Failover for Sun Cluster
Recovering from a Failed prepare_failback
Location of the Logs
Configuring Adaptive Server for Failover on Sun Cluster 3.0
Hardware and operating system requirements
Adaptive Server and high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to interfaces file for client connections during failover
Making the value of $SYBASE the same for both companions
Executing sybha
Creating new default devices
Adding the local server to sysservers
Adding secondary companion to sysservers
Assigning ha_role to SA
Installing HA stored procedures
Verifying configuration parameters
Adding thresholds to the master log
Adding user and login for monitoring
Configuring the Sun Cluster subsystem
Configuring Adaptive Server for high availability on Sun Cluster 3.0
Primary server
Secondary server
Configuring companion servers for failover
Setting the HA services library within Adaptive Server
Running sp_companion with do_advisory
Before initiating sp_companion
Configuring for asymmetric configuration
Configuring for symmetric configuration
Administering Sybase Failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Verifying high availability on Sun Cluster 3.0
Troubleshooting
Recovering from a failed prepare_failback
Prevent failover of secondary companion
Changing resource and resource group state
Location of the logs
Configuring Adaptive Server for Failover on Veritas
Hardware and operating system requirements
Adaptive Server and high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to the interfaces file for client connections during failover
Making the value of $SYBASE identical for both companions
Organizing the components of the runserver file
Executing sybha
Creating new default devices
Adding the local server to sysservers
Adding a secondary companion to sysservers
Installing HA stored procedures
Assigning ha_role
Verifying configuration parameters
Adding thresholds to the master log
Configuring the Veritas subsystem
Copying the Sybase agent scripts
Configuring companion servers
Running sp_companion with do_advisory
Verifying the cluster software
Configuring for asymmetric configuration
Configuring for symmetric configuration
Administering Sybase Failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Troubleshooting
Recovering from a failed prepare_failback
Configuring Adaptive Server for Failover on Windows NT
Configure Hardware and Operating System for High Availability
Prepare Adaptive Server for HA Configuration
Install Adaptive Servers
Changing the Domain Administration Account
Add Entries for Both Adaptive Servers to sql.ini
Add Entries to sql.ini for Client Connections During Failover
Create New Default Device Other Than Master
Add Primary Companion as a Local Server
Add Secondary Companion to sysservers
Run insthasv to Install HA Stored Procedures
Assign ha_role to SA
Verify Configuration Parameters
Run sp_companion with do_advisory Option
Configuring Windows NT for Failover
Configure for Asymmetric Configuration from the Command Line
Configure for Symmetric Setup from the Command Line
Configure Windows NT for Failover Using Cluster Administrator
Configuring and Securing Microsoft Cluster Server
Check the MSCS Configuration
Securing the MSCS Cluster
Troubleshooting Sybase Failover on Windows NT
Error Message 18750
Recovering from a Failed prepare_failback
Troubleshooting Second Point of Failures
Troubleshooting with dbcc ha_admin
Re-Installing installmaster and installhasvss
Re-Installing installmaster
Re-Installing installhasvss
Using dbcc ha_admin to Address Second Point of Failures for Failover and prepare_failback
Error Messages 18805, 18769, 18836
Changes to Commands, System Procedures, System Databases, and New dbcc Commands, and Functions
Changes to System Procedures in Adaptive Server Configured for Failover
System Procedures Hold Table Lock When Modifying System Tables
Changes to System Procedures in A Failover Configuration
dbcc Options for High Availability Systems
dbcc dbrepair Option for Sybase Failover
Open Client Functionality in a Failover Configuration
CTLIB Application Changes
Glossary
Utility Guide
About this book
Building Servers Using dataserver
Introduction
Building a new master device
Environments when using dataserver
build mode
start mode
Upgrading to a server with larger page sizes
Viewing the current server limits
Using the isql Utility
Before you begin
Starting and stopping isql
How to use Transact-SQL in isql
Formatting isql output
Correcting input
set options that affect output
Changing the command terminator
Performance statistics interaction with command terminator values
Setting the network packet size
Input and output files
UNIX command-line redirection
Using bcp to Transfer Data to and from Adaptive Server
Methods for moving data
Importing and exporting data with bcp
bcp requirements
bcp modes
bcp performance
Using fast or slow bcp
Copying in data with fast bcp
Bulk copying data into partitioned tables
Monitoring bcp sessions with dbcc checktable and sp_helpsegment
Reducing logging by increasing page allocations
Using parallel bulk copy to copy data into a specific partition
bcp in and locks
Parallel bulk copy methods
Parallel bulk copy syntax
Using parallel bulk copy on partitioned tables
Parallel bulk copy and IDENTITY columns
Using the bcp options
Using the default formats
Native format
Character format
Changing terminators from the command line
Changing the defaults: interactive bcp
Responding to bcp prompts
File storage type
Prefix length
Field length
Field and row terminators
Choosing Terminators
Using format files
Elements of the bcp format file
Examples: copying out data interactively
Copying out data with field lengths
Copying out data with delimiters
Comma-delimited, newline-delimited with format file
Tab-delimited with format file
Examples: copying in data interactively
Copying in data with field lengths
Copying in data with delimiters
Copying in data with a format file
Using bcp with alternate languages
Copy in and batch files
Improving recoverability
Batches and partitioned tables
Copy out and text and image data
Specifying a network packet size
Copy in and error files
Copy out and error files
Data integrity: defaults, rules, and triggers
Defaults and datatypes
Rules and triggers
How bcp differs from other utilities
Using dsedit
Getting started with dsedit
Starting dsedit
Opening an editing session
Adding, viewing, and editing server entries
Modifying server entries in Windows NT
Modifying server entries in UNIX platforms
Adding or editing network transport addresses
SPX/IPX addresses
Copying server entries
Troubleshooting dsedit
The dsedit utility does not start
Error message: “Unable to open X display”
Cannot add, modify, or delete server entries
Using dscp
Getting started with dscp
Using a dscp session
Working with server entries
Adding and modifying server entries
Copying server entries
Listing and viewing contents of server entries
Deleting server entries
Exiting dscp
Quick reference for dscp utility commands
Utility Commands Reference
Getting started
*_dce and *_r utilities
Utilities quick reference
Installation or configuration utilities
Utilities for languages, character sets, and sort orders
Utilities to start servers
Database creation and manipulation utilities
Utilities to gather information
backupserver
bcp
buildmaster
certauth
certpk12
certreq
charset
cobpre
cpre
dataserver
dataxtr
ddlgen
defncopy
dscp
dsedit
extractjava
installjava
isql
langinstall
optdiag
pwdcrypt
showserver
sqldbgr
sqlloc
sqllocres
sqlsrvr
sqlupgrade
sqlupgraderes
srvbuild
srvbuildres
startserver
xpserver
XA Interface Integration Guide for CICS, Encina, and TUXEDO
About this book
Introduction
Requirements
The Sybase XA Environment
Definitions
Overview of the X/Open DTP model
Components of the model
How the components communicate
How the components interact
Recovery
The Sybase XA environment
Components of the Sybase XA environment
Connections in the Sybase XA environment
Identifying connections via LRMs
Where is the connection information stored?
Establishing connections
Distributing work across LRMs
Configuring the XA Environment
Configuring Adaptive Server
Open string parameters for DTM XA Interface
Open string parameters
dtm_tm_role required for username
Log file and trace flag parameters
Labels for logfile entries
xa_open() function behavior
XA configuration file for DTM XA Interface
Environment variable for specifying configuration file
[all] section for defining common LRM parameters
Parameter definitions for [all] section
Editing the XA configuration file
Additional capabilities, properties, and options
Using the DTM XA Interface with CICS
Building the switch-load file
Compiling the switch-load file on IBM RISC System/6000 AIX
Compiling the switch-load file on HP9000 Series 800 HP-UX
Compiling the switch-load file on Sun Solaris 2.x (SPARC)
Adding a Sybase stanza to the CICS region XAD definition
Using the DTM XA Interface with Encina
Assigning an open string with monadmin create rm
Initializing LRMs with mon_RegisterRmi
Linking applications with DTM XA Interface libraries
Establishing connections
Using the DTM XA Interface with TUXEDO
Linking
Setting up the UBBCONFIG file
Creating the TUXEDO configuration file
Building the TMS
Build COBOL runtime environment
Application Programming Guidelines
X/Open DTP versus traditional Sybase transaction processing
Transaction and connection management
Transaction management
Connection management
The current connection
Nontransactional connections
Deallocate cursor function with Client-Library
Dynamic SQL
Getting a Client-Library connection handle
Multiple-thread environment issues
Caveats of thread use
Embedded SQL thread-safe code
Tightly coupled transactions
Linking with CT Library
Sample embedded SQL COBOL fragment
Sample embedded SQL C fragment
What's New in Adaptive Server Enterprise?
About this book
New Features in Adaptive Server Version 12.5
New features in version 12.5
Relaxed server limits
Varying logical page sizes
Number of columns and column size
Maximum length of expressions, variables, and stored procedure arguments
Number of logins
Performance implications of new limits
Dynamic reconfiguration
Dynamic memory allocation
Changes to how memory is allocated
SQLJ stored procedures and functions (Java)
XML in the database
Union in views
Internet directory services (LDAP)
Secure Socket Layers (SSL)
Enterprise Java Beans (EJB Server)
External file system support
Row-level access control
Suspending and resuming updates to databases
Java.net support
Compressed backups
Unichar support
Changes to CIS
SQL debug utility
Migration utility
System Changes in Adaptive Server Version 12.5
System changes in version 12.5
Changes to configuration parameters
New configuration parameters
Changes to configuration parameters
Changes to Transact-SQL commands
New Transact-SQL commands
Changed Transact-SQL commands
New and changed set command options
New Transact-SQL functions
New and changed system procedures
New system procedures
Changed system procedures
New utility programs
Changes to current utility programs
Changes to databases and system tables
New databases
New system tables
Changed system tables
Changed status in existing columns
New reserved words
New global variables
Changes to the documentation
Changes that may effect existing applications
New Transact SQL keywords
Wide column and data truncation
Changes that effect Client Server applications
Using Open Client with Adaptive Server’s new limits
If you use a earlier version of Open Client with Adaptive Server
Maximum number of expressions in a select statement
New Features and System Changes in Adaptive Server Version 12.0
New features in version 12
Sybase’s Failover for a high availability system
Rebuilding indexes
New Backup Server features
High performance backup and restore
Non-rewinding tapes
UNIX file system support
Modifying an existing table’s schema with alter table
Suspending database updates with quiesce database
Taking Adaptive Server engines offline
User settable process information
Identity number gap for tables
Diagnostic database
Java in Adaptive Server Enterprise
Capabilities of Java in Adaptive Server
Java user-defined functions
Java classes as datatypes
Number of tables in a query
Query processing and optimization enhancements
Merge joins
Query costing improvements
ANSI joins
Dynamic execution of Transact-SQL
text and image datatype enhancements
Abstract plans
Disabling triggers
Cache partitions
Distributed Transaction Management
Enhancements to Component Integration Services (CIS)
Network security
Performance considerations
Security features supported in Adaptive Server 12
User-defined login security
Increased maximum number of users and logins
Setting and changing the maximum login attempts
Locking and unlocking logins and roles
Displaying password information
Checking passwords for at least one character
Setting and changing minimum password length
Setting the expiration interval for a password
Concrete identification
System changes in version 12
Changes to configuration parameters
New configuration parameters
Changes to configuration parameters
Changes to Transact-SQL commands
New Transact-SQL commands
Changed Transact-SQL commands
New and changed set command options
New Transact-SQL functions
New and changed system procedures
New system procedures
Changed system procedures
New utility programs
Changes to Databases and System Tables
New Databases
New system tables
Changed System Tables
New reserved words
Changes to the documentation
Changes that may affect existing applications
New Transact-SQL Keywords for 12
dsync On By Default for UNIX File Devices
New Features in Adaptive Server Version 11.9.2
New locking schemes
Changes to table-level locking
Changes to statistics and query optimization
Enhancements to the create index command
Changes and additions to Transact-SQL syntax
New readpast concurrency option
New lock table command
Specifying a wait time for locks
Repeatable read transaction isolation
Configurable database recovery order
Fault verification for dbcc checkstorage faults
License use monitor
Task-to-engine affinity
Dynamic SQL performance improvements
Direct updates through joins
Component Integration Services changes
Character set changes
Changes that may affect existing applications
Effects of changing to data-only-locking
Query optimization changes and forced query plans
Index forcing and data-only-locked tables
Performance after loading pre-11.9 databases
Ordering of results with data-only locked tables
Delay of cursor compilation until cursor open
Visible effects of delayed cursor optimization
New Features in Adaptive Server Release 11.5
New features in release 11.5
Asynchronous prefetch
Auditing enhancements
New system procedures
case expression
Component Integration Services
New commands
New system procedures
Modified system procedures
create index enhancements
dbcc enhancements
Advantages of using dbcc checkstorage
System and stored procedures for creating dbccdb
Stored procedures for maintaining dbccdb
Stored procedures for generating reports on dbccdb
Descending index scan optimization
Directory services
Engine affinity and execution precedence
New system procedures
Expanded error logging
New system procedures
Modified system procedures
Extended Stored Procedures (ESPs)
XP Server
System-defined ESPs
New system procedures for ESPs
Supporting commands
Increased referential integrity limits
Metadata cache management
Monitor access to SQL batch text
Allocating memory for batch text
New columns in sysprocesses
Parallel bulk copy
Parallel queries and enhanced partitioning
Point-in-time recovery
Proxy authorization
Recovery fault isolation
New system procedures
Side effects of recovery fault isolation
Relaxed LRU cache replacement policy
Resource limits
New system procedures
Supporting commands
Source text verification and encryption
Sybase Central
sp_sysmon
Two-phase commit enhancements
spt_comittab moved to sybsystemdb
Commit identifier changed to a random value
User-defined roles
Windows NT event log integration
Supporting system ESPs and system procedures
Windows NT MAPI support
Supporting system ESPs and system procedures
Windows NT Performance Monitor integration
Supporting system procedure
New Features in SQL Server Release 11.0
New features in release 11.0
User-defined caches
Configuring caches
Binding objects to user-defined caches
Cache strategies
Large I/O
Changing the log I/O size
New query tuning options
Data storage changes
Maximum number of rows per page
Page allocation
Partitioned tables
Transaction log changes
User log caches
syslogshold table
Isolation level 0
Lock manager changes
Table, page, and address lock tables
Deadlock checking
New engine freelock lists
Increasing the engine freelock lists
Housekeeper task
SQL Server configuration
Lock escalation
Multiple network engines
Improvements to showplan
Query and data modification changes
Subquery changes
Update changes
Upgrading database dumps
Tape device determination by Backup Server
IDENTITY column changes
New text and image global variables
System changes in release 11.0
New online database command
Changes to existing commands
New set options
New system procedures
Changes to system procedures
New system tables
Changes to existing system tables
Changes that may affect existing applications
New Transact-SQL keywords in release 11.0
Changes to SQL Server configuration
The reconfigure command
buildmaster -r no longer supported
New names for existing configuration parameters
New configuration parameters
New deadlock checking period parameter
New page utilization percent parameter
Compiled object sizes have grown
SQL Server code size has grown
Subquery changes
Different results
Changes in subquery restrictions
Handling NULL results
Improved performance
Changes to showplan output in release 11.0
New caching strategies may affect performance
Upgrading database dumps
Partitions and physical data placement
Adaptive Server Enterprise 12.5.3 (Chinese-Simplified)
New Features Adaptive Server Enterprise 12.5.3a
New Features Adaptive Server Enterprise 12.5.3a
Adaptive Server Enterprise 12.5.3 (French)
New Features Adaptive Server Enterprise 12.5.3
New Features Adaptive Server Enterprise 12.5.3a
New Features Adaptive Server Enterprise 12.5.3
New Features Adaptive Server Enterprise 12.5.3a
Adaptive Server Enterprise 15.0
Release Bulletin ASE 15.0 for IBM AIX
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
The wrong version of auditinit was shipped with Adaptive Server version 15.0
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
Specifying the SunJCE cipher provider
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for HP-UX
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Sybase Software Asset Management instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Creating the uninstaller
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
SSL unavailable
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
IPv6 support causes Adaptive Server to hang
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Using jConnect and Adaptive Server
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for HP Itanium
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Disabling High Availability during upgrade
Upgrading High Availability and cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling from HP-UX 11.23
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Highlighted known Web Services problems
Alias names limited to 255 characters
Known alter table problems
alter table unpartition errors
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
Replication Server compatibility issues
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
bcp in or bcp out
Silent installation
Sybase Central
File names
table scan and index scan
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Linux
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special SySAM instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be acquired
Acquiring SySAM licenses within a grace period
SySAM Limitations
Special installation instructions
Limitations
Runtime libraries required for Linux on Power installation
Special upgrade instructions
Upgrading compiled objects
Upgrading compiled objects
Product and platform interoperability
Changes that affect existing applications
Installation, upgrade, and migration
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Installation issues
ClearCase causes InstallShield to stops responding
Uninstalling Adaptive Server
Running on RH3.0 64-bit distribution occasionally stops responding
Adaptive Server Replicator 15.0 supports only Adaptive Server 12.5 datatypes
XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Interactive SQL and Adaptive Server plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
Inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross-platform loads
Running dbcc checktable or dbcc checkdb before bringing a database online
Recovering from an upgrade during an online database command
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Replication Server compatibility issues
Blank spaces in an ldap server entry
Dumping or loading databases with asynchronous I/O
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Network package reallocation during reconfiguration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
jConnect 6.0 and sqldbgr
Installing Replication Server with other Sybase software
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for Linux Opteron
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Runtime libraries required for Linux on Power installation
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Upgrading compiled objects
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
ClearCase causes InstallShield to stop responding
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Known alter table problems
alter table unpartition errors
Running on RH3.0 64-bit distribution occasionally stops responding
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
IPv6 support causes Adaptive Server Enterprise to stop responding
Replication Server compatibility issues
Dumping or loading databases with asynchronous I/O
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Network package reallocation during reconfiguration
bcp in or bcp out
Silent installation
Sybase Central
File names
Command line flag -k
table scan and index scan
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
jConnect 6.0 and sqldbgr
Installing Replication Server with other Sybase software
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Sun Solaris
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management (SySAM) instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for Sun Solaris AMD
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Known alter table problems
alter table unpartition errors
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Adaptive Server Enterprise plug-in shows incorrect status for Job Scheduler task
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
IPv6 support causes Adaptive Server Enterprise to stop responding
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
bcp in or bcp out
Silent installation
Sybase Central
File names
Command line flag -k
table scan and index scan
Indexes
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Copy menu
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Windows
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management (SySAM) instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be acquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Syntax error in the Job Scheduler utility scripts
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
Messaging functionality
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Quick Installation Guide for Linux
About this book
Installing Adaptive Server
Adaptive Server editions
Adaptive Server Enterprise Express Edition
Adaptive Server Enterprise Developer Edition
Adaptive Server Enterprise (Enterprise Edition for evaluation)
System requirements
Pre-installation tasks for a fresh installation
Pre-installation tasks for an overlay installation
Installing Adaptive Server
Changing default character set, sort order or language
Changing the default character set and sort order
Changing the default language
Post-installation tasks for an overlay installation
Running the installmaster script
Running the installcommit script
Running the installsecurity script
Running the instmsgs.ebf script
Running the installjsdb script
Upgrading Job Scheduler Templates
Running the installmontables script
Reverting to the previously installed release
Quick Installation Guide for Windows
About this book
Installing Adaptive Server
Adaptive Server editions
Adaptive Server Enterprise Developer Edition
Adaptive Server Enterprise (Enterprise Edition for evaluation)
System requirements
Pre-installation tasks for a fresh installation
Pre-installation tasks for an overlay installation
Installing Adaptive Server
Changing default character set, sort order or language
Changing the default character set and sort order
Changing the default language
Post-installation tasks for an overlay installation
Running the installmaster script
Running the installcommit script
Running the installsecurity script
Running the instmsgs.ebf script
Running the installjsdb script
Upgrading Job Scheduler Templates
Running the installmontables script
Reverting to the previously installed release
Installation Guide for IBM AIX
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Moving to Adaptive Server 15.0 on AIX 5.2 64-bit
Upgrade to Adaptive Server release 15.0 on a new machine running IBM AIX 5.2
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for HP
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for Linux
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Express Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Creating Raw Partitions
Overview
Creating the partitions
Red Hat Raw device administration
SuSE raw device administration
Accessing raw devices from Adaptive Sever
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Backup Server Tape Device Support
Installation Guide for Sun Solaris
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for Windows
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Post installation instructions
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Note server and device names and locations
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Upgrading the server
Testing the Adaptive Server upgrade
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Fatal error: cannot map libct.so
Adaptive Server fails to start
The Installer fails to start
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an old server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Resource file variables
Running the sybatch utility
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Configuration Guide for UNIX
About this book
Introduction
About Adaptive Server
System-specific issues
System user roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
dsync option on by default for database device files
Determining the location, type, and size of a database device
For Solaris, HP-UX, IBM AIX, and Linux
For All Platforms
Client/server communication
Changing Adaptive Server configuration
Languages other than U.S. English
Adaptive Server specifications
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Using a RUN_server_name file
Using the startserver command
Using the monserver and backupserver commands
Starting servers when the operating system restarts
For HP-UX
For IBM RS/6000
For Sun Solaris and Linux
Starting XP Server after initial installation
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Configuring the Operating System
Setting environment variables
Configuring new servers with srvbuild
Using the stty setting
Restoring correct permissions
File descriptors and user connections
For HP-UX
For AIX
For Linux
For Sun Solaris
Displaying current soft and hard limits
Increasing the soft limit
Increasing the hard limit
Sample program
Enabling asynchronous disk I/O
Adjusting the client connection timeout period
For HP-UX
For IBM RS/6000
For Sun Solaris
For Linux
Checking for hardware errors
For HP-UX
For IBM RS/6000
For Sun Solaris
For Linux
Monitoring the use of operating system resources
For HP-UX
For IBM RS/6000
For Sun Solaris and Linux
A sample C shell maintenance script
Adaptive Server Default Configuration
Default settings
Setting Up Communications Across the Network
How Adaptive Server determines which directory service entry to use
How a client uses directory services
Creating a directory services entry
Supported directory drivers
Contents of an interfaces file
Heterogeneous and homogeneous environments
Understanding the format of the interfaces file
Components of an interfaces file entry
Creating a master interfaces file
Using dsedit or dscp to create a master interfaces file
Using a text editor to create a master interfaces file
Configuring interfaces files for multiple networks
Configuring the server for multiple network handlers
Sample interfaces files for multiple network handlers
Configuring the client connections
Using one network-independent DSQUERY name
Using different DSQUERY names
Configuring for query port backup
IPv6 support
Understanding IPv6
IPv6 infrastructure
Starting Adaptive Server Enterprise as IPv6-aware
Troubleshooting
Server fails to start
Error when executing an ESP
Using the Lightweight Directory Access Protocol as a Directory Service
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl*.cfg file
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the interfaces file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default language and character set
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
Adaptive Server localization
Backup Server localization
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Adaptive Server error logging
Enabling and disabling error logging
Setting error log paths
Setting the Adaptive Server error log path
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating files for database devices
Adding Optional Functionality to Adaptive Server
Adding auditing
Audit system devices and databases
Overview of audit installation
Pre-installation tasks for auditing devices
Installing auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuration Guide for Windows
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication (the interfaces file)
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Adaptive Server specifications
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Starting and stopping servers using Unified Agent
Starting and stopping servers using the Control Panel
Starting servers as an automatic service
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Monitoring servers
Unified Agent
The Control Panel
Default Adaptive Server Configuration
Starting Server Config for Adaptive Server
Configuring Adaptive Server
Setting Adaptive Server parameters
Changing the default Backup Server
Changing the default XP Server
Configuring Backup Server
Configuring Monitor Server
Supporting access to large memory
Configuring Job Scheduler and Self Management
Network Communications Using sql.ini
How clients connect to Adaptive Server
How Adaptive Server listens for client connections
How a client accesses Adaptive Server
Enabling client access to a server
Changing the server entries in sql.ini
Components in the sql.ini file
Server name
Network driver
Service type
Server address
Address format
IP address
Named Pipes format
Windows Sockets format
NWLink IPX/SPX format
Sharing network configuration information
Creating a master sql.ini file
Using Windows Registry as a directory service
Verifying server connections
Configuring ODBC connections
Configuring the ODBC driver
IPv6 support
Understanding IPv6
IPv6 infrastructure
Starting Adaptive Server Enterprise as IPv6-aware
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg file
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the sql.ini file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Logging errors and events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
Windows event-logging
Setting up Windows event-logging for use by Adaptive Server
Types of information logged
Managing the logs
Setting error log paths
Setting the Adaptive Server error log path
Setting the Backup Server error log path
Setting the Monitor Server error log path
Enabling and disabling Windows event logging
Using Server Config
Using sp_configure
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Logging user-defined events
Using a remote log
Using a central logging site
Logging messages from multiple Adaptive Servers
Setting up a local central logging site
To create and define a Registry key
Viewing the messages
In the Windows event log
In the Adaptive Server error log
Using Security Services with Windows LAN Manager
Security services with Windows LAN Manager
How login authentication works
Administering security services using LAN Manager
Modifying configuration files for a unified login
Setting up drivers for network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
Checking the LAN Manager’s local name
Specifying security information for Adaptive Server
Identifying users and servers to LAN Manager
Configuring Adaptive Server for LAN Manager security
Enabling and disabling external security services
Managing unified login
Requiring unified login
Establishing a secure default login
Mapping LAN Manager login names to server names
Requiring data integrity check
Ensuring adequate memory for security services
Initiating the new security services
Adding logins to support unified login
General procedure for adding logins
Defining the connection to a server for security services
Specifying the principal name
Specifying network-based user authentication
Specifying the name assigned to LAN Manager
Determining the status of security services
Configuration parameters used in security services
Checking data integrity
Checking message sequence
Detecting interception or replay
Specifying a login
Controlling user authentication
Managing login security on an Windows computer
Overview of security features
Adaptive Server security
Combined Adaptive Server and Windows login security
Standard mode
Integrated mode
Mixed mode
Managing the login security features
Permitting trusted connections
Windows Registry parameters
Administering login security using system procedures
Assigning trusted connection permissions
Displaying the current Registry values
Displaying permissions and user names
Revoking permissions granted with sp_grantlogin
Configuring login security
Create Windows users and groups
Configure mapping and Default Domain values
Set login security mode
Add network login names to syslogins
Assign roles
Changing login security options
Using E-mail with Adaptive Server
Sybmail messages
Sending messages
Receiving messages
Preparing Windows Mail for Sybmail
Connecting to a post office
Creating a mailbox for Adaptive Server
Creating a mail profile for Adaptive Server
Creating an Adaptive Server login for Sybmail
Sybmail and extended stored procedures
Managing a mail session
Starting a session
Starting Sybmail without parameters
Stopping a mail session
Stored and extended procedures for handling messages
Sending messages
Text messages
Query result messages
Receiving messages
Finding the next message
Reading a specific message
Deleting a message
Processing incoming mail
Using Sybmail security
Setting execution privileges
Setting the execution context
Naming both the user and the database
Naming the user but not the database
Naming the database but not the user
Naming neither the user nor the database
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
Windows tape drive names
Setting the maximum capacity for a tape drive
Using a hard disk
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Optimizing Adaptive Server performance and tuning
Using dedicated Adaptive Server operation
Using disk drives
Monitoring disk usage
Monitoring Adaptive Server statistics with Windows Performance Monitor
Adding Optional Functionality to Adaptive Server
Installing auditing
Audit system devices and databases
The sybsecurity device and database
Tables and devices for the audit trail
Device for syslogs systems table
Pre-installation tasks for auditing devices
Installing Auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Troubleshooting Network Connections
The dsedit Server Ping Utility
Running Server Ping
Troubleshooting connection failures
When a test fails
Using returned messages to diagnose a failure
Failure to connect to Adaptive Server
Failure to load Net-Library DLLs
Failure of other applications
Before calling Sybase Technical Support
Adaptive Server Registry Keys
ASE Replicator User's Guide
About this book
Introduction to ASE Replicator
Understanding replication concepts
Table replication
Stored procedure replication
Transaction replication
Guaranteed delivery
Understanding ASE Replicator
ASE Replicator components
ASE Replicator process
Distribution Database
Publisher component
Distributor component
ASE Replicator processing
ASE Replicator objects
Database connections
Publications and subscriptions
Articles
Fields
ASE Replicator limitations
Setting Up and Starting ASE Replicator
Setting up ASE Replicator
Configuring the primary Adaptive Server
Enabling and configuring CIS
Setting up the ASE Replicator system user
Defining a local name and remote alias for the primary Adaptive Server
Defining a remote server name for the ASE Replicator process
Creating the Distribution Database
Configuring the replicate servers and databases
Identifying the remote server
Setting up a separate a Maintenance User login
Granting permissions in the replicate database
Initializing the ASE Replicator process
Running the aserep script the first time
UNIX permissions
Setting up the sp_helpddb system procedure
Starting ASE Replicator
Using the aserep script
Using the RUN script
Setting up a replication system
Uninstalling ASE Replicator
Administering ASE Replicator
Administering the ASE Replicator process
Configuring ASE Replicator
Shutting down the ASE Replicator process
Suspending replication
Resuming replication
Monitoring ASE Replicator
Managing database connections
Creating a database connection
Creating a primary database connection
Creating a replicate database connection
Deleting a database connection
Configuring a database connection
Suspending and resuming database connections
Suspending database connections
Resuming database connections
Getting information about database connections
Getting metadata and status information for connections
Getting statistics information for connections
Getting connection configuration information
Managing publications and subscriptions
Creating publications and subscriptions
Deleting publications and subscriptions
Suspending and resuming subscriptions
Getting information about publications and subscriptions
Managing primary and replicate articles
Creating primary articles
Creating replicate articles
Deleting primary articles
Deleting replicate articles
Materializing and validating replicate articles
Getting information about primary articles
Getting metadata information for primary articles
Getting information about published fields in primary articles
Getting information about primary articles in publications
Getting information about unpublished objects
Getting information about primary articles with no subscribers
Getting information about replicate articles
Getting replicate article metadata information
Getting information about fields in replicate articles
Getting information about replicate articles in subscriptions
ASE Replicator configuration parameters
General configuration parameters
admin_port
ase_charset
ase_host
ase_port
batch_size
batch_timeout
ddb_name
log_directory
log_trace_verbose
log_wrap
monitor_delay
queue_size
scan_sleep_increment
scan_sleep_max
stat_trunc_interval
stat_write_timeout
status_monitoring
truncate_numops
Connection configuration parameters
gen_id
lti_version
mode
numrecs
queue_size
scan_sleep_increment
scan_sleep_max
timeout
ASE Replicator Procedures
sp_addprimaryart
sp_addprimaryconn
sp_addpub
sp_addreplicateart
sp_addreplicateconn
sp_addsub
sp_configprimaryconn
sp_configrep
sp_configreplicateconn
sp_dropprimaryart
sp_dropprimaryconn
sp_droppub
sp_dropreplicateart
sp_dropreplicateconn
sp_dropsub
sp_helpconn
sp_helplastcommit
sp_helplocator
sp_helpprimaryart
sp_helpprimaryconn
sp_helppub
sp_helprep
sp_helpreplicateart
sp_helpreplicateconn
sp_helpsub
sp_materializesub
sp_resumeprimaryconn
sp_resumerep
sp_resumereplicateconn
sp_resumesub
sp_shutdownrep
sp_suspendprimaryconn
sp_suspendrep
sp_suspendreplicateconn
sp_suspendsub
sp_tracerep
sp_validatesub
Troubleshooting ASE Replicator
Problems that prevent replication from starting
Primary server configuration problems
Adaptive Server character set problems
Remote server configuration problems
ASE Replicator configuration problems
User login or permission problems
Problems that cause replication to fail
Schema changes in primary or replicate tables
Altering a published primary object
Altering a replicate object
Datatypes, constraints, and column properties
Replicating approximate numeric datatypes
Replicating the value of the timestamp datatype
Replicating IDENTITY columns
Incompatible datatypes
Incompatible primary key constraints
Different null types
Java memory problems
Other problems and issues
Subscription status after abnormal shutdown
Distribution Database Schema
Distribution Database base objects
Distribution Database datatypes
Base tables in the Distribution Database
Distribution Database system table
Connections table
Connection properties table
Publications table
Primary articles table
Primary article fields table
Primary articles/publications relation table
Subscriptions table
Replicate articles table
Replicate article fields table
Transaction log table
Configuration table
Trace table
Statistics table
Truncation table
Base procedures in the Distribution Database
Distribution Database shadow tables
Shadow tables for primary tables without large objects
Shadow tables for primary tables with large objects
Shadow tables for primary procedures
Distribution Database replicate objects
Distribution procedures
Replicate article proxy tables
Glossary
Component Integration Services User's Guide
About this book
Introduction
Understanding Component Integration Services
Basic concepts
Access methods
Server classes
Object types
Interface to remote servers
Proxy tables
Using the create table command
Using the create existing table command
Datatype conversions
Example of remote table definition
Using the create proxy_table command
Remote procedures as proxy tables
Server limits
create new proxy table
create existing proxy table
create proxy_table
alter table
select, insert, delete, update
RPC handling
sp_tables
Cascading proxy tables
Proxy databases
User proxy databases
User proxy database schema synchronization
System proxy databases
System proxy database creation
Schema synchronization when current database has a system proxy database
Stored procedure execution within a system proxy database
Additional behavior of the system proxy database
File system access
Security considerations
Directory access
Recursion through subordinate directories
File access
Remote servers
Server class ASEnterprise
Server class ASAnywhere
Server class ASIQ
Server class direct_connect
Server class sds
Connection management
Connecting to remote servers without the interfaces file
LDAP directory services
Secure communication with SSL
Trusted roots files
Security issues
Remote server logins
Trusted mode
Connecting to Backup Server and XP Server
Mapping external logins
Remote server connection failover
Remote server capabilities
Query processing
Processing steps
Query parsing
Query normalization
Query preprocessing
Decision point
Component Integration Services plan generation
Adaptive Server optimization and plan generation
Component Integration Services plan generation
Component Integration Services remote location optimizer
Query plan execution
RPC handling and Component Integration Services
Site handler and outbound RPCs
Component Integration Services and outbound RPCs
Text parameters for RPCs
Text parameter support for XJS/390
Distributed Transaction Management
Server classes and ASTC
DTM-enabled servers
Pre-DTM servers
strict DTM enforcement
enable xact coordination
Enable Component Integration Services
Transactional RPCs
Restrictions on transaction management
Adaptive Server to Adaptive Server update statistics
Limitations
Updating statistics on non-Adaptive Server backends
Java in the database
@@textsize
@@stringsize
Constraints on Java class columns
Error messages
Java abstract datatypes (ADTs)
Java class definitions
Datatypes
Unicode support
create table
create existing table
create proxy_table
alter table
select, insert, update, and delete statements
Datatype conversions
text and image datatypes
Restrictions on text, image, and unitext columns
Limits of @@textsize
Odd bytes padded
Converting text and image datatypes
Pattern matching with text and unitext data
Entering text and image values
readtext using bytes
text, image, and unitext with bulk copy
Error logging
text, unitext, and image data with server class ASEnterprise
text, image, and unitext data with server class direct_connect
Configuration and tuning
Using sp_configure
sysconfigures table
Changing the configuration parameters
Component Integration Services configuration parameters
Global variables for status
SQL Reference
dbcc commands
dbcc options
Trace flags
Functions
Support for functions within Component Integration Services
Aggregate functions
Datatype conversion functions
Date functions
Mathematical functions
Security functions
String functions
System functions
Text and image functions
Transact-SQL commands
alter table
case
connect to...disconnect
create existing table
create index
create table
delete
drop index
fetch
insert
readtext
select
truncate table
update
update statistics
writetext
Passthrough mode
connect to
sp_autoconnect
sp_passthru
sp_remotesql
Quoted identifier support
Delimited identifier support
auto identity option
Triggers
Tutorial
Getting started with Component Integration Services
Adding a remote server
Overview
Adding the remote server to the interfaces file
Creating server entries in system tables
Adding an alternate login and password
Verifying connectivity
Join between two remote tables
Adding the remote servers to the interfaces file
Defining the remote servers
Mapping the remote tables to Adaptive Server
Performing the join
Troubleshooting
Problems accessing Component Integration Services
Problems using Component Integration Services
Unable to access remote server
Requested server name not found
Driver call to connect two endpoints failed
Login failed
Unable to access remote object
Problem retrieving data from remote objects
Object is altered outside Component Integration Services
Index is added or dropped outside Component Integration Services
If you need help
ASE 15.0 with Encrypted Columns
Installing Adaptive Server
Column encryption
Overview
Setting the system encryption password
Creating and managing encryption keys
Creating encryption keys
Using encryption keys
Granting permissions on keys
Changing the key
Encrypting data
Specifying encryption on new tables
Creating indexes on encrypted columns
Encrypting data in existing tables
Decrypting data
Permissions for decryption
Revoking decryption permission
Dropping encryption and keys
Dropping encryption and encryption keys
select into command
Length of encrypted columns
Auditing encrypted columns
Auditing options
Audit values
New event names and numbers
Performance considerations
Indexes on encrypted columns
Joins on encrypted columns
Constant valued search arguments and encrypted columns
Movement of encrypted data as ciphertext
System tables
syscolumns
sysobjects
sysencryptkeys
ddlgen utility extensions for encrypted columns
Replicating encrypted data
Bulk copy (bcp)
Component Integration Services (CIS)
load and dump databases
unmount database
quiesce database
Drop database
sybmigrate
Referential integrity constraints
Upgrade issues
New commands
create encryption key
alter encryption key
drop encryption key
grant create encryption key
revoke create encryption key
grant decrypt
revoke decrypt
New system-stored procedure
sp_encryption
Changes to commands and system procedures
sp_helprotect
sp_configure “enable encrypted columns”
alter table
create index
create table
enable encrypted columns configuration parameter
load database
select into
dbcc
Full syntax for commands
alter encryption key
alter table
create table
select
Downgrade procedure
Enhanced Full-Text Search Specialty Data Store User’s Guide
About this book
Introduction
Capabilities of the Enhanced Full-Text Search Engine
High availability
Understanding the Enhanced Full-Text Search Engine
Components of the Enhanced Full-Text Search engine
The source table
The Verity collections
Filters
The text_db database
The vesaux table
The vesauxcol table
The index table
The text_events table
Relationships between the components
How a full-text search works
Configuring Adaptive Server for Full-Text Searches
Configuring Adaptive Server for an Enhanced Full-Text Search engine
Enabling configuration parameters
Running the installtextserver script
Editing the installtextserver script
Starting the installtextserver script
Running the installmessages script
Running the installevent script
Editing the installevent script
Running the installevent script
Naming the local Adaptive Server
Creating and maintaining text indexes
Setting up source tables for indexing
Adding an IDENTITY column to a source table
Adding a unique index to an IDENTITY column
Creating the text index and index table
Specifying multiple columns when creating a text index
Bringing the database online for full-text searches
Propagating changes to the text index
Replicating text indexes
Example: enabling a new database for text searches
Step 1. Verifing that the text_events table exists
Step 2. Checking for an IDENTITY column or primary key
Step 3. Creating a unique index on the IDENTITY column
Step 4. Creating the text index and index table
Step 5. Bringing the database online for a full-text search
Indexing the euro symbol
Setting Up Verity Functions
Enabling query-by-example, summarization, and clustering
Editing the master style.prm file
Editing individual style.prm files
Setting up a column to use as a sort specification
Using filters on text that contains tags
Creating a custom thesaurus
Examining the default thesaurus (optional)
Creating the control file
Control file syntax
Creating the thesaurus
Replacing the default thesaurus with the custom thesaurus
Creating topics
Creating an outline file
Creating a topic set directory
Creating a knowledge base map
Defining the location of the knowledge base map
Executing queries against defined topics
Troubleshooting topics
Writing Full-Text Search Queries
Components of a full-text search query
Default behaviour
Pseudo columns in the index table
Using the score column to relevance-rank search results
Using the sort_by column to specify a sort order
Using the summary column to summarize documents
Using pseudo columns to request clustered result sets
Preparing to use clustering
Writing queries requesting a clustered result set
Full-text search operators
Considerations when using Verity operators
Using the Verity operators
accrue
and, or
complement
in
like
near, near/n
or
phrase
paragraph
product
sentence
stem
sum
thesaurus
topic
typo/n
wildcard
word
yesno
Operator modifiers
System Administration
Starting the Enhanced Full-Text Search engine on UNIX
Creating the runserver file
Starting the Enhanced Full-Text Search engine on Windows NT
Starting the Enhanced Full-Text Search engine as a service
Shutting down the Enhanced Full-Text Search engine
Modifying the configuration parameters
Modifying configuration values
Available configuration parameters
Setting the default language
Setting the default character set
Indexing on the euro symbol
Setting the default sort order
Setting trace flags
Setting Open Server trace flags
Setting case sensitivity
Backup and recovery for the Enhanced Full-Text Search engine
Customizable backup and restore
Backing up Verity collections
Restoring collections and text indexes from backup
Performance and Tuning
Updating existing indexes
Increasing query performance
Limiting the number of rows
Ensuring the correct join order for queries
Reconfiguring Adaptive Server
cis cursor rows
cis packet size
Reconfiguring the Enhanced Full-Text Search engine
batch_size
min_sessions and max_sessions
Using sp_text_notify
Configuring multiple Enhanced Full-Text Search engines
Creating multiple Enhanced Full-Text Search engines at start-up
Adding Enhanced Full-Text Search engines
Configuring additional Enhanced Full-Text Search engines
Multiple users
File Descriptors and Enhanced Full-Text Search
Verity Topics
What are topics?
Topic organization
Weight assignments
Using a topic outline file
Making topics available
Setup process
Knowledge bases of topics
Combining topics into a knowledge base
Structure of topics
Top-level topics
Subtopics
Evidence topics
Topic and subtopic relationships
Maximum number of topics
Topic naming issues
Verity query language
Query language summary
Evidence operators
Proximity operators
Relational operators
Concept operators
Boolean operators
Modifiers
Operator precedence rules
Sample topic outlines
Operator reference
ACCRUE operator
ALL operator
AND operator
ANY operator
CONTAINS operator
ENDS operator
= (EQUALS) operator
FILTER operator
> (GREATER THAN) operator
>= (GREATER THAN OR EQUAL TO) operator
< (LESS THAN) operator
<= (LESS THAN OR EQUAL TO) operator
IN operator
MATCHES operator
NEAR operator
NEAR/N operator
OR operator
PARAGRAPH operator
PHRASE operator
SENTENCE operator
SOUNDEX operator
STARTS operator
STEM operator
SUBSTRING operator
THESAURUS operator
TYPO/N operator
WILDCARD operator
Using wildcard special characters
Searching for nonalphanumeric characters
Searching for wildcard characters as literals
Searching for special characters as literals
WORD operator
Modifier reference
CASE modifier
MANY modifier
NOT modifier
ORDER modifier
Weights and document importance
Topic weights
Which operators accept weights
How weights affect importance
Assigning weights
Automatic weight assignments
Tips for assigning weights
Changing weights
Topic scoring and document importance
Designing topics
Preparing your topic design
Understanding your information needs
Understanding your documents
Using scanned data
Categorizing document samples
Topic design strategies
Top-down design
Bottom-up design
Designing the initial topic
Outlining a topic
Top-down topic outline example
Establishing an information hierarchy
Establishing individual search categories
Establishing the topics to be built
Bottom-up topic outline example
Identifying low-level topics
Categorizing related subtopics
Establishing top-level topics
System Procedures
sp_check_text_index
sp_clean_text_events
sp_clean_text_indexes
sp_create_text_index
sp_drop_text_index
sp_help_text_index
sp_optimize_text_index
sp_redo_text_events
sp_refresh_text_index
sp_show_text_online
sp_text_cluster
sp_text_configure
sp_text_dump_database
sp_text_kill
sp_text_load_index
sp_text_notify
sp_text_online
Sample Files
Default textsvr.cfg configuration file
The sample_text_main.sql script
Sample files illustrating Enhanced Full-Text Search engine features
Custom thesaurus
Topics
Clustering, summarization, and query-by-example
getsend sample program
Unicode Support
Glossary
Glossary
Java in Adaptive Server® Enterprise
About this book
An Introduction to Java in the Database
Advantages of Java in the database
Capabilities of Java in the database
Invoking Java methods in the database
Invoking Java methods directly in SQL
Invoking Java methods as SQLJ stored procedures and functions
Storing Java classes as datatypes
Storing and querying XML in the database
Standards
Java in the database: questions and answers
What are the key features?
How can I store Java instructions in the database?
How is Java executed in the database?
Client- and server-side JDBC
How can I use Java and SQL together?
What is the Java API?
How can I access the Java API from SQL?
Which Java classes are supported in the Java API?
Can I install my own Java classes?
Can I access data using Java?
Can I use the same classes on client and server?
How do I use Java classes in SQL?
Where can I find information about Java in the database?
What you cannot do with Java in the database
Sample Java classes
Preparing for and Maintaining Java in the Database
The Java runtime environment
Java classes in the database
Sybase runtime Java classes
User-defined Java classes
JDBC drivers
The Java VM
Configuring memory for Java in the database
Enabling the server for Java
Disabling the server for Java
Creating Java classes and JARs
Writing the Java code
Compiling Java code
Saving classes in a JAR file
Installing uncompressed JARs
Installing compressed JARs
Installing Java classes in the database
Using installjava
Retaining the JAR file
Updating installed classes
Referencing other Java-SQL classes
Viewing information about installed classes and JARs
Downloading installed classes and JARs
Removing classes and JARs
Retaining classes
Using Java Classes in SQL
General concepts
Java considerations
Java-SQL names
Using Java classes as datatypes
Creating and altering tables with Java-SQL columns
Altering partitioned tables
Selecting, inserting, updating, and deleting Java objects
Invoking Java methods in SQL
Sample methods
Exceptions in Java-SQL methods
Representing Java instances
Assignment properties of Java-SQL data items
Datatype mapping between Java and SQL fields
Character sets for data and identifiers
Subtypes in Java-SQL data
Widening conversions
Narrowing conversions
Runtime versus compile-time datatypes
The treatment of nulls in Java-SQL data
References to fields and methods of null instances
Null values as arguments to Java-SQL methods
Null values when using the SQL convert function
Java-SQL string data
Zero-length strings
Type and void methods
Java void instance methods
Java void static methods
Equality and ordering operations
Evaluation order and Java method calls
Columns
Variables and parameters
Static variables in Java-SQL classes
Java classes in multiple databases
Scope
Cross-database references
Inter-class transfers
Passing inter-class arguments
Temporary and work databases
Java classes
Data Access Using JDBC
Overview
JDBC concepts and terminology
Differences between client- and server-side JDBC
Permissions
Using JDBC to access data
Overview of the JDBCExamples class
The main( ) and serverMain( ) methods
Using main( )
Using serverMain( )
Obtaining a JDBC connection: the Connecter( ) method
Routing the action to other methods: the doAction( ) method
Executing imperative SQL operations: the doSQL( ) method
Executing an update statement: the updater( ) method
Executing a select statement: the selecter( ) method
Calling a SQL stored procedure: the caller( ) method
Error handling in the native JDBC driver
The JDBCExamples class
The main( ) method
The serverMain( ) method
The connecter( ) method
The doAction( ) method
The doSQL( ) method
The updater( ) method
The selecter( ) method
The caller( ) method
SQLJ Functions and Stored Procedures
Overview
Compliance with SQLJ Part 1 specifications
General issues
Security and permissions
SQLJ Examples
Invoking Java methods in Adaptive Server
Using Sybase Central to manage SQLJ functions and procedures
SQLJ user-defined functions
Handling null argument values
Handling nulls when creating the function
Handling nulls in the function call
Deleting a SQLJ function name
SQLJ stored procedures
Modifying SQL data
Using input and output parameters
Returning result sets
Deleting a SQLJ stored procedure name
Viewing information about SQLJ functions and procedures
Advanced topics
Mapping Java and SQL datatypes
Using the command main method
SQLJ and Sybase implementation: a comparison
SQLJExamples class
Debugging Java in the Database
Introduction to debugging Java
How the debugger works
Requirements for using the Java debugger
What you can do with the debugger
Using the debugger
Starting the debugger and connecting to the database
Compiling classes for debugging
Attaching to a Java VM
The Source window
The debugger windows
Options
Setting breakpoints
Breaking on a line number
Breaking on a static method
Using counts with breakpoints
Using conditions with breakpoints
Breaking when execution is not interrupted
Disconnecting from the database
A debugging tutorial
Before you begin
Start the Java debugger and connect to the database
Attach to a Java VM
Load source code into the debugger
Step through source code
Examples
Inspecting and modifying variables
Inspecting local variables
Modifying local variables
Inspecting static variables
Network Access Using java.net
Overview
java.net classes
Setting up java.net
Example usage
Using socket classes
Saving text out of Adaptive Server
Using the URL class
Use the mailto:URL class to mail a document
Obtaining an HTTP document
User notes
Reference Topics
JDK requirement for Java classes in the server
Assignments
Assignment rules at compile-time
Assignment rules at runtime
Allowed conversions
Transferring Java-SQL objects to clients
Supported Java API packages, classes, and methods
Supported Java packages and classes
Unsupported Java packages, classes, and methods
Unsupported java.sql methods and interfaces
Invoking SQL from Java
Special considerations
Transact-SQL commands from Java methods
Datatype mapping between Java and SQL
Java-SQL identifiers
Java-SQL class and package names
Java-SQL column declarations
Java-SQL variable declarations
Java-SQL column references
Java-SQL member references
Java-SQL method calls
Glossary
Job Scheduler User's Guide
About this book
Overview
Introduction
Terminology and concepts
Job Scheduler components and functionality
Job Scheduler architecture
Security
js_user_role
js_admin_role
Shared objects
Configuring and Running Job Scheduler
Installing Job Scheduler manually
Setting up Job Scheduler users
Setting up access to target servers
Using Templates to Create Jobs
Introduction
Installing stored procedures on a target server
Installing the templates into Job Scheduler
Using Job Scheduler templates
Backup
Statistics management
Reorganization
Reconfiguration
Template updates
Using Job Scheduler at the Command Line
Creating a job
Job state codes
Creating a schedule
Creating a scheduled job
Deleting a scheduled job
Modifying a scheduled job
Invoking stored procedures on a target server
Managing jobs
Managing job history and logs
Command Reference
Command line stored procedures
Command syntax
sp_sjobcreate
sp_sjobcmd
sp_sjobmodify
sp_sjobdrop
sp_sjobhelp
sp_sjobcontrol
sp_sjobhistory
Managing Job Scheduler in the Sybase Central ASE Plug-in
Adding a scheduled job
Adding a job
Adding a schedule
Scheduling an existing job
Viewing job history
Purging job history
Administering Job Scheduler
Showing all users
Managing a scheduled job
Editing properties
Deleting a Job Scheduler object
Troubleshooting
Logging error messages
A job fails to run at the time you scheduled it
A scheduled job created from a template fails
A job with multiple calls to sp_sjobcmd fails
A stored procedure fails
Messaging Services User’s Guide
About this book
Introduction
Adaptive Server messaging concepts
Messaging models
Publish-and-subscribe (topics)
Point-to-point (queues)
Message format
JMS message properties
Message selectors
Understanding Real-Time Data Services
Sending and receiving messages from a queue
Publishing and consuming messages from a JMS topic
Working with message properties
Previewing the messaging interface
Configuring Real-Time Data Services
Configuring RTDS
Configuring Adaptive Server to communicate with TIBCO Rendezvous Server
SQL Reference
Messaging-related global variables
<msgheader> and <msgproperties> documents
Adaptive Server-specific message properties
Keywords
Stored procedures
Built-in functions
Syntax segment
sp_msgadmin
msgconsume
msgpropcount
msgproplist
msgpropname
msgproptype
msgpropvalue
msgpublish
msgrecv
msgsend
msgsubscribe
msgunsubscribe
option_string
Transactional Behavior
Transactional message behavior
Transactional messaging set option
Samples
Sybase directories
Using code samples with Replication Server function strings
Using code samples with SQL
Using code samples with Java/JDBC
Glossary
Migration Guide
About this book
Documenting Business Requirements
Creating an information-flow diagram
Identifying your operational business requirements
Availability requirements
Database change metrics
Database dump details
Maintenance procedures
Service-level requirements
Transaction profile
Recording current performance metrics
Recording additional business requirements
Documenting Your Environment
Hardware configuration
General server hardware
CPU resources per machine
Disk configuration
Network configuration
Tape configuration
Physical memory utilization
Software configuration
Operating system
Applications
Sybase configuration
General information
Database devices
Databases and segments
Dump devices
Adaptive Server objects
Adaptive Server performance
Writing a Migration Plan
Note for the upgrade process
Migrating to a 64-bit operating system or a larger page size
Alternative to dump and load for Adaptive Server 12.5.1
Determining a migration approach
Parallel with replication
Cutover without replication
Phased cutover
Writing a migration plan
Building the Adaptive Server environment
Update hardware resources
Verify operating system version and EBF level
Review Adaptive Server interoperability with other Sybase products
Use Sybase Product Download Center
Implement licensing environment
Update applications and system administration procedures
Create Migration Scripts
Making Required Application Changes
Reserved words
Upgrading Adaptive Server release 11.5
Upgrading from version 11.9.x
ANSI joins
Query processing changes
Predicate transformation and factoring
Support for as many as 50 tables in a query
Abstract query plans
Increased optimization time
like optimization enhancements
Concrete identification
Upgrading from release 12.0
Changes to Transact-SQL
enable xact coordination configuration parameter
Unlimited expressions in a select statement
Wide columns and data truncation
Change in truncation behavior
Wide columns and optimizer statistics
Wide columns with col_length() and datalength()
If you are upgrading from release 12.5
Date and time datatypes
Query and optimizer changes
Unsupported trace flags
Partition changes
Partitions and primary keys and unique indexes
Multiple and composite partition keys and range partitioning
Semantic partitions and data skew
Dropping partitions
Moving data in and out of partitions
Changes for computed columns and function-based indexes
Computed column evaluation
Nonmaterialized computed columns and invalid values
Long identifier changes
Error message changes
Open Client/SDK compatibility with Adaptive Server
New features in Open Client
Adaptive Server and Open Client compatibilities
Making Database Administration Changes
Upgrading from version 11.5 or earlier
Upgrading from version 11.9.2 or later
Optimizer changes
Abstract plan enhancements
Capturing query metrics
Updating statistics after upgrading
Automatic update statistics
datachange function
update statistics on partitions
Changes to functions
Changes to system tables
Changes to third-party tools
Changes to database IDs
ASE plug-in for Sybase Central
Interactive SQL
sybsyntax
Changes to documentation
sybsystemdb
bcp with syslogins
Maximum number of users and logins
New reserved words
Configuration parameters
stack size
Increased memory
Changes that affect upgrade and server functionality
Device size
bigint support
unsigned int support
Integer identity
Separate device ID column
File system or raw partition?
Row-locked system catalogs
Databases are larger
#temp table changes
New limits for regular delimited identifiers
SySAM license manager
buildmaster obsolete
Ensuring Stability and Performance
Overview
Setting up the test environment
Make backups
Use scripts to create the test system
Install monitoring tables
Create your databases by loading backups
If your test environment is not an exact duplicate
Prioritizing applications to be tested
Establishing performance criteria
Developing fallback procedures
Summary of testing techniques
Writing performance scripts
Write benchmark scripts
Drivers
General error handling
Deadlock handling
Result handling
Time measurement
Runtime data generation
Summary of tests
Determining query processing changes
Before you start testing
Determining which queries are impacted during migration
Finding impacted queries
Finding long-running stored procedures
Diagnosing and fixing query processing issues in 15.0 servers
Using sysquerymetrics and sp_metrics
Using sysquerymetrics to support regression testing
Using showplan options
set statistics plancost
Query plans as XML
Query-level debugging in Adaptive Server 15.0
Early timeout detection versus tablecount
Fixing queries using abstract query plans
Forcing an join order
Forcing different subquery attachments
Reporting query processor and optimizer issues
Testing for performance
Pre-upgrade single-user tests
Optimizer
I/O
Pre-upgrade multiuser tests
Untimed benchmarks
Timed benchmarks
Test system upgrade
Post-upgrade single-user tests
Post-upgrade multiuser tests
Untimed benchmarks
Timed benchmarks
Worksheets for Your Current Environment
Adaptive Server operational worksheets
Operational business requirements
Backup and restore procedures
Database dump details
Maintenance procedure details
Data architecture worksheet
Client application components
Production performance metrics
Transaction profile
Adaptive Server infrastructure worksheets
Host configuration
Hardware
Physical memory usage
Disk I/O configuration
Network configuration
Tape configuration
Operating system configuration
Adaptive Server configuration
Database devices
Databases and segments
Dump devices
Sample Migration Task Lists
Sample task list template
General migration task list example
Migration analysis
Document current configuration
Gather business requirements
Conduct compatibility analysis
Develop migration strategy
Migration preparation
Write test plans and test scripts
Prepare applications for migration
Design and develop server migration scripts
Design and develop database migration scripts
Design and develop data migration scripts
Perform other premigration tasks
Implement migration (using install/load technique)
Create target environment
Perform server migration
Perform database migration
Perform data migration
Complete server and data migration
Perform application migration
Implement migration (using upgrade technique)
Upgrade adaptive server
Complete migration
Perform application migration
Migration quality assurance
Perform aystem tests
Perform integration tests
Perform stress tests
Perform user acceptance tests
Perform production data refresh
Parallel migration task list example
Define test/acceptance criteria—regression test suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Set up target production environment
Set up Replication Server
Run regression test suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Upgrade server B (shadow)
Run post-upgrade regression test suites on Adaptive Server 15.0 (server B)
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end phase 1 and 2 regression test suite
Other testing
Run user acceptance tests on Adaptive Server 15.0 (server B)
Shift production users to Adaptive Server 15.0 (server B)
Perform final steps
Cutover migration task list example
Set up Adaptive Server 15.0 on development system
Define test/acceptance criteria—regression test suites
Front-end simulation regression test suite
Front-end regression test suite
Define fallback procedures on test system
“Baseline” older environment on test system
Run regression test suites on older release test system
Front-end simulation regression test suite
Front-end regression test suite
Upgrade test system to version 15.0
Run regression test suites on version 15.0 Test System
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end regression test suite
Other testing
Run user/acceptance tests on version 15.0 test system
Execute fallback procedures on test system
Upgrade production server to Adaptive Server version 15.0
Perform final steps
Staged cutover task overview
Tasks
Migration Issue Checklists
Logical data architecture
Logical Application Architecture
Logical technology architecture
Logical support architecture
Migration strategy design
Pre-Upgrade Checklist
Pre-upgrade checklist
Monitor Client Library Programmer’s Guide
About this book
Getting Started with Monitor Client Library
Overview
What is Adaptive Server Enterprise Monitor?
Adaptive Server Enterprise Monitor components
Adaptive Server Enterprise Monitor architecture
Writing a basic Monitor Client Library program
Application logic flow
Step 1: Defining error handling
Step 2: Connecting to a server
Allocating a connection structure
Setting connection structure properties
Required connection properties
Connecting to a server
Step 3: creating a view
Data items
Statistical types
Creating views for a connection
Step 4: Creating filters
Step 5: Setting alarms
Step 6: Requesting performance data and process results
Step 7: closing and deallocating connections
Closing and deallocating connections
Reopening connections
Playing back recorded data
A sample Monitor Client Library program
Example program
Data Items and Statistical Types
Overview
Result and key data items
Data items and views
Rows with no data versus no rows in views
Server-level status
Combining data items
Result and key combinations
Connection summaries
Current statement and application name data items
Data item definitions
Deciphering the names of data items
SMC_NAME_ACT_STP_DB_ID
SMC_NAME_ACT_STP_DB_NAME
SMC_NAME_ACT_STP_ID
SMC_NAME_ACT_STP_NAME
SMC_NAME_ACT_STP_OWNER_NAME
SMC_NAME_APPLICATION_NAME
SMC_NAME_APP_EXECUTION_CLASS
SMC_NAME_BLOCKING_SPID
SMC_NAME_CONNECT_TIME
SMC_NAME_CPU_BUSY_PCT
SMC_NAME_CPU_PCT
SMC_NAME_CPU_TIME
SMC_NAME_CPU_YIELD
SMC_NAME_CUR_APP_NAME
SMC_NAME_CUR_ENGINE
SMC_NAME_CUR_EXECUTION_CLASS
SMC_NAME_CUR_PROC_STATE
SMC_NAME_CUR_STMT_ACT_STP_DB_ID
SMC_NAME_CUR_STMT_ACT_STP_DB_NAME
SMC_NAME_CUR_STMT_ACT_STP_ID
SMC_NAME_CUR_STMT_ACT_STP_NAME
SMC_NAME_CUR_STMT_ACT_STP_OWNER_NAME
SMC_NAME_CUR_STMT_ACT_STP_TEXT
SMC_NAME_CUR_STMT_BATCH_ID
SMC_NAME_CUR_STMT_BATCH_TEXT
SMC_NAME_CUR_STMT_BATCH_TEXT_ENABLED
SMC_NAME_CUR_STMT_CONTEXT_ID
SMC_NAME_CUR_STMT_CPU_TIME
SMC_NAME_CUR_STMT_ELAPSED_TIME
SMC_NAME_CUR_STMT_LINE_NUM
SMC_NAME_CUR_STMT_LOCKS_GRANTED_IMMED
SMC_NAME_CUR_STMT_LOCKS_GRANTED_WAITED
SMC_NAME_CUR_STMT_LOCKS_NOT_GRANTED
SMC_NAME_CUR_STMT_NUM
SMC_NAME_CUR_STMT_PAGE_IO
SMC_NAME_CUR_STMT_PAGE_LOGICAL_READ
SMC_NAME_CUR_STMT_PAGE_PHYSICAL_READ
SMC_NAME_CUR_STMT_PAGE_WRITE
SMC_NAME_CUR_STMT_QUERY_PLAN_TEXT
SMC_NAME_CUR_STMT_START_TIME
SMC_NAME_CUR_STMT_TEXT_BYTE_OFFSET
SMC_NAME_DATA_CACHE_CONTENTION
SMC_NAME_DATA_CACHE_EFFICIENCY
SMC_NAME_DATA_CACHE_HIT
SMC_NAME_DATA_CACHE_HIT_PCT
SMC_NAME_DATA_CACHE_ID
SMC_NAME_DATA_CACHE_LARGE_IO_DENIED
SMC_NAME_DATA_CACHE_LARGE_IO_PERFORMED
SMC_NAME_DATA_CACHE_LARGE_IO_REQUESTED
SMC_NAME_DATA_CACHE_MISS
SMC_NAME_DATA_CACHE_NAME
SMC_NAME_DATA_CACHE_PREFETCH_EFFICIENCY
SMC_NAME_DATA_CACHE_REUSE
SMC_NAME_DATA_CACHE_REUSE_DIRTY
SMC_NAME_DATA_CACHE_REF_AND_REUSE
SMC_NAME_DATA_CACHE_SIZE
SMC_NAME_DB_ID
SMC_NAME_DB_NAME
SMC_NAME_DEADLOCK_CNT
SMC_NAME_DEMAND_LOCK
SMC_NAME_DEV_HIT
SMC_NAME_DEV_HIT_PCT
SMC_NAME_DEV_IO
SMC_NAME_DEV_MISS
SMC_NAME_DEV_NAME
SMC_NAME_DEV_READ
SMC_NAME_DEV_WRITE
SMC_NAME_ELAPSED_TIME
SMC_NAME_ENGINE_NUM
SMC_NAME_HOST_NAME
SMC_NAME_KPID
SMC_NAME_LOCK_CNT
SMC_NAME_LOCK_HIT_PCT
SMC_NAME_LOCK_RESULT
SMC_NAME_LOCK_RESULT_SUMMARY
SMC_NAME_LOCK_STATUS
SMC_NAME_LOCK_STATUS_CNT
SMC_NAME_LOCK_TYPE
SMC_NAME_LOCKS_BEING_BLOCKED_CNT
SMC_NAME_LOCKS_GRANTED_IMMED
SMC_NAME_LOCKS_GRANTED_WAITED
SMC_NAME_LOCKS_NOT_GRANTED
SMC_NAME_LOG_CONTENTION_PCT
SMC_NAME_LOGIN_NAME
SMC_NAME_MEM_CODE_SIZE
SMC_NAME_MEM_KERNEL_STRUCT_SIZE
SMC_NAME_MEM_PAGE_CACHE_SIZE
SMC_NAME_MEM_PROC_BUFFER
SMC_NAME_MEM_PROC_HEADER
SMC_NAME_MEM_SERVER_STRUCT_SIZE
SMC_NAME_MOST_ACT_DEV_IO
SMC_NAME_MOST_ACT_DEV_NAME
SMC_NAME_NET_BYTE_IO
SMC_NAME_NET_BYTES_RCVD
SMC_NAME_NET_BYTES_SENT
SMC_NAME_NET_DEFAULT_PKT_SIZE
SMC_NAME_NET_MAX_PKT_SIZE
SMC_NAME_NET_PKT_SIZE_RCVD
SMC_NAME_NET_PKT_SIZE_SENT
SMC_NAME_NET_PKTS_RCVD
SMC_NAME_NET_PKTS_SENT
SMC_NAME_NUM_ENGINES
SMC_NAME_NUM_PROCESSES
SMC_NAME_OBJ_ID
SMC_NAME_OBJ_NAME
SMC_NAME_OBJ_TYPE
SMC_NAME_OWNER_NAME
SMC_NAME_PAGE_HIT_PCT
SMC_NAME_PAGE_INDEX_LOGICAL_READ
SMC_NAME_PAGE_INDEX_PHYSICAL_READ
SMC_NAME_PAGE_IO
SMC_NAME_PAGE_LOGICAL_READ
SMC_NAME_PAGE_NUM
SMC_NAME_PAGE_PHYSICAL_READ
SMC_NAME_PAGE_WRITE
SMC_NAME_PROC_STATE
SMC_NAME_PROC_STATE_CNT
SMC_NAME_SPID
SMC_NAME_SQL_SERVER_NAME
SMC_NAME_SQL_SERVER_VERSION
SMC_NAME_STP_CPU_TIME
SMC_NAME_STP_ELAPSED_TIME
SMC_NAME_STP_EXECUTION_CLASS
SMC_NAME_STP_HIT_PCT
SMC_NAME_STP_LINE_NUM
SMC_NAME_STP_LINE_TEXT
SMC_NAME_STP_LOGICAL_READ
SMC_NAME_STP_NUM_TIMES_EXECUTED
SMC_NAME_STP_PHYSICAL_READ
SMC_NAME_STP_STMT_NUM
SMC_NAME_THREAD_EXCEEDED_MAX
SMC_NAME_THREAD_EXCEEDED_MAX_PCT
SMC_NAME_THREAD_MAX_USED
SMC_NAME_TIME_WAITED_ON_LOCK
SMC_NAME_TIMESTAMP
SMC_NAME_TIMESTAMP_DATIM
SMC_NAME_XACT
SMC_NAME_XACT_DELETE
SMC_NAME_XACT_DELETE_DEFERRED
SMC_NAME_XACT_DELETE_DIRECT
SMC_NAME_XACT_INSERT
SMC_NAME_XACT_INSERT_CLUSTERED
SMC_NAME_XACT_INSERT_HEAP
SMC_NAME_XACT_SELECT
SMC_NAME_XACT_UPDATE
SMC_NAME_XACT_UPDATE_DEFERRED
SMC_NAME_XACT_UPDATE_DIRECT
SMC_NAME_XACT_UPDATE_EXPENSIVE
SMC_NAME_XACT_UPDATE_IN_PLACE
SMC_NAME_XACT_UPDATE_NOT_IN_PLACE
Monitor Client Library Functions
Library functions
Threads
Error handling
Error handler
Callback function
smc_close
smc_connect_alloc
smc_connect_drop
smc_connect_ex
smc_connect_props
smc_create_alarm_ex
smc_create_filter
smc_create_playback_session
smc_create_recording_session
smc_create_view
smc_drop_alarm
smc_drop_filter
smc_drop_view
smc_get_command_info
smc_get_dataitem_type
smc_get_dataitem_value
smc_get_row_count
smc_get_version_string
smc_initiate_playback
smc_initiate_recording
smc_refresh_ex
smc_terminate_playback
smc_terminate_recording
Building a Monitor Client Library Application
Building on UNIX platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Building on Windows platforms
Compiling the application
Linking the application
Running the application
Building the sample applications
Monitor Client Library Configuration Instructions
Loading Monitor Client Library
Using InstallShield
Results of the load
Confirming your login account and permissions
Modifying the interfaces file
Setting up the user environment
Setting the SYBASE environment variable
Overriding the default location of the interfaces file
Using Monitor Client Library
Examples of Views
Cache performance summary
Current statement summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for session
Data cache statistics for sample interval
Device I/O for session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for session
Network activity for sample interval
Network performance summary
Procedure cache statistics for session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Datatypes and Structures
Summary of datatypes
Enum: SMC_ALARM_ACTION_TYPE
Enum: SMC_CLOSE_TYPE
Enum: SMC_DATAITEM_NAME
Enum: SMC_DATAITEM_STATTYPE
Structure: SMC_DATAITEM_STRUCT
Enum: SMC_DATAITEM_TYPE
Enum: SMC_ERR_SEVERITY
Enum: SMC_FILTER_TYPE
Enum: SMC_HS_ESTIM_OPT
Enum: SMC_HS_MISSDATA_OPT
Enum: SMC_HS_PLAYBACK_OPT
Enum: SMC_HS_SESS_DELETE_OPT
Enum: SMC_HS_SESS_ERR_OPT
Enum: SMC_HS_SESS_PROT_LEVEL
Enum: SMC_HS_SESS_SCRIPT_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_HS_TARGET_OPT
Enum: SMC_INFO_TYPE
Enum: SMC_LOCK_RESULT
Enum: SMC_LOCK_RESULT_SUMMARY
Enum: SMC_LOCK_STATUS
Enum: SMC_LOCK_TYPE
Enum: SMC_OBJ_TYPE
Enum: SMC_PROC_STATE
Enum: SMC_PROP_ACTION
Enum: SMC_PROP_TYPE
Enum: SMC_RETURN_CODE
Enum: SMC_SERVER_MODE
Enum: SMC_SOURCE
Union: SMC_VALUE_UNION
Backward Compatibility
Obsolete and replacement functions
New functions, as Adaptive Server version 11.5
Rules for functions and callbacks compatibility
Troubleshooting Information and Error Messages
Troubleshooting
Confusing messages from Adaptive Server
View refreshes fail
Negative numbers as object IDs
Error messages
Communication failure: check if server is running
Configuration failure: possibly missing interfaces file or bad login parameters
Don’t know how to build example.h
error L2029: ‘SMC_CONNECT’ : unresolved external
error L2029: ‘SMC_CREATE_VIEW’ : unresolved external
fatal error C1083: Cannot open include file: ‘cstypes.h’: No such file or directory
fatal error C1083: Cannot open include file: ‘mcpublic.h’: No such file or directory
LINK: fatal error L4051: smcapi32.lib : cannot find library
Monitor Historical Server User's Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Adaptive Server Monitor components
Adaptive Server Monitor architecture
Adaptive Server Enterprise Monitor architecture
Historical Server concepts
Recording sessions
Playback sessions
Views
Data items and statistic types
Configuring Historical Server
Historical Server configuration concepts
The Historical Server control file and home directory
Accessing control file information
Do not edit the control file
The operating system start-up account
The Historical Server superuser account
Sybase Open Client/Server connections
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Windows platforms
Assumptions on Windows
Results of installation on Windows
Configuration procedures on Windows
Changing start-up parameters
Setting Historical Server start-up parameters
Function
Syntax
Parameters
Configuring multiple instances of Historical Server
When to create multiple instances of Historical Server
Configuring an additional Historical Server on UNIX platforms
Configuring an additional Historical Server on Windows NT
Adding start-up parameters to the NT Registry
Updating the NT Registry services list
Adding connectivity information for Historical Server
Configuring Historical Server client machines
Creating a .bat file (optional)
Starting and Stopping Historical Server
Starting and stopping Historical Server on UNIX platforms
Starting Historical Server on UNIX
Stopping Historical Server on UNIX
Who can shut down Historical Server
Determining current activity on Historical Server
Deferred versus immediate shutdown
Detailed shutdown procedures
Starting and stopping Historical Server on Windows NT
Starting Historical Server on Windows NT
Inferring start-up parameters from the NT Registry
Verifying that Historical Server is running
Stopping Historical Server on Windows NT
Who can shut down Historical Server on Windows NT
Determining current activity on Windows NT
Deferred versus immediate shutdown on Windows NT
Detailed shutdown procedures on Windows NT
Shutdown methods to avoid on Windows NT
Command Reference
Command summary
Command syntax
Command status and errors
Script files as input to Historical Server
Connecting to Historical Server
Assumptions before connection
How to connect
Required permissions for Historical Server activities
Mutually exclusive sessions
Starting and ending a recording session definition
Starting and ending a playback session
Historical Server commands
hs_create_alarm
hs_create_filter
hs_create_playback_session
hs_create_playback_view
hs_create_recording_session
hs_create_view
hs_delete_data
hs_initiate_playback
hs_initiate_recording
hs_list
hs_playback_sample
hs_shutdown
hs_status
hs_terminate_playback
hs_terminate_recording
Data Files and Output Options
Overview of Historical Server data files
Description of Historical Server files
Permissions on files
General file format
Control file
Header record
Session control record
View control record
Data item control record
Alarm control record
Filter control record
Data file
Error message file
Script file
Script file table names
Script file table column names
Passing script file commands
Script use example
Bulk copy example
Example
Cut utility example
Enabling Historical Server to output monitoring data to a database
Setting up the receiving Adaptive Server
Starting Historical Server
Viewing the data
Data storage
Deleting Historical Server sessions
Reporting errors
Data Items
Table of data items and definitions
Specifications for Defining Recording Session Views
Definition of key and result
Designing recording session views
Using the Process ID
Using the application name
Empty rows versus no rows in views
Table of valid key and result data item combinations
Examples of valid combinations
Examples of invalid combinations
Table of valid statistic types for data items
Specifications for Defining Playback Views
Summarization level details
Raw playback
Actual playback
Entire playback
Playback with user-defined intervals
Summary of summarization intervals
Designing playback views
Rules for specifying input sessions
Relationship of input views to playback views
Rules for defining views
Rules for defining raw playback views
Rules for defining non-raw playback views
Table of data item requirements for playback views
Additional information about some data items
Using “Timestamp”, “Timestamp Datim”, and “Elapsed Time”
Using Process ID
Using Procedure Elapsed Time and Procedure CPU Time
Examples of Recording Session Views
Cache performance summary
Database object lock status
Database object page I/O
Data cache activity for individual caches
Data cache statistics for recording session
Data cache statistics for sample interval
Device I/O for recording session
Device I/O for sample interval
Device I/O performance summary
Engine activity
Lock performance summary
Network activity for recording session
Network activity for sample interval
Network performance summary
Page I/O
Procedure cache statistics for recording session
Procedure cache statistics for sample interval
Procedure page I/O
Process activity
Process database object page I/O
Process detail for locks
Process detail page I/O
Process locks
Process page I/O
Process state summary
Process stored procedure page I/O
Server performance summary
Stored procedure activity
Transaction activity
Monitor Server User’s Guide
About this book
Introduction
Description of Adaptive Server Enterprise Monitor
Monitor components
Monitor architecture
Configuring Monitor Server
Initial configuration on UNIX platforms
Assumptions on UNIX platforms
Results of installation on UNIX platforms
Configuration procedures on UNIX platforms
Initial configuration on Windows platforms
Assumptions on Windows platofrms
Results of installation on Windows
Configuration procedures on Windows platforms
Setting up the automatic start-up service
Setting up the server start-up order
Changing the default configuration
Changing start-up information in the NT Registry
Changing the .bat file
Configuring another Monitor Server
Monitor Server start-up parameters
Function
Syntax
Parameters
Adjusting Monitor Server runtime configuration
Monitor Server configuration file
Initial scan interval
Heartbeat interval
Configuring Monitor Server heap space usage
Summary buffer size
Number of summary buffers per event summary request
Maximum number of event summaries per connection
Adaptive Server configuration issues that affect Monitor Server
Restrictions on length of Adaptive Server name
Configuring event buffers
Understanding event buffers and event loss
Determining a value for event buffers per engine parameter
Changing the event buffers per engine parameter
Configuring SQL text buffers
Understanding the SQL text feature
Determining a value for the max SQL text monitored parameter
Changing the max SQL text monitored parameter
Starting, Verifying, and Stopping Monitor Server
Starting, verifying, and stopping Monitor Server on UNIX platforms
Starting Monitor Server on UNIX
Verifying that Monitor Server is running on UNIX
Stopping Monitor Server on UNIX
Starting, verifying, and stopping Monitor Server on Windows NT
Starting Monitor Server on Windows NT
How start-up parameters are inferred on Windows NT
Verifying that Monitor Server is running on Windows NT
Stopping Monitor Server on Windows NT
Orderly shutdowns and restarts
Orderly shutdowns
Automatic shutdowns
Orderly restarts
Connecting to clients
Monitor Server isql commands
Using the commands
sms_shutdown
sms_status
Troubleshooting Monitor Server
Error messages
Common problems
Monitor Server fails to start
Access violations
Check the NT Registry services entry (NT only)
Client errors
Maximum connection errors
ct_netlib errors (Windows NT)
Messages in Adaptive Server error log
Performance and Tuning: Basics
About this book
Introduction to Performance and Tuning
Introduction to the Basics
Good performance
Response time
Throughput
Designing for performance
Tuning performance
Tuning levels
Application layer
Database layer
Adaptive Server layer
Devices layer
Network layer
Hardware layer
Operating – system layer
Configuration parameters
Dynamic
Identifying system limits
Varying logical page sizes
Number of columns and column size
Maximum length of expressions, variables, and stored procedure arguments
Number of logins
Performance implications for limits
Setting tuning goals
Analyzing performance
Normal Forms
Locking
Special Considerations
Networks and Performance
Introduction
Potential performance problems
Basic questions on network performance
Techniques summary
Using sp_sysmon while changing network configuration
How Adaptive Server uses the network
Managing Network Listeners
Network Listeners on UNIX
Managing listeners with sp_listener
Using the remaining parameter
Determining the status of listeners
Starting new listeners
Stopping listeners
Suspending listeners
Resume suspended listeners
Changing network packet sizes
Large versus default packet sizes for user connections
Number of packets is important
Evaluation tools with Adaptive Server
Evaluation tools outside of Adaptive Server
Server-based techniques for reducing network traffic
Impact of other server activities
Single user versus multiple users
Improving network performance
Isolate heavy network users
Set tcp no delay on TCP networks
Configure multiple network listeners
Using Engines and CPUs
Background concepts
How Adaptive Server processes client requests
Client task implementation
Single-CPU process model
Scheduling engines to the CPU
Scheduling tasks to the engine
Execution task scheduling
Scheduling client task processing time
Maintaining CPU availability during idle time
Adaptive Server SMP process model
Scheduling engines to CPUs
Scheduling Adaptive Server tasks to engines
Multiple network engines
Task priorities and run queues
Processing scenario
Asynchronous log service
Understanding the user log cache (ULC) architecture
When to use ALS
Using the ALS
ULC flusher
Log writer
Changes in stored procedures
Housekeeper task improves CPU utilization
Side effects of the housekeeper task
Configuring the housekeeper task
Changing the percentage by which writes can be increased
Disabling the housekeeper task
Allowing the housekeeper task to work continuously
Measuring CPU usage
Single-CPU machines
Using sp_monitor to measure CPU usage
Using sp_sysmon to measure CPU usage
Operating - system commands and CPU usage
Determining when to configure additional engines
Taking engines offline
Enabling engine-to-CPU affinity
Multiprocessor application design guidelines
Distributing Engine Resources
Algorithm for successfully distributing engine resources
Algorithm guidelines
Environment analysis and planning
Analyzing
Example: phase 1 – execution object behavior
Example: phase 2 – the environment as a whole
Performing benchmark tests
Setting goals
Results analysis and tuning
Monitoring the environment over time
Manage preferred access to resources
Types of execution classes
Predefined execution classes
User-Defined execution classes
Execution class attributes
Base priority
Time slice
Task-to-engine affinity
Setting execution class attributes
Assigning execution classes
Engine groups and establishing task-to-engine affinity
How execution class bindings affect scheduling
Execution class bindings
Engine affinity can affect scheduling
Setting attributes for a session only
Getting information
Rules for determining precedence and scope
Multiple execution objects and ECs
Precedence rule
Scope rule
Resolving a precedence conflict
Examples: determining precedence
Example scenario using precedence rules
Planning
Configuration
Execution characteristics
Considerations for Engine Resource Distribution
Client applications: OLTP and DSS
Unintrusive client applications
I/O-bound client applications
Highly critical applications
Adaptive Server logins: high-priority users
Stored procedures: “hot spots”
Controlling Physical Data Placement
Object placement can improve performance
Symptoms of poor object placement
Underlying problems
Using sp_sysmon while changing data placement
Terminology and concepts
Guidelines for improving I/O performance
Spreading data across disks to avoid I/O contention
Avoiding physical contention in parallel join queries
Isolating server-wide I/O from database I/O
Where to place tempdb
Where to place sybsecurity
Keeping transaction logs on a separate disk
Mirroring a device on a separate disk
Device mirroring performance issues
Using serial mode
Creating objects on segments
Using segments
Separating tables and indexes
Splitting large tables across devices
Moving text storage to a separate device
Partitioning tables for performance
User transparency
Partitioned tables and parallel query processing
Distributing data across partitions
Improving insert performance with partitions
How partitions address page contention
Selecting heap tables to partition
Restrictions on partitioned tables
Partition-related configuration parameters
How Adaptive Server distributes partitions on devices
RAID devices and partitioned tables
Space planning for partitioned tables
Read-only tables
Read-mostly tables
Tables with random data modification
Commands for partitioning tables
alter table...partition syntax
alter table...unpartition Syntax
Changing the number of partitions
Distributing data evenly across partitions
Commands to create and drop clustered indexes
Using reorg rebuild on data-only-locked tables
Using drop index and create clustered index
Using constraints and alter table
Special concerns for partitioned tables and clustered indexes
Using parallel bcp to copy data into partitions
Parallel copy and locks
Getting information about partitions
Using bcp to correct partition balance
Checking data distribution on devices with sp_helpsegment
Effects of imbalance of data on segments and partitions
Determining the number of pages in a partition
Updating partition statistics
Syntax for update partition statistics
Steps for partitioning tables
Backing up the database after partitioning tables
Table does not exist
Table exists elsewhere in the database
Table exists on the segment
Redistributing data
Adding devices to a segment
Special procedures for difficult situations
Clustered indexes on large tables
Alternative for clustered indexes
Problems when devices for partitioned tables are full
Adding disks when devices are full
Adding disks when devices are nearly full
Maintenance issues and partitioned tables
Regular maintenance checks for partitioned tables
Database Design
Basic design
Physical database design for Adaptive Server
Logical Page Sizes
Number of columns and column size
Normalization
Levels of normalization
Benefits of normalization
First Normal Form
Second Normal Form
Third Normal Form
Denormalizing for performance
Risks
Disadvantages
Performance advantages
Denormalization input
Techniques
Adding redundant columns
Adding derived columns
Collapsing tables
Duplicating tables
Splitting tables
Horizontal splitting
Vertical splitting
Managing denormalized data
Using triggers
Using application logic
Batch reconciliation
Data Storage
Performance gains through query optimization
Query processing and page reads
Adaptive Server pages
Page headers and page sizes
Varying logical page sizes
Data and index pages
Large Object (LOB) Pages
Extents
Pages that manage space allocation
Global allocation map pages
Allocation pages
Object allocation map pages
How OAM pages and allocation pages manage object storage
Page allocation keeps an object’s pages together
sysindexes table and data access
Space overheads
Number of columns and size
Variable-length columns in APL tables
Variable length columns in DOL tables
Number of rows per data page
Maximum numbers
Arguments for stored procedures
Retrieving data with enhanced limits
Heaps of data: tables without clustered indexes
Lock schemes and differences between heaps
Select operations on heaps
Allpages-locked heap tables
Data-only locked heap tables
Inserting data into an allpages-locked heap table
Conflicts during heap inserts
Inserting data into a data-only-locked heap table
If conflicts occur during heap inserts
Deleting data from a heap table
Deleting from an allpages-locked heap table
Deleting from a data-only locked heap table
Deleting the last row on a page
Updating data on a heap table
Allpages-locked heap tables
Data-only-locked heap tables
How Adaptive Server performs I/O for heap operations
Sequential prefetch, or large I/O
Caches and object bindings
Heaps, I/O, and cache strategies
Overview of cache strategies
LRU replacement strategy
When LRU strategy is used
MRU replacement strategy
Select operations and caching
Data modification and caching
Caching and inserts on heaps
Caching, update and delete operations on heaps
Asynchronous prefetch and I/O on heap tables
Heaps: pros and cons
Maintaining heaps
Methods
Using reorg rebuild to reclaim space
Reclaiming space by creating a clustered index
Reclaiming space using bcp
Transaction log: a special heap table
Setting Space Management Properties
Reducing index maintenance
Advantages of using fillfactor
Disadvantages of using fillfactor
Setting fillfactor values
fillfactor examples
No stored fillfactor values
Table-level or clustered index fillfactor value stored
Use of the sorted_data and fillfactor options
Reducing row forwarding
Default, minimum, and maximum values for exp_row_size
Default value
Specifying an expected row size with create table
Adding or changing an expected row size
Setting a default expected row size server-wide
Displaying the expected row size for a table
Choosing an expected row size for a table
Using optdiag to check for forwarded rows
Querying systabstats to check for forwarded rows
Conversion of max_rows_per_page to exp_row_size
Monitoring and managing tables that use expected row size
Leaving space for forwarded rows and inserts
Extent allocation operations and reservepagegap
Specifying a reserve page gap with create table
Specifying a reserve page gap with create index
Changing reservepagegap
reservepagegap examples
reservepagegap specified only for the table
reservepagegap specified for a clustered index
Choosing a value for reservepagegap
Monitoring reservepagegap settings
reservepagegap and sorted_data options to create index
Background on the sorted_data option
Matching options and goals
Using max_rows_per_page on allpages-locked tables
Reducing lock contention
Indexes and max_rows_per_page
select into and max_rows_per_page
Applying max_rows_per_page to existing data
Memory Use and Performance
How memory affects performance
How much memory to configure
Dynamic reconfiguration
Dynamic memory allocation
How memory is allocated
Caches in Adaptive Server
CAche sizes and buffer pools
Procedure cache
Getting information about the procedure cache size
proc buffers
proc headers
Monitoring procedure cache performance
Procedure cache errors
Procedure cache sizing
Estimating stored procedure size
Data cache
Default cache at installation time
Page aging in data cache
Effect of data cache on retrievals
Effect of data modifications on the cache
Data cache performance
Testing data cache performance
Cache hit ratio for a single query
Cache hit ratio information from sp_sysmon
Configuring the data cache to improve performance
Commands to configure named data caches
Tuning named caches
Cache configuration goals
Gather data, plan, and then implement
Evaluating cache needs
Large I/O and performance
The optimizer and cache choices
Choosing the right mix of I/O sizes for a cache
Reducing spinlock contention with cache partitions
Cache replacement strategies and policies
Strategies
Policies
Named data cache recommendations
Sizing caches for special objects, tempdb, and transaction logs
Determining cache sizes for special tables or indexes
Examining cache needs for tempdb
Examining cache needs for transaction logs
Choosing the I/O size for the transaction log
Configuring for large log I/O size
Additional tuning tips for log caches
Basing data pool sizes on query plans and I/O
Checking I/O size for queries
Configuring buffer wash size
Overhead of pool configuration and binding objects
Pool configuration overhead
Cache binding overhead
Maintaining data cache performance for large I/O
Diagnosing excessive I/O Counts
Using sp_sysmon to check large I/O performance
Speed of recovery
Tuning the recovery interval
Effects of the housekeeper wash task on recovery time
Auditing and performance
Sizing the audit queue
Auditing performance guidelines
Text and images pages
Determining Sizes of Tables and Indexes
Why object sizes are important to query tuning
Tools for determining the sizes of tables and indexes
Effects of data modifications on object sizes
Using optdiag to display object sizes
Advantages of optdiag
Disadvantages of optdiag
Using sp_spaceused to display object size
Advantages of sp_spaceused
Disadvantages of sp_spaceused
Using sp_estspace to estimate object size
Advantages of sp_estspace
Disadvantages of sp_estspace
Using formulas to estimate object size
Factors that can affect storage size
Storage sizes for datatypes
Tables and indexes used in the formulas
Calculating table and clustered index sizes for allpages-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Compute the size of clustered index rows
Step 4: Compute the number of clustered index pages
Step 5: Compute the total number of index pages
Step 6: Calculate allocation overhead and total pages
Step 7: Calculate the size of the leaf index row
Step 8: Calculate the number of leaf pages in the index
Step 9: Calculate the size of the non-leaf rows
Step 10: Calculate the number of non-leaf pages
Step 11: Calculate the total number of non-leaf index pages
Step 12: Calculate allocation overhead and total pages
Calculating the sizes of data-only-locked tables
Step 1: Calculate the data row size
Step 2: Compute the number of data pages
Step 3: Calculate allocation overhead and total pages
Step 4: Calculate the size of the index row
Step 5: Calculate the number of leaf pages in the index
Step 6: Calculate the number of non-leaf pages in the index
Step 7: Calculate the total number of non-leaf index pages
Step 8: Calculate allocation overhead and total pages
Other factors affecting object size
Effects of space management properties
Using average sizes for variable fields
Very small rows
LOB pages
Advantages of using formulas to estimate object size
Disadvantages of using formulas to estimate object size
How Indexes Work
Types of indexes
Index pages
Root level
Leaf level
Intermediate level
Index Size
Clustered indexes on allpages-locked tables
Clustered indexes and select operations
Clustered indexes and insert operations
Page splitting on full data pages
Exceptions to page splitting
Page splitting on index pages
Performance impacts of page splitting
Overflow pages
Clustered indexes and delete operations
Deleting the last row on a page
Index page merges
Nonclustered indexes
Leaf pages revisited
Nonclustered index structure
Nonclustered indexes and select operations
Nonclustered index performance
Nonclustered indexes and insert operations
Nonclustered indexes and delete operations
Clustered indexes on data-only-locked tables
Index covering
Covering matching index scans
Covering nonmatching index scans
Indexes and caching
Using separate caches for data and index pages
Index trips through the cache
Indexing for Performance
How indexes affect performance
Detecting indexing problems
Symptoms of poor indexing
Lack of indexes is causing table scans
Index is not selective enough
Index does not support range queries
Too many indexes slow data modification
Index entries are too large
Exception for wide data rows and wide index rows
Fixing corrupted indexes
Repairing the system table index
Repairing a nonclustered index
Index limits and requirements
Choosing indexes
Index keys and logical keys
Guidelines for clustered indexes
Choosing clustered indexes
Candidates for nonclustered indexes
Index Selection
Examples of using the index selection
Other indexing guidelines
Choosing nonclustered indexes
Performance price for data modification
Choosing composite indexes
Key order and performance in composite indexes
Advantages and disadvantages of composite indexes
Techniques for choosing indexes
Choosing an index for a range query
Adding a point query with different indexing requirements
Index and statistics maintenance
Dropping indexes that hurt performance
Choosing space management properties for indexes
Additional indexing tips
Creating artificial columns
Keeping index entries short and avoiding overhead
Dropping and rebuilding indexes
Configure enough sort buffers
Create the clustered index first
Configure large buffer pools
Asynchronous log service
Understanding the user log cache (ULC) architecture
When to use ALS
Using the ALS
ULC flusher
Log writer
Changes in stored procedures
Cursors and Performance
Definition
Set-oriented versus row-oriented programming
Example
Resources required at each stage
Memory use and execute cursors
Cursor modes
Index use and requirements for cursors
Allpages-locked tables
Data-only-locked tables
Table scans to avoid the Halloween problem
Comparing performance with and without cursors
Sample stored procedure without a cursor
Sample stored procedure with a cursor
Cursor versus noncursor performance comparison
Locking with read-only cursors
Isolation levels and cursors
Partitioned heap tables and cursors
Optimizing tips for cursors
Optimizing for cursor selects using a cursor
Using union instead of or clauses or in lists
Declaring the cursor’s intent
Specifying column names in the for update clause
Using set cursor rows
Keeping cursors open across commits and rollbacks
Opening multiple cursors on a single connection
Maintenance Activities and Performance
Running reorg on tables and indexes
Creating and maintaining indexes
Configuring Adaptive Server to speed sorting
Dumping the database after creating an index
Creating an index on sorted data
Maintaining index and column statistics
Rebuilding indexes
Speeding index creation with sorted_data
Creating or altering a database
Backup and recovery
Local backups
Remote backups
Online backups
Using thresholds to prevent running out of log space
Minimizing recovery time
Recovery order
Bulk copy
Parallel bulk copy
Batches and bulk copy
Slow bulk copy
Improving bulk copy performance
Replacing the data in a large table
Adding large amounts of data to a table
Using partitions and multiple bulk copy processes
Impacts on other users
Database consistency checker
Using dbcc tune (cleanup)
Using dbcc tune on spinlocks
When not to use this command
Determining the space available for maintenance activities
Overview of space requirements
Tools for checking space usage and space available
Checking space used for tables and indexes
Checking space on segments
Checking space requirements for space management properties
Space management properties applied to the table
Space management properties applied to the index
Estimating the effects of space management properties
If there is not enough space
Tuning Asynchronous Prefetch
How asynchronous prefetch improves performance
Improving query performance by prefetching pages
Prefetching control mechanisms in a multiuser environment
Look-ahead set during recovery
Prefetching log pages
Prefetching data and index pages
Look-ahead set during sequential scans
Look-ahead set during nonclustered index access
Look-ahead set during dbcc checks
Allocation checking
checkdb and checktable
Look-ahead set minimum and maximum sizes
When prefetch is automatically disabled
Flooding pools
I/O system overloads
Unnecessary reads
Page chain fragmentation
Tuning Goals for asynchronous prefetch
Commands for configuration
Other Adaptive Server performance features
Large I/O
Sizing and limits for the 16k pool
Limits for the 2K pool
Fetch-and-discard (MRU) scans
Parallel scans and large I/Os
Hash-based table scans
Partition-based scans
Special settings for asynchronous prefetch limits
Setting limits for recovery
Setting limits for dbcc
Maintenance activities for high prefetch performance
Eliminating kinks in heap tables
Eliminating kinks in clustered index tables
Eliminating kinks in nonclustered indexes
Performance monitoring and asynchronous prefetch
tempdb Performance Issues
How management of tempdb affects performance
Main solution areas for tempdb performance
Types and uses of temporary tables
Truly temporary tables
Regular user tables
Worktables
Initial allocation of tempdb
Sizing the tempdb
Placing tempdb
Dropping the master device from tempdb segments
Using multiple disks for parallel query performance
Binding tempdb to its own cache
Commands for cache binding
Temporary tables and locking
Minimizing logging in tempdb
With select into
By using shorter rows
Optimizing temporary tables
Creating indexes on temporary tables
Creating nested procedures with temporary tables
Breaking tempdb uses into multiple procedures
Performance and Tuning: Locking
About this book
Introduction to Performance and Tuning
Locking Overview
How locking affects performance
Overview of locking
Granularity of locks and locking schemes
Allpages locking
Datapages locking
Datarows locking
Types of locks in Adaptive Server
Page and row locks
Table locks
Demand locks
Demand locking with serial execution
Demand locking with parallel execution
Range locking for serializable reads
Latches
Lock compatibility and lock sufficiency
How isolation levels affect locking
Isolation Level 0, read uncommitted
Isolation Level 1, read committed
Isolation Level 2, repeatable read
Isolation Level 3, serializable reads
Adaptive Server default isolation level
Lock types and duration during query processing
Lock types during create index commands
Locking for select queries at isolation Level 1
Table scans and isolation Levels 2 and 3
Table scans and table locks at isolation Level 3
Isolation Level 2 and Allpages-Locked tables
When update locks are not required
Locking during or processing
Processing or queries for Allpages-Locked tables
Processing or queries for Data-Only-Locked tables
Skipping uncommitted inserts during selects
Skipping uncommitted inserts during deletes, updates and inserts
Using alternative predicates to skip nonqualifying rows
Pseudo column-level locking
Select queries that do not reference the updated column
Qualifying old and new values for uncommitted updates
Suggestions to reduce contention
Locking Configuration and Tuning
Locking and performance
Using sp_sysmon and sp_object_stats
Reducing lock contention
Adding indexes to reduce contention
Keeping transactions short
Avoiding hot spots
Additional locking guidelines
Configuring locks and lock promotion thresholds
Configuring Adaptive Server’s lock limit
Estimating number of locks for data-only-locked tables
Configuring the lock hashtable (Lock Manager)
Setting lock promotion thresholds
Lock promotion and scan sessions
Lock promotion high water mark
Lock promotion low water mark
Lock promotion percent
Setting server-wide lock promotion thresholds
Setting the lock promotion threshold for a table or database
Precedence of settings
Dropping database and table settings
Using sp_sysmon while tuning lock promotion thresholds
Choosing the locking scheme for a table
Analyzing existing applications
Choosing a locking scheme based on contention statistics
Monitoring and managing tables after conversion
Applications not likely to benefit from data-only locking
Tables where clustered index performance must remain high
Tables with maximum-length rows
Optimistic index locking
Understanding optimistic index locking
Using optimistic index locking
Cautions and issues
Using Locking Commands
Specifying the locking scheme for a table
Specifying a server-wide locking scheme
Specifying a locking scheme with create table
Changing a locking scheme with alter table
Before and after changing locking schemes
After alter table completes
Expense of switching to or from allpages locking
Sort performance during alter table
Specifying a locking scheme with select into
Controlling isolation levels
Setting isolation levels for a session
Syntax for query-level and table-level locking options
Using holdlock, noholdlock, or shared
Using the at isolation clause
Making locks more restrictive
Using read committed
Making locks less restrictive
Using read uncommitted
Using shared
Readpast locking
Cursors and locking
Using the shared keyword
Additional locking commands
lock table Command
Lock timeouts
Locking Reports
Locking tools
Getting information about blocked processes
Viewing locks
Viewing locks
Intrafamily blocking during network buffer merges
Deadlocks and concurrency
Server-side versus application-side deadlocks
Application deadlock example
Server task deadlocks
Deadlocks and parallel queries
Printing deadlock information to the error log
Avoiding deadlocks
Acquire locks on objects in the same order
Delaying deadlock checking
Identifying tables where concurrency is a problem
Lock management reporting
Indexing for Performance
How indexes affect performance
Detecting indexing problems
Symptoms of poor indexing
Lack of indexes is causing table scans
Index is not selective enough
Index does not support range queries
Too many indexes slow data modification
Index entries are too large
Exception for wide data rows and wide index rows
Fixing corrupted indexes
Repairing the system table index
Repairing a nonclustered index
Index limits and requirements
Choosing indexes
Index keys and logical keys
Guidelines for clustered indexes
Choosing clustered indexes
Candidates for nonclustered indexes
Index Selection
Examples of using the index selection
Other indexing guidelines
Choosing nonclustered indexes
Performance price for data modification
Choosing composite indexes
Key order and performance in composite indexes
Advantages and disadvantages of composite indexes
Techniques for choosing indexes
Choosing an index for a range query
Adding a point query with different indexing requirements
Index and statistics maintenance
Dropping indexes that hurt performance
Choosing space management properties for indexes
Additional indexing tips
Creating artificial columns
Keeping index entries short and avoiding overhead
Dropping and rebuilding indexes
Configure enough sort buffers
Create the clustered index first
Configure large buffer pools
Asynchronous log service
Understanding the user log cache (ULC) architecture
When to use ALS
Using the ALS
ULC flusher
Log writer
Changes in stored procedures
How Indexes Work
Types of indexes
Index pages
Root level
Leaf level
Intermediate level
Index Size
Clustered indexes on allpages-locked tables
Clustered indexes and select operations
Clustered indexes and insert operations
Page splitting on full data pages
Exceptions to page splitting
Page splitting on index pages
Performance impacts of page splitting
Overflow pages
Clustered indexes and delete operations
Deleting the last row on a page
Index page merges
Nonclustered indexes
Leaf pages revisited
Nonclustered index structure
Nonclustered indexes and select operations
Nonclustered index performance
Nonclustered indexes and insert operations
Nonclustered indexes and delete operations
Clustered indexes on data-only-locked tables
Index covering
Covering matching index scans
Covering nonmatching index scans
Indexes and caching
Using separate caches for data and index pages
Index trips through the cache
Performance and Tuning: Monitoring and Analyzing
About this book
Introduction to Performance and Tuning
Monitoring Tables
Monitoring system tables in Adaptive Server
Using Transact-SQL to monitor performance
The mon_role role
Examples of querying the monitoring tables
Processing information through search arguments
Wrapping counter datatypes
Stateful historical monitoring tables
Transient monitoring data
Installing the monitoring tables
Adaptive Server configuration options
deadlock pipe active
deadlock pipe max messages
enable monitoring
errorlog pipe active
errorlog pipe max messages
max SQL text monitored
object lockwait timing
per object statistics active
plan text pipe active
plan text pipe max messages
process wait events
sql text pipe active
sql text pipe max messages
statement pipe active
statement pipe max messages
statement statistics active
SQL batch capture
wait event timing
System tables for monitor tables
monTables
monTableParameters
monTableColumns
monState
monEngine
monDataCache
monProcedureCache
monOpenDatabases
monSysWorkerThread
monNetworkIO
monErrorLog
monLocks
monDeadLock
monWaitClassInfo
monWaitEventInfo
monCachedObject
monCachePool
monOpenObjectActivity
monIOQueue
monDeviceIO
monSysWaits
monProcess
monProcessLookup
monProcessActivity
monProcessNetIO
monProcessObject
monProcessWaits
monProcessStatement
monProcessSQLText
monSysPlanText
monSysStatement
monCachedProcedures
monSysSQLText
monProcessProcedures
Using Statistics to Improve Performance
Importance of statistics
Updating
Adding statistics for unindexed columns
update statistics commands
Using sampling for update statistics
Column statistics and statistics maintenance
Creating and updating column statistics
When additional statistics may be useful
Adding statistics for a column with update statistics
Adding statistics for minor columns with update index statistics
Adding statistics for all columns with update all statistics
Choosing step numbers for histograms
Disadvantages of too many steps
Choosing a step number
Scan types, sort requirements, and locking
Sorts for unindexed or non leading columns
Locking, scans, and sorts during update index statistics
Locking, scans and sorts during update all statistics
Using the with consumers clause
Reducing update statistics impact on concurrent processes
Using the delete statistics command
When row counts may be inaccurate
Using the set statistics Commands
Command syntax
Using simulated statistics
Checking subquery cache performance
Checking compile and execute time
Converting ticks to milliseconds
Reporting physical and logical I/O statistics
Total actual I/O cost value
Statistics for writes
Statistics for reads
Sample output with and without an index
statistics io output for cursors
Scan count
Queries reporting a scan count of 1
Queries reporting a scan count of more than 1
Queries reporting scan count of 0
Relationship between physical and logical reads
Logical reads, physical reads, and 2K I/O
Physical reads and large I/O
Reads and writes on worktables
Effects of caching on reads
statistics io and merge joins
Using set showplan
Using
Basic showplan messages
Query plan delimiter message
Step message
Query type message
FROM TABLE message
FROM TABLE and referential integrity
TO TABLE message
Update mode messages
Direct update mode
Deferred mode
Deferred index and deferred varcol messages
Optimized using messages
Simulated statistics message
Abstract plan messages
showplan messages for query clauses
GROUP BY message
Selecting into a worktable
Grouped aggregate message
Grouped aggregates and group by
compute by message
Ungrouped aggregate message
Ungrouped aggregates
compute messages
messages for order by and distinct
Worktable message for distinct
Worktable message for order by
Sorting messages
Step involves sorting message
GETSORTED message
Serial or parallel sort message
Messages describing access methods, caching, and I/O cost
Auxiliary scan descriptors message
Nested iteration message
Merge join messages
Worktable message
Table scan message
Clustered index message
Index name message
Scan direction messages
Positioning messages
Scanning messages
Index covering message
Keys message
Matching index scans message
Dynamic index message (OR strategy)
Reformatting Message
Trigger Log Scan Message
I/O Size Messages
Cache strategy messages
Total estimated I/O cost message
showplan messages for parallel queries
Executed in parallel messages
Coordinating process message
Worker processes message
Scan type message
Merge messages
Data merge messages
Runtime adjustment message
showplan messages for subqueries
Output for flattened or materialized subqueries
Flattened queries
Materialized queries
Structure of subquery showplan output
Subquery execution message
Nesting level delimiter message
Subquery plan start delimiter
Subquery plan end delimiter
Type of subquery
Subquery predicates
Internal subquery aggregates
Quantified predicate subqueries and the ANY aggregate
Expression subqueries and the ONCE aggregate
Subqueries with distinct and the ONCE-UNIQUE aggregate
Existence join message
Subqueries that perform existence tests
Statistics Tables and Displaying Statistics with optdiag
System tables that store statistics
systabstats table
sysstatistics table
Viewing statistics with the optdiag utility
optdiag syntax
optdiag header information
Table statistics
Sample output for table statistics
Data page CR count
Table-level derived statistics
Data page cluster ratio
Space utilization
Large I/O efficiency
Index statistics
Sample output for index statistics
Index-level derived statistics
Data page cluster ratio
Index page cluster ratio
Data row cluster ratio
Space utilization for an index
Large I/O efficiency for an index
Column statistics
Sample output for column statistics
Range cell and total density values
Range and in-between selectivity values
Histogram displays
Sample output for histograms
Understanding histogram output
Histograms for columns with highly duplicated values
Choosing the number of steps for highly duplicated values
Changing statistics with optdiag
Using the optdiag binary mode
When you must use binary mode
Updating selectivities with optdiag input mode
Editing histograms
Adding frequency count cells to a histogram
Skipping the load-time verification for step numbering
Rules checked during histogram loading
Re-creating indexes without losing statistics updates
Using simulated statistics
optdiag syntax for simulated statistics
Simulated statistics output
Requirements for loading and using simulated statistics
Using simulated statistics in the original database
Using simulated statistics in another database
Dropping simulated statistics
Running queries with simulated statistics
showplan messages for simulated statistics
Character data containing quotation marks
Effects of SQL commands on statistics
How query processing affects systabstats
Tuning with dbcc traceon
Tuning with dbcc traceon(302)
dbcc traceon(310)
Invoking the dbcc trace facility
General tips for tuning with dbcc traceon(302)
Checking for join columns and search arguments
Determining how the optimizer estimates I/O costs
Structure of dbcc traceon(302) output
Additional blocks and messages
Table information block
Identifying the table
Basic table data
Cluster ratio
Partition information
Base cost block
Concurrency optimization message
Clause block
Search clause identification
When search clauses are not optimizable
Values unknown at optimize time
Join clause identification
Sort avert messages
Column block
Selectivities when statistics exist and values are known
When the optimizer uses default values
Unknown values
If no statistics are available
Out-of-range messages
“Disjoint qualifications” message
Forcing messages
Unique index messages
Other messages in the column block
Index selection block
Scan and filter selectivity values
How scan and filter selectivity can differ
Other information in the index selection block
Best access block
dbcc traceon(310) and final query plan costs
Flattened subquery join order message
Worker process information
Final plan information
Sort-merge costs
Monitoring Performance with sp_sysmon
Using
When to run
Invoking
Fixed time intervals
Using begin_sample and end_sample
Specifying report sections for output
Specifying the application detail parameter
Cache Wizard syntax
Parameters
Redirecting output to a file
How to use the reports
Reading output
Rows
Columns
Interpreting the data
Per second and per transaction data
Percent of total and count data
Per engine data
Total or summary data
Sample interval and time reporting
Cache Wizard
Preparing to run the cache wizard
Output
Sample output for Cache Wizard
Kernel utilization
Sample output
Engine busy utilization
CPU yields by engine
Network checks
Non–blocking
Blocking
Total network I/O checks
Average network I/Os per check
Disk I/O checks
Total disk I/O checks
Checks returning I/O
Average disk I/Os returned
Worker process management
Sample output
Worker process requests
Worker process usage
Memory requests for worker processes
Avg mem ever used by a WP
Parallel query management
Sample output
Parallel query usage
Merge lock requests
Sort buffer waits
Task management
Sample output
Connections opened
Task context switches by engine
Task context switches due to
Voluntary yields
Cache search misses
System disk writes
I/O pacing
Logical lock contention
Address lock contention
Latch contention
Log semaphore contention
PLC lock contention
Group commit sleeps
Last log page writes
Modify conflicts
I/O device contention
Network packet received
Network packet sent
Other causes
Application management
Sample output
Requesting detailed application information
Sample output
Application statistics summary (all applications)
Priority changes
Allotted slices exhausted
Skipped tasks by engine
Engine scope changes
Per application or per application and login
Application activity
Application priority changes
Application I/Os completed
Resource limits violated
ESP management
Sample output
ESP requests
Avg. time to execute an ESP
Housekeeper task activity
Sample output
Buffer cache washes
Garbage collections
Statistics updates
Monitor access to executing SQL
Sample output
Waits on execution plans
Number of SQL text overflows
Maximum SQL text requested
Transaction profile
Sample output
Transaction summary
How to count multi database transactions
Transaction detail
Inserts
APL heap tables
APL clustered table
Data only lock table
Total rows inserted
Updates and update detail sections
Updates
Data-only-locked updates
Deletes
Total rows deleted
Transaction management
Sample output
ULC flushes to transaction log
By full ULC
By end transaction
By change of database
By system log record and by other
Total ULC flushes
ULC log records
Maximum ULC size
ULC semaphore requests
Log semaphore requests
Log semaphore contention and user log caches
Transaction log writes
Transaction log allocations
Avg # writes per log page
Index management
Sample output
Nonclustered maintenance
Inserts and updates requiring maintenance to indexes
Deletes requiring maintenance
Row ID updates from clustered split
Data-Only-Locked updates and deletes requiring maintenance
Page splits
Reducing page splits for ascending key inserts
Default data page splitting
Effects of ascending inserts
Setting ascending inserts mode for a table
Retries and deadlocks
Add index level
Page shrinks
Index scans
Metadata cache management
Sample output
Open object, index, and database usage
Object Manager Spinlock Contention
Object and index spinlock contention
Hash spinlock contention
Using sp_monitorconfig to find metadata cache usage statistics
Lock management
Sample output
Lock summary
Lock detail
Address locks
Last page locks on heaps
Table lock hashtable
Deadlocks by lock type
Deadlock detection
Deadlock searches
Searches skipped
Average deadlocks per search
Lock promotions
Lock time-out information
Data cache management
Sample output
Cache statistics summary (all caches)
Cache search summary
Cache turnover
Cache strategy summary
Large I/O usage
Large I/O effectiveness
Asynchronous prefetch activity report
Other asynchronous prefetch statistics
Dirty read behavior
Cache management by cache
Cache spinlock contention
Utilization
Cache search, hit, and miss information
Pool turnover
Buffer wash behavior
Cache strategy
Large I/O usage
Large I/O detail
Dirty read behavior
Procedure cache management
Sample output
Procedure requests
Procedure reads from disk
Procedure writes to disk
Procedure removals
Memory management
Sample output
Pages allocated
Pages released
Recovery management
Sample output
Checkpoints
Number of normal checkpoints
Number of free checkpoints
Total checkpoints
Average time per normal checkpoint
Average time per free checkpoint
Increasing the housekeeper batch limit
Disk I/O management
Sample output
Maximum outstanding I/Os
I/Os delayed by
Disk I/O structures
Server configuration limit
Engine configuration limit
Operating system limit
Requested and completed disk I/Os
Total requested disk I/Os
Completed disk I/Os
Device activity detail
Reads and writes
Total I/Os
Device semaphore granted and waited
Network I/O management
Sample output
Total network I/Os requests
Network I/Os delayed
Total TDS packets received
Total bytes received
Average bytes received per packet
Total TDS packets sent
Total bytes sent
Average bytes sent per packet
Reducing packet overhead
Performance and Tuning: Query Processing and Abstract Plans
About this book
Understanding Query Processing
Query optimizer
Factors analyzed in optimizing queries
Transformations for query optimization
Search arguments converted to equivalent arguments
Search argument transitive closure applied where applicable
equijoin predicate transitive closure applied where applicable
Predicate transformation and factoring to provide additional optimization paths
Handling search arguments and useful indexes
Nonequality operators
Handling joins
join density and join histograms
joins with mixed datatypes
joins with expressions and or predicates
join ordering
Optimization goals
Exceptions
Limiting the time spent optimizing a query
Parallelism
Optimization issues
Query execution engine
Query plans
Query plan operators
Query plan execution
Using showplan
Displaying a query plan
Query plans in Adaptive Server Enterprise 15.0
Statement-level output
Query plan shape
Query plan operators
emit operator
scan operator
from cache message
from or list
from table
I/O size messages
rid scan
log scan
delete, insert, and update operators
text delete operator
Query plans for referential integrity enforcement
join operators
NestedLoopJoin
MergeJoin
HashJoin
NaryNestedLoopJoin operator
Distinct operators
GroupSorted (Distinct) operator
SortOp (Distinct) operator
HashDistinctOp operator
Vector aggregation operators
GroupSortedOp (Aggregation) operator
HashVectorAgOp operator
GroupInsertingOp
compute by message
Union operators
union all operator
merge union operator
hash union
ScalarAggOp operator
restrict operator
sort operator
store operator
sequencer operator
remote scan operator
scroll operator
rid join operator
sqfilter operator
exchange operator
Instead-of trigger operators
instead-of trigger operator
CURSOR SCAN operator
Displaying Query Optimization Strategies and Estimates
set commands for text format messages
set commands for XML format messages
Using show_execio_xml to diagnose query plans
Usage scenarios
Permissions for set commands
Tracing commands
Parallel Query Processing
Vertical, horizontal, and pipelined parallelism
Queries that benefit from parallel processing
Enabling parallelism
Setting the number of worker processes
Setting max parallel degree
Setting max resource granularity
Setting max repartition degree
Setting max scan parallel degree
Setting prod-consumer overlap factor
Setting min pages for parallel scan
Setting max query parallel degree
Controlling parallelism at the session level
set command examples
Controlling query parallelism
Query-level parallel clause examples
Using parallelism selectively
Using parallelism with large numbers of partitions
When parallel query results differ
Queries that use set rowcount
Queries that set local variables
Understanding parallel query plans
Adaptive Server parallel query execution model
exchange operator
Pipe management
Worker process model
Using parallelism in SQL operations
Parallelism of attribute-insensitive operation
Scalar aggregation
union all
Parallelism of attribute-sensitive operation
Subqueries
select into clauses
insert/delete/update
Partition elimination
Partition skew
Why queries do not run in parallel
Runtime adjustment
Recognizing and managing runtime adjustments
Using set process_limit_action
Using showplan
Reducing the likelihood of runtime adjustments
Controlling Optimization
Special optimizing techniques
Specifying query processor choices
Specifying table order in joins
Risks of using forceplan
Things to try before using forceplan
Specifying the number of tables considered by the query processor
Specifying an query index
Risks
Things to try before specifying an index
Specifying I/O size in a query
Index type and large I/O size
When prefetch specification is not followed
setting prefetch
Specifying cache strategy
In select, delete, and update statements
Controlling large I/O and cache strategies
Getting information on cache strategies
Asynchronous log service
Understanding the user log cache (ULC) architecture
When to use ALS
Using the ALS
ULC flusher
Log writer
Changed system procedures
Enabling and disabling merge joins
Enabling and disabling hash joins
Enabling and disabling join transitive closure
Suggesting a degree of parallelism for a query
Query level parallel clause examples
Optimization goals
Setting optimization goals
Optimization criteria
Limiting optimization time
Controlling parallel optimization
Specifying the maximum number of worker processes
Specifying the number of worker processes available for parallel processing
Specifying the percentage of resources available to process a query
Specifying the number of worker processes available to partition a data stream
Concurrency optimization for small tables
Changing locking scheme
Using Statistics to Improve Performance
Statistics maintained in Adaptive Server
Definitions
Importance of statistics
Updating statistics
Adding statistics for unindexed columns
update statistics commands
Using sampling for update statistics
Automatically updating statistics
What is the datachange function?
Configuring automatic update statistics
Using Job Scheduler to update statistics
Examples of updating statistics with datachange
Column statistics and statistics maintenance
Creating and updating column statistics
When additional statistics may be useful
Adding statistics for a column with update statistics
Adding statistics for minor columns with update index statistics
Adding statistics for all columns with update all statistics
Choosing step numbers for histograms
Disadvantages of too many steps
Choosing a step number
Scan types, sort requirements, and locking
Sorts for unindexed or non-leading columns
Locking, scans, and sorts during update index statistics
Locking, scans and sorts during update all statistics
Using the with consumers clause
Reducing update statistics impact on concurrent processes
Using the delete statistics command
When row counts may be inaccurate
Introduction to Abstract Plans
Overview
Managing abstract plans
Relationship between query text and query plans
Limits of options for influencing query plans
Full versus partial plans
Creating a partial plan
Abstract plan groups
How abstract plans are associated with queries
Creating and Using Abstract Plans
Using set commands to capture and associate plans
Enabling plan capture mode with set plan dump
Associating queries with stored plans
Using replace mode during plan capture
When to use replace mode
Using dump, load, and replace modes simultaneously
Using dump and load to the same group
Using dump and load to different groups
set plan exists check option
Using other set options with abstract plans
Using showplan
Using noexec
Using fmtonly
Using forceplan
Server-wide abstract plan capture and association modes
Creating plans using SQL
Using create plan
Using the plan clause
Abstract Query Plan Guide
Introduction
Abstract plan language
Queries, access methods, and abstract plans
Derived tables
Identifying tables
Identifying indexes
Specifying join order
Shorthand notation for joins
Join order examples
Match between execution methods and abstract plans
Specifying join order for queries using views
Specifying the join type
Specifying partial plans and hints
Grouping multiple hints
Inconsistent and illegal plans using hints
Creating abstract plans for subqueries
Materialized subqueries
Flattened subqueries
Example of changing the join order in a flattened subquery
Nested subqueries
Subquery identification and attachment
More subquery examples: reading ordering and attachment
Modifying subquery nesting
Abstract plans for materialized views
Abstract plans for queries containing aggregates
Abstract plans for queries containing unions
Using abstract plans when queries need ordering
Specifying the reformatting strategy
Specifying the OR strategy
When the store operator is not specified
Abstract plans for parallel processing
Tips on writing abstract plans
Comparing plans before and after
Effects of enabling server-wide capture mode
Time and space to copy plans
Abstract plans for stored procedures
Procedures and plan ownership
Procedures with variable execution paths and optimization
Ad hoc queries and abstract plans
Managing Abstract Plans with System Procedures
System procedures for managing abstract plans
Managing an abstract plan group
Creating a group
Dropping a group
Getting information about a group
Renaming a group
Finding abstract plans
Managing individual abstract plans
Viewing a plan
Copying a plan to another group
Dropping an individual abstract plan
Comparing two abstract plans
Changing an existing plan
Managing all plans in a group
Copying all plans in a group
Comparing all plans in a group
Dropping all abstract plans in a group
Importing and exporting groups of plans
Exporting plans to a user table
Importing plans from a user table
Query Processing Metrics
Overview
Executing QP metrics
Accessing metrics
sysquerymetrics view
Using metrics
Examples
Identifying the most expensive statement
Identifying the most frequently used statement for tuning
Identifying possible performance regression
Clearing the metrics
Restricting query metrics capture
Understanding uid in sysquerymetrics
Quick Reference Guide
Quick Reference
Datatypes
Standards and compliance
Adaptive Server global variables
Transact-SQL reserved words
ANSI SQL reserved words
Potential ANSI SQL reserved words
Functions
Commands
Interactive dbsql commands
System procedures
Catalog stored procedures
Extended stored procedures
dbcc stored procedures
System tables
DBCC tables
Utilities
Reference Manual: Building Blocks
About this book
System and User-Defined Datatypes
Datatype categories
Range and storage size
Datatypes of columns, variables, or parameters
Declaring the datatype for a column in a table
Declaring the datatype for a local variable in a batch or procedure
Declaring the datatype for a parameter in a stored procedure
Determining the datatype of a literal
Numeric literals
Character literals
Datatypes of mixed-mode expressions
Determining the datatype hierarchy
Determining precision and scale
Datatype conversions
Automatic conversion of fixed-length NULL columns
Handling overflow and truncation errors
Standards and compliance
Exact numeric datatypes
Integer types
Decimal datatypes
Standards and compliance
Approximate numeric datatypes
Understanding approximate numeric datatypes
Range, precision, and storage size
Entering approximate numeric data
Values that may be entered by Open Client clients
Standards and compliance
Money datatypes
Accuracy
Range and storage size
Entering monetary values
Standards and compliance
Timestamp datatype
Creating a timestamp column
Date and time datatypes
Range and storage requirements
Entering date and time data
Standards and compliance
Character datatypes
unichar, univarchar
Length and storage size
Entering character data
Entering Unicode characters
Treatment of blanks
Manipulating character data
Standards and compliance
Binary datatypes
Valid binary and varbinary entries
Entries of more than the maximum column size
Treatment of trailing zeros
Platform dependence
Standards and compliance
bit datatype
Standards and compliance
sysname and longsysname datatypes
Standards and compliance
text, image, and unitext datatypes
Data structures used for storing text, unitext, and image data
Initializing text, unitext, and image columns
Defining unitext columns
Saving space by allowing NULL
Getting information from sysindexes
Using readtext and writetext
Determining how much space a column uses
Restrictions on text, image, and unitext columns
Selecting text, unitext, and image data
Converting text and image datatypes
Converting to or from unitext
Pattern matching in text data
Duplicate rows
Standards and compliance
User-defined datatypes
Standards and compliance
Transact-SQL Functions
Types of functions
Aggregate functions
Aggregates used with group by
Aggregate functions and NULL values
Vector and scalar aggregates
Aggregate functions as row aggregates
Datatype conversion functions
Converting character data to a noncharacter type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to and from money types
Converting date and time information
Converting between numeric types
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Conversions between binary and integer types
Converting between binary and numeric or decimal types
Converting image columns to binary types
Converting other types to bit
Converting NULL value
Date functions
Date parts
Mathematical functions
Security functions
String functions
Limits on string functions
System functions
Text, unitext, and image columns
Text and image functions
abs
acos
ascii
asin
atan
atn2
avg
audit_event_name
biginttohex
case
cast
ceiling
char
char_length
charindex
coalesce
col_length
col_name
compare
convert
cos
cot
count
count_big
current_date
current_time
curunreservedpgs
data_pages
datachange
datalength
dateadd
datediff
datename
datepart
day
db_id
db_name
degrees
derived_stat
difference
exp
floor
get_appcontext
getdate
getutcdate
has_role
hextobigint
hextoint
host_id
host_name
identity_burn_max
index_col
index_colorder
inttohex
is_quiesced
is_sec_service_on
isnull
lct_admin
left
len
license_enabled
list_appcontext
lockscheme
log
log10
lower
ltrim
max
min
month
mut_excl_roles
newid
next_identity
nullif
object_id
object_name
pagesize
partition_id
partition_name
patindex
pi
power
proc_role
radians
rand
replicate
reserved_pages
reverse
right
rm_appcontext
role_contain
role_id
role_name
round
row_count
rtrim
set_appcontext
show_role
show_sec_services
sign
sin
sortkey
soundex
space
square
sqrt
str
str_replace
stuff
substring
sum
suser_id
suser_name
syb_quit
syb_sendmsg
tan
tempdb_id
textptr
textvalid
to_unichar
tran_dumptable_status
tsequal
uhighsurr
ulowsurr
upper
uscalar
used_pages
user
user_id
user_name
valid_name
valid_user
year
Global Variables
Adaptive Server global variables
Expressions, Identifiers, and Wildcard Characters
Expressions
Size of expressions
Arithmetic and character expressions
Relational and logical expressions
Operator precedence
Arithmetic operators
Bitwise operators
String concatenation operator
Comparison operators
Nonstandard operators
Using any, all and in
Negating and testing
Ranges
Using nulls in expressions
Comparisons that return TRUE
Difference between FALSE and UNKNOWN
Using “NULL” as a character string
NULL compared to the empty string
Connecting expressions
Using parentheses in expressions
Comparing character expressions
Using the empty string
Including quotation marks in character expressions
Using the continuation character
Identifiers
Short identifiers
Tables beginning with # (temporary tables)
Case sensitivity and identifiers
Uniqueness of object names
Using delimited identifiers
Identifying tables or columns by their qualified object name
Using delimited identifiers within an object name
Omitting the owner name
Referencing your own objects in the current database
Referencing objects owned by the database owner
Using qualified identifiers consistently
Determining whether an identifier is valid
Renaming database objects
Using multibyte character sets
Pattern matching with wildcard characters
Using not like
Case and accent insensitivity
Using wildcard characters
The percent sign (%) wildcard character
The underscore (_) wildcard character
Bracketed ([ ]) characters
The caret (^) wildcard character
Using multibyte wildcard characters
Using wildcard characters as literal characters
Using square brackets ( [ ] ) as escape characters
Using the escape clause
Using wildcard characters with datetime data
Reserved Words
Transact-SQL reserved words
ANSI SQL reserved words
Potential ANSI SQL reserved words
SQLSTATE Codes and Messages
Warnings
Exceptions
Cardinality violations
Data exceptions
Integrity constraint violations
Invalid cursor states
Syntax errors and access rule violations
Transaction rollbacks
with check option violation
Reference Manual: Commands
About this book
Commands
Overview
alter database
alter role
alter table
begin...end
begin transaction
break
checkpoint
close
commit
compute clause
connect to...disconnect
continue
create database
create default
create existing table
create function (SQLJ)
create index
create plan
create procedure
create procedure (SQLJ)
create proxy_table
create role
create rule
create schema
create table
create trigger
create view
dbcc
deallocate cursor
declare
declare cursor
delete
delete statistics
disk init
disk mirror
disk refit
disk reinit
disk remirror
disk resize
disk unmirror
drop database
drop default
drop function (SQLJ)
drop index
drop procedure
drop role
drop rule
drop table
drop trigger
drop view
dump database
dump transaction
execute
fetch
goto label
grant
group by and having clauses
if...else
insert
kill
load database
load transaction
lock table
mount
online database
open
order by clause
prepare transaction
print
quiesce database
raiserror
readtext
reconfigure
remove java
reorg
return
revoke
rollback
rollback trigger
save transaction
select
set
setuser
shutdown
truncate table
union operator
unmount
update
update all statistics
update index statistics
update statistics
update table statistics
use
waitfor
where clause
while
writetext
Interactive SQL Commands
clear
configure
connect
disconnect
exit
input
output
parameters
read
set connection
set option
start logging
stop logging
system
Reference Manual: Procedures
About this book
System Procedures
Introduction to system procedures
Permissions on system procedures
Auditing system procedures
Executing system procedures
Entering parameter values
Messages
System procedure tables
List of system procedures
sp_activeroles
sp_add_qpgroup
sp_add_resource_limit
sp_add_time_range
sp_addalias
sp_addauditrecord
sp_addaudittable
sp_addengine
sp_addexeclass
sp_addextendedproc
sp_addexternlogin
sp_addgroup
sp_addlanguage
sp_addlogin
sp_addmessage
sp_addobjectdef
sp_addremotelogin
sp_addsegment
sp_addserver
sp_addthreshold
sp_addtype
sp_addumpdevice
sp_adduser
sp_altermessage
sp_audit
sp_autoconnect
sp_autoformat
sp_bindcache
sp_bindefault
sp_bindexeclass
sp_bindmsg
sp_bindrule
sp_cacheconfig
sp_cachestrategy
sp_changedbowner
sp_changegroup
sp_checknames
sp_checkreswords
sp_checksource
sp_chgattribute
sp_clearpsexe
sp_clearstats
sp_client_addr
sp_cmp_all_qplans
sp_cmp_qplans
sp_commonkey
sp_companion
sp_configure
sp_copy_all_qplans
sp_copy_qplan
sp_countmetadata
sp_cursorinfo
sp_dbextend
sp_dboption
sp_dbrecovery_order
sp_dbremap
sp_defaultloc
sp_depends
sp_deviceattr
sp_diskdefault
sp_displayaudit
sp_displaylevel
sp_displaylogin
sp_displayroles
sp_dropalias
sp_drop_all_qplans
sp_drop_qpgroup
sp_drop_qplan
sp_drop_resource_limit
sp_drop_time_range
sp_dropdevice
sp_dropengine
sp_dropexeclass
sp_dropextendedproc
sp_dropexternlogin
sp_dropglockpromote
sp_dropgroup
sp_dropkey
sp_droplanguage
sp_droplogin
sp_dropmessage
sp_dropobjectdef
sp_dropremotelogin
sp_droprowlockpromote
sp_dropsegment
sp_dropserver
sp_dropthreshold
sp_droptype
sp_dropuser
sp_dumpoptimize
sp_engine
sp_estspace
sp_export_qpgroup
sp_extendsegment
sp_extengine
sp_familylock
sp_find_qplan
sp_fixindex
sp_flushstats
sp_forceonline_db
sp_forceonline_object
sp_forceonline_page
sp_foreignkey
sp_freedll
sp_getmessage
sp_grantlogin
sp_ha_admin
sp_help
sp_help_resource_limit
sp_help_qpgroup
sp_help_qplan
sp_helpartition
sp_helpcache
sp_helpcomputedcolumn
sp_helpconfig
sp_helpconstraint
sp_helpdb
sp_helpdevice
sp_helpextendedproc
sp_helpexternlogin
sp_helpgroup
sp_helpindex
sp_helpjava
sp_helpjoins
sp_helpkey
sp_helplanguage
sp_helplog
sp_helpobjectdef
sp_helpremotelogin
sp_helprotect
sp_helpsegment
sp_helpserver
sp_helpsort
sp_helptext
sp_helpthreshold
sp_helpuser
sp_hidetext
sp_import_qpgroup
sp_indsuspect
sp_ldapadmin
sp_listener
sp_listsuspect_db
sp_listsuspect_object
sp_listsuspect_page
sp_lmconfig
sp_lock
sp_locklogin
sp_logdevice
sp_loginconfig
sp_logininfo
sp_logiosize
sp_maplogin
sp_metrics
sp_modify_resource_limit
sp_modify_time_range
sp_modifylogin
sp_modifystats
sp_modifythreshold
sp_monitor
sp_monitorconfig
sp_object_stats
sp_passthru
sp_password
sp_placeobject
sp_plan_dbccdb
sp_poolconfig
sp_post_xpload
sp_primarykey
sp_processmail
sp_procxmode
sp_recompile
sp_remap
sp_remoteoption
sp_remotesql
sp_rename
sp_rename_qpgroup
sp_renamedb
sp_reportstats
sp_revokelogin
sp_role
sp_sendmsg
sp_serveroption
sp_set_qplan
sp_setlangalias
sp_setpglockpromote
sp_setpsexe
sp_setrowlockpromote
sp_setsuspect_granularity
sp_setsuspect_threshold
sp_showcontrolinfo
sp_showexeclass
sp_showplan
sp_showpsexe
sp_spaceused
sp_ssladmin
sp_syntax
sp_sysmon
sp_tempdb
sp_thresholdaction
sp_transactions
sp_unbindcache
sp_unbindcache_all
sp_unbindefault
sp_unbindexeclass
sp_unbindmsg
sp_unbindrule
sp_version
sp_volchanged
sp_who
Catalog Stored Procedures
Overview
Specifying optional parameters
Pattern matching
System procedure tables
ODBC datatypes
sp_column_privileges
sp_columns
sp_databases
sp_datatype_info
sp_fkeys
sp_pkeys
sp_server_info
sp_special_columns
sp_sproc_columns
sp_statistics
sp_stored_procedures
sp_table_privileges
sp_tables
System Extended Stored Procedures
Overview
Permissions on system ESPs
DLLs associated with system ESPs
Using system ESPs
xp_cmdshell
xp_deletemail
xp_enumgroups
xp_findnextmsg
xp_logevent
xp_readmail
xp_sendmail
xp_startmail
xp_stopmail
dbcc Stored Procedures
Overview
Specifying the object name and date
Specifying the object name
Specifying the date
sp_dbcc_alterws
sp_dbcc_configreport
sp_dbcc_createws
sp_dbcc_deletedb
sp_dbcc_deletehistory
sp_dbcc_differentialreport
sp_dbcc_evaluatedb
sp_dbcc_exclusions
sp_dbcc_faultreport
sp_dbcc_fullreport
sp_dbcc_help_fault
sp_dbcc_patch_finishtime
sp_dbcc_recommendations
sp_dbcc_runcheck
sp_dbcc_statisticsreport
sp_dbcc_summaryreport
sp_dbcc_updateconfig
Reference Manual: Tables
About this book
System Tables
Locations of system tables
System tables in master
System tables in sybsecurity
System table in sybsystemdb
System tables in all databases
About the sybdiagdb database
About the syblicenseslog table
Rules for using system tables
Permissions on system tables
Locking schemes used for system tables
Reserved columns
Updating system tables
Triggers on system tables
syblicenseslog
sysalternates
sysattributes
sysauditoptions
sysaudits_01 – sysaudits_08
syscharsets
syscolumns
syscomments
sysconfigures
sysconstraints
syscoordinations
syscurconfigs
sysdatabases
sysdepends
sysdevices
sysencryptkeys
sysengines
sysgams
sysindexes
sysjars
syskeys
syslanguages
syslisteners
syslocks
sysloginroles
syslogins
syslogs
syslogshold
sysmessages
sysmonitors
sysobjects
syspartitionkeys
syspartitions
sysprocedures
sysprocesses
sysprotects
sysquerymetrics
sysqueryplans
sysreferences
sysremotelogins
sysresourcelimits
sysroles
syssecmechs
syssegments
sysservers
syssessions
sysslices
syssrvroles
sysstatistics
systabstats
systhresholds
systimeranges
systransactions
systypes
sysusages
sysusermessages
sysusers
sysxtypes
dbccdb Tables
dbccdb workspaces
dbccdb log
dbcc_config
dbcc_counters
dbcc_exclusions
dbcc_fault_params
dbcc_faults
dbcc_operation_log
dbcc_operation_results
dbcc_types
System Administration Guide: Volume 1
About this book
Conventions
Formatting SQL statements
SQL syntax conventions
Case
Obligatory options {you must choose at least one}
Optional options
Ellipsis
Expressions
Overview of System Administration
Adaptive Server administration tasks
Roles required for system administration tasks
Database Owner
Database object owner
Using isql to perform system administration tasks
Starting isql
Entering statements
Saving and reusing statements
Using Sybase Central for system administration tasks
System tables
Querying the system tables
Keys in system tables
Updating system tables
System procedures
Using system procedures
System procedure tables
Creating system procedures
System extended stored procedures
Creating system ESPs
Logging error messages
Connecting to Adaptive Server
The interfaces file
Directory services
LDAP as a directory service
Multiple directory services
LDAP directory services versus the Sybase interfaces file
Security features available in Adaptive Server
System and Optional Databases
Overview of system databases
master database
Controlling object creation in master
Backing up master and keeping copies of system tables
model database
sybsystemprocs database
tempdb database
Creating temporary tables
sybsecurity database
sybsystemdb database
sybmgmtdb database
pubs2 and pubs3 sample databases
Maintaining the sample databases
pubs2 image data
dbccdb database
sybdiag database
Determining the version of the installation scripts
System Administration for Beginners
Logical page sizes
Using “test” servers
Understanding new procedures and features
Planning resources
Achieving performance goals
Installing Sybase products
Check product compatibility
Install or upgrade Adaptive Server
Install additional third-party software
Configure and test client connections
Allocating physical resources
Dedicated versus shared servers
Decision support and OLTP applications
Advance resource planning
Operating system configuration
Backup and recovery
Keep up-to-date backups of master
Keep offline copies of system tables
Automate backup procedures
Verify data consistency before backing up a database
Monitor the log size
Ongoing maintenance and troubleshooting
Starting and stopping Adaptive Server
Viewing and pruning the error log
Keeping records
Contact information
Configuration information
Maintenance schedules
System information
Disaster recovery plan
Getting more help
Introduction to the Adaptive Server Plug-in for Sybase Central
Overview for Adaptive Server Sybase Central Plug-in
Using the Adaptive Server Plug-in
Starting and stopping Sybase Central
Registering Adaptive Server Plug-in
Performing common tasks
Using Interactive SQL
Starting Interactive SQL
Setting Configuration Parameters
What are configuration parameters?
The Adaptive Server configuration file
How to modify configuration parameters
Who can modify configuration parameters?
Unit specification using sp_configure
Getting help information on configuration parameters
Using sp_configure
Syntax elements
Parameter parsing
Using sp_configure with a configuration file
Naming tips for the configuration file
Using sp_configure to read or write the configuration file
Parameters for using configuration files
Editing the configuration file
Starting Adaptive Server with a configuration file
The parameter hierarchy
User-defined subsets of the parameter hierarchy: display levels
The effect of the display level on sp_configure output
The reconfigure command
Performance tuning with sp_configure and sp_sysmon
Output from sp_configure
The sysconfigures and syscurconfigs tables
Querying syscurconfigs and sysconfigures: an example
Configuration parameters
Alphabetical listing of configuration parameters
abstract plan cache
abstract plan dump
abstract plan load
abstract plan replace
additional network memory
allocate max shared memory
allow backward scans
allow nested triggers
allow procedure grouping
allow remote access
allow resource limits
allow sendmsg
allow sql server async i/o
allow updates to system tables
audit queue size
auditing
check password for digit
cis bulk insert array size
cis bulk insert batch size
cis connect timeout
cis cursor rows
cis packet size
cis rpc handling
configuration file
cpu accounting flush interval
cpu grace time
current audit table
deadlock checking period
deadlock pipe active
deadlock pipe max messages
deadlock retries
default character set id
default database size
default exp_row_size percent
default fill factor percent
default language id
default network packet size
default sortorder id
default unicode sortorder
default XML sortorder
disable character set conversions
disable disk mirroring
disk i/o structures
dtm detach timeout period
dtm lock timeout period
dump on conditions
dynamic allocation on demand
enable cis
enable DTM
enable enterprise java beans
enable file access
enable full-text search
enable HA
enable housekeeper GC
enable java
enable job scheduler
enable ldap user auth
enable metrics capture
enable monitoring
enable pam user auth
enable real time messaging
enable rep agent threads
enable row level access control
enable ssl
enable semantic partitioning
enable surrogate processing
enable unicode conversion
enable unicode normalization
enable webservices
enable xact coordination
enable xml
errorlog pipe active
errorlog pipe max messages
esp execution priority
esp execution stacksize
esp unload dll
event buffers per engine
event log computer name (Windows only)
event logging (Windows only)
executable codesize + overhead
extended cache size
global async prefetch limit
global cache partition number
heap memory per user
histogram tuning factor
housekeeper free write percent
i/o accounting flush interval
i/o batch size
i/o polling process count
identity burning set factor
identity grab size
job scheduler interval
job scheduler tasks
license information
lock address spinlock ratio
lock hashtable size
lock scheme
lock shared memory
lock spinlock ratio
lock table spinlock ratio
lock wait period
log audit logon failure
log audit logon success
max async i/os per engine
max async i/os per server
max cis remote connections
max concurrently recovered db
max memory
max native threads per engine
max network packet size
max number network listeners
max online engines
max parallel degree
max repartition degree
max resource granularity
max scan parallel degree
max SQL text monitored
maximum dump conditions
maximum failed logins
maximum job output
memory alignment boundary
memory per worker process
messaging memory
minimum password length
msg confidentiality reqd
msg integrity reqd
number of alarms
number of aux scan descriptors
number of checkpoint tasks
number of devices
number of dtx participants
number of dump threads
number of engines at startup
number of histogram steps
number of index trips
number of java sockets
number of large i/o buffers
number of locks
number of mailboxes
number of messages
number of oam trips
number of open databases
number of open indexes
number of open objects
number of open partitions
number of pre-allocated extents
number of remote connections
number of remote logins
number of remote sites
number of sort buffers
number of user connections
number of worker processes
o/s file descriptors
object lockwait timing
open index hash spinlock ratio
open index spinlock ratio
open object spinlock ratio
optimization goal
optimization timeout limit
page lock promotion HWM
page lock promotion LWM
page lock promotion PCT
page utilization percent
partition groups
partition spinlock ratio
per object statistics active
percent database for history
percent database for output
percent history free
percent output free
performance monitoring option
permission cache entries
plan text pipe active
plan text pipe max messages
print deadlock information
print recovery information
procedure cache size
process wait events
read committed with lock
recovery interval in minutes
remote server pre-read packets
row lock promotion HWM
row lock promotion LWM
row lock promotion PCT
rtm thread idle wait period
runnable process search count
sampling percent
secure default login
select on syscomments.text column
shared memory starting address
size of auto identity column
size of global fixed heap
size of process object heap
size of shared class heap
size of unilib cache
SQL batch capture
SQL Perfmon Integration (Windows only)
sql server clock tick length
sql text pipe active
sql text pipe max messages
stack guard size
stack size
start mail session (Windows only)
statement cache size
statement pipe active
statement pipe max messages
statement statistics active
strict dtm enforcement
suspend audit when device full
syb_sendmsg port number
sysstatistics flush interval
systemwide password expiration
tape retention in days
tcp no delay
text prefetch size
time slice
total data cache size
total logical memory
total physical memory
txn to pss ratio
unified login required (Windows only)
upgrade version
use security services (Windows only)
user log cache size
user log cache spinlock ratio
wait event timing
xact coordination interval
xp_cmdshell context
Overview of Disk Resource Issues
Device allocation and object placement
Commands for managing disk resources
Considerations in storage management decisions
Recovery
Keeping logs on a separate device
Mirroring
Performance
Status and defaults at installation time
System tables that manage storage
The sysdevices table
The sysusages table
The syssegments table
The sysindexes table
The syspartitions table
Initializing Database Devices
What are database devices?
Using the disk init command
disk init syntax
disk init examples
Specifying a logical device name with disk init
Specifying a physical device name with disk init
Choosing a device number for disk init
Specifying the device size with disk init
Specifying the dsync setting with disk init (optional)
Performance implications of dsync
Limitations and restrictions of dsync
Using directio to bypass operating system buffer
Other optional parameters for disk init
Getting information about devices
Dropping devices
Designating default devices
Choosing default and nondefault devices
Increasing the size of devices with disk resize
Insufficient disk space
Device shrinkage
disk resize syntax
Disk resize example
Specifying a logical device name with disk resize
Specifying the device size with disk resize
Setting Database Options
What are database options?
Using the sp_dboption procedure
Database option descriptions
abort tran on log full
allow nulls by default
asynch log service
auto identity
dbo use only
ddl in tran
delayed commit
identity in nonunique index
no chkpt on recovery
no free space acctg
read only
select into/bulkcopy/pllsort
single user
trunc log on chkpt
unique auto_identity index
Changing database options
Viewing the options on a database
Configuring Character Sets, Sort Orders, and Languages
Understanding internationalization and localization
Advantages of internationalized systems
A sample internationalized system
Elements of an internationalized system
Selecting the character set for your server
Unicode
Character set installation
Configuration parameters
Functions
Using unichar columns
Using unitext
Open Client interoperability
Java interoperability
Limitations
Selecting the server default character set
Selecting the sort order
Using sort orders
Different types of sort orders
Selecting the default sort order
Selecting the default Unicode sort order
Selecting a language for system messages
Setting up your server: examples
A Spanish-version server
A U.S.-based company in Japan
A Japan-based company with multinational clients
Changing the character set, sort order, or message language
Changing the default character set
Changing the sort order with a resources file
Changing the default sort order
Reconfiguring the character set, sort order, or message language
Unicode examples
Schema
Converting to UTF-8
Migrating selected columns to unichar
Migrating to or from unitext
Preliminary steps
Setting the user’s default language
Recovery after reconfiguration
Using sp_indsuspect to find corrupt indexes
Rebuilding indexes after changing the sort order
Upgrading text data after changing character sets
Retrieving text values after changing character sets
Installing date strings for unsupported languages
Server versus client date interpretation
Internationalization and localization files
Types of internationalization files
Character sets directory structure
Types of localization files
Software messages directory structure
Message languages and global variables
Configuring Client/Server Character Set Conversions
Character set conversion in Adaptive Server
Supported character set conversions
Conversion for native character sets
Conversion in a Unicode system
Types of character set conversion
Adaptive Server direct conversions
Unicode conversions
Which type of conversion do I use?
Non-Unicode client/server systems
Unicode client/server systems
Configuring the server
Enabling and disabling character set conversion
Characters that cannot be converted
Error handling in character set conversion
Conversions and changes to data lengths
Configuring your system and application
Specifying the character set for utility programs
Display and file character set command line options
Setting the display character set
Setting the file character set
Diagnosing System Problems
How Adaptive Server uses error messages
Error messages and message numbers
Variables in error message text
Adaptive Server error logging
Error log format
Severity levels
Security levels 10–18
Level 10: Status information
Level 11: Specified database object not found
Level 12: Wrong datatype encountered
Level 13: User transaction syntax error
Level 14: Insufficient permission to execute command
Level 15: Syntax error in SQL statement
Level 16: Miscellaneous user error
Level 17: Insufficient resources
Level 18: Non-fatal internal error detected
Severity levels 19–26
Level 19: Adaptive Server fatal error in resource
Level 20: Adaptive Server fatal error in current process
Level 21: Adaptive Server fatal error in database processes
Level 22: Adaptive Server fatal error: Table integrity suspect
Level 23: Fatal error: Database integrity suspect
Level 24: Hardware error or system table corruption
Level 25: Adaptive Server internal error
Level 26: Rule error
Reporting errors
Backup Server error logging
Killing processes
Using kill with status only
Using sp_lock to examine blocking processes
Housekeeper functionality
Three housekeepers
Housekeeper wash
Housekeeper chores
Housekeeper garbage collection
Running at user priority
Configuring enable housekeeper GC
Using the reorg command
Configuring Adaptive Server to save SQL batch text
Allocating memory for batch text
Configuring the amount of SQL text retained in memory
Enabling Adaptive Server to start saving SQL text
SQL commands not represented by text
Viewing the query plan of a SQL statement
Viewing previous statements
Viewing a nested procedure
Shutting down servers
Shutting down Adaptive Server
Shutting down a Backup Server
Checking for active dumps and loads
Using nowait on a Backup Server
Learning about known problems
Introduction to Security
Introduction to security
What is “information security?”
Information security standards
Adaptive Server version 12.5.2 available for common criteria configuration
C2 security evaluation for Adaptive Server release 11.0.6
FIPS 140-2 Validated cryptographic module
Getting Started With Security Administration in Adaptive Server
General process of security administration
Recommendations for setting up security
Using the “sa” login
Changing the “sa” login password
When to enable auditing
Assigning login names
An example of setting up security
Introduction to Security Features in Adaptive Server
Identification and authentication
External authentication
Managing remote servers
Discretionary access controls
Policy-Based Access Control
Division of roles
Role hierarchy
Mutual exclusivity
Auditing for accountability
Confidentiality of data
Password-Protected Database Backup
Managing Adaptive Server Logins, Database Users, and Client Connections
Overview
Choosing and creating a password
Adding logins to Adaptive Server
Login failure to Adaptive Server
Creating groups
Adding users to databases
Adding a “guest” user to a database
“guest” user permissions
“guest” user in user databases
“guest” user in pubs2 and pubs3
Adding a guest user to the server
Adding remote users
Number of user and login IDs
Limits and ranges of ID numbers
Login connection limitations
Viewing server limits for logins, users, and groups
Creating and assigning roles to users
System-defined roles
System Administrator privileges
System Security Officer privileges
Operator privileges
Sybase technical support
Replication role
Distributed Transaction Manager role
High availability role
Monitoring and diagnosis
Job Scheduler roles
Real-Time Messaging role
Web Services role
User-defined roles
Planning user-defined roles
Configuring user-defined roles
Creating a user-defined role
Adding and removing passwords from a role
Role hierarchies and mutual exclusivity
Role heirarchies and mutual exclusivity
Defining and changing mutual exclusivity of roles
Defining and changing a role hierarchy
Setting up default activation at login
Activating and deactivating roles
Dropping users, groups, and user-defined roles
Dropping users
Dropping groups
Dropping user-defined roles
Locking or dropping Adaptive Server login accounts
Locking and unlocking login accounts
Dropping login accounts
Locking logins that own thresholds
Changing user information
Changing passwords
Requiring new passwords
Null passwords
Logging in after lost password
Changing user defaults
Changing a user’s group membership
Changing the user process information
Using aliases in databases
Adding aliases
Dropping aliases
Getting information about aliases
Getting information about users
Getting reports on users and processes
Getting information about login accounts
Getting information about database users
Finding user names and IDs
Displaying information about roles
Finding role IDs and names
Viewing active roles
Displaying a role hierarchy
Viewing user roles in a hierarchy
Determining mutual exclusivity
Determining role activation
Checking for roles in stored procedures
Establishing a password and login policy
Setting and changing the maximum login attempts
Logging in after lost password
Locking and unlocking logins and roles
Displaying password information
Checking passwords for at least one digit
Setting and changing minimum password length
Setting the expiration interval for a password
Password expiration turned off for pre-12.x passwords
Message for impending password expiration
Circumventing password protection
Creating a password expiration interval for a new login
Creating a password expiration interval for a new role
Creation date added for passwords
Changing or removing password expiration interval for login or role
Monitoring license use
How licenses are counted
Configuring the License Use Manager to monitor user licenses
Monitoring license use with the housekeeper task
Logging the number of user licenses
Getting information about usage: chargeback accounting
Reporting current usage statistics
Displaying current accounting totals
Initiating a new accounting interval
Specifying the interval for adding accounting statistics
Managing Remote Servers
Overview
Managing remote servers
Adding a remote server
Examples of adding remote servers
Managing remote server names
Setting server connection options
Using the timeouts option
Using the net password encryption option
Using the rpc security model options
Getting information about servers
Dropping remote servers
Adding remote logins
Mapping users’ server IDs
Mapping remote logins to particular local names
Mapping all remote logins to one local name
Keeping remote login names for local servers
Example of remote user login mapping
Password checking for remote users
Effects of using the untrusted mode
Getting information about remote logins
Configuration parameters for remote logins
Allowing remote access
Controlling the number of active user connections
Controlling the number of remote sites
Controlling the number of active remote connections
Controlling number of preread packets
External Authentication
Overview
Configuring Adaptive Server for Network-Based Security
How applications use security services
Login authentication
Message protection
Security services and Adaptive Server
Administering network-based security
Setting up configuration files for security
Preparinglibtcl.cfg to use network-based security
The objectid.dat file
Specifying security information for the server
Identifying users and servers to the security mechanism
Configuring Adaptive Server for security
Enabling network-based security
Using unified login
Requiring message confidentiality with encryption
Requiring data integrity
Memory requirements for network-based security
Restarting the server to activate security services
Determining security mechanisms to support
Adding logins to support unified login
General procedure for adding logins
Establishing security for remote procedures
Security model A
Security model B
Unified login and the remote procedure models
Establishing the security model for RPCs
Setting server options for RPC security model B
Rules for setting up security model B for RPCs
Preparing to use security model B for RPCs
Example of setting up security model B for RPCs
Getting information about remote servers
Connecting to the server and using the security services
Example of using security services
Using security mechanisms for the client
Getting information about available security services
Determining supported security services and mechanisms
Determining enabled security services
Determining whether a security service Is enabled
Using Kerberos
Kerberos compatibility
Starting Adaptive Server under Kerberos
Configuring Kerberos
Configuring Adaptive Server for LDAP User Authenticaiton
Composed DN algorithm
Searched DN algorithm
Configuring LDAP
LDAP administration
Failover support
Adaptive Server logins and LDAP user accounts
Configuring Adaptive Server for authentication using PAM
Enabling PAM in Adaptive Server
Determining which PAM module to use
Configuring operating system files
Running a 32- and 64-bit server on the same machine
Configuring Adaptive Server for PAM user authentication
Adaptive Server logins and PAM user accounts
Enhanced login controls
Forcing authentication
Mapping logins using sp_maplogin
Displaying mapping information
Determining the authentication mechanism
Managing User Permissions
Overview
Permissions for creating databases
Changing database ownership
Database Owner privileges
Permissions on system procedures
Database object owner privileges
Other database user privileges
Granting and revoking permissions
Object access permissions
Concrete identification
Special requirements for SQL92 standard compliance
Examples of granting object access permissions
Examples of revoking object access permissions
Granting and revoking permissions for update statistics, delete statistics, and truncate table
Granting permissions on functions
Granting and revoking permissions to execute commands
Examples of granting object creation permissions
Example of revoking object creation permissions
Granting proxy authorization
Granting permissions on dbcc commands
Server-wide and database-specific dbcc commands
dbcc grantees and users in databases
Permissions on system tables
Granting default permissions to system tables and stored procedures
Combining grant and revoke statements
Understanding permission order and hierarchy
Grant dbcc and set proxy issue warning for fipsflagger
Granting and revoking roles
Granting roles
Understanding grant and roles
Revoking roles
Using row-level access control
Access rules
Syntax for access rules
Using access and extended access rules
Access rule examples
Access rules and alter table command
Access rules and bcp
Access rules as user-defined Java functions
Using the Application Context Facility
Setting permissions for using application context functions
Creating and using application contexts
set_appcontext
get_appcontext
list_appcontext
rm_appcontext
SYS_SESSION system application context
Solving a problem using an access rule and ACF
Using login triggers
Creating login triggers
Configuring login triggers
Executing a login trigger
Understanding login trigger output
Using login triggers for other applications
Login trigger restrictions
Issues and information
Disabling execute privilege on login triggers
Acquiring the permissions of another user
Using setuser
Using proxy authorization
Using set proxy to restrict roles
Executing proxy authorization
Proxy authorization for applications
Reporting on permissions
Querying the sysprotects table for proxy authorization
Displaying information about users and processes
Reporting permissions on database objects or users
Reporting permissions on specific tables
Reporting permissions on specific columns
Using views and stored procedures as security mechanisms
Using views as security mechanisms
Using stored procedures as security mechanisms
Roles and stored procedures
Understanding ownership chains
Example of views and ownership chains
Example of procedures and ownership chains
Permissions on triggers
Auditing
Introduction to auditing in Adaptive Server
Correlating Adaptive Server and operating system audit records
The audit system
The sybsecurity database
The audit queue
Auditing configuration parameters
System procedures for auditing
Installing and setting up auditing
Installing the audit system
Tables and devices for the audit trail
Device for the syslogs transaction log table
Installing auditing with installsecurity
Moving the auditing database to multiple devices
Setting up audit trail management
Setting up threshold procedures
Setting auditing configuration parameters
Setting up transaction log management
Truncating the transaction log
Managing the transaction log with no truncation
Enabling and disabling auditing
Single-table auditing
Establishing and managing single-table auditing
Threshold procedure for single-table auditing
What happens when the current audit table is full?
Recovering when the current audit table is full
Restarting auditing
Setting global auditing options
Auditing options: types and requirements
Examples of setting auditing options
Determining current auditing settings
Adding user-specified records to the audit trail
Examples of adding user-defined audit records
Querying the audit trail
Understanding the audit tables
Reading the extrainfo column
Auditing login failures
Confidentiality of Data
Secure Sockets Layer (SSL) in Adaptive Server
Internet communications overview
Public-key cryptography
SSL overview
SSL in Adaptive Server
SSL filter
Authentication via the certificate
Connection types
Enabling SSL
Obtaining a certificate
Creating server directory entries
Administering certificates
Performance
Cipher Suites
@@ssl_ciphersuite
Setting SSL cipher suite preferences
Examples sp_ssladmin
Other considerations
Kerberos confidentiality
Dumping and loading databases with password protection
Passwords and earlier versions of Adaptive Server
Passwords and character sets
System Administration Guide: Volume 2
About this book
Conventions
Formatting SQL statements
SQL syntax conventions
Case
Obligatory options {you must choose at least one}
Optional options
Ellipsis
Expressions
Limiting Access to Server Resources
What are resource limits?
Planning resource limits
Enabling resource limits
Defining time ranges
Determining the time ranges you need
Creating named time ranges
A time range example
Modifying a named time range
Dropping a named time range
When do time range changes take effect?
Identifying users and limits
Identifying heavy-usage users
Identifying heavy-usage applications
Choosing a limit type
Determining time of enforcement
Determining the scope of resource limits
Understanding limit types
Limiting I/O cost
Identifying I/O costs
Calculating the I/O cost of a cursor
The scope of the io_cost limit type
Limiting elapsed time
The scope of the elapsed_time limit type
Limiting the size of the result set
Determining row count limits
Applying row count limits to a cursor
The scope of the row_count limit type
Setting limits for tempdb space usage
Creating a resource limit
Resource limit examples
Examples
Getting information on existing limits
Example of listing all existing resource limits
Modifying resource limits
Examples of modifying a resource limit
Dropping resource limits
Examples of dropping a resource limit
Resource limit precedence
Time ranges
Resource limits
Mirroring Database Devices
What is disk mirroring?
Deciding what to mirror
Mirroring using minimal physical disk space
Mirroring for nonstop recovery
Conditions that do not disable mirroring
Disk mirroring commands
Initializing mirrors
Unmirroring a device
Temporarily deactivating a device
Permanently disabling a mirror
Effects on system tables
Restarting mirrors
waitfor mirrorexit
Mirroring the master device
Getting information about devices and mirrors
Disk mirroring tutorial
Disk resizing and mirroring
Configuring Memory
Determining memory availability for Adaptive Server
How Adaptive Server allocates memory
Disk space allocation
Larger logical page sizes and buffers
Heap memory
Calculating heap memory
How Adaptive Server uses memory
How much memory does Adaptive Server need?
If you are upgrading
How much memory can Adaptive Server use?
Configuration parameters that affect memory allocation
Dynamically allocating memory
If Adaptive Server cannot start
Dynamically decreasing memory configuration parameters
System procedures for configuring memory
Using sp_configure to set configuration parameters
How much memory is available for dynamic growth?
Using sp_helpconfig
Using sp_monitorconfig
Major uses of Adaptive Server memory
Adaptive Server executable code size
Data and procedure caches
Determining the procedure cache size
Determining the default data cache size
Monitoring cache space
User connections
Open databases, open indexes, and open objects
Number of locks
Database devices and disk I/O structures
Other parameters that use memory
Parallel processing
Worker processes
Remote servers
Number of remote sites
Other configuration parameters for RPCs
Referential integrity
Other parameters that affect memory
The statement cache
Setting the statement cache
Ad hoc query processing
Statement cache sizing
Monitoring the statement cache
Purging the statement cache
Printing statement summaries
Configuring memory for caches
Configuring Data Caches
The Adaptive Server data cache
Cache configuration commands
Information on data caches
Configuring data caches
Mixing static and dynamic parameters
Creating a new cache
Insufficient space for new cache
Adding memory to an existing named cache
Decreasing the size of a cache
Deleting a cache
Explicitly configuring the default cache
Changing the cache type
Configuring cache replacement policy
Dividing a data cache into memory pools
Matching log I/O size for log caches
Binding objects to caches
Cache binding restrictions
Getting information about cache bindings
Checking cache overhead
How overhead affects total cache space
Dropping cache bindings
Changing the wash area for a memory pool
When the wash area is too small
When the wash area is too large
Setting housekeeper to avoid washes for cache
Changing the asynchronous prefetch limit for a pool
Changing the size of memory pools
Moving space from the memory pool
Moving space from other memory pools
Adding cache partitions
Setting the number of cache partitions with sp_configure
Setting the number of local cache partitions
Precedence
Dropping a memory pool
When pools cannot be dropped due to pages use
Cache binding effects on memory and query plans
Flushing pages from cache
Locking to perform bindings
Cache binding effects on stored procedures and triggers
Configuring data caches with the configuration file
Cache and pool entries in the configuration file
Cache configuration guidelines
Configuration file errors
Managing Multiprocessor Servers
Parallel processing
Definitions
Target architecture
Configuring an SMP environment
Managing engines
Resetting the number of engines
Choosing the right number of engines
Starting and stopping engines
Monitoring engine status
Starting and stopping engines with sp_engine
Managing user connections
Configuration parameters that affect SMP systems
Configuring spinlock ratio parameters
Creating and Managing User Databases
Commands for creating and managing user databases
Permissions for managing user databases
Using the create database command
create database syntax
How create database works
Adding users to databases
Assigning space and devices to databases
Default database size and devices
Estimating the required space
Placing the transaction log on a separate device
Estimating the transaction log size
Default log size and device
Moving the transaction log to another device
Using the for load option for database recovery
Using the with override option with create database
Changing database ownership
Using the alter database command
alter database syntax
Using the drop database command
System tables that manage space allocation
The sysusages table
The segmap column
The lstart, size, and vstart columns
Getting information about database storage
Database device names and options
Checking the amount of space used
Checking space used in a database
Checking summary information for a table
Checking information for a table and its indexes
Querying system table for space usage information
Database Mount and Unmount
Overview
Manifest file
Considerations
Device allocation
Moving a database
Copying a database
Performance considerations
System restrictions
Configuration restrictions
Logical restrictions
Device verification
Commands
Unmounting a database
Mounting a database
Renaming devices
Destination changes
quiesce database extension
Examples
Creating and Using Segments
What is a segment?
System-defined segments
Commands and procedures for managing segments
Why use segments?
Controlling space usage
Improving performance
Separating tables, indexes, and logs
Splitting tables
Moving a table to another device
Creating segments
Changing the scope of segments
Extending the scope of segments
Automatically extending the scope of a segment
Reducing the scope of a segment
Assigning database objects to segments
Creating new objects on segments
Placing existing objects on segments
Placing text pages on a separate device
Creating clustered indexes on segments
Dropping segments
Getting information about segments
sp_helpsegment
sp_helpdb
sp_help and sp_helpindex
Segments and system tables
A segment tutorial
Segments and clustered indexes
Using the reorg Command
reorg subcommands
When to run a reorg command
Using the optdiag utility to assess the need for a reorg
Space reclamation without the reorg command
Moving forwarded rows to home pages
Using reorg compact to remove row forwarding
Reclaiming unused space from deletions and updates
Reclaiming unused space and undoing row forwarding
Rebuilding a table
Prerequisites for running reorg rebuild
Changing space management settings before using reorg rebuild
Using the reorg rebuild command on indexes
Syntax
Comments
Limitations
How indexes are rebuilt with reorg rebuild index_name partition_name
Space requirements for rebuilding an index
Performance characteristics
Status messages
resume and time options for reorganizing large tables
Specifying no_of_minutes in the time option
Checking Database Consistency
What is the database consistency checker?
Understanding page and object allocation concepts
Understanding the object allocation map (OAM)
Understanding page linkage
What checks can be performed with dbcc?
Checking consistency of databases and tables
dbcc checkstorage
Advantages of using dbcc checkstorage
Comparison of dbcc checkstorage and other dbcc commands
Understanding the dbcc checkstorage operation
Performance and scalability
dbcc checktable
dbcc checkdb
Checking page allocation
dbcc checkalloc
dbcc indexalloc
dbcc tablealloc
Correcting allocation errors using the fix | nofix option
Generating reports with dbcc tablealloc and dbcc indexalloc
Checking consistency of system tables
Understanding the output from dbcc commands
Strategies for using consistency checking commands
Comparing the performance of dbcc commands
Using large I/O and asynchronous prefetch
Scheduling database maintenance at your site
Database use
Backup schedule
Size of tables and importance of data
Understanding the output from dbcc commands
Errors generated by database consistency problems
Reporting on aborted checkstorage and checkverify operations
Comparison of soft and hard faults
Soft faults
Hard faults
Verifying faults with dbcc checkverify
How dbcc checkverify works
When to use dbcc checkverify
How to use dbcc checkverify
Dropping a damaged database
Preparing to use dbcc checkstorage
Planning resources
Examples of sp_plan_dbccdb output
Planning workspace size
Configuring Adaptive Server for dbcc checkstorage
Configuring worker processes
Setting up a named cache for dbcc
Configuring an 8-page I/O buffer pool
Allocating disk space for dbccdb
Segments for workspaces
Creating the dbccdb database
Updating the dbcc_config table
Adding default configuration values with sp_dbcc_updateconfig
Deleting configuration values with sp_dbcc_updateconfig
Viewing the current configuration values
Maintaining dbccdb
Reevaluating and updating dbccdb configuration
Cleaning up dbccdb
Removing workspaces
Performing consistency checks on dbccdb
Generating reports from dbccdb
Reporting a summary of dbcc checkstorage operations
Reporting configuration, statistics and fault information
Displaying configuration information for a target database
Comparing results of dbcc checkstorage operations
Reporting faults found in a database object
Reporting statistics information from dbcc_counter
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Developing a Backup and Recovery Plan
Keeping track of database changes
Getting information about the transaction log
Using delayed_commit to determine when log records are committed
Synchronizing a database and its log: checkpoints
Setting the recovery interval
Automatic checkpoint procedure
Checkpoint after user database upgrade
Truncating the log after automatic checkpoints
Free checkpoints
Manually requesting a checkpoint
Automatic recovery after a system failure or shutdown
Determining whether messages are displayed during recovery
Fast recovery
Adaptive Server start-up sequence
Bringing engines online early
Parallel recovery
max concurrently recovered db
Database recovery
Recovery order
Parallel checkpoints
number of checkpoint tasks
Recovery state
Tuning for fast recovery
Database layout
Runtime configuration suggestions
Recovery time suggestions
User-defined database recovery order
Using sp_dbrecovery_order
Changing or deleting the recovery position of a database
Listing the user-assigned recovery order of databases
Fault isolation during recovery
Persistence of offline pages
Configuring recovery fault isolation
Isolating suspect pages
Raising the number of suspect pages allowed
Getting information about offline databases and pages
Bringing offline pages online
Index-level fault isolation for data-only-locked tables
Side effects of offline pages
Recovery strategies using recovery fault isolation
Reload strategy
Repair strategy
Assessing the extent of corruption
Using the dump and load commands
Making routine database dumps: dump database
Making routine transaction log dumps: dump transaction
Copying the log after device failure: dump tran with no_truncate
Restoring the entire database: load database
Applying changes to the database: load transaction
Making the database available to users: online database
dump and load databases across platforms
Dump and load across platforms with the same endian architecture
Dump and load across platforms with different endian architecture
Dumping a database
Loading a database
Restrictions
Performance notes
Moving a database to another Adaptive Server
Upgrading a user database
Using the special dump transaction options
Using the special load options to identify dump files
Restoring a database from backups
Suspending and resuming updates to databases
Guidelines for using quiesce database
Maintaining server roles in a primary and secondary relationship
Starting the secondary server with the -q option
“in quiesce” database log record value updated
Updating the dump sequence number
Backing up primary devices with quiesce database
Recovery of databases for warm standby method
Making archived copies during the quiescent state
Using mount and unmount commands
Manifest file
Performance considerations
System restrictions
Unmounting the database
Mounting a database
Renaming devices
quiesce database
Creating a mountable copy of a database
Moving databases from one Adaptive Server to another
Designating responsibility for backups
Using the Backup Server for backup and recovery
Relationship between Adaptive Server and Backup Servers
Communicating with the Backup Server
Mounting a new volume
Starting and stopping Backup Server
Configuring your server for remote access
Choosing backup media
Protecting backup tapes from being overwritten
Dumping to files or disks
Creating logical device names for local dump devices
Listing the current device names
Adding a backup device
Redefining a logical device name
Scheduling backups of user databases
Scheduling routine backups
Other times to back up a database
Dumping a user database after upgrading
Dumping a database after creating an index
Dumping a database after unlogged operations
Dumping a database when the log has been truncated
Scheduling backups of master
Dumping master after each change
Saving scripts and system tables
Truncating the master database transaction log
Avoiding volume changes and recovery
Scheduling backups of the model database
Truncating the model database’s transaction log
Scheduling backups of the sybsystemprocs database
Configuring Adaptive Server for simultaneous loads
Gathering backup statistics
Backing Up and Restoring User Databases
Dump and load command syntax
Specifying the database and dump device
Rules for specifying database names
Rules for specifying dump devices
Tape device determination by backup server
Tape sevice configuration file
Compressing a dump
Backup Server dump files and compressed dumps
Loading compressed dumps
Specifying a remote Backup Server
Specifying tape density, block size, and capacity
Overriding the default density
Overriding the default block size
Specifying a higher block size value
Specifying tape capacity for dump commands
Non-rewinding tape functionality for Backup Server
Dump label changes
Tape operations
Dump version compatibility
Specifying the volume name
Loading from a multifile volume
Identifying a dump
Improving dump or load performance
Compatibility with prior versions
Labels stored in integer format
Configuring system resources
Setting shared memory usage
Setting maximum number of stripes
Setting maximum number of network connections
Setting maximum number of service threads
Specifying additional dump devices: the stripe on clause
Dumping to multiple devices
Loading from multiple devices
Using fewer devices to load than to dump
Specifying the characteristics of individual devices
Tape handling options
Specifying whether to dismount the tape
Rewinding the tape
Protecting dump files from being overwritten
Reinitializing a volume before a dump
Dumping multiple databases to a single volume
Dumping and loading databases with password protection
Passwords and earlier versions of Adaptive Server
Passwords and character sets
Overriding the default message destination
Bringing databases online with standby_access
When do I use with standby_access?
Bring databases online with standby_access
Getting information about dump files
Requesting dump header information
Determining the database, device, file name, and date
Copying the log after a device failure
Truncating a log that is not on a separate segment
Truncating the log in early development environments
Truncating a log that has no free space
Dangers of using with truncate_only and with no_log
Providing enough log space
The syslogshold table
Responding to volume change requests
sp_volchanged syntax
Volume change prompts for dumps
Volume change prompts for loads
Recovering a database: step-by-step instructions
Getting a current dump of the transaction log
Examining the space usage
Dropping the databases
Dropping the failed devices
Initializing new devices
Re-creating the databases
Loading the database
Loading the transaction logs
Loading a transaction log to a point in time
Bringing the databases online
Replicated databases
Loading database dumps from older versions
How to upgrade a dump to Adaptive Server
The database offline status bit
Version identifiers
Cache bindings and loading databases
Databases and cache bindings
Database objects and cache bindings
Checking on cache bindings
Cross-database constraints and loading databases
Restoring the System Databases
What does recovering a system database entail?
Symptoms of a damaged master database
Recovering the master database
About the recovery process
Summary of recovery procedure
Step 1: Find copies of system tables
Step 2: Build a new master device
Step 3: Start Adaptive Server in master-recover mode
Step 4: Re-create device allocations for master
Step 5: Check your Backup Server sysservers information
Step 6: Verify that your Backup Server is running
Step 7: Load a backup of master
Step 8: Update the number of devices configuration parameter
Step 9: Restart Adaptive Server in master-recover mode
Step 10: Check system tables to verify current backup of master
Step 11: Restart Adaptive Server
Step 12: Restore server user IDs
Step 13: Restore the model database
Step 14: Check Adaptive Server
Step 15: Back up master
Recovering the model database
Restoring the generic model database
Restoring model from a backup
Restoring model with no backup
Recovering the sybsystemprocs database
Restoring sybsystemprocs with installmaster
Restoring sybsystemprocs with load database
Restoring system tables with disk reinit and disk refit
Restoring sysdevices with disk reinit
Restoring sysusages and sysdatabase with disk refit
Automatic Database Expansion
Introduction
Understanding disks, devices, databases, and segments
Threshold action procedures
Installing automatic database expansion procedures
Using the stored procedure
Command options in the sp_dbextend interface
Dropping the threshold action procedure
Testing the process with sp_dbextend
Setting up the pubs2 database for automatic expansion
Restrictions and limitations
Managing Free Space with Thresholds
Monitoring free space with the last-chance threshold
Crossing the threshold
Controlling how often sp_thresholdaction executes
Rollback records and the last-chance threshold
Calculating the space for rollback records
Using lct_admin to determine the free log space
Determining the current space for rollback records
Effect of rollback records on the last-chance threshold
User-defined thresholds
Last-chance threshold and user log caches for shared log and data segments
Reaching last-chance threshold suspends transactions
Using lct_admin abort to abort suspended transactions
lct_admin abort syntax
Getting the process ID for the oldest open transaction
Using alter database when the master database reaches the last-chance threshold
Automatically aborting or suspending processes
Using abort tran on log full to abort transactions
Waking suspended processes
Adding, changing, and deleting thresholds
Displaying information about existing thresholds
Thresholds and system tables
Adding a free-space threshold
Changing a free-space threshold
Specifying a new last-chance threshold procedure
Dropping a threshold
Creating a free-space threshold for the log segment
Adding a log threshold at 45 percent of log size
Testing and adjusting the new threshold
Creating additional thresholds on other segments
Determining threshold placement
Creating threshold procedures
Declaring procedure parameters
Generating error log messages
Dumping the transaction log
A simple threshold procedure
A more complex procedure
Deciding where to put a threshold procedure
Disabling free-space accounting for data segments
System Tables Diagram
Transact-SQL User’s Guide
About this book
SQL Building Blocks
SQL in Adaptive Server
Queries, data modification, and commands
Tables, columns, and rows
Relational operations
Compiled objects
Saving or restoring source text
Verifying and encrypting source text
Naming conventions
SQL data characters
SQL language characters
Identifiers
Multibyte character sets
Delimited identifiers
Uniqueness and qualification conventions
Remote servers
Expressions in Adaptive Server
Arithmetic and character expressions
Operator precedence
Arithmetic operators
Bitwise operators
The String concatenation operator
The comparison operators
Nonstandard operators
Character expression comparisons
Empty strings
Quotation marks
Relational and logical expressions
any, all, and in
and and or
Transact-SQL extensions
compute clause
Control-of-flow language
Stored procedures
Extended stored procedures
Triggers
Defaults and rules
Error handling and set options
Additional Adaptive Server extensions to SQL
Compliance to ANSI standards
Federal Information Processing Standards (FIPS) flagger
Chained transactions and isolation levels
Identifiers
SQL standard-style comments
Right truncation of character strings
Permissions required for update and delete statements
Arithmetic errors
Synonymous keywords
Treatment of nulls
Adaptive Server login accounts
Group membership
Role membership
Information about your Adaptive Server account
Password changes
Remote logins
Password changes on a remote server
isql utility
Default databases
Network-based security services with isql
isql logout
pubs2 and pubs3 sample databases
Sample database content
Queries: Selecting Data from a Table
What are queries?
select syntax
Choosing columns using the select clause
Choosing all columns using select *
Choosing specific columns
Rearranging the column order
Renaming columns in query results
Using expressions
Quoted strings in column headings
Character strings in query results
Computed values in the select list
Arithmetic operator precedence
Selecting text, unitext, image, and values
Using readtext
Select list summary
Eliminating duplicate query results with distinct
Specifying tables with the from clause
Selecting rows using the where clause
Comparison operators
Ranges (between and not between)
Lists (in and not in)
Matching patterns
Matching character strings: like
Using not like
Getting different results using not like and ^
Using wildcard characters as literal characters
Interaction of wildcard characters and square brackets
Using trailing blanks and %
Using wildcard characters in columns
Character strings and quotation marks
“Unknown” values: NULL
Testing a column for null values
Difference between FALSE and UNKNOWN
Substituting a value for NULLs
Expressions that evaluate to NULL
Concatenating strings and NULL
System-generated NULLs
Connecting conditions with logical operators
Logical operator precedence
Using Aggregates, Grouping, and Sorting
Using aggregate functions
Aggregate functions and datatypes
count vs. count (*)
Aggregate functions with distinct
Null values and the aggregate functions
Organizing query results into groups: the group by clause
group by syntax
group by and SQL standards
Nesting groups with group by
Referencing other columns in queries using group by
Using outer joins and and aggregate extended columns
Expressions and group by
Using group by in nested aggregates
Null values and group by
where clause and group by
group by and all
Aggregates without group by
Selecting groups of data: the having clause
How the having, group by, and where clauses interact
Using having without group by
Sorting query results: the order by clause
order by and group by
order by and group by used with select distinct
Summarizing groups of data: the compute clause
Row aggregates and compute
Rules for compute clauses
Specifying more than one column after compute
Using more than one compute clause
Applying an aggregate to more than one column
Using different aggregates in the same compute clause
Generating totals: compute without by
Combining queries: the union operator
Guidelines for union queries
Using union with other Transact-SQL commands
Joins: Retrieving Data from Several Tables
How joins work
Join syntax
Joins and the relational model
How joins are structured
The from clause
The where clause
Join operators
Datatypes in join columns
Joins and text and image columns
How joins are processed
Equijoins and natural joins
Joins with additional conditions
Joins not based on equality
Self-joins and correlation names
The not-equal join
Not-equal joins and subqueries
Joining more than two tables
Outer joins
Inner and outer tables
Outer join restrictions
Views used with outer joins
ANSI inner and outer joins
Correlation name and column referencing rules for ANSI joins
ANSI inner joins
ANSI outer joins
Should the predicate be in the on or where clause?
Nested ANSI outer joins
Converting outer joins with join-order dependency
Transact-SQL outer joins
How null values affect joins
Determining which table columns to join
Subqueries: Using Queries Within Other Queries
How subqueries work
Subquery syntax
Subquery restrictions
Example of using a subquery
Qualifying column names
Subqueries with correlation names
Multiple levels of nesting
Subqueries in update, delete, and insert statements
Subqueries in conditional statements
Subqueries instead of expressions
Types of subqueries
Expression subqueries
Using scalar aggregate functions to guarantee a single value
Using group by and having in expression subqueries
Using distinct with expression subqueries
Quantified predicate subqueries
Subqueries with any and all
Subqueries used with in
Subqueries used with not in
Subqueries using not in with NULL
Subqueries used with exists
Subqueries used with not exists
Finding intersection and difference with exists
Subqueries using SQL derived tables
Using correlated subqueries
Correlated subqueries containing Transact-SQL outer joins
Correlated subqueries with correlation names
Correlated subqueries with comparison operators
Correlated subqueries in a having clause
Using and Creating Datatypes
How Transact-SQL datatypes work
Using system-supplied datatypes
Exact numeric types: integers
Exact numeric types: decimal numbers
Approximate numeric datatypes
Money datatypes
Date and time datatypes
Character datatypes
unichar datatype
text datatype
unitext datatype
Binary datatypes
image datatype
The bit datatype
The timestamp datatype
The sysname and longsysname datatype
Converting between datatypes
Mixed-mode arithmetic and datatype hierarchy
Working with money datatypes
Determining precision and scale
Creating user-defined datatypes
Creating a user-defined datatype with the identity property
Specifying length, precision, and scale
Specifying null type
Associating rules and defaults with user-defined datatypes
Creating user-defined datatype with IDENTITY property
Creating IDENTITY columns from user-defined datatypes
Dropping a user-defined datatype
Getting information about datatypes
Adding, Changing, and Deleting Data
Introduction
Permissions
Referential integrity
Transactions
Using the sample databases
Datatype entry rules
char, nchar, unichar, univarchar, varchar, nvarchar, unitext, and text
date and time
Entering times
Entering dates
Searching for dates and times
binary, varbinary, and image
money and smallmoney
float, real, and double precision
decimal and numeric
Integer types and their unsigned counterparts
timestamp
Adding new data
insert syntax
Adding new rows with values
Inserting data into specific columns
Restricting column data: rules
Using the NULL character string
Inserting NULLs into columns that do not allow them
Adding rows without values in all columns
Changing a column’s value to NULL
Adaptive-Server-generated values for IDENTITY columns
Explicitly inserting data into an IDENTITY column
Retrieving IDENTITY column values with @@identity
Reserving a block of IDENTITY column values
Reaching the IDENTITY column’s maximum value
Adding new rows with select
Using computed columns
Inserting data into some columns
Inserting data from the same table
Changing existing data
update syntax
Using the set clause with update
Assigning variables in the set clause
Using the where clause with update
Using the from clause with update
Performing updates with joins
Updating IDENTITY columns
Changing text, unitext, and image data
Deleting data
Using the from clause with delete
Deleting from IDENTITY columns
Deleting all rows from a table
truncate table syntax
Creating Databases and Tables
What are databases and tables?
Enforcing data integrity in databases
Permissions within databases
Using and creating databases
Choosing a database: use
Creating a user database: create database
The on clause
The log on clause
The for load option
quiesce database command
Altering the sizes of databases
Dropping databases
Creating tables
Maximum number of columns per table
Example of creating a table
Choosing table names
Creating tables in different databases
create table syntax
Using IDENTITY columns
Creating IDENTITY columns with user-defined datatypes
Referencing IDENTITY columns
Referring to IDENTITY columns with syb_identity
Creating “hidden” IDENTITY columns automatically
Allowing null values in a column
Constraints and rules used with null values
Defaults and null values
Nulls require variable-length datatypes
text, unitext, and image columns
Using temporary tables
Ensuring that the temporary table name is unique
Manipulating temporary tables in stored procedures
General rules on temporary tables
Managing identity gaps in tables
Parameters for controlling identity gaps
Comparison of identity burning set factor and identity_gap
Example of using identity burning set factor
Example of using identity_gap
Setting the table-specific identity gap
Setting identity gap with create table
Setting identity gap with select into
Changing the table-specific identity gap
Displaying table-specific identity gap information
Gaps from other causes
When table inserts reach IDENTITY column maximum value
Defining integrity constraints for tables
Specifying table-level or column-level constraints
Creating error messages for constraints
After creating a check constraint
Specifying default column values
Specifying unique and primary key constraints
Specifying referential integrity constraints
Table-level or column-level referential integrity constraints
Maximum number of references allowed for a table
Using create schema for cross-referencing constraints
General rules for creating referential integrity constraints
Specifying check constraints
Designing applications that use referential integrity
How to design and create a table
Make a design sketch
Create the user-defined datatypes
Choose the columns that accept null values
Define the table
Creating new tables from query results: select into
Checking for errors
Using select into with IDENTITY columns
Selecting an IDENTITY column into a new table
Selecting the IDENTITY column more than once
Adding a new IDENTITY column with select into
Defining a column whose value must be computed
IDENTITY columns selected into tables with unions or joins
Altering existing tables
Objects using select * do not list changes to table
Using alter table on remote tables
Adding columns
Adding columns appends column IDs
Adding NOT NULL columns
Adding constraints
Dropping columns
Dropping columns renumbers the column ID
Dropping constraints
Modifying columns
Which datatypes can I convert?
Modifying tables may prevent successful bulk copy of previous dump
Decreasing column length may truncate data
Modifying datetime columns
Modifying the NULL default value of a column
Modifying columns that have precision or scale
Modifying text, unitext, and image columns
Adding, dropping, and modifying IDENTITY columns
Adding IDENTITY columns
Dropping IDENTITY columns
Modifying IDENTITY columns
Data copying
Changing exp_row_size
Modifying locking schemes and table schema
Altering columns with user-defined datatypes
Adding a column with user-defined datatypes
Dropping a column with user-defined datatypes
Modifying a column with user-defined datatypes
Errors and warnings from alter table
Errors and warnings generated by alter table modify
Scripts generated by if exists()...alter table
Renaming tables and other objects
Renaming dependent objects
Dropping tables
Computed columns—overview
Using computed columns
Computed columns example
Indexes on computed columns
Computed columns and function-based indexes syntax changes
Deterministic property
What is the deterministic property?
What affects the deterministic property?
How does the deterministic property affect computed columns?
Examples
How does the deterministic property affect function-based indexes?
Assigning permissions to users
Getting information about databases and tables
Getting help on databases
Getting help on database objects
Using sp_help on database objects
Using sp_helpconstraint to find a table’s constraint information
Finding out how much space a table uses
Listing tables, columns, and datatypes
Finding an object name and ID
SQL Derived Tables
Differences from abstract plan derived tables
How SQL derived tables work
Advantages of SQL derived tables
SQL derived tables and optimization
SQL derived table syntax
Derived column lists
Correlated SQL derived tables
Using SQL derived tables
Nesting
Subqueries using SQL derived tables
Unions
Unions in subqueries
Renaming columns with SQL derived tables
Constant expressions
Aggregate functions
Joins with SQL derived tables
Creating a table from a SQL derived table
Using views with SQL derived tables
Correlated attributes
Partitioning Tables and Indexes
Overview
Upgrading from Adaptive Server 12.5.x and earlier
Data partitions
Index partitions
Partition IDs
Locks and partitions
Partitioning types
Range partitioning
Hash partitioning
List partitioning
Round-robin partitioning
Composite partitioning keys
Partition pruning
Indexes and partitions
Global indexes
Global nonclustered index on unpartitioned table
Global clustered index on unpartitioned table
Global clustered index on round-robin partitioned table
Global nonclustered index on partitioned table
Local indexes
Local clustered indexes
Local nonclustered indexes
Guaranteeing a unique index
Creating and managing partitions
Enabling partitioning
Partitioning tasks
Creating data partitions
Creating a range-partitioned table
Creating a hash-partitioned table
Creating a list-partitioned table
Creating a round-robin–partitioned table
Creating partitioned indexes
Creating global indexes
Creating local indexes
Creating clustered indexes on partitioned tables
Creating a partitioned table from an existing table
Altering data partitions
Changing an unpartitioned table to a partitioned table
Adding partitions to a partitioned table
Changing the partitioning type
Changing the partitioning key
Unpartitioning round-robin–partitioned tables
Using the partition parameter
Altering partition key columns
Configuring partitions
Updating, deleting, and inserting in partitioned tables
Updating values in partition-key columns
Displaying information about partitions
Using functions
Truncating a partition
Using partitions to load table data
Updating partition statistics
Views: Limiting Access to Data
How views work
Advantages of views
Security
Logical data independence
View examples
Creating views
create view syntax
Using the select statement with create view
View definition with projection
View definition with a computed column
View definition with an aggregate or built-in function
View definition with a join
Views used with outer joins
Views derived from other views
distinct views
Views that include IDENTITY columns
After creating a view
Validating a view’s selection criteria
Views derived from other views
Retrieving data through views
View resolution
Redefining views
Renaming views
Altering or dropping underlying objects
Modifying data through views
Restrictions on updating views
Computed columns in a view definition
group by or compute in a view definition
NULL values in underlying objects
Views created using with check option
Multitable views
Views with IDENTITY columns
Dropping views
Using views as security mechanisms
Getting information about views
Getting help on views with sp_help
Using sp_helptext to display view information
Using sp_depends to list dependent objects
Listing all views in a database
Finding an object name and ID
Creating Indexes on Tables
How indexes work
Comparing the two ways to create indexes
Guidelines for using indexes
When to index
When not to index
Creating indexes
create index syntax
Indexing more than one column: composite indexes
Indexing with function-based indexes
Syntax changes
Using the unique option
Including IDENTITY columns in nonunique indexes
Ascending and descending index-column values
Using fillfactor, max_rows_per_page, and reservepagegap
Indexes on computed columns
Function-based indexes
Using clustered or nonclustered indexes
Creating clustered indexes on segments
Specifying index options
Using the ignore_dup_key option
Using the ignore_dup_row and allow_dup_row options
Using the sorted_data option
Using the on segment_name option
Dropping indexes
Determining what indexes exist on a table
Updating statistics about indexes
Defining Defaults and Rules for Data
How defaults and rules work
Creating defaults
create default syntax
Binding defaults
Unbinding defaults
How defaults affect NULL values
After creating a default
Dropping defaults
Creating rules
create rule syntax
Binding rules
Rules bound to columns
Rules bound to user-defined datatypes
Precedence of rules
Rules and NULL values
After defining a rule
Unbinding rules
Dropping rules
Getting information about defaults and rules
Using Batches and Control-of-Flow Language
Introduction
Rules associated with batches
Examples of using batches
Batches submitted as files
Using control-of-flow language
if...else
case expression
Using case expression for alternative representation
case and division by zero
Using rand() functions in case expressions
case expression results
case expression requires at least one non-null result
case
case and value comparisons
coalesce
nullif
begin...end
while and break...continue
declare and local variables
goto
return
print
raiserror
Creating messages for print and raiserror
waitfor
Comments
Slash-asterisk style comments
Double-hyphen style comments
Local variables
Declaring local variables
Local variables and select statements
Local variables and update statements
Local variables and subqueries
Local variables and while loops and if…else blocks
Variables and null values
Global variables
Transactions and global variables
Checking for errors with @@error
Checking IDENTITY values with @@identity
Checking the transaction nesting level with @@trancount
Checking the transaction state with @@transtate
Checking the nesting level with @@nestlevel
Checking the status from the last fetch
Global variables affected by set options
Language and character set information in global variables
Global variables for monitoring system activity
Optimizer and partition information stored in global variables
Server information stored in global variables
Global variables and text, unitext, and image data
Using the Built-In Functions in Queries
System functions that return database information
Examples of using system functions
col_length
datalength
isnull
user_name
String functions used for character strings or expressions
Examples of using string functions
charindex, patindex
str
stuff
soundex, difference
substring
Examples of other string functions
Concatenation
Concatenation and the empty string
Nested string functions
Text functions used for text, unitext, and image data
readtext
Using readtext on unitext columns
Examples of using text functions
Aggregate functions
Mathematical functions
Examples of using mathematical functions
Date functions
Get current date: getdate
Find date parts as numbers or names
Calculate intervals or increment dates
Add date interval: dateadd
Datatype conversion functions
Using the general purpose conversion function: convert
Conversion rules
Converting character data to a noncharacter type
Converting from one character type to another
Converting numbers to a character type
Rounding during conversion to or from money types
Converting date and time information
Converting to or from unitext
Converting between numeric types
Converting binary-like data
Converting hexadecimal data
Converting image data to binary or varbinary
Converting between binary and numeric or decimal types
Conversion errors
Arithmetic overflow and divide-by-zero errors
Scale errors
Domain errors
Security functions
Using Stored Procedures
How stored procedures work
Examples of creating and using stored procedures
Stored procedures and permissions
Stored procedures and performance
Creating and executing stored procedures
Parameters
Default parameters
Using default parameters in stored procedures
NULL as the default parameter
Wildcard characters in the default parameter
Using more than one parameter
Procedure groups
Using with recompile in create procedure
Using with recompile in execute
Nesting procedures within procedures
Using temporary tables in stored procedures
Setting options in stored procedures
Arguments for stored procedures
Length of expressions, variables, and arguments
After creating a stored procedure
Executing stored procedures
Executing procedures after a time delay
Executing procedures remotely
Returning information from stored procedures
Return status
Reserved return status values
User-generated return values
Checking roles in procedures
Return parameters
Passing values in parameters
The output keyword
Restrictions associated with stored procedures
Qualifying names inside procedures
Renaming stored procedures
Renaming objects referenced by procedures
Using stored procedures as security mechanisms
Dropping stored procedures
System procedures
Executing system procedures
Permissions on system procedures
Types of system procedures
System procedures for auditing
System procedures used for security administration
System procedures used for remote servers
System procedures for managing databases
System procedures used for data definition and database objects
System procedures used for user-defined messages
System procedures for languages
System procedures used for device management
System procedures used for backup and recovery
System procedures used for configuration and tuning
System procedures used for system administration
System procedures for upgrade
Other Sybase-supplied procedures
Catalog stored procedures
System extended stored procedures
dbcc procedures
Getting information about stored procedures
Getting a report with sp_help
Viewing the source text of a procedure with sp_helptext
Identifying dependent objects with sp_depends
Identifying permissions with sp_helprotect
Using Extended Stored Procedures
Overview
XP Server
Dynamic link library support
Open Server API
Example of creating and using ESPs
ESPs and permissions
ESPs and performance
Setting priority
Freeing memory
Creating functions for ESPs
Files for ESP development
Open Server data structures
SRV_PROC
CS_SERVERMSG
CS_DATAFMT
Open Server return codes
Outline of a simple ESP function
Multithreading
ESP function example
Building the DLL
Search order for DLLs
Sample makefile (UNIX)
Sample definitions file
Registering ESPs
Using create procedure
Using sp_addextendedproc
Removing ESPs
Renaming ESPs
Executing ESPs
System ESPs
Getting information about ESPs
ESP exceptions and messages
Starting XP Server manually
Cursors: Accessing Data
How cursors work
Sensitivity and scrollability
Using cursors
How processes cursors
Declaring cursors
declare cursor syntax
Types of cursors
Cursor scope
Cursor scans and the cursor result set
Making cursors updatable
Determining which columns can be updated
Opening cursors
Fetching data rows using cursors
fetch syntax
Checking the cursor status
Getting multiple rows with each fetch
Checking the number of rows fetched
Updating and deleting rows using cursors
Updating cursor result set rows
Deleting cursor result set rows
Closing and deallocating cursors
Examples of using scrollable and forward-only cursors
Forward-only (default) cursors
Example table for scrollable cursors
insensitive scrollable cursors
semi_sensitive scrollable cursors
Using cursors in stored procedures
Cursors and locking
Cursor locking options
Getting information about cursors
Using browse mode instead of cursors
Browsing a table
Browse-mode restrictions
Timestamping a new table for browsing
Timestamping an existing table
Comparing timestamp values
Join cursor processing and data modifications
Updates and deletes that may affect the cursor position
Cursor positioning after a delete or update command without joins
Effects of updates and deletes on join cursors
Effects of join column buffering on join cursors
Recommendations
Triggers: Enforcing Referential Integrity
How triggers work
Using triggers vs. integrity constraints
Creating triggers
create trigger syntax
SQL statements that are not allowed in triggers
Using triggers to maintain referential integrity
Testing data modifications against the trigger test tables
Insert trigger example
Delete trigger examples
Cascading delete example
Restricted delete examples
Update trigger examples
Restricted update triggers
Updating a foreign key
Multirow considerations
Insert trigger example using multiple rows
Delete trigger example using multiple rows
Update trigger example using multiple rows
Conditional insert trigger example using multiple rows
Rolling back triggers
Nesting triggers
Trigger self-recursion
Rules associated with triggers
Triggers and permissions
Trigger restrictions
Implicit and explicit null values
Triggers and performance
set commands in triggers
Renaming and triggers
Trigger tips
Disabling triggers
Dropping triggers
Getting information about triggers
sp_help
sp_helptext
sp_depends
Transactions: Maintaining Data Consistency and Recovery
How transactions work
Transactions and consistency
Transactions and recovery
Using transactions
Allowing data definition commands in transactions
System procedures that are not allowed in transactions
Beginning and committing transactions
Rolling back and saving transactions
Checking the state of transactions
Nested transactions
Example of a transaction
Selecting the transaction mode and isolation level
Choosing a transaction mode
Transaction modes and nested transactions
Finding the status of the current transaction mode
Choosing an isolation level
Default isolation levels for Adaptive Server and ANSI SQL
Dirty reads
Repeatable reads
Finding the status of the current isolation level
Changing the isolation level for a query
Isolation level precedences
Cursors and isolation levels
Stored procedures and isolation levels
Triggers and isolation levels
Compliance with SQL standards
Using the lock table command to improve performance
Syntax of the lock table command
Using transactions in stored procedures and triggers
Errors and transaction rollbacks
Transaction modes and stored procedures
Setting transaction modes for stored procedures
Using cursors in transactions
Issues to consider when using transactions
Backup and recovery of transactions
Locking Commands and Options
Setting a time limit on waiting for locks
wait/nowait option of the lock table command
Setting a session-level lock-wait limit
Setting a server-wide lock-wait limit
Information on the number of lock-wait timeouts
Readpast locking for queue processing
readpast syntax
Incompatible locks during readpast queries
Allpages-locked tables and readpast queries
Effects of isolation levels select queries with readpast
Session-level transaction isolation levels and readpast
Query-level isolation levels and readpast
Data modification commands with readpast and isolation levels
text, unitext, and image columns and readpast
Readpast-locking examples
The pubs2 Database
Tables in the pubs2 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
roysched table
discounts table
blurbs table
au_pix table
Diagram of the pubs2 database
The pubs3 Database
Tables in the pubs3 database
publishers table
authors table
titles table
titleauthor table
salesdetail table
sales table
stores table
store_employees table
roysched table
discounts table
blurbs table
Diagram of the pubs3 database
Troubleshooting Guide: Error Messages Advanced Resolutions
About this book
Introduction
Understanding error message severity levels
Notifying the System Administrator
Variables in error message text
Finding object names in error message text
Finding the Adaptive Server version
Understanding the field order in the version string
Creating error messages
Reporting errors
Sybase Technical Support checklist
Sending error log fragments
Reproducing problems
Parser Errors (100s, 7380)
Error 102
Error 107
Error 195
Error 7380
Sequencer Errors (200s, 7783, 7788, 11000s, 14200)
Error 207
Error 208
Error 213
Error 216
Error 225
Error 226
Error 229
Error 232
Error 233
Error 241
Error 247
Error 257
Error 259
Error 265
Error 266
Error 268
Error 277
Error 7783
Error 7788
Error 11018
Error 11068
Error 11072
Error 14200
Query Processor Errors (300s, 400s, 500s)
Error 311
Error 313
Error 314
Error 403
Error 414
Error 428
Error 511
Error 512
Error 515
Error 530
Error 539
Error 540
Error 546
Error 547
Error 551
Error 584
Access Method Errors (600s)
Error 601
Error 603
Error 605
Error 611
Error 614
Error 622
Error 623
Error 624
Error 625
Error 629
Error 631
Error 644
Error 678
Error 691
Error 692
Error 693
Error 694
Error 695
Error 696
Error 697
Memory Manager Errors (700s)
Error 701
Error 702
Error 703
Error 706
Error 707
Error 709
Error 714
Error 715
Error 717
Error 718
Error 719
Error 720
Error 721
Buffer Manager Errors (800s)
Error 803
Error 804
Error 806
Error 813
Error 820
Error 821
Error 822
Error 823
Error 832
Error 834
Error 835
Error 840
Error 842
Error 847
Error 849
Error 852
Error 855
Error 861
Error 863
Error 881
Error 890
Open Database Manager Errors (900s)
Error 903
Error 905
Error 906
Error 908
Error 911
Error 913
Error 916
Error 921
Error 924
Error 925
Error 926
Error 930
Error 935
Error 940
Error 941
Error 945
Error 950
Error 965
Abstract Plan Manager Errors (1000s)
Error 1024
Page Manager Errors (1100s)
Error 1105
Error 1108
Error 1120
Error 1124
Error 1127
Error 1129
Error 1131
Error 1133
Error 1141
Error 1142
Error 1143
Error 1159
Error 1161
Lock Manager Errors (1200s)
Error 1203
Error 1204
Error 1205
Error 1243
Error 1244
Error 1249
Error 1251
Error 1265
Error 1279
Sort Manager Errors (1500s)
Error 1501
Error 1505
Error 1506
Error 1508
Error 1509
Error 1510
Error 1514
Error 1530
Error 1531
Initialization Errors (1600s)
Error 1601
Error 1602
Error 1603
Error 1605
Error 1608
Error 1613
Error 1621
Error 1622
Error 1623
Create Utilities Errors (1700 - 1900s, 2100s, 2700s, 12800s)
Error 1702
Error 1708
Error 1732
Error 1803
Error 1808
Error 1809
Error 1810
Error 1813
Error 1820
Error 1902
Error 1903
Error 1916
Error 1928
Error 2110
Error 2714
Error 2729
Error 2753
Error 2762
Error 12818
Error 12842
Error 12881
High Availability Errors (2200s)
Error 2243
Character Set Conversion Errors (2400s)
Error 2401
Error 2402
Error 2409
dbcc Errors (2500s, 7900s, 12000s, 15000s)
Error 2501
Error 2502
Error 2503
Error 2507
Error 2509
Error 2510
Error 2511
Error 2513
Error 2514
Error 2517
Error 2520
Error 2521
Error 2524
Error 2525
Error 2529
Error 2540
Error 2546
Error 2547
Error 2550
Error 2558
Error 2559
Error 2572
Error 2573
Error 2574
Error 2575
Error 2578
Error 2582
Error 2583
Error 2591
Error 2596
Error 7901
Error 7902
Error 7928
Error 7930
Error 7939
Error 7940
Error 7949
Error 7989
Error 9961
Error 12964
Error 15056
Error 15080
Error 15082
Error 15084
insert Errors (2600s)
Error 2601
Error 2610
Error 2615
Error 2619
Error 2620
Error 2626
Error 2628
Error 2630
Error 2631
Procedure Manager Errors (2800s)
Error 2805
Error 2806
Error 2811
Error 2812
Error 2824
Error 2835
Error 2844
dump and load Errors (3000s - 3200s, 4200s - 4300s)
Error 3019
Error 3020
Error 3021
Error 3105
Error 3120
Error 3143
Error 3144
Error 3161
Error 3162
Error 3201
Error 3203
Error 3211
Error 3212
Error 3216
Error 3225
Error 3230
Error 3233
Error 3240
Error 4204
Error 4205
Error 4207
Error 4216
Error 4221
Error 4222
Error 4305
Error 4322
commit and abort Errors (3300s)
Error 3301
Error 3307
Error 3321
Error 3322
Recovery Errors (3400s, 12500s)
Error 3401
Error 3403
Error 3404
Error 3414
Error 3429
Error 3434
Error 3445
Error 3446
Error 3447
Error 3452
Error 3454
Error 3462
Error 3470
Error 12546
Error 12547
Error 12551
Error 12583
Error 12587
Exception Handling Errors (3600s)
Error 3604
Error 3621
Error 3624
Error 3626
Error 3641
Error 3642
Error 3643
Error 3644
Error 3646
Error 3648
drop Errors (3700s)
Error 3701
Error 3702
Error 3703
Transaction Errors (3900s)
Error 3904
Error 3905
Error 3906
Error 3908
Error 3917
Error 3949
dataserver Errors (4000s)
Error 4001
Error 4002
Error 4020
View Resolution Manager Errors (4400s)
Error 4430
truncate table Errors (4700s)
Error 4716
Bulk Copy Utility Errors (4800s)
Error 4801
Error 4806
alter table Errors (4900s)
Error 4951
Error 4953
Error 4954
Error 4956
Error 4964
alter database Errors (5000s)
Error 5006
Error 5013
Error 5018
Error 5034
Disk Errors (5100s)
Error 5115
Error 5123
Error 5142
Transaction Coordinator Errors (5600s)
Error 5602
Open Client Errors (5700s)
Error 5701
Error 5704
Configuration Errors (5800s, 10800s)
Error 5806
Error 5808
Error 5824
Error 5846
Error 5847
Error 5848
Error 5849
Error 5850
Error 5851
Error 5852
Error 5853
Error 5854
Error 5857
Error 5859
Error 5861
Error 5863
Error 5865
Error 5866
Error 5867
Error 5868
Error 5893
Error 10841
Error 10865
Process Kill Errors (6100s)
Error 6103
Error 6107
Timestamp Errors (6900s)
Error 6901
Error 6902
Distributed Database Network Errors (7200s)
Error 7201
Error 7205
Error 7207
Error 7211
Error 7212
Error 7214
Error 7215
Error 7218
Error 7220
Error 7221
Error 7223
Error 7227
Error 7234
Error 7235
Text Manager Errors (7100s)
Error 7101
Error 7105
Error 7114
Error 7130
Error 7134
Threshold Manager Errors (7400s)
Error 7401
Error 7402
Error 7403
Error 7404
Error 7406
Error 7407
Error 7408
Error 7409
Error 7410
Error 7411
Error 7412
Error 7413
Error 7414
Error 7415
Error 7417
Error 7418
Error 7438
Auditing Errors (7600s)
Error 7618
Remote Procedure Call Errors (8000s)
Error 8006
Error 8009
Descriptor Manager Errors (8200s)
Error 8201
Error 8203
Error 8204
Error 8207
Error 8210
Error 8211
Error 8219
Error 8239
Error 8241
sysindexes Manager Errors (8400s)
Error 8402
Error 8419
Process Status Structure Errors (8600s)
Error 8601
Site Buffer Manager Errors (8700s)
Error 8704
Disk Manager Errors (9000s)
Error 9004
Replication Agent Manager Errors (9100s - 9200s)
Error 9122
Error 9287
Error 9289
Error 9290
Component Integration Services Errors (11200s)
Error 11201
Error 11202
Error 11203
Configurable Shared Memory Dump Manager (12000s, 12300s)
Error 12036
Error 12326
Error 12328
Error 12329
Error 12330
Error 12333
Error 12334
Error 12335
Fault Isolation Utility Errors (12700s)
Error 12716
Error 12717
Partition (14100s) and Partition Key Manager (14300s) Errors
Error 14100
Error 14108
Error 14120
Error 14124
Error 14126
Error 14313
mount database Errors (14500s)
Error 14503
Error 14504
Error 14511
Error 14513
Error 14560
Error 14561
Anchor Manager Errors (14600s)
Error 14605
Error 14618
Error 14619
Error 14620
Error 14621
Error 14622
Error 14623
XML Utility Manager Errors (14900s)
Error 14901
Message Service Errors (15100s)
Error 15101
Error 15105
Web Services Errors (15200s)
Error 15219
Encryption Errors (15400s)
Error 15402
Error 15403
Error 15412
Error 15413
Error 15417
Statistics Errors (15600s)
Error 15600
Error 15601
System Procedure Errors (17000s, 18000s)
Error 17461
Error 17715
Error 17716
Error 17737
Error 17870
Error 17871
Error 17872
Error 17873
Error 17874
Error 17875
Error 17903
Error 17904
Error 17905
Error 17906
Error 17910
Error 18031
Error 18032
Error 18033
Error 18123
Error 18750
Kernel Errors
Asynchronous I/O not available
Buffer mismatch
Could not create shared memory
Current process infected
dopen error
dstart I/O request repeatedly delayed
Failed to open device
Feature is not licensed
File already in use
Memory too fragmented
Memory usage in procedure headers
Network information message
No more alarms available
Open objects parameter may be too low
os_attach_region errors
os_create_region errors
Read/write errors
Server is unnamed
Stack guardword corrupted
time slice error
t_rcvconnect error
udunmirror errors
No more engines can be offlined
Unified Agent and Agent Management Console 2.0 for Windows and UNIX User's Guide
About this book
Overview
What is Unified Agent?
Services provided by Unified Agent
Mandatory Unified Agent services
Optional Unified Agent services
Agent Management Console
Installing and Configuring Unified Agent and Agent Management Console
Pre-installation tasks
Installing Unified Agent
Starting the Jini server
Starting and stopping Unified Agent
Checking the Unified Agent version
Starting Unified Agent as a service on UNIX platforms
Starting Unified Agent as a service on Windows platforms
Installing the Agent Management Console
Configuring Unified Agent
Security
Unified Agent security
Encryption
Authentication
Login modules
Security module control flags
Authorization
Role mappings
Permissions
Agent Management Console Features and Functionality
Managing look-up services
Creating a network lookup profile
Discovering Unified Agents
Deleting a network look-up profile
Changing a network look-up profile
Specifying a network plug-in name filter
Managing Unified aAgents
Manually adding an agent
Connecting to an agent
Adding credentials
Disconnecting from an agent
Restarting an agent
Retrieving the agent log
Viewing and changing agent properties
Managing discovery adaptors
Creating a discovery adaptor
Deleting a discovery adaptor
Viewing and changing discovery adaptor properties
Setting discovery adaptor password
Managing security modules
Creating a security module
Deleting a security module
Ordering the security module authentication
Viewing and changing security module properties
Setting a security module password
Managing role mappings
Creating a role mapping
Managing agent services
Starting an agent service
Restarting an agent service
Stopping an agent service
Viewing agent service properties
Managing agent plug-ins
Loading an agent plug-in
Unloading an agent plug-in
Reloading an agent plug-in
Viewing agent plug-in properties
Server-based plug-ins
Pinging the server
Starting the server
Restarting the server
Stopping the server
Retrieving the server log
Managing attributes
Viewing attributes
Updating attribute values
Viewing properties and changing permissions
Managing operations
Viewing operations
Password Encryption and Security Configuration
Password encryption utility
Enabling Rivest-Shamir-Adleman (RSA) encryption
Adaptive Server agent plug-in server password encryption
Pluggable Authentication Module (PAM) configuration
SNMP Agent Plug-in
Overview
Terminology
Sybase Adaptive Server MIB
Unified Agent SNMP services and plug-ins
UAF SNMP Service
UAF SNMP Service MIBs
Adaptive Server-to-SNMP client architecture
Security
Security for connections from Adaptive Server
Security for connections from SNMP
Configuring Adaptive Server for the SNMP Agent Plug-in
TDS services
UAF SNMP Agent Service
Adaptive Server runtime
Using the Adaptive Server SNMP Agent Plug-in
Viewing the SNMP information from NET-SNMP
Sybase MIB
Tabular Data Stream (TDS) Service
What is TDS?
Using the TDS service
UAF services
uaf_list_service_operations
uaf_list_services
uaf_list_service_operation_arguments
uaf_invoke_service_operation
uaf_list_service_attributes
uaf_get_service_attribute
uaf_set_service_attribute
UAF plug-ins
uaf_list_plugins
uaf_list_plugin_operations
uaf_list_plugin_operation_arguments
uaf_invoke_plugin_operation
uaf_list_plugin_attributes
uaf_get_plugin_attribute
uaf_set_plugin_attribute
TDS listener client examples
Setting up examples for the Adaptive Server client
Examples for configuring the Adaptive Server client
Examples for using the Adaptive Server client
Examples for configuring the Adaptive Server client
Reporting functionality and error recovery
Using Adaptive Server Distributed Transaction Management Features
About this book
Overview
Distributed Transaction Management features
Affected transaction types
Distributed transactions coordinated by external transaction managers
Behavior for transaction manager-coordinated transactions
RPC and CIS transactions
New behavior for RPC and CIS transactions
SYB2PC transactions
Enabling DTM Features
Installing a license key
Enabling DTM features
enable dtm parameter
enable xact coordination parameter
Configuring transaction resources
Calculating required transaction descriptors
Setting the number of transaction descriptors
Using Adaptive Server Transaction Coordination Services
Overview of transaction coordination services
Hierarchical transaction coordination
X/Open XA-compliant behavior in DTP environments
Requirements and behavior
Configuring participant server resources
number of dtx participants parameter
Optimizing number of dtx participants for your system
Using transaction coordination services in heterogeneous environments
strict dtm enforcement parameter
Monitoring coordinated transactions and participants
DTM Administration and Troubleshooting
Transactions and threads of control
Implications for system administrators
dtm detach timeout period parameter
Lock manager changes to support detached transactions
Getting information about distributed transactions
Transaction identification in systransactions
Transaction keys
Viewing active transactions with sp_transactions
Identifying local, remote, and external transactions
Identifying the transaction coordinator
Viewing the transaction thread of control
Understanding transaction state information
Transaction failover information
Determining the commit node and gtrid with sp_transactions
Commit and parent nodes
Global transaction ID
Crash recovery procedures for distributed transactions
Transactions coordinated with MSDTC
Transactions coordinated by Adaptive Server or X/Open XA
Transactions coordinated with SYB2PC
Heuristically completing transactions
Completing prepared transactions
Forgetting heuristically completed transactions
Manually clearing the commit status
Completing transactions that are not prepared
Determining the commit status for Adaptive Server transactions
Configuration considerations
Behavior of DDLs within distributed transactions
Using Sybase Failover in a High Availability System
About this book
What is High Availability?
Differences between active-active and active-passive
Requirements for failover
Resource requirements
How does Sybase Failover work with high availability?
Single-system presentation
Special considerations for Sybase Failover
Installing the monitoring table scripts
Using disk mirroring
Running the installhasvss script
Creating a SYB_HACMP server entry
Defining user-defined datatypes
Adaptive Server and two-phase commit transactions
Failover and Failback
What is failover?
Client connections during fail over
User logins in failover
What is failback?
Performing failback
Cluster locks in a high availability node
Asymmetric and Symmetric Configurations
Asymmetric and symmetric configuration
Configuring the asymmetric companion
Performance of Adaptive Server in an asymmetric configuration
Configuring the symmetric companion
Performance of Adaptive Server in a symmetric configuration
Auditing in a high availability system
Setting auditing options
sybsecurity and Sybase Failover
Audit trails and Sybase Failover
Modes of Failover
What are modes?
Different modes of a companion server
Determining the companion’s mode
Domains
Proxy Databases, User Databases, and Proxy System Tables
Proxy databases
Creating proxy databases
When are proxy databases created?
Size of the proxy databases
Commands and system procedures in proxy databases
Changes to commands in proxy databases
Changes to system procedures in proxy databases
Issuing user-defined stored procedures in proxy databases
Manually updating the proxy databases
Proxy system tables in master
Running do_advisory
What is the do_advisory option?
Running the do_advisory option
Quorum attributes
Configuring Adaptive Server for Failover on HP
Hardware and operating system requirements
Preparing Adaptive Server for high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to interfaces file for client connections
Setting the value of $SYBASE
Configuring sybha executable
Creating a new default device other than master
Adding the local server to sysservers
Adding the secondary companion to sysservers
Running installhasvss
Assigning ha_role to system administrator
Verifying configuration parameters
Configuring HP for failover
Creating the package configuration
Editing the ASE_HA.sh script
Creating the package control script
Verifying and distributing the configuration
Starting the primary and secondary companions
Configuring companion servers for failover
Running sp_companion with do_advisory option
Creating an asymmetric companion configuration
Creating the symmetric configuration
Administering Sybase Failover
Failing back to the primary companion and resuming normal companion mode
Suspending companion mode
Resuming normal companion mode from suspended mode
Dropping companion mode
Troubleshooting Sybase Failover on HP
Error message 18750
Recovering from a failed prepare_failback
Location of error logs
Configuring Adaptive Server for Failover on IBM AIX HACMP
Hardware and operating system requirements
Requirements for running Failover on IBM AIX HACMP
Special considerations for running Adaptive Server on HACMP for AIX
Preparing Adaptive Server to work with high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to the interfaces file for client connections
Setting the value of $SYBASE
sybha executable
Verifying configuration parameters
Adding thresholds to the master log
Creating a new default device other than master
Adding a local server to sysservers
Adding a secondary companion to sysservers
Running installhasvss script
Assigning ha_role to System Administrator
Configuring the IBM AIX subsystem for Sybase Failover
Modifying the ASE_HA.sh script
Configuring resource groups in HACMP
Configuring companion servers for failover
Running sp_companion with do_advisory option
Creating an asymmetric companion configuration
Creating the symmetric configuration
Starting the primary companion as a monitored resource
Administering Sybase Failover
Failing back to the primary node
Failing back manually
Suspending companion mode
Restarting companion during suspended mode
Resuming normal companion mode
Resuming normal companion mode from suspended mode
Resuming normal companion mode from failover mode
Dropping companion mode
Troubleshooting fail over for HACMP for AIX
Error message 18750
Recovering from a failed prepare_failback
Location of error logs
Active-Active Configuration for Sun Cluster 3.0 and 3.1
Hardware and operating system requirements
Active-active setup in Sun Cluster
Preparing Adaptive Server for active-active setup
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
The value of $SYBASE is the same for both companions
Executing sybha
Creating new default devices
Adding the local server to sysservers
Adding secondary companion to sysservers
Assigning the ha_role to System Administrator
Running installhasvss script
Verifying configuration parameters
Adding thresholds to the master log
Adding user and login for fault monitor
Configuring the Sun Cluster subsystem
Using the syscadm script
Sample sysc_input_file
Adaptive Server resource extension properties
Configuring Adaptive Server resource groups
Using SUNW.HAStoragePlus
Configuring companion servers for failover
High availability services library within Adaptive Server
Running sp_companion with do_advisory
Before initiating sp_companion
Creating an asymmetric companion configuration
Setting up a symmetric configuration
Administering Sybase Failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Verifying high availability on Sun Cluster
Configuring the resource groups manually
Primary companion resource group
Secondary companion resource group
Troubleshooting
Recovering from a failed prepare_failback
Recovering from a secondary failover on the secondary companion
Preventing the failover of secondary companion
Changing resource and resource group state
Location of the error logs
Active-Passive Configuration for Sun Cluster 3.0 and 3.1
Hardware and operating system requirements
Active-passive setup in Sun Cluster
Failing back in an active-passive configuration
Clients in an active-passive configuration
Preparing Adaptive Server for active-passive setup
Installing Adaptive Server
Passing environment to Adaptive Server
Running the SySam license manager in the cluster
Adding an entry for Adaptive Server to the interfaces file
Configuring the interfaces file on the server side
Configuring the interfaces file on the client side
Verifying configuration parameters
Adding thresholds to the master log
Adding user and login for fault monitor
Configuring the Sun Cluster subsystem
Using the syscadm script
Sample sysc_input_file
Configuring the Adaptive Server resource group
Using SUNW.HAStoragePlus
Verifying the active-passive configuration
Working with a multi-node cluster
Multi-node setup
Configuring the resource group manually
Location of the error logs
Configuring Adaptive Server for Failover on Veritas 4.0
Hardware and operating system requirements
Preparing Adaptive Server to work with high availability
Installing Adaptive Servers
Adding entries for both Adaptive Servers to the interfaces file
Adding entries to the interfaces file for client connections during fail over
sybha executable
Creating a new default device
Adding the local server to sysservers
Adding secondary companion to sysservers
Assigning ha_role
Installing high availability stored procedures
Verifying configuration parameters
Adding thresholds to the master log
Configuring the Veritas subsystem for Sybase Failover
Installing the HAase agent
Creating an Adaptive Server login file
Importing the HAase resource type
Starting the HAase agent
Adding the HAase resource
Configuring an instance of the HAase resource for each service group
Configuring companion servers for failover
Adding user and login for high availability monitor
Running sp_companion with do_advisory option
Verifying the high availability agent
Creating an asymmetric companion configuration
Configuring for symmetric configuration
Administering Sybase Failover
During failover
Failing back to the primary companion
Suspending normal companion mode
Resuming normal companion mode
Dropping companion mode
Troubleshooting failover for Veritas Cluster
Recovering from a failed prepare_failback
Location of the logs
Upgrading from an agent of resource type Sybase
Configuring Adaptive Server for Failover on Windows
Hardware and operating system requirements
Installing Adaptive Servers
Changing the domain administration account
Adding entries for both Adaptive Servers to sql.ini
Adding entries to sql.ini for client connections
Creating a new default device other than master
Adding the primary companion as a local server
Adding secondary companion to sysservers
Running insthasv to install high availability stored procedures
Assigning ha_role to the System Administrator
Verifying configuration parameters
Running sp_companion with do_advisory option
Configuring Windows
Asymmetric setup from the command line
Symmetric configuration from the command line
Configuring Windows using Cluster Administrator
Configuring and securing Microsoft Cluster Server
Checking the MSCS configuration
Securing the MSCS cluster
Troubleshooting
Error message 18750
Recovering from a failed prepare_failback
Troubleshooting Secondary Points of Failure
Troubleshooting with dbcc ha_admin
Using dbcc ha_admin for rolling back failover commands
Using @@hacmpservername
Error messages
Changes to Commands, System Procedures, and Databases
Changes to commands
Changes to system procedures
System procedures hold table lock
System procedures that synchronize changes
Other changes to system procedures
dbcc options for high availability systems
dbcc dbrepair option
Open Client Functionality in a Failover Configuration
CTLIB application changes
Glossary
Utility Guide
About this book
Building Servers Using dataserver
Introduction
Building a new master device
Environments when using dataserver
build mode
start mode
Upgrading to a server with larger page sizes
Viewing the current server limits
Using Interactive isql from the Command Line
Before you begin
Starting and stopping isql
How to use Transact-SQL in isql
Formatting isql output
Correcting input
set options that affect output
Changing the command terminator
Performance statistics interaction with command terminator values
Setting the network packet size
Input and output files
UNIX command-line redirection
Using Interactive SQL in Graphics Mode
Starting Interactive SQL
Main window description
Plan dialog tab
Using the Interactive SQL toolbar
Opening multiple windows
Keyboard shortcuts
Using Interactive SQL to display data
Editing table values in Interactive SQL
Copying rows from the Interactive SQL result set
Editing table values from the Interactive SQL result set
Inserting rows into the database from the Interactive SQL result set
Deleting rows from the database using Interactive SQL
Working with SQL statements in Interactive SQL
Canceling an Interactive SQL command
Combining multiple statements
Looking up tables, columns, and procedures
Recalling commands
Logging commands
Configuring Interactive SQL
General dialog box
Result dialog box
Import/Export dialog box
Messages dialog tab
Editor
Query Editor
Running command files
Writing output to a file
Executing command files
Saving, loading, and running command files
Using SQL escape syntax in Interactive SQL
Interactive SQL commands
Using bcp to Transfer Data to and from Adaptive Server
Methods for moving data
Importing and exporting data with bcp
bcp requirements
bcp modes
Copying data to a file
Examples
bcp performance
Using fast or slow bcp
Copying in data with fast bcp
Bulk copying data into partitioned tables
Monitoring bcp sessions with dbcc checktable and sp_helpsegment
Reducing logging by increasing page allocations
Using parallel bulk copy to copy data into a specific partition
bcp in and locks
Parallel bulk copy methods
Parallel bulk copy syntax
Using parallel bulk copy on round-robin partitioned tables
Parallel bulk copy and IDENTITY columns
Using the bcp options
Using the default formats
Native format
Character format
Changing terminators from the command line
Changing the defaults: interactive bcp
Responding to bcp prompts
File storage type
Prefix length
Field length
Field and row terminators
Choosing Terminators
Using format files
Elements of the bcp format file
Examples: copying out data interactively
Copying out data with field lengths
Copying out data with delimiters
Comma-delimited, newline-delimited with format file
Tab-delimited with format file
Examples: copying in data interactively
Copying in data with field lengths
Copying in data with delimiters
Copying in data with a format file
Using bcp with alternate languages
bcp and row-level access rules
Copy in and batch files
Improving recoverability
Batches and partitioned tables
Copy out and text and image data
Specifying a network packet size
Copy in and error files
Copy out and error files
Data integrity: defaults, rules, and triggers
Defaults and datatypes
Rules and triggers
How bcp differs from other utilities
Using dsedit
Getting started with dsedit
Starting dsedit
Opening an editing session
Adding, viewing, and editing server entries
Modifying server entries in Windows NT
Modifying server entries in UNIX platforms
Adding or editing network transport addresses
SPX/IPX addresses
Copying server entries
Troubleshooting dsedit
The dsedit utility does not start
Error message: “Unable to open X display”
Cannot add, modify, or delete server entries
Migration Utility
Overview
Benefits of sybmigrate
What sybmigrate does
What sybmigrate does not do
Before you begin
Required components for the sybmigrate
Dependencies
Installation
Permissions
Changing target login accounts
Platforms
Environment settings
Migration process
Overview of the migration process
Pre-migration considerations
Configuration and tuning for higher performance
Configuration considerations for sybmigrate
Configuration considerations for Adaptive Server
Possible errors to avoid
Auto-select dependent objects for migration
Starting sybmigrate
GUI mode
Setup
Migrate
Validate
Migration and validation progress
Resource file mode
Post-migration activities
Migrating databases in the Replication Server domain
Premigration procedures
Postmigration procedures
Restoring primary databases
Restoring replicate databases
Restoring the RSSD
Amending system tables when the logical page size changes
Logs
Migrating databases that support wide data
Limitations
Troubleshooting and error messages
Objects fail to migrate
Beginning database migration
“Connection refused” and “Unable to obtain connection to the server”
Target server cannot be reached from source server
If sybmigrate hangs during migration
Merging two databases
Post-migration failure cleanup
Remigrating one database
Re-creating an individual object
Connection fail
“Insufficient memory in JVM shared class”
“There is not enough memory in the procedure cache”
java.lang related error
Using dscp
Getting started with dscp
Using a dscp session
Working with server entries
Adding and modifying server entries
Copying server entries
Listing and viewing contents of server entries
Deleting server entries
Exiting dscp
Quick reference for dscp utility commands
Utility Commands Reference
Getting started
*_r utilities
Utilities quick reference
Installation or configuration utilities
Utilities for languages, character sets, and sort orders
Utilities to start servers
Database creation and manipulation utilities
Utilities to gather information
backupserver
bcp
buildmaster
certauth
certpk12
certreq
charset
cobpre
cpre
dataserver
ddlgen
defncopy
dscp
dsedit
extractjava
installjava
isql
langinstall
optdiag
preupgrade
pwdcrypt
showserver
sqldbgr
sqlloc
sqllocres
sqlsrvr
sqlupgrade
sqlupgraderes
srvbuild
srvbuildres
startserver
sybmigrate
xpserver
XA Interface Integration Guide for CICS, Encina, and TUXEDO
About this book
Introduction
Overview
Requirements
The Sybase XA Environment
Definitions
Overview of the X/Open DTP model
Components of the model
How the components communicate
How the components interact
Recovery
The Sybase XA environment
Components of the Sybase XA environment
Connections in the Sybase XA environment
Identifying connections via LRMs
Where is the connection information stored?
Establishing connections
Distributing work across LRMs
Configuring the XA Environment
Configuring Adaptive Server
Open string parameters for DTM XA Interface
Open string parameters
dtm_tm_role required for username
Log file and trace flag parameters
Labels for logfile entries
xa_open() function behavior
XA configuration file for DTM XA Interface
Environment variable for specifying configuration file
[all] section for defining common LRM parameters
Parameter definitions for [all] section
Editing the XA configuration file
Additional capabilities, properties, and options
Using the DTM XA Interface with CICS
Building the switch-load file
Compiling the switch-load file on IBM RISC System/6000 AIX
Compiling the switch-load file on HP9000 Series 800 HP-UX
Compiling the switch-load file on Sun Solaris 2.x (SPARC)
Adding a Sybase stanza to the CICS region XAD definition
Using the DTM XA Interface with Encina
Assigning an open string with monadmin create rm
Initializing LRMs with mon_RegisterRmi
Linking applications with DTM XA Interface libraries
Establishing connections
Using the DTM XA Interface with TUXEDO
Linking
Setting up the UBBCONFIG file
Creating the TUXEDO configuration file
Building the TMS
Build COBOL runtime environment
Application Programming Guidelines
X/Open DTP versus traditional Sybase transaction processing
Transaction and connection management
Transaction management
Connection management
The current connection
Nontransactional connections
Deallocate cursor function with Client-Library
Dynamic SQL
Getting a Client-Library connection handle
Multiple-thread environment issues
Caveats of thread use
Embedded SQL thread-safe code
Tightly coupled transactions
Linking with CT Library
Sample embedded SQL COBOL fragment
Sample embedded SQL C fragment
XML Services
About this book
Introduction to XML Services
XML capabilities
Overview
XML in the database
A sample XML document
HTML display of Order data
XML document types
XML Query Functions
XML query functions
Example sections
xmlextract
xmltest
xmlparse
xmlrepresentation
xmlvalidate
option_strings: general format
Option values for query functions.
XML Language and XML Query Language
Character set support
URI support
Namespace support
XML schema support
Predefined entities in XML documents
Predefined entities in XPath queries
White space
Empty elements
XML Query Language
XPath-supported syntax and tokens
XPath operators
XPath basic operators
XPath set operators
XPath comparison operators
XPath functions
General guidelines and examples
Functions
Parenthesized expressions
Parentheses and subscripts
Parentheses and unions
XML Mapping Functions
for xml clause
for xml subqueries
for xml schema and for xml all
forxmlj, forxmldtdj, forxmlschemaj, forxmlallj
forsqlcreatej, forsqlinsertj, forsqlscriptj
Using Java functions to map hierarchic XML documents and SQL data
Sample data and its tree-structured XML representation
Using ForXmlTree to map SQL data to hierarchic XML
Using OpenXml to map hierarchic XML to SQL
Java SQLX mappings for multiple result set queries
forxmlmultiplej
XML Mappings
SQLX options
SQLX option definitions
SQLX data mapping
Mapping duplicate column names and unnamed columns
Mapping SQL names to XML names
Mapping SQL values to XML values
Numeric values
Character values
Binary values
SQLX schema mapping
Overview
Option: columnstyle=element
Option: columnstyle=attribute
Option: nullstyle=omit
Option: nullstyle=attribute
XML Support for I18N
Overview
Unicode datatypes
Surrogate pairs
Numeric character representation
Client-server conversions
Character sets and XML data
I18N in for xml
Option strings
Numeric Character Representation in for xml
header option
Exceptions
Examples
Example 1
Example 2
Example 3
Example 4
Example 5
Example 6
Example 7
I18N in xmlparse
Options
I18N in xmlextract
NCR option
Sort ordering in xmlextract
Sort ordering in XML Services
The sample_docs Example Table
sample_docs table columns and rows
Sample_docs table columns
sample_docs table rows
sample_docs tables
Table script (for publishers table)
Publishers table representation
Titles table representation
Setting up XML Services
Enabling the native XML processor
Installing the Java-based SQLX mapping functions
Java-based XML functions
Mapping function installation
Environment variables
Installing the parser
Installing the mapping functions
Creating alias names
XML Services and External File System Access
Getting Started
Enabling XML services and External File System Access
Character set conversions with external file systems
Examples
Setting up your XML documents and creating the proxy table
Example: extracting the book title from the XML documents
Example: importing XML documents or XML query results to an Adaptive Server table
Example: storing parsed XML documents in the file system
Example: 'xmlerror' option capabilities with External File Access
Example: specifying the 'xmlerror=message’ option in xmlextract
Example: parsing XML and non-XML documents with the 'xmlerror=message' option
Example: using the option 'xmlerror=null' for non-XML documents
The Java-Based XQL Processor
Setting up the Java-based XQL processor
Setting the CLASSPATH environment variable
Installing the Java-based XQL processor in Adaptive Server
Memory requirements for running the Java-based XQL processor inside Adaptive Server
Using the Java-based XQL processor
Converting a raw XML document to a parsed version
Inserting XML documents
Updating XML documents
Deleting XML documents
Using XQL
Query structures that affect performance
Examples
Other usages of the Java-based XQL processor
com.sybase.xml.xql.XqlDriver syntax
Sample queries
Validating your document
Using the Java-based XQL processor for standalone applications
Example standalone application
Example EJB example
Methods in com.sybase.xml.xql.Xql
parse(String xmlDoc)
parse(InputStream xml_document, boolean validate)
query(String query, String xmlDoc)
query(String query, InputStream xmlDoc)
query(String query, SybXmlStream xmlDoc)
sybase.aseutils.SybXmlStream
com.sybase.xml.xql.store.SybMemXmlStream
com.sybase.xml.xql.store.SybFileXmlStream
setParser(String parserName)
resetParser
Migrating Between the Java-based XQL Processor and the Native XML Processor
Introduction
Migrating documents and queries
Migrating documents between the Java-based XQL processor and the native XML processor
Migrating text documents between the Java-based XQL processor and the native XML processor
Migrating documents from regenerated copies
Regenerating text documents from the Java-based XQL processor
Regenerating text documents from the native XML processor
Migrating queries between the native XML processor and the Java-based XQL processor
Web Services User's Guide
About this book
Understanding Adaptive Server Enterprise Web Services
Overview
Adaptive Server Enterprise Web Services
Advantages of ASE Web Services
Stored procedures and functions
SQL
Security
LDAP
User-defined Web services
Web services standards
XML
Example
XML document structure
WSDL
SOAP
SOAP message structure
Understanding the ASE Web Services Engine
Producer of Web services
Producer components
HTTP handler
SOAP handler
XML mapper
Producer Web methods
User-defined Web services
Consumer of Web services
Consumer components
SDS server
SOAP stack
Proxy tables
Configuring ASE Web Services
Configuration
Configuring during installation
Configuring after installation
Licensing
Configuration files
ws.properties file
logging.properties file
wsmsg.properties file
Security
Configuring SSL
Installing a certificate for Microsoft .NET
Using ASE Web Services
Using the ASE Web Services Engine
Starting and stopping the ASE Web Services Engine
Conditions
Verification
ASE Web Services methods
execute
login
logout
Using sp_webservices
add
help
list
modify
remove
Invoking a Web service
Example 1
Example 2
Example 3
Using user-defined Web services
Commands for user-defined Web services
create service
drop service
Using sp_webservices with user-defined Web services
addalias
deploy
dropalias
listudws
listalias
undeploy
Security for user-defined Web services
Auditing for user-defined Web services
Auditing sp_webservices ‘deploy’
Auditing sp_webservices ‘undeploy’
ASE Web Services logging
ASE Web Services log files
consumer.log
producer.log
http.log
Rolling over log files
Using Sybase Central
Sample Applications
Apache sample client
Creating the sample client
Using runexecute
Microsoft .NET sample client
Creating the sample client
Using Execute.exe
Troubleshooting
Troubleshooting issues
Remote server class definition setting
Unmapped RPC/encoded Web method
Truncated document/literal results
Starting ASE Web Services Engine
Locating WSDL
Specifying entries in ws.properties
Windows NT command-line arguments
Run or stop scripts fail
Null passwords
Specifying SOAP endpoints with SSL
Abnormal termination of sp_webservices ‘add’
Web Services proxy table restrictions
sysattributes table entry
Diagnostic tools
Detailed logging
Enabling JDBC-level tracing
Messages
Installation Contents
ASE Web Services directory tree
bin directory contents
lib directory contents
logs directory contents
producer directory contents
props directory contents
samples directory contents
Configuration Properties
ws.properties
myres.properties
Specifying properties file entries
SOAP and Adaptive Server Enterprise Datatype Mapping
Datatype mapping
SOAP-to-ASE datatype mappings
ASE-to-SOAP datatype mappings for the create service command
Glossary
What’s New In Adaptive Server Enterprise?
About this book
New Features in Adaptive Server Version 15.0
Partition support
Row-locked system catalogs
Query Processor
Large identifiers
Computed columns
Scrollable cursors
Unitext support
big int support
Unsigned int support
Integer identity
Enhancements to XML services
XML schema support
Internationalization (I18N) support
for xml enhancements
Adaptive Server Plug-in enhancements
Interactive SQL
User-defined web services
Very large storage support
Automatic update statistics
SySAM license management
Query processing metrics (qp metrics)
Updates to abstract plans
showplan changes
Secure Socket Layer Uses FIPS 140-2
System Changes in Adaptive Server Version 15.0
System changes in version 15.0
Changes to configuration parameters
New configuration parameters
Changes to existing configuration parameters
Changes to Transact-SQL commands
New Transact-SQL commands
Changed Transact-SQL commands
New set command options
New Transact-SQL functions
Changes to functions
New and changed system procedures
New system procedures
Changed system procedures
Changes to utility programs
Changes to databases and system tables
New databases
New system tables
Changed system tables
Changed status in existing columns
New and changed monitoring tables
Changed monitoring tables
New reserved words
New or changed global variables
New Features in Adaptive Server 12.5.2 and 12.5.3
New features in Adaptive Server 12.5.3
Cross platform dump and load
Importing statistics for proxy tables
Additional support for historical server
Additional support for SSL
Native XML
HP-UX support
Enhancements to Real Time Data Services
Resource Governor enhancements
Page allocation for partitioned DOL tables
User connections enhancements
Number of user connections
User disconnections
dtdValidation support
Migration tool enhancements
top n functionality
New language support
Monitor counter concurrency
System changes in 12.5.3
Changes to commands
New Transact-SQL functions
New system procedures
Changed system procedures
New features in Adaptive Server 12.5.2
Setting the statement cache
XML services
Real Time Messaging Services
Web Services
IPv6 support
Changes to Enhanced Full-Text Search Capabilities
Changes to installation
New style files directory
New features
Security changes
Identification and authentication
Access control
Accountability
Encryption
Password-protected backups
Making compressed database dumps
Linux Adaptive Server for Failover on Veritas 2.1
Large Memory Support for 32-Bit Linux
Additions to dbcc complete_xact
System changes in 12.5.2
XML language changes
Changes to commands
New and changed set command options
New Transact-SQL functions
New system procedures
Changed system procedures
Changes to utility programs
New configuration parameters
New global variables
New Features in Adaptive Server Version 12.5.1
Dynamic data cache
Automatic database expansion
Improvements to the Adaptive Server plug-in for Sybase Central
Dynamic listeners
Globalization enhancements
UTF-8 sort order
Unicode parser
SQL derived tables
Date and time datatypes
XML mapping
Native XML processor
Native XML query
LDAP user authentication
HA agent on VCS 3.5
Fast recovery
Database mount and unmount
Job Scheduler
New cache wizard section for sp_sysmon
Web Services for Adaptive Server
Enhanced compatibility with Microsoft SQL extensions
Adaptive Server 12.5.1 backward compatibility
System changes in version 12.5.1
New and changed configuration parameters
New and changed Transact-SQL commands
New functions
New and changed system procedures
New and changed system tables
New databases
New reserved words
Changes to the documentation
New Features in Adaptive Server Version 12.5.0.x
New features in version 12.5.0.3
Monitoring system tables in Adaptive Server
Using Transact-SQL to monitor performance
Index selection
Active-passive configuration for Sun Cluster 3.0
Asynchronous log service and optimistic index locking
Using sampling for update statistics
Multiple temporary databases
Housekeeper enhancements
Chinese character set (GB18030) support
SQLJ aliases for XQL
SQLX mapping functions
New configuration parameters in sp_monitorconfig
Faster checkpoints
Changes to checkstorage
Changes to CIS
set bulk array size
set bulk batch size
Global variables
Improved performance for select into
New set parameters
Improved performance for create database, alter database, load database, and dbcc checkalloc
Number of databases per transaction
System changes
New and changed configuration parameters
New and changed Transact-SQL commands
New and changed system procedures
New global variables
New functions
New features in version 12.5.0.1
Options for Adaptive Server version 12.5.0.1
Using grant dbcc and revoke dbcc
Increasing the size of devices with disk resize
ASE Replicator
Synchronizing EJB Servers
XQL result sets
XQL query engine
Proxy table space
Creating files and directories with the insert command
Migration utility
Benefits of sybmigrate
High availability on Sun Cluster 3.0
New character sets
System changes
New configuration parameters
New and changed Transact-SQL commands
Changed system procedures
New utility programs
Changes to databases and system tables
Release Bulletin ASE 15.0 for IBM AIX
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
The wrong version of auditinit was shipped with Adaptive Server version 15.0
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
Specifying the SunJCE cipher provider
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for HP-UX
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Sybase Software Asset Management instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Creating the uninstaller
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
SSL unavailable
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
IPv6 support causes Adaptive Server to hang
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Using jConnect and Adaptive Server
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for HP Itanium
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Disabling High Availability during upgrade
Upgrading High Availability and cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling from HP-UX 11.23
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Highlighted known Web Services problems
Alias names limited to 255 characters
Known alter table problems
alter table unpartition errors
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
Replication Server compatibility issues
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
bcp in or bcp out
Silent installation
Sybase Central
File names
table scan and index scan
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Linux
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special SySAM instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be acquired
Acquiring SySAM licenses within a grace period
SySAM Limitations
Special installation instructions
Limitations
Runtime libraries required for Linux on Power installation
Special upgrade instructions
Upgrading compiled objects
Upgrading compiled objects
Product and platform interoperability
Changes that affect existing applications
Installation, upgrade, and migration
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Installation issues
ClearCase causes InstallShield to stops responding
Uninstalling Adaptive Server
Running on RH3.0 64-bit distribution occasionally stops responding
Adaptive Server Replicator 15.0 supports only Adaptive Server 12.5 datatypes
XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Interactive SQL and Adaptive Server plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
Inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross-platform loads
Running dbcc checktable or dbcc checkdb before bringing a database online
Recovering from an upgrade during an online database command
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Replication Server compatibility issues
Blank spaces in an ldap server entry
Dumping or loading databases with asynchronous I/O
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Network package reallocation during reconfiguration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
jConnect 6.0 and sqldbgr
Installing Replication Server with other Sybase software
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for Linux Opteron
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Runtime libraries required for Linux on Power installation
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Upgrading compiled objects
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
ClearCase causes InstallShield to stop responding
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Known alter table problems
alter table unpartition errors
Running on RH3.0 64-bit distribution occasionally stops responding
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
IPv6 support causes Adaptive Server Enterprise to stop responding
Replication Server compatibility issues
Dumping or loading databases with asynchronous I/O
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Network package reallocation during reconfiguration
bcp in or bcp out
Silent installation
Sybase Central
File names
Command line flag -k
table scan and index scan
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
jConnect 6.0 and sqldbgr
Installing Replication Server with other Sybase software
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Sun Solaris
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management (SySAM) instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be aquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Release Bulletin ASE 15.0 for Sun Solaris AMD
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special installation instructions
Using SySAM 2.0
Monitoring and Diagnostic (MDA) tables
Special upgrade instructions
Changes that affect existing applications
Directory changes
Changes to ODBC and OLE DB Driver support
Changes that affect application behavior
Long-identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 6.05 ships with Adaptive Server Enterprise
SQL Remote no longer ships on the PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-in functions
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resource changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Highlighted known Job Scheduler issues
Modifying Job Scheduler SQL
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross-platform bulk copying of parsed XML images
Known alter table problems
alter table unpartition errors
Interactive SQL and Adaptive Server Enterprise plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL Make Permanent button
Adaptive Server Enterprise plug-in shows incorrect status for Job Scheduler task
Interactive SQL does not generate plans for SQL statements using go
Connecting Adaptive Server Enterprise plug-in to RepConnector
Query support in Interactive SQL
Adaptive Server Enterprise plug-in drag-and-drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
Adaptive Server Enterprise plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
Inserting into a table with identity column using select distinct
SySAM licenses needed to upgrade Adaptive Server Enterprise
Cross-platform dumps and loads
Running dbcc checktable or dbcc checkdb before bringing a database online
allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition timetable corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device can report errors
Using an equijoin clause between two different length columns
set statistics io does not display I/O generated by worker processes
IPv6 support causes Adaptive Server Enterprise to stop responding
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
bcp in or bcp out
Silent installation
Sybase Central
File names
Command line flag -k
table scan and index scan
Indexes
Determining devices for a database
Product compatibilities
Adaptive Server interoperability
Adaptive Server Replicator 15.0 support of Adaptive Server Enterprise 12.5 datatypes
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Copy menu
Documentation updates and clarifications
Reference Manual: Building Blocks
Correction in derived_stat
Correction in xa_bqual example
Reference Manual: Commands
Correction in create table
Clarification in dbcc
Correction in select
Correction in set proc_output_params off
Reference Manual: Procedures
sp_sproc_columns column_type description
sp_poolconfig
Installation guide
Determining devices for a database
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Accessibility features
Release Bulletin ASE 15.0 for Windows
Accessing current release bulletin information
Product summary
Installation kit
Operating system requirements
Special Sybase Software Asset Management (SySAM) instructions
Monitoring Adaptive Server for SySAM issues
If the SySAM license cannot be acquired
Aquiring SySAM licenses under grace
The SySAM network license server
Special installation instructions
Special upgrade instructions
Upgrading compiled objects
Upgrading high availability and Cluster support
Upgrading the cluster subsystem
Upgrading Adaptive Server configured with high availability
Product and platform interoperability
Changes that may affect existing applications
Installation, upgrade and migration
Changes that will affect application behavior
Long identifier changes
Query changes
Component Integration Services changes
Error message changes
jConnect version 5.5 no longer shipped with Adaptive Server
SQL Remote is no longer shipped on the Adaptive Server PC-Client CD
Table changes
Changes that affect database administration operations
Usage of system built-ins
DDL and DML changes
System stored procedure changes
Common diagnostics changes including trace flag usage
System resources changes
Unpartitioning of user tables during upgrade
Space management changes
Changes to transaction dump content from pre-version 15.0 Adaptive Server releases
Open Client and Open Server changes
Known problems
Highlighted known installation issues
Uninstalling Adaptive Server
Highlighted known Job Scheduler issues
Syntax error in the Job Scheduler utility scripts
Modifying Job Scheduler SQL
Highlighted known ASE Replicator problems
ASE Replicator 15.0 supports only ASE 12.5 datatypes
Highlighted known XML problems
Storing a parsed XML document in a varbinary column
Cross platform bcp of parsed XML images
Highlighted known Web Services problems
Run scripts fail to find LDAP configuration file
Alias names limited to 255 characters
Highlighted known Interactive SQL and ASE plug-in issues
Opening XML files with Interactive SQL
Displaying messages next to result sets with Interactive SQL
Running a script file with Interactive SQL
Connecting or disconnecting from pass-through servers using Interactive SQL
Interactive SQL’s Make Permanent button
ASE plug-in shows incorrect status for Job Scheduler task
Interactive SQL may not generate plans for SQL statements using go
Connecting ASE plug-in to RepConnect
Query support in Interactive SQL
ASE plug-in drag and drop server capability
Finding help in the Options dialog
Unified Agent Framework RMI ports
ASE plug-in data panel for a table with a binary null column
Starting Interactive SQL from a command line fails
Statistics in system tables
Running checkstorage on an upgraded master device may report faults with the syscharsets catalog
Monitor GUI does not start when the LDAP server is used
A stacktrace occurs when inserting into a table with identity column using select distinct
SySAM licenses are needed before upgrading Adaptive Server
Cross platform loads
Running dbcc checktable or dbcc checkdb before bring a database online
Recovering from an upgrade during an online database command
Messaging functionality
The configuration parameter allow backward scan does not work
Modifying dbccdb schema for large identifiers
Drop definition time table corruption
Manual upgrade with named cache fails
Running diskrefit to recover a corrupt master device may report errors
Using an equi-join clause between two different length columns
set statistics io does not display I/O generated by worker processes
alter table unpartition errors
Edit and Load windows
Replication Server compatibility issues
Blank spaces in an ldap server entry
cis connect timeout and enable SNMP are not implemented
Handling multibyte character sets during migration
Product compatibilities
Known compatibility issues
Installing Enterprise Connect Data Access (ECDA) or MainframeConnect DirectConnect for z/OS with other Sybase software
Installing Replication Server with other Sybase software
Using Job Scheduler templates
Technical support
Other sources of information
Sybase certifications on the Web
Sybase EBFs and software maintenance
Quick Installation Guide for Linux
About this book
Installing Adaptive Server
Adaptive Server editions
Adaptive Server Enterprise Express Edition
Adaptive Server Enterprise Developer Edition
Adaptive Server Enterprise (Enterprise Edition for evaluation)
System requirements
Pre-installation tasks for a fresh installation
Pre-installation tasks for an overlay installation
Installing Adaptive Server
Changing default character set, sort order or language
Changing the default character set and sort order
Changing the default language
Post-installation tasks for an overlay installation
Running the installmaster script
Running the installcommit script
Running the installsecurity script
Running the instmsgs.ebf script
Running the installjsdb script
Upgrading Job Scheduler Templates
Running the installmontables script
Reverting to the previously installed release
Quick Installation Guide for Windows
About this book
Installing Adaptive Server
Adaptive Server editions
Adaptive Server Enterprise Developer Edition
Adaptive Server Enterprise (Enterprise Edition for evaluation)
System requirements
Pre-installation tasks for a fresh installation
Pre-installation tasks for an overlay installation
Installing Adaptive Server
Changing default character set, sort order or language
Changing the default character set and sort order
Changing the default language
Post-installation tasks for an overlay installation
Running the installmaster script
Running the installcommit script
Running the installsecurity script
Running the instmsgs.ebf script
Running the installjsdb script
Upgrading Job Scheduler Templates
Running the installmontables script
Reverting to the previously installed release
Installation Guide for IBM AIX
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Moving to Adaptive Server 15.0 on AIX 5.2 64-bit
Upgrade to Adaptive Server release 15.0 on a new machine running IBM AIX 5.2
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for HP
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for Linux
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Express Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Creating Raw Partitions
Overview
Creating the partitions
Red Hat Raw device administration
SuSE raw device administration
Accessing raw devices from Adaptive Sever
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Backup Server Tape Device Support
Installation Guide for Sun Solaris
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Checking RUN_server file location
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Using sqlupgrade
Using sqlupgraderes
Resource file attributes for upgrading Adaptive Server
Upgrading using sqlupgraderes
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Migrating from 32-bit to 64-bit versions
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Cannot use X-Windows
Fatal error: cannot map libct.so
Cannot eject the CD from the drive
DISPLAY environment variable not set correctly
Client not authorized to connect to server
Address already in use
Adaptive Server fails to start
The Installer fails to start
Cannot start XP Server
Configuration failed
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
Troubleshooting resource file installations
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an existing Adaptive Server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Editing a resource file created by srvbuild
Resource file attributes for Adaptive Server
Resource file attributes for Backup Server
Using srvbuildres
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Installation Guide for Windows
About this book
Overview
Product licensing with SySAM 2.0
Product components
Adaptive Server Enterprise
Backup Server
Stored procedures
The client
Adaptive Server editions
Enterprise Edition
Small Business Edition
Developer Edition
Adaptive Server specifications
Product descriptions and directory layout
Sybase support for ADO.NET, OLE DB, and ODBC
PC-Client product descriptions and directory layout
Separately installable PC-Client products
Installing Adaptive Server
Overview
System requirements
Pre-installation tasks for SySAM
Accessing SPDC
Getting your host ID
Generating licenses at SPDC
Generating a served license
Generating an unserved license
Installing a new license server
Pre-installation tasks for Adaptive Server
Installing server components
Installation methods
Installing components with the Installer in GUI mode
Post-Installation Tasks
Post installation instructions
Verifying that servers are running
Verifying that you can connect to servers
Connecting to Adaptive Server via Sybase Central
Setting the System Administrator password
Installing and configuring SAMreport
Installing sample databases
Default devices for sample databases
interpubs database
jpubs database
Maintaining the sample databases
Installing Sybase PC-Client Products
Overview
Before you install the PC-Client products
Installing PC-Client products
Installing PowerDesigner, PowerTransfer, and InfoMaker
Configuring network connections for client products
Configuring libtcl.cfg for LDAP
Adding a server to the interfaces file
Testing the Sybase Central installation
Upgrading Adaptive Server
Overview of the upgrade process
System catalog changes during upgrade
Pre-upgrade tasks
Checking system and upgrade requirements
Note server and device names and locations
Procedure text is required for upgrade
Reserved words
Running a reserved word check
Addressing reserved words conflicts
Using quoted identifiers
Preparing the database and devices for the upgrade
Create a sybsystemdb database
If you have a sybsystemdb database
If you do not have a sybsystemdb database
sybsystemprocs
Upgrading to Adaptive Server 15.0
Upgrading the server
Testing the Adaptive Server upgrade
Post-upgrade tasks
Restoring functionality in Adaptive Server
Re-enabling Replication Server
Removing old log records
Reenabling replication
Restoring replication after upgrade
Re-enabling auditing
Special considerations for threshold procedures for audit segments
Shutting down SySAM servers
Upgrading Backup Server, Monitor Server, and XP Server
Upgrading Job Scheduler
Upgrading Job Scheduler templates
Upgrading high availability
Recovering from a failed upgrade
Troubleshooting
Overview
Error log locations
Solutions to common installation problems
Fatal error: cannot map libct.so
Adaptive Server fails to start
The Installer fails to start
Stopping Adaptive Server after a failure
Recovering from a failed installation
If installation fails after files are created
If Adaptive Server fails the pre-upgrade eligibility test
Recovering from a failed upgrade
Restoring from backup
Re-running the upgrade
If the cause of the failure is known
If the cause of the failure is unknown
Upgrading compiled objects with dbcc upgrade_object
Finding compiled object errors before production
Reserved word errors
Missing, truncated, or corrupted source text
Quoted identifier errors
Temporary table references
select * potential problem areas
Using dbcc upgrade_object
Increasing the log segment size
Error reporting
Using database dumps in upgrades
Upgrading using dump and load
Upgrading compiled objects in database dumps
Determining whether a compiled object has been upgraded
Troubleshooting SySAM Issues
Calling Sybase technical support for SySAM-related issues
Where to look for SySAM-related errors
Troubleshooting SySAM
SySAM grace mode
SySAM grace period
Enabling and changing e-mail notifications
Removing Adaptive Server
Uninstalling Adaptive Server 15.0
Removing an old server
Alternative Installation Methods
Installation on consoles (non-GUI mode)
Silent installation
Configuration using resource files
Configuring from a resource file
Editing a sample resource file
Resource file variables
Running the sybatch utility
Upgrading Servers with Replicated Databases
Introduction
Suspending transaction processing and replication activities
Draining the transaction logs for primary databases
Draining the RSSD transaction log
Disabling the secondary truncation point
Using sybsystemprocs
Introduction
Increasing the size of the sybsystemprocs database
Increasing device and database capacity for system procedures
Configuration Guide for UNIX
About this book
Introduction
About Adaptive Server
System-specific issues
System user roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
dsync option on by default for database device files
Determining the location, type, and size of a database device
For Solaris, HP-UX, IBM AIX, and Linux
For All Platforms
Client/server communication
Changing Adaptive Server configuration
Languages other than U.S. English
Adaptive Server specifications
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Using a RUN_server_name file
Using the startserver command
Using the monserver and backupserver commands
Starting servers when the operating system restarts
For HP-UX
For IBM RS/6000
For Sun Solaris and Linux
Starting XP Server after initial installation
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Using the kill command
Shutdown and shared memory files
Configuring the Operating System
Setting environment variables
Configuring new servers with srvbuild
Using the stty setting
Restoring correct permissions
File descriptors and user connections
For HP-UX
For AIX
For Linux
For Sun Solaris
Displaying current soft and hard limits
Increasing the soft limit
Increasing the hard limit
Sample program
Enabling asynchronous disk I/O
Adjusting the client connection timeout period
For HP-UX
For IBM RS/6000
For Sun Solaris
For Linux
Checking for hardware errors
For HP-UX
For IBM RS/6000
For Sun Solaris
For Linux
Monitoring the use of operating system resources
For HP-UX
For IBM RS/6000
For Sun Solaris and Linux
A sample C shell maintenance script
Adaptive Server Default Configuration
Default settings
Setting Up Communications Across the Network
How Adaptive Server determines which directory service entry to use
How a client uses directory services
Creating a directory services entry
Supported directory drivers
Contents of an interfaces file
Heterogeneous and homogeneous environments
Understanding the format of the interfaces file
Components of an interfaces file entry
Creating a master interfaces file
Using dsedit or dscp to create a master interfaces file
Using a text editor to create a master interfaces file
Configuring interfaces files for multiple networks
Configuring the server for multiple network handlers
Sample interfaces files for multiple network handlers
Configuring the client connections
Using one network-independent DSQUERY name
Using different DSQUERY names
Configuring for query port backup
IPv6 support
Understanding IPv6
IPv6 infrastructure
Starting Adaptive Server Enterprise as IPv6-aware
Troubleshooting
Server fails to start
Error when executing an ESP
Using the Lightweight Directory Access Protocol as a Directory Service
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl*.cfg file
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the interfaces file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default language and character set
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
Adaptive Server localization
Backup Server localization
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Adaptive Server error logging
Enabling and disabling error logging
Setting error log paths
Setting the Adaptive Server error log path
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating files for database devices
Adding Optional Functionality to Adaptive Server
Adding auditing
Audit system devices and databases
Overview of audit installation
Pre-installation tasks for auditing devices
Installing auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Configuration Guide for Windows
About this book
Introduction
About Adaptive Server
System-specific issues
Definition of terms
User roles
Environment variables
Adaptive Server devices and system databases
The master device
The sybsystemdb device
The sysprocsdev device
Optional devices and databases
Client/server communication (the interfaces file)
Changing Adaptive Server configuration
Support for high-availability products
Languages other than U.S. English
Adaptive Server specifications
Starting and Stopping Servers
Overview
Requirements for starting servers
Starting servers
Server start-up parameters
Changing start-up parameters
Starting and stopping servers using Unified Agent
Starting and stopping servers using the Control Panel
Starting servers as an automatic service
Starting, stopping, and pausing servers manually
Stopping servers
Stopping Adaptive Server
Stopping Backup Server
Stopping Monitor Server
Monitoring servers
Unified Agent
The Control Panel
Default Adaptive Server Configuration
Starting Server Config for Adaptive Server
Configuring Adaptive Server
Setting Adaptive Server parameters
Changing the default Backup Server
Changing the default XP Server
Configuring Backup Server
Configuring Monitor Server
Supporting access to large memory
Configuring Job Scheduler and Self Management
Network Communications Using sql.ini
How clients connect to Adaptive Server
How Adaptive Server listens for client connections
How a client accesses Adaptive Server
Enabling client access to a server
Changing the server entries in sql.ini
Components in the sql.ini file
Server name
Network driver
Service type
Server address
Address format
IP address
Named Pipes format
Windows Sockets format
NWLink IPX/SPX format
Sharing network configuration information
Creating a master sql.ini file
Using Windows Registry as a directory service
Verifying server connections
Configuring ODBC connections
Configuring the ODBC driver
IPv6 support
Understanding IPv6
IPv6 infrastructure
Starting Adaptive Server Enterprise as IPv6-aware
Lightweight Directory Access Protocol in Adaptive Server
Overview
LDAP directory services versus the Sybase interfaces file
The libtcl.cfg file
Enabling LDAP directory services
Adding a server to the directory services
Multiple directory services
Encrypting the password
Performance
Migrating from the sql.ini file to LDAP
Customizing Localization for Adaptive Server
Overview of localization support
Language modules
Default character sets for servers
Changing the default character set for servers
Supported character sets
Character set conversion
Conversions between server and client
Sort orders
Available sort orders
Language modules
Installing a new language module
Message languages
Localization
Localization directories
About the directory
About the charsets directory
About the locales.dat file
Format of locales.dat file entries
How client applications use locales.dat
Editing the locales.dat file
Changing the localization configuration
For Adaptive Server
For Backup Server
Configuring Adaptive Server for other character sets
Sort orders
Character sets
charset utility
Logging Error Messages and Events
Logging errors and events
Adaptive Server error logging
Enabling and disabling error logging
Types of information logged
Windows event-logging
Setting up Windows event-logging for use by Adaptive Server
Types of information logged
Managing the logs
Setting error log paths
Setting the Adaptive Server error log path
Setting the Backup Server error log path
Setting the Monitor Server error log path
Enabling and disabling Windows event logging
Using Server Config
Using sp_configure
Managing messages
Logging user-defined messages
New messages
Existing messages
Logging auditing events
Logging user-defined events
Using a remote log
Using a central logging site
Logging messages from multiple Adaptive Servers
Setting up a local central logging site
To create and define a Registry key
Viewing the messages
In the Windows event log
In the Adaptive Server error log
Using Security Services with Windows LAN Manager
Security services with Windows LAN Manager
How login authentication works
Administering security services using LAN Manager
Modifying configuration files for a unified login
Setting up drivers for network-based security
Entries for network drivers
Entries for Directory Services
Entries for security drivers
Checking the LAN Manager’s local name
Specifying security information for Adaptive Server
Identifying users and servers to LAN Manager
Configuring Adaptive Server for LAN Manager security
Enabling and disabling external security services
Managing unified login
Requiring unified login
Establishing a secure default login
Mapping LAN Manager login names to server names
Requiring data integrity check
Ensuring adequate memory for security services
Initiating the new security services
Adding logins to support unified login
General procedure for adding logins
Defining the connection to a server for security services
Specifying the principal name
Specifying network-based user authentication
Specifying the name assigned to LAN Manager
Determining the status of security services
Configuration parameters used in security services
Checking data integrity
Checking message sequence
Detecting interception or replay
Specifying a login
Controlling user authentication
Managing login security on an Windows computer
Overview of security features
Adaptive Server security
Combined Adaptive Server and Windows login security
Standard mode
Integrated mode
Mixed mode
Managing the login security features
Permitting trusted connections
Windows Registry parameters
Administering login security using system procedures
Assigning trusted connection permissions
Displaying the current Registry values
Displaying permissions and user names
Revoking permissions granted with sp_grantlogin
Configuring login security
Create Windows users and groups
Configure mapping and Default Domain values
Set login security mode
Add network login names to syslogins
Assign roles
Changing login security options
Using E-mail with Adaptive Server
Sybmail messages
Sending messages
Receiving messages
Preparing Windows Mail for Sybmail
Connecting to a post office
Creating a mailbox for Adaptive Server
Creating a mail profile for Adaptive Server
Creating an Adaptive Server login for Sybmail
Sybmail and extended stored procedures
Managing a mail session
Starting a session
Starting Sybmail without parameters
Stopping a mail session
Stored and extended procedures for handling messages
Sending messages
Text messages
Query result messages
Receiving messages
Finding the next message
Reading a specific message
Deleting a message
Processing incoming mail
Using Sybmail security
Setting execution privileges
Setting the execution context
Naming both the user and the database
Naming the user but not the database
Naming the database but not the user
Naming neither the user nor the database
Managing Adaptive Server Databases
Managing database devices
Device requirements
Creating .dat files for database devices
Backing up and restoring data
Using a tape drive
Windows tape drive names
Setting the maximum capacity for a tape drive
Using a hard disk
Dumping across a network
Examples of backing up and restoring databases
User databases
System databases
Optimizing Adaptive Server performance and tuning
Using dedicated Adaptive Server operation
Using disk drives
Monitoring disk usage
Monitoring Adaptive Server statistics with Windows Performance Monitor
Adding Optional Functionality to Adaptive Server
Installing auditing
Audit system devices and databases
The sybsecurity device and database
Tables and devices for the audit trail
Device for syslogs systems table
Pre-installation tasks for auditing devices
Installing Auditing
Installing online help for Transact-SQL syntax
Online syntax help: sp_syntax
Default device for the sybsyntax database
Installing sybsyntax
Troubleshooting Network Connections
The dsedit Server Ping Utility
Running Server Ping
Troubleshooting connection failures
When a test fails
Using returned messages to diagnose a failure
Failure to connect to Adaptive Server
Failure to load Net-Library DLLs
Failure of other applications
Before calling Sybase Technical Support
Adaptive Server Registry Keys
ASE Replicator User's Guide
About this book
Introduction to ASE Replicator
Understanding replication concepts
Table replication
Stored procedure replication
Transaction replication
Guaranteed delivery
Understanding ASE Replicator
ASE Replicator components
ASE Replicator process
Distribution Database
Publisher component
Distributor component
ASE Replicator processing
ASE Replicator objects
Database connections
Publications and subscriptions
Articles
Fields
ASE Replicator limitations
Setting Up and Starting ASE Replicator
Setting up ASE Replicator
Configuring the primary Adaptive Server
Enabling and configuring CIS
Setting up the ASE Replicator system user
Defining a local name and remote alias for the primary Adaptive Server
Defining a remote server name for the ASE Replicator process
Creating the Distribution Database
Configuring the replicate servers and databases
Identifying the remote server
Setting up a separate a Maintenance User login
Granting permissions in the replicate database
Initializing the ASE Replicator process
Running the aserep script the first time
UNIX permissions
Setting up the sp_helpddb system procedure
Starting ASE Replicator
Using the aserep script
Using the RUN script
Setting up a replication system
Uninstalling ASE Replicator
Administering ASE Replicator
Administering the ASE Replicator process
Configuring ASE Replicator
Shutting down the ASE Replicator process
Suspending replication
Resuming replication
Monitoring ASE Replicator
Managing database connections
Creating a database connection
Creating a primary database connection
Creating a replicate database connection
Deleting a database connection
Configuring a database connection
Suspending and resuming database connections
Suspending database connections
Resuming database connections
Getting information about database connections
Getting metadata and status information for connections
Getting statistics information for connections
Getting connection configuration information
Managing publications and subscriptions
Creating publications and subscriptions
Deleting publications and subscriptions
Suspending and resuming subscriptions
Getting information about publications and subscriptions
Managing primary and replicate articles
Creating primary articles
Creating replicate articles
Deleting primary articles
Deleting replicate articles
Materializing and validating replicate articles
Getting information about primary articles
Getting metadata information for primary articles
Getting information about published fields in primary articles
Getting information about primary articles in publications
Getting information about unpublished objects
Getting information about primary articles with no subscribers
Getting information about replicate articles
Getting replicate article metadata information
Getting information about fields in replicate articles
Getting information about replicate articles in subscriptions
ASE Replicator configuration parameters
General configuration parameters
admin_port
ase_charset
ase_host
ase_port
batch_size
batch_timeout
ddb_name
log_directory
log_trace_verbose
log_wrap
monitor_delay
queue_size
scan_sleep_increment
scan_sleep_max
stat_trunc_interval
stat_write_timeout
status_monitoring
truncate_numops
Connection configuration parameters
gen_id
lti_version
mode
numrecs
queue_size
scan_sleep_increment
scan_sleep_max
timeout
ASE Replicator Procedures
sp_addprimaryart
sp_addprimaryconn
sp_addpub
sp_addreplicateart
sp_addreplicateconn
sp_addsub
sp_configprimaryconn
sp_configrep
sp_configreplicateconn
sp_dropprimaryart
sp_dropprimaryconn
sp_droppub
sp_dropreplicateart
sp_dropreplicateconn
sp_dropsub
sp_helpconn
sp_helplastcommit
sp_helplocator
sp_helpprimaryart
sp_helpprimaryconn
sp_helppub
sp_helprep
sp_helpreplicateart
sp_helpreplicateconn
sp_helpsub
sp_materializesub
sp_resumeprimaryconn
sp_resumerep
sp_resumereplicateconn
sp_resumesub
sp_shutdownrep
sp_suspendprimaryconn
sp_suspendrep
sp_suspendreplicateconn
sp_suspendsub
sp_tracerep
sp_validatesub
Troubleshooting ASE Replicator
Problems that prevent replication from starting
Primary server configuration problems
Adaptive Server character set problems
Remote server configuration problems
ASE Replicator configuration problems
User login or permission problems
Problems that cause replication to fail
Schema changes in primary or replicate tables
Altering a published primary object
Altering a replicate object
Datatypes, constraints, and column properties
Replicating approximate numeric datatypes
Replicating the value of the timestamp datatype
Replicating IDENTITY columns
Incompatible datatypes
Incompatible primary key constraints
Different null types
Java memory problems
Other problems and issues
Subscription status after abnormal shutdown
Distribution Database Schema
Distribution Database base objects
Distribution Database datatypes
Base tables in the Distribution Database
Distribution Database system table
Connections table
Connection properties table
Publications table
Primary articles table
Primary article fields table
Primary articles/publications relation table
Subscriptions table
Replicate articles table
Replicate article fields table
Transaction log table
Configuration table
Trace table
Statistics table
Truncation table
Base procedures in the Distribution Database
Distribution Database shadow tables
Shadow tables for primary tables without large objects
Shadow tables for primary tables with large objects
Shadow tables for primary procedures
Distribution Database replicate objects
Distribution procedures
Replicate article proxy tables
Glossary
Component Integration Services User's Guide
About this book
Introduction
Understanding Component Integration Services
Basic concepts
Access methods
Server classes
Object types
Interface to remote servers
Proxy tables
Using the create table command
Using the create existing table command
Datatype conversions
Example of remote table definition
Using the create proxy_table command
Remote procedures as proxy tables
Server limits
create new proxy table
create existing proxy table
create proxy_table
alter table
select, insert, delete, update
RPC handling
sp_tables
Cascading proxy tables
Proxy databases
User proxy databases
User proxy database schema synchronization
System proxy databases
System proxy database creation
Schema synchronization when current database has a system proxy database
Stored procedure execution within a system proxy database
Additional behavior of the system proxy database
File system access
Security considerations
Directory access
Recursion through subordinate directories
File access
Remote servers
Server class ASEnterprise
Server class ASAnywhere
Server class ASIQ
Server class direct_connect
Server class sds
Connection management
Connecting to remote servers without the interfaces file
LDAP directory services
Secure communication with SSL
Trusted roots files
Security issues
Remote server logins
Trusted mode
Connecting to Backup Server and XP Server
Mapping external logins
Remote server connection failover
Remote server capabilities
Query processing
Processing steps
Query parsing
Query normalization
Query preprocessing
Decision point
Component Integration Services plan generation
Adaptive Server optimization and plan generation
Component Integration Services plan generation
Component Integration Services remote location optimizer
Query plan execution
RPC handling and Component Integration Services
Site handler and outbound RPCs
Component Integration Services and outbound RPCs
Text parameters for RPCs
Text parameter support for XJS/390
Distributed Transaction Management
Server classes and ASTC
DTM-enabled servers
Pre-DTM servers
strict DTM enforcement
enable xact coordination
Enable Component Integration Services
Transactional RPCs
Restrictions on transaction management
Adaptive Server to Adaptive Server update statistics
Limitations
Updating statistics on non-Adaptive Server backends
Java in the database
@@textsize
@@stringsize
Constraints on Java class columns
Error messages
Java abstract datatypes (ADTs)
Java class definitions
Datatypes
Unicode support
create table
create existing table
create proxy_table
alter table
select, insert, update, and delete statements
Datatype conversions
text and image datatypes
Restrictions on text, image, and unitext columns
Limits of @@textsize
Odd bytes padded
Converting text and image datatypes
Pattern matching with text and unitext data
Entering text and image values
readtext using bytes
text, image, and unitext with bulk copy
Error logging
text, unitext, and image data with server class ASEnterprise
text, image, and unitext data with server class direct_connect
Configuration and tuning
Using sp_configure
sysconfigures table
Changing the configuration parameters
Component Integration Services configuration parameters
Global variables for status
SQL Reference
dbcc commands
dbcc options
Trace flags
Functions
Support for functions within Component Integration Services
Aggregate functions
Datatype conversion functions
Date functions
Mathematical functions
Security functions
String functions
System functions
Text and image functions
Transact-SQL commands
alter table
case
connect to...disconnect
create existing table
create index
create table
delete
drop index
fetch
insert
readtext
select
truncate table
update
update statistics
writetext
Passthrough mode
connect to
sp_autoconnect
sp_passthru
sp_remotesql
Quoted identifier support
Delimited identifier support
auto identity option
Triggers
Tutorial
Getting started with Component Integration Services
Adding a remote server
Overview
Adding the remote server to the interfaces file
Creating server entries in system tables
Adding an alternate login and password
Verifying connectivity
Join between two remote tables
Adding the remote servers to the interfaces file
Defining the remote servers
Mapping the remote tables to Adaptive Server
Performing the join
Troubleshooting
Problems accessing Component Integration Services
Problems using Component Integration Services
Unable to access remote server
Requested server name not found
Driver call to connect two endpoints failed
Login failed
Unable to access remote object
Problem retrieving data from remote objects
Object is altered outside Component Integration Services
Index is added or dropped outside Component Integration Services
If you need help
ASE 15.0 with Encrypted Columns
Installing Adaptive Server
Column encryption
Overview
Setting the system encryption password
Creating and managing encryption keys
Creating encryption keys
Using encryption keys
Granting permissions on keys
Changing the key
Encrypting data
Specifying encryption on new tables
Creating indexes on encrypted columns
Encrypting data in existing tables
Decrypting data
Permissions for decryption
Revoking decryption permission
Dropping encryption and keys
Dropping encryption and encryption keys
select into command
Length of encrypted columns
Auditing encrypted columns
Auditing options
Audit values
New event names and numbers
Performance considerations
Indexes on encrypted columns
Joins on encrypted columns
Constant valued search arguments and encrypted columns
Movement of encrypted data as ciphertext
System tables
syscolumns
sysobjects
sysencryptkeys
ddlgen utility extensions for encrypted columns
Replicating encrypted data
Bulk copy (bcp)
Component Integration Services (CIS)
load and dump databases
unmount database
quiesce database
Drop database
sybmigrate
Referential integrity constraints
Upgrade issues
New commands
create encryption key
alter encryption key
drop encryption key
grant create encryption key
revoke create encryption key
grant decrypt
revoke decrypt
New system-stored procedure
sp_encryption
Changes to commands and system procedures
sp_helprotect
sp_configure “enable encrypted columns”
alter table
create index
create table
enable encrypted columns configuration parameter
load database
select into
dbcc
Full syntax for commands
alter encryption key
alter table
create table
select
Downgrade procedure
Enhanced Full-Text Search Specialty Data Store User’s Guide
About this book
Introduction
Capabilities of the Enhanced Full-Text Search Engine
High availability
Understanding the Enhanced Full-Text Search Engine
Components of the Enhanced Full-Text Search engine
The source table
The Verity collections
Filters
The text_db database
The vesaux table
The vesauxcol table
The index table
The text_events table
Relationships between the components
How a full-text search works
Configuring Adaptive Server for Full-Text Searches
Configuring Adaptive Server for an Enhanced Full-Text Search engine
Enabling configuration parameters
Running the installtextserver script
Editing the installtextserver script
Starting the installtextserver script
Running the installmessages script
Running the installevent script
Editing the installevent script
Running the installevent script
Naming the local Adaptive Server
Creating and maintaining text indexes
Setting up source tables for indexing
Adding an IDENTITY column to a source table
Adding a unique index to an IDENTITY column
Creating the text index and index table
Specifying multiple columns when creating a text index
Bringing the database online for full-text searches
Propagating changes to the text index
Replicating text indexes
Example: enabling a new database for text searches
Step 1. Verifing that the text_events table exists
Step 2. Checking for an IDENTITY column or primary key
Step 3. Creating a unique index on the IDENTITY column
Step 4. Creating the text index and index table
Step 5. Bringing the database online for a full-text search
Indexing the euro symbol
Setting Up Verity Functions
Enabling query-by-example, summarization, and clustering
Editing the master style.prm file
Editing individual style.prm files
Setting up a column to use as a sort specification
Using filters on text that contains tags
Creating a custom thesaurus
Examining the default thesaurus (optional)
Creating the control file
Control file syntax
Creating the thesaurus
Replacing the default thesaurus with the custom thesaurus
Creating topics
Creating an outline file
Creating a topic set directory
Creating a knowledge base map
Defining the location of the knowledge base map
Executing queries against defined topics
Troubleshooting topics
Writing Full-Text Search Queries
Components of a full-text search query
Default behaviour
Pseudo columns in the index table
Using the score column to relevance-rank search results
Using the sort_by column to specify a sort order
Using the summary column to summarize documents
Using pseudo columns to request clustered result sets
Preparing to use clustering
Writing queries requesting a clustered result set
Full-text search operators
Considerations when using Verity operators
Using the Verity operators
accrue
and, or
complement
in
like
near, near/n
or
phrase
paragraph
product
sentence
stem
sum
thesaurus
topic
typo/n
wildcard
word
yesno
Operator modifiers
System Administration
Starting the Enhanced Full-Text Search engine on UNIX
Creating the runserver file
Starting the Enhanced Full-Text Search engine on Windows NT
Starting the Enhanced Full-Text Search engine as a service
Shutting down the Enhanced Full-Text Search engine
Modifying the configuration parameters
Modifying configuration values
Available configuration parameters
Setting the default language
Setting the default character set
Indexing on the euro symbol
Setting the default sort order
Setting trace flags
Setting Open Server trace flags
Setting case sensitivity
Backup and recovery for the Enhanced Full-Text Search engine
Customizable backup and restore
Backing up Verity collections
Restoring collections and text indexes from backup
Performance and Tuning
Updating existing indexes
Increasing query performance
Limiting the number of rows
Ensuring the correct join order for queries
Reconfiguring Adaptive Server
cis cursor rows
cis packet size
Reconfiguring the Enhanced Full-Text Search engine
batch_size
min_sessions and max_sessions
Using sp_text_notify
Configuring multiple Enhanced Full-Text Search engines
Creating multiple Enhanced Full-Text Search engines at start-up
Adding Enhanced Full-Text Search engines
Configuring additional Enhanced Full-Text Search engines
Multiple users
File Descriptors and Enhanced Full-Text Search
Verity Topics
What are topics?
Topic organization
Weight assignments
Using a topic outline file
Making topics available
Setup process
Knowledge bases of topics
Combining topics into a knowledge base
Structure of topics
Top-level topics
Subtopics
Evidence topics
Topic and subtopic relationships
Maximum number of topics
Topic naming issues
Verity query language
Query language summary
Evidence operators
Proximity operators
Relational operators
Concept operators
Boolean operators
Modifiers
Operator precedence rules
Sample topic outlines
Operator reference
ACCRUE operator
ALL operator
AND operator
ANY operator
CONTAINS operator
ENDS operator
= (EQUALS) operator
FILTER operator
> (GREATER THAN) operator
>= (GREATER THAN OR EQUAL TO) operator
< (LESS THAN) operator
<= (LESS THAN OR EQUAL TO) operator
IN operator
MATCHES operator
NEAR operator
NEAR/N operator
OR operator
PARAGRAPH operator
PHRASE operator
SENTENCE operator
SOUNDEX operator
STARTS operator
STEM operator
SUBSTRING operator
THESAURUS operator
TYPO/N operator
WILDCARD operator
Using wildcard special characters
Searching for nonalphanumeric characters
Searching for wildcard characters as literals
Searching for special characters as literals
WORD operator
Modifier reference
CASE modifier
MANY modifier
NOT modifier
ORDER modifier
Weights and document importance
Topic weights
Which operators accept weights
How weights affect importance
Assigning weights
Automatic weight assignments
Tips for assigning weights
Changing weights
Topic scoring and document importance
Designing topics
Preparing your topic design
Understanding your information needs
Understanding your documents
Using scanned data
Categorizing document samples
Topic design strategies
Top-down design
Bottom-up design
Designing the initial topic
Outlining a topic
Top-down topic outline example
Establishing an information hierarchy
Establishing individual search categories
Establishing the topics to be built
Bottom-up topic outline example
Identifying low-level topics
Categorizing related subtopics
Establishing top-level topics
System Procedures
sp_check_text_index
sp_clean_text_events
sp_clean_text_indexes
sp_create_text_index
sp_drop_text_index
sp_help_text_index
sp_optimize_text_index
sp_redo_text_events
sp_refresh_text_index
sp_show_text_online
sp_text_cluster
sp_text_configure
sp_text_dump_database
sp_text_kill
sp_text_load_index
sp_text_notify
sp_text_online
Sample Files
Default textsvr.cfg configuration file
The sample_text_main.sql script
Sample files illustrating Enhanced Full-Text Search engine features
Custom thesaurus
Topics
Clustering, summarization, and query-by-example
getsend sample program
Unicode Support
Glossary
Glossary
Java in Adaptive Server® Enterprise
About this book
An Introduction to Java in the Database
Advantages of Java in the database
Capabilities of Java in the database
Invoking Java methods in the database
Invoking Java methods directly in SQL
Invoking Java methods as SQLJ stored procedures and functions
Storing Java classes as datatypes
Storing and querying XML in the database
Standards
Java in the database: questions and answers
What are the key features?
How can I store Java instructions in the database?
How is Java executed in the database?
Client- and server-side JDBC
How can I use Java and SQL together?
What is the Java API?
How can I access the Java API from SQL?
Which Java classes are supported in the Java API?
Can I install my own Java classes?
Can I access data using Java?
Can I use the same classes on client and server?
How do I use Java classes in SQL?
Where can I find information about Java in the database?
What you cannot do with Java in the database
Sample Java classes
Preparing for and Maintaining Java in the Database
The Java runtime environment
Java classes in the database
Sybase runtime Java classes
User-defined Java classes
JDBC drivers
The Java VM
Configuring memory for Java in the database
Enabling the server for Java
Disabling the server for Java
Creating Java classes and JARs
Writing the Java code
Compiling Java code
Saving classes in a JAR file
Installing uncompressed JARs
Installing compressed JARs
Installing Java classes in the database
Using installjava
Retaining the JAR file
Updating installed classes
Referencing other Java-SQL classes
Viewing information about installed classes and JARs
Downloading installed classes and JARs
Removing classes and JARs
Retaining classes
Using Java Classes in SQL
General concepts
Java considerations
Java-SQL names
Using Java classes as datatypes
Creating and altering tables with Java-SQL columns
Altering partitioned tables
Selecting, inserting, updating, and deleting Java objects
Invoking Java methods in SQL
Sample methods
Exceptions in Java-SQL methods
Representing Java instances
Assignment properties of Java-SQL data items
Datatype mapping between Java and SQL fields
Character sets for data and identifiers
Subtypes in Java-SQL data
Widening conversions
Narrowing conversions
Runtime versus compile-time datatypes
The treatment of nulls in Java-SQL data
References to fields and methods of null instances
Null values as arguments to Java-SQL methods
Null values when using the SQL convert function
Java-SQL string data
Zero-length strings
Type and void methods
Java void instance methods
Java void static methods
Equality and ordering operations
Evaluation order and Java method calls
Columns
Variables and parameters
Static variables in Java-SQL classes
Java classes in multiple databases
Scope
Cross-database references
Inter-class transfers
Passing inter-class arguments
Temporary and work databases
Java classes
Data Access Using JDBC
Overview
JDBC concepts and terminology
Differences between client- and server-side JDBC
Permissions
Using JDBC to access data
Overview of the JDBCExamples class
The main( ) and serverMain( ) methods
Using main( )
Using serverMain( )
Obtaining a JDBC connection: the Connecter( ) method
Routing the action to other methods: the doAction( ) method
Executing imperative SQL operations: the doSQL( ) method
Executing an update statement: the updater( ) method
Executing a select statement: the selecter( ) method
Calling a SQL stored procedure: the caller( ) method
Error handling in the native JDBC driver
The JDBCExamples class
The main( ) method
The serverMain( ) method
The connecter( ) method
The doAction( ) method
The doSQL( ) method
The updater( ) method
The selecter( ) method
The caller( ) method
SQLJ Functions and Stored Procedures
Overview
Compliance with SQLJ Part 1 specifications
General issues
Security and permissions
SQLJ Examples
Invoking Java methods in Adaptive Server
Using Sybase Central to manage SQLJ functions and procedures
SQLJ user-defined functions
Handling null argument values
Handling nulls when creating the function
Handling nulls in the function call
Deleting a SQLJ function name
SQLJ stored procedures
Modifying SQL data
Using input and output parameters
Returning result sets
Deleting a SQLJ stored procedure name
Viewing information about SQLJ functions and procedures
Advanced topics
Mapping Java and SQL datatypes
Using the command main method
SQLJ and Sybase implementation: a comparison
SQLJExamples class
Debugging Java in the Database
Introduction to debugging Java
How the debugger works
Requirements for using the Java debugger
What you can do with the debugger
Using the debugger
Starting the debugger and connecting to the database
Compiling classes for debugging
Attaching to a Java VM
The Source window
The debugger windows
Options
Setting breakpoints
Breaking on a line number
Breaking on a static method
Using counts with breakpoints
Using conditions with breakpoints
Breaking when execution is not interrupted
Disconnecting from the database
A debugging tutorial
Before you begin
Start the Java debugger and connect to the database
Attach to a Java VM
Load source code into the debugger
Step through source code
Examples
Inspecting and modifying variables
Inspecting local variables
Modifying local variables
Inspecting static variables
Network Access Using java.net
Overview
java.net classes
Setting up java.net
Example usage
Using socket classes
Saving text out of Adaptive Server
Using the URL class
Use the mailto:URL class to mail a document
Obtaining an HTTP document
User notes
Reference Topics
JDK requirement for Java classes in the server
Assignments
Assignment rules at compile-time
Assignment rules at runtime
Allowed conversions
Transferring Java-SQL objects to clients
Supported Java API packages, classes, and methods
Supported Java packages and classes
Unsupported Java packages, classes, and methods
Unsupported java.sql methods and interfaces
Invoking SQL from Java
Special considerations
Transact-SQL commands from Java methods
Datatype mapping between Java and SQL
Java-SQL identifiers
Java-SQL class and package names
Java-SQL column declarations
Java-SQL variable declarations
Java-SQL column references
Java-SQL member references
Java-SQL method calls
Glossary
Job Scheduler User's Guide
About this book
Overview
Introduction
Terminology and concepts
Job Scheduler components and functionality
Job Scheduler architecture
Security
js_user_role
js_admin_role
Shared objects
Configuring and Running Job Scheduler
Installing Job Scheduler manually
Setting up Job Scheduler users
Setting up access to target servers
Using Templates to Create Jobs
Introduction
Installing stored procedures on a target server
Installing the templates into Job Scheduler
Using Job Scheduler templates
Backup
Statistics management
Reorganization
Reconfiguration
Template updates
Using Job Scheduler at the Command Line
Creating a job
Job state codes
Creating a schedule
Creating a scheduled job
Deleting a scheduled job
Modifying a scheduled job
Invoking stored procedures on a target server
Managing jobs
Managing job history and logs
Command Reference
Command line stored procedures
Command syntax
sp_sjobcreate
sp_sjobcmd
sp_sjobmodify
sp_sjobdrop
sp_sjobhelp
sp_sjobcontrol
sp_sjobhistory
Managing Job Scheduler in the Sybase Central ASE Plug-in
Adding a scheduled job
Adding a job
Adding a schedule
Scheduling an existing job
Viewing job history
Purging job history
Administering Job Scheduler
Showing all users
Managing a scheduled job
Editing properties
Deleting a Job Scheduler object
Troubleshooting
Logging error messages
A job fails to run at the time you scheduled it
A scheduled job created from a template fails
A job with multiple calls to sp_sjobcmd fails
A stored procedure fails
Messaging Services User’s Guide
About this book
Introduction
Adaptive Server messaging concepts
Messaging models
Publish-and-subscribe (topics)
Point-to-point (queues)
Message format
JMS message properties
Message selectors
Understanding Real-Time Data Services
Sending and receiving messages from a queue
Publishing and consuming messages from a JMS topic
Working with message properties
Previewing the messaging interface
Configuring Real-Time Data Services
Configuring RTDS
Configuring Adaptive Server to communicate with TIBCO Rendezvous Server
SQL Reference
Messaging-related global variables
<msgheader> and <msgproperties> documents
Adaptive Server-specific message properties
Keywords
Stored procedures
Built-in functions
Syntax segment
sp_msgadmin
msgconsume
msgpropcount
msgproplist
msgpropname
msgproptype
msgpropvalue
msgpublish
msgrecv
msgsend
msgsubscribe
msgunsubscribe
option_string
Transactional Behavior
Transactional message behavior
Transactional messaging set option
Samples
Sybase directories
Using code samples with Replication Server function strings
Using code samples with SQL
Using code samples with Java/JDBC
Glossary
Migration Guide
About this book
Documenting Business Requirements
Creating an information-flow diagram
Identifying your operational business requirements
Availability requirements
Database change metrics
Database dump details
Maintenance procedures
Service-level requirements
Transaction profile
Recording current performance metrics
Recording additional business requirements
Documenting Your Environment
Hardware configuration
General server hardware
CPU resources per machine
Disk configuration
Network configuration
Tape configuration
Physical memory utilization
Software configuration
Operating system
Applications
Sybase configuration
General information
Database devices
Databases and segments
Dump devices
Adaptive Server objects
Adaptive Server performance
Writing a Migration Plan
Note for the upgrade process
Migrating to a 64-bit operating system or a larger page size
Alternative to dump and load for Adaptive Server 12.5.1
Determining a migration approach
Parallel with replication
Cutover without replication
Phased cutover
Writing a migration plan
Building the Adaptive Server environment
Update hardware resources
Verify operating system version and EBF level
Review Adaptive Server interoperability with other Sybase products
Use Sybase Product Download Center
Implement licensing environment
Update applications and system administration procedures
Create Migration Scripts
Making Required Application Changes
Reserved words
Upgrading Adaptive Server release 11.5
Upgrading from version 11.9.x
ANSI joins
Query processing changes
Predicate transformation and factoring
Support for as many as 50 tables in a query
Abstract query plans
Increased optimization time
like optimization enhancements
Concrete identification
Upgrading from release 12.0
Changes to Transact-SQL
enable xact coordination configuration parameter
Unlimited expressions in a select statement
Wide columns and data truncation
Change in truncation behavior
Wide columns and optimizer statistics
Wide columns with col_length() and datalength()
If you are upgrading from release 12.5
Date and time datatypes
Query and optimizer changes
Unsupported trace flags
Partition changes
Partitions and primary keys and unique indexes
Multiple and composite partition keys and range partitioning
Semantic partitions and data skew
Dropping partitions
Moving data in and out of partitions
Changes for computed columns and function-based indexes
Computed column evaluation
Nonmaterialized computed columns and invalid values
Long identifier changes
Error message changes
Open Client/SDK compatibility with Adaptive Server
New features in Open Client
Adaptive Server and Open Client compatibilities
Making Database Administration Changes
Upgrading from version 11.5 or earlier
Upgrading from version 11.9.2 or later
Optimizer changes
Abstract plan enhancements
Capturing query metrics
Updating statistics after upgrading
Automatic update statistics
datachange function
update statistics on partitions
Changes to functions
Changes to system tables
Changes to third-party tools
Changes to database IDs
ASE plug-in for Sybase Central
Interactive SQL
sybsyntax
Changes to documentation
sybsystemdb
bcp with syslogins
Maximum number of users and logins
New reserved words
Configuration parameters
stack size
Increased memory
Changes that affect upgrade and server functionality
Device size
bigint support
unsigned int support
Integer identity
Separate device ID column
File system or raw partition?
Row-locked system catalogs
Databases are larger
#temp table changes
New limits for regular delimited identifiers
SySAM license manager
buildmaster obsolete
Ensuring Stability and Performance
Overview
Setting up the test environment
Make backups
Use scripts to create the test system
Install monitoring tables
Create your databases by loading backups
If your test environment is not an exact duplicate
Prioritizing applications to be tested
Establishing performance criteria
Developing fallback procedures
Summary of testing techniques
Writing performance scripts
Write benchmark scripts
Drivers
General error handling
Deadlock handling
Result handling
Time measurement
Runtime data generation
Summary of tests
Determining query processing changes
Before you start testing
Determining which queries are impacted during migration
Finding impacted queries
Finding long-running stored procedures
Diagnosing and fixing query processing issues in 15.0 servers
Using sysquerymetrics and sp_metrics
Using sysquerymetrics to support regression testing
Using showplan options
set statistics plancost
Query plans as XML
Query-level debugging in Adaptive Server 15.0
Early timeout detection versus tablecount
Fixing queries using abstract query plans
Forcing an join order
Forcing different subquery attachments
Reporting query processor and optimizer issues
Testing for performance
Pre-upgrade single-user tests
Optimizer
I/O
Pre-upgrade multiuser tests
Untimed benchmarks
Timed benchmarks
Test system upgrade
Post-upgrade single-user tests
Post-upgrade multiuser tests
Untimed benchmarks
Timed benchmarks
Worksheets for Your Current Environment
Adaptive Server operational worksheets
Operational business requirements
Backup and restore procedures
Database dump details
Maintenance procedure details
Data architecture worksheet
Client application components
Production performance metrics
Transaction profile
Adaptive Server infrastructure worksheets
Host configuration
Hardware
Physical memory usage
Disk I/O configuration
Network configuration
Tape configuration
Operating system configuration
Adaptive Server configuration
Database devices
Databases and segments
Dump devices
Sample Migration Task Lists
Sample task list template
General migration task list example
Migration analysis
Document current configuration
Gather business requirements
Conduct compatibility analysis
Develop migration strategy
Migration preparation
Write test plans and test scripts
Prepare applications for migration
Design and develop server migration scripts
Design and develop database migration scripts
Design and develop data migration scripts
Perform other premigration tasks
Implement migration (using install/load technique)
Create target environment
Perform server migration
Perform database migration
Perform data migration
Complete server and data migration
Perform application migration
Implement migration (using upgrade technique)
Upgrade adaptive server
Complete migration
Perform application migration
Migration quality assurance
Perform aystem tests
Perform integration tests
Perform stress tests
Perform user acceptance tests
Perform production data refresh
Parallel migration task list example
Define test/acceptance criteria—regression test suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Set up target production environment
Set up Replication Server
Run regression test suites
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end Phase 1 and 2 regression test suite
Upgrade server B (shadow)
Run post-upgrade regression test suites on Adaptive Server 15.0 (server B)
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end phase 1 and 2 regression test suite
Other testing
Run user acceptance tests on Adaptive Server 15.0 (server B)
Shift production users to Adaptive Server 15.0 (server B)
Perform final steps
Cutover migration task list example
Set up Adaptive Server 15.0 on development system
Define test/acceptance criteria—regression test suites
Front-end simulation regression test suite
Front-end regression test suite
Define fallback procedures on test system
“Baseline” older environment on test system
Run regression test suites on older release test system
Front-end simulation regression test suite
Front-end regression test suite
Upgrade test system to version 15.0
Run regression test suites on version 15.0 Test System
Back-end regression test suite—production loads
Front-end simulation regression test suite
Front-end regression test suite
Other testing
Run user/acceptance tests on version 15.0 test system
Execute fallback procedures on test system
Upgrade production server to Adaptive Server version 15.0
Perform final steps
Staged cutover task overview
Tasks
Migration Issue Checklists
Logical data architecture
Logical Application Architecture
Logical technology architecture
Logical support architecture
Migration strategy design
Pre-Upgrade Checklist
Pre-upgrade checklist
Monitor Client Library Programmer’s Guide
About this book
Getting Started with Monitor Client Library
Overview
What is Adaptive Server Enterprise Monitor?
Adaptive Server Enterprise Monitor components
Adaptive Server Enterprise Monitor architecture
Writing a basic Monitor Client Library program
Application logic flow
Step 1: Defining error handling
Step 2: Connecting to a server