Mobile terminal Database Management and Designing a Table



Similar documents
Code Generation for Mobile Terminals Remote Accessing to the Database Based on Object Relational Mapping

Design of Data Archive in Virtual Test Architecture

UPS battery remote monitoring system in cloud computing

USB Recorder. User s Guide. Sold by: Toll Free: (877)

The full setup includes the server itself, the server control panel, Firebird Database Server, and three sample applications with source code.

Design and Implementation of Supermarket Management System Yongchang Rena, Mengyao Chenb

CSE 530A Database Management Systems. Introduction. Washington University Fall 2013

An ECG Monitoring and Alarming System Based On Android Smart Phone

CS2310 Final project report

USB Recorder User Guide

2Creating Reports: Basic Techniques. Chapter

DEVELOPING CONTRACT - DRIVEN WEB SERVICES USING JDEVELOPER. The purpose of this tutorial is to develop a java web service using a top-down approach.

Unit 10: Microsoft Access Queries

Research on Operation Management under the Environment of Cloud Computing Data Center

Research and realization of Resource Cloud Encapsulation in Cloud Manufacturing

Sample- for evaluation purposes only. Advanced Crystal Reports. TeachUcomp, Inc.

E-R Method Applied to Design the Teacher Information Management System s Database Model

Database Applications Microsoft Access

Company Setup 401k Tab

WHAT S NEW IN THOMSON REUTERS EIKON FOR JANUARY 2011 FIXED INCOME

Microsoft Access 2010 Overview of Basics

Visualization Method of Trajectory Data Based on GML, KML

The Digital Signage System Supporting Multi-Resources Schedule on an Elevator

Database 10g Edition: All possible 10g features, either bundled or available at additional cost.

System Administration and Log Management

12 File and Database Concepts 13 File and Database Concepts A many-to-many relationship means that one record in a particular record type can be relat

Access Queries (Office 2003)

No web design or programming expertise is needed to give your museum a world-class web presence.

Human Computer Interaction Final Project Tutorial. Hardware Inventory Management System (HIMS) By M. Michael Nourai

Click to create a query in Design View. and click the Query Design button in the Queries group to create a new table in Design View.

Technical Data Sheet: imc SEARCH 3.1. Topology

Results CRM 2012 User Manual

How to create and personalize a PDF portfolio

Bitrix Site Manager 4.1. User Guide

Microsoft Access 3: Understanding and Creating Queries

How to consume a Domino Web Services from Visual Studio under Security

OUTLOOK 2003: HOW TO GET OUT OF JAIL

A Ruby on Rails-Framework-Based E-commerce Information Management Platform Design of Enterprise

APPLICATIONS AND RESEARCH ON GIS FOR THE REAL ESTATE

Design of Electric Energy Acquisition System on Hadoop

How to test and debug an ASP.NET application

CS2Bh: Current Technologies. Introduction to XML and Relational Databases. The Relational Model. The relational model

Study on Architecture and Implementation of Port Logistics Information Service Platform Based on Cloud Computing 1

How To Use An Online Forum On The Pomposifical Germany University

Data Tool Platform SQL Development Tools

ImageNow Report Library Catalog

Microsoft Dynamics CRM 2013 Applications Introduction Training Material Version 2.0

Modern Accounting Information System Security (AISS) Research Based on IT Technology

Data Movement Modeling PowerDesigner 16.1

Aeries Student Information System Attendance Notes October 3, 2008

Advanced Excel Charts : Tables : Pivots : Macros

Reverse Engineering in Data Integration Software

Realization of the High-density SaaS Infrastructure with a Fine-grained Multitenant Framework

Construct User Guide

Designing Reports in Access

IENG2004 Industrial Database and Systems Design. Microsoft Access I. What is Microsoft Access? Architecture of Microsoft Access

User manual BS1000 LAN base station

SYSTEM DEVELOPMENT AND IMPLEMENTATION

<Insert Picture Here>

Lab 9 Access PreLab Copy the prelab folder, Lab09 PreLab9_Access_intro

Implementation of Information Integration Platform in Chinese Tobacco Industry Enterprise Based on SOA. Hong-lv Wang, Yong Cen

Manage. Help Documentation. This document was auto-created from web content and is subject to change at any time. Copyright (c) 2016 SmarterTools Inc.

Smart Card Authentication. Administrator's Guide

