ASA SQL User's Guide
Debugging Logic in the Database
Tutorial: Getting started with the debugger
Lesson 3: Debug a Java class
The debugger looks in a set of locations for source code files (with .java extension). You need to add the Samples\ASA\Java subdirectory of your installation directory to the list of locations, so that the code for the class currently being executed in the database is available to the debugger.
To display Java source code in the debugger
Start Sybase Central and connect to the sample database (ASA 9.0 Sample ODBC data source).
Choose the Sybase Central Debug task.
Choose Task
Set the locations in which to look for Java source code.
From the Debug menu, choose Set Java Source Path. The Java Source Path window appears.
Click Browse Folder. Navigate to the folder where your Java source code (.java files) is stored. To view the source code for the JDBCExamples class, browse to the Samples\ASA\Java subdirectory of your SQL Anywhere installation. If you installed SQL Anywhere in the default installation directory, you would navigate to the following directory:
C:\Program Files\Sybase\SQL Anywhere 9\Samples\ASA\Java
Display the source code for the JDBCExamples class:
In the Sybase Central left pane, open the Java Objects folder.
In the right pane, open the All Java Classes folder and locate the JAR file or class you wish to debug. Depending on your Sybase Central settings, you may wish to click the Creator column. This sorts the listing by creator so that classes owned by DBA appear before those owned by SYS.
Double-click the JDBCExamples class.
In the right pane, click the Source tab. The source code for the class is displayed.