In this step, define the SSCA Master application. The master application displays a list of departments within an organization. The application has two columns for department name, and department manager data.
Defining the SSCA Master application
Log in to Mobile Web Studio.
Select Applications from the Build menu in the left pane, select New under Application Manager, and click the New button to launch Application Builder.
Click the down-arrow to the right of Add, and select Database Element.
In the Database Elements Definition window, enter Java Database Connection (JDBC) information. The JDBC connection allows the master application to access a database and extract specific database information.
The values in this example assume that the database included with Mobile Web Studio—sampledb—has been started and that it is accessible on port 4747.
Select the JDBC URL option.
Complete these options:
Username – enter dba
,
which is the database user name.
Password – enter SQL
,
which is the password used to access the database.
JDBC Connect URL – enter the URL used by JDBC to connect to the database:
jdbc:sybase:Tds:localhost:4747?ServiceName= sampledb
JDBC driver – enter the JDBC driver used to connect to the database, in this case:
com.sybase.jdbc2.jdbc.SybDriver
SQL Query String – enter the following SQL code to select department heads for each department from sambledb:
select d.dept_name as 'Dept Name', e.emp_fname + ' ' + e.emp_lname as 'Dept Head' from department d, employee e where d.dept_head_id = e.emp_id
UI XSLT – leave this field empty.
Click Preview. A two column table showing Dept Name and Dept Head displays in the Preview panel.
Dept Name |
Dept Head |
---|---|
R & D |
David Scott |
Sales |
Judy Snow |
Finance |
Mary Anne Shea |
Marketing |
Scott Evans |
Shipping |
Jose Martinez |
Click Next. The Split window displays.
Click Next to bypass these options.
Use the Define window to identify record 1 as the header row. In the Define Record Layout section:
Click “Records contain labels.” The “Labels are displayed in Record” option displays.
Accept the default 1
,
and click Next. The Filter window displays.
On the Filter window, click Next. The parameter definition window displays.
On the parameter definition window, click Next. The Window Preview displays.
In Element Name, enter SSCA Master
.
Under Window Preview, notice the grid showing Dept Name and Dept
Head.
Click Next.
On the Continuous Capture Page, click Finish.
On the Application Builder window, click Save to create the application.
In the Finish window, change this entry (accept all other defaults).
Name – enter SSCA
Master
.
Click Finish to save the application.
Click OK to confirm.
Click Close to exit the Application Builder.
In Mobile Web Studio, approve the application:
Right-click the SSCA Master application in the detail pane, and select Approval Status | Approved.
Click OK to confirm.
Select Approved from the Application Manager Status menu. You see your newly approved SSCA Master application in the detail pane.
Copyright © 2005. Sybase Inc. All rights reserved. |
![]() |