Stored Documents and the FileCabinet

Recording Supervisor Manual Presence Software

Business Portal for Microsoft Dynamics GP User s Guide Release 5.1

Mobile Surveillance. User Manual

BreezingForms Guide. 18 Forms: BreezingForms

IBM Unica emessage Version 8 Release 6 February 13, User's Guide

Client Portal User Guide

Microsoft Excel 2010 Part 3: Advanced Excel

Online Database Management System

Technical Support Set-up Procedure

Save Time and Eliminate Data Entry Errors

CPM release notes

The software shall provide the necessary tools to allow a user to create a Dashboard based on the queries created.

Design of Company s Salary Management System. Lei Xiong

Appendix IP CAMERA Network Connections

CSSEA Helpdesk User Guide

Toad for Data Analysts, Tips n Tricks

Tutorial 3. Maintaining and Querying a Database

Microsoft Office 2010

Trouble Ticket Express

When a variable is assigned as a Process Initialization variable its value is provided at the beginning of the process.

Implementation of an Efficient RBAC Technique of Cloud Computing in.net Environment

Importing Xerox LAN Fax Phonebook Data from Microsoft Outlook

SQL Server for developers. murach's TRAINING & REFERENCE. Bryan Syverson. Mike Murach & Associates, Inc. Joel Murach

Improving SQL Server Performance

Operation and Maintenance Management Strategy of Cloud Computing Data Center

USING MYWEBSQL FIGURE 1: FIRST AUTHENTICATION LAYER (ENTER YOUR REGULAR SIMMONS USERNAME AND PASSWORD)

MS Access Lab 2. Topic: Tables

Chapter 9 Creating Reports in Excel

Journal of Chemical and Pharmaceutical Research, 2015, 7(3): Research Article

2: Entering Data. Open SPSS and follow along as your read this description.

Introduction to Microsoft Access 2003

DocumentsCorePack for MS CRM 2011 Implementation Guide

Bitrix Site Manager 4.0. Quick Start Guide to Newsletters and Subscriptions

TestManager Administration Guide

Managing Software Feature Licenses

CB Linked Server for Enterprise Applications

Transcription:

Code Generation for Mobile Terminals Accessing to the Remote Database Based on Object Association Wen Hu, Yanli Zhao School of Computer and Information Engineering, Harbin University of Commerce, 150028 zhylclover@126.com Abstract. Now the mobile terminal accessing the remote database is important research area. This paper presents a new access method for generating the code in order to solve the programming problems of the application design and the poor portability in Mobile terminals accessing to the remote database. The paper proposes a new management mechanism to database connection and access. It adopts the object association methods and defines the object association rules. The method achieves mobile terminals and database transmission of information and the management. It achieves visualization of the database interface. Keywords: Mobile terminals, Database, Object Association Relationship. 1 Introduction With the development of mobile networks, mobile terminal accessing the remote database has paid more and more attention [1]. Generally, mobile terminals connect to database and obtain the required data through the server transfer. Therefore, developers need to develop remote database server-side programs. This method is relatively flexible, but increases the cost of development and maintenance [2] [3]. It has become an important topic how to develop high reliability application quickly and efficiently in the mobile Internet era. Software visualization is an important way to solve the problem. Software visualization could play an important role in software engineering in the future [4]. When the mobile terminals access remote database, they not only need to provide critical information for remote database access, but also consider the style of returned results. This paper proposes a new method for accessing remote database by mobile terminals. Through the method of OAR (Object Association Relationship) [5], it has been built visual development methods which access remote database. 2 Problem analysis and related research ITCS 2013, ASTL Vol. 25, pp. 364-369, 2013 SERSC 2013 364

