File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java Micro Edition and the fly likes database client/server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "database client/server" Watch "database client/server" New topic

database client/server

Henk Rog
Ranch Hand

Joined: Dec 04, 2003
Posts: 36
If I have a database running on a server, how can I let a client
store information in the database?
Do I need a socketconnection for this?
Lasse Koskela

Joined: Jan 23, 2002
Posts: 11962
You can also use a proxy servlet, which translates your HTTP requests into JDBC calls. The best service you can do to yourself regarding this subject is to buy Michael's latest book.

Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Mark Spritzler

Joined: Feb 05, 2001
Posts: 17276

You can also check out PointBase. They have a small Cell Phone version of their database so that you can use SQL etc in your J2ME app. Also with their connectivity software, you can have the app connect and use a Server Database like Oracle, etc. It can also sync your Cell Phone tables to the backend Oracle database. It works with other RDBMS besides Oracle.
The other way to access data from a Database is through Servlets that connect to the database and return data.

Perfect World Programming, LLC - iOS Apps
How to Ask Questions the Smart Way FAQ
serge masse
Ranch Hand

Joined: Jul 23, 2003
Posts: 102
Currently, there are 3 main models for designing a client/server architecture with mobile clients:
1) The classic Web-like client/server design where wap or html is used in a client browser, and jsp/servlets are used on the server side to interface with an dbms using HTTP. Only the client triggers data analysis and transmission.
2) The real-time data design where the server sends data to the client without requiring that the client requests it first, commonly using TCP/IP. Both the client and the server can trigger data analysis and transmission.
3) The intermittent synchronization of batch data between a mobile and a remote component. This is mostly a batch type of data exchange where the user or the application triggers data transmission by batches, in relatively infrequent time intervals compared to the the other two models.
Model 2 is required when the business requires that the data be pushed to the client in a semi-real-time fashion, e.g., as soon as it is available.
MIDP 1 supports Model 1 and 3, and MIDP 2 supports all 3 models. MIDP 2 supports Model 2 by using full TCP sockets between client and server, and not just HTTP connections.
[ January 14, 2004: Message edited by: serge masse ]

serge - - my android apps
I agree. Here's the link:
subject: database client/server
It's not a secret anymore!