Proceedings, The 2nd International Conference on Information Technology and Computer Science The visual database tools and methods which mobile terminals access remote database need a specific rule definition. According to the designing rule, it is conducive to use its features. This article presents a visual software development method based on OAR. The functionality of the program is defined as objects. Through feature combination of objects and the corresponding relationships of objects, you can automatically form part of the program, combine with the mobile terminals program and finish design of programming. Resource requirements determine database association relationship between the terminal database schema and remote database schema, through OAR method, the terminal structure of the database schema can be determined. When you create a table in the terminal database, you can either create all remote database table fields or a subset of the remote database table fields. By Object Association way, it will be based on the real database server converts the request to query the database based on resource discovery requests, and provide a consistent interface to access the database using this method[6]. A property equivalent mode combined with XML Schema technology achieves function. Figure 1 shows querying and updating schematic. Mobile Client Mobile Client Mobile Terminal Database Terminal UI Widgets Service Database Table Table Register widgetid1,widgetid2,widgetid3,widget4,widget5,widget6 DBTable1 Register DBTable2 Table DBTable Request response XML File DataBase DataBase DataBase Fig. 1. Fields relationship, querying and updating schematic 3 Defining OAR rules for accessing to remote database OAR (Object Association Relationship) is an important aspect in object modeling. By OAR, the method studies the mobile terminals accessing to the remote database. When mobile terminals access to the remote database, mobile terminals data corresponds to remote databases data and interface widget data corresponds to the remote database data. Its OAR can be defined as: relationships relational set (Relationships) is a subset of set relationship rules (RelationshipRule). A relationship rule includes a subset of table relationships (TableRelation), a subset of field relationship (ColumnRelationship) and a subset of terminal widget ID and field relations (IdColumnRelation). All elements of the field relationship subset must belong to the same remote database table (DBTable). Their relationship can be expressed as follows: Rule1: In OAR rules, RelationshipRules set is composed of three relational object elements. They are defined as follows: 365

Code Generation for Mobile Terminals Accessing to the Remote Database Based on Object Association Relationships = {mr mr RelationshipRules}; RelationshipRules={<TRs,CM,ICRs> TRs TableRelations,CMs ColumnRelationshi ps,icrs IdColumnRelations, cm1,cm2,icr3,icr4,cm1 CMs,cm2 CMs,icr3 ICRs,icr4 ICRs cm1.dbcolumn.dbtable=cm2.dbcolumn.dbtable,icr3.id=cm1. DBColumn, icr4.id=cm2.column}; TCRelations= {field field table}; Rule2: Table OAR and fields OAR are defined as follows: TableRelations={<(table1,table2),relation> table1 Tables, table2 DBTables, Tables DBTables,relation Relations} ColumnRelationships={<column,DBColumn> column Columns,DBColumn DBColumns, Columns DBColumns } ; Rule3: In field and widget OAR, set id is ID in terminal widget, and column is field in mobile terminals, and dbcolumn is field in remote database. They are defined as follows: IdColumnRelations={<(id,column,dbcolumn),realtion> id Ids, column Columns,dbcolumn DBColumns} ; Relations= { =, <, >, <>, >=, <= }. Among them, Columns is the set of fields in the local database; DBColumns is a set of fields in the remote database; Tables is a set of tables for the mobile terminals; Ids is a set of id for mobile terminal widgets. And id value of terminal widgets and some of the necessary widget variables of the mobile terminal interface programming must be the same name and it is conducive to the terminal interface and database information interoperability. Relations is a set of Logical relationship. 4 Code generation based on OAR (1) Generate creating table s code in mobile terminals Assuming that remote database has login and student tables. Then DBTable= {login, student}; DBColumn contains DBColumnLogin and DBColumnStudent; DBColumnStudent={id, name, gender, age, date, grade, class, email }. And insert the data to the remote database STUDENT table. According to rule 2 in section 3, you can create mobile terminal database tables and fields through visualization tools. So you can create one or two tables. Now you can establish table named student. Then, Tables= {student}, ColumnStudent= {name, gender, age, grade, class} and they satisfy OAR rules, such as Tables DBTable and ColumnStudent DBColumnStudent. Step1: According to rule 2, judging set Tables = {STUDENT} is not empty. And by comparison Relations, they satisfy Rule 2, Tables DBTables, so you can create tables SRUDENT. When the Tables is empty, creating table finishes and code of creating table is generated. Step2: According to rule 2, you can create name field of STUDENT. Judgment ColumnStudent is not empty, so Columns= {name} and DBColumnStudent satisfy Columns DBColumns. Then you can create name field. According to the Step2, you can establish other fields. When the STUDENT is empty, creating table field ends, return to step1. 366

Proceedings, The 2nd International Conference on Information Technology and Computer Science Finally, you can generate creating mobile terminal database table STUDENT code. As follows: public static final String STUDENT = "STUDENT"; public static final String NAME = "NAME"; public static final String GENDER = "GENDER"; public static final String AGE = "AGE"; public static final String GRADE = "GRADE"; public static final String CLASS = "CLASS"; String tablestudent= "CREATE TABLE " + STUDENT + "(" + NAME + " TEXT PRIMARY KEY," + GENDER + " Integer,"+ AGE + " Integer,"+ GRADE + " Integer, " + CLASS + "Integer " + ");" (2) Generate querying data s code in mobile terminals Mobile terminals operating remote database includes querying and updating remote database. Updating includes inserting, modifying and deleting data. Now describe querying process. It assumes that you have id s set Ids in mobile terminal: Ids= {querybutton, name, gender, age, grade, class}. Click on the button with the ID value querybutton in mobile terminals and query STUDENT table in remote database. You can query name, gender, age, grade and class. There are querying conditions, including grade and name value that are obtained from EditText of ID grade and ID name in terminal interface. According to the class, results are sorted in ascending order. Processing is shown as follows. Step1: Gets the ID of the query button. By iterating Ids set, you can find the ID value for the querybutton button. Step2: By iterating DBTables set, judging if STUDENT exists. If it does not exist, the querying fails; Step3: In remote database you need iterate DBColumnStudent of SRUDENT s fields set and get querying fields: name, gender, age, grade and class. If it does not exist, return to Step2, and select another table again, until all tables are not satisfied. If not, go to step4. Step4: Get conditions. According to Rule 1 and 3, the terminal widget ID and field relations are the same and unique. And condition values are passed by the Android Terminal. According to Android application programming requirements, grade value is obtained by using grade.gettext () in mobile terminals and name value is from name.gettext (). If name or grade does not exist in the set of Ids, the querying fails, it needs to reset the terminal programming code. Step5: Select the order in which querying results are displayed. Iterate DBColumnStudent set and select the class field. If it does not exist, return to Step2. Finally, operation finishes, it generates the query code. As follows: "select "+"name,gender,age,grade,class"+" from "+"student"+" where "+"grade="+ grade.gettext()+" and "+"name=" +"\'" +name.gettext()+"\'" +" order by "+"class" Through the above steps, the mobile terminal will return data in XML format to the client interface. Figure 2 shows a part of the query results. Through mobile terminal interface design handles querying results, and you can get the data you need and complete the design. 367

Code Generation for Mobile Terminals Accessing to the Remote Database Based on Object Association Figure 2 Query results in XML format 5 Conclusion This paper presents a visual coding method for the mobile terminals accessing remote database. Through OAR, we can visually design mobile terminal database structure. We can achieve access and update to remote databases with code as little as possible. By OAR, this paper designs and implements code generation tool for mobile terminal remote accessing the database. The method increases development efficiency and reduces the learning curve. It is conducive to realize mobile terminal remote accessing the database operations. References 1. ZHANG Jinzeng, MENG Xiaofeng. : Research on Mobile Web Search. Journal of Software. 23, 47--64(2012) 2. Paul POCATILU.: Developing Mobile Learning Applications for Android using Web Services. Informatica Economică. 14(3), 106--115(2010) 3. Sunguk Lee.: Creating and Using Databases for Android Applications. International Journal of Database Theory and Application. 5(2), 99--105(2012). 4. WU Quanyuan.: Network Computing Middleware. Journal of Software. 24(1), 67--76 (2013) 5. Lan Shumei, Zhong Zhicheng,Wang Shuming, Li Shaoyan.: Object Map in Technique of Object-Oriented. Microelectronics & Computer. 22(2), 172--182(2005). 6. CHEN XiaoWu, PAN ZhangSheng, ZHAO QinPing.: A Schema-Reusable Method on Heterogenous Databases Access and Integration in Grid Environment. Journal of Software. 17(11), 2224--2233(2006). 368

Proceedings, The 2nd International Conference on Information Technology and Computer Science Authors Wen Hu:Prof. WenHu, master instructor, president of School of the Computer and Information Engineering, Harbin University of Commerce, backup leader of Electronic Commerce provincial key discipline echelon and academic leader of secondary doctoral discipline electronic commerce and information service in first-class doctoral discipline business administration. His main research fields include computer network and communication, electronic commerce, embedded technology. Yan li Zhao:Master, student of School of the Computer and Information Engineering, Harbin University of Commerce. Her main research fields include embedded technology. 369