This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
Hi, Something pretty basic but real important- Can I expect that the user will type in the full database path name for both server and client? Ofcourse, in remotemode server needs it and in local mode client needs it. I don't have to include db.db in the client/server jar files, do I? Thanks much, Aruna.
You don't have to put the db.db file in the client.jar or server.jar. A place commonly used is the folder where the client.jar and server.jar are. Then you can ommit the full path when using a command line like: java -jar client.jar db.db bern
Can I expect that the user will type in the full database path name for both server and client?
When database is accessed locally, the user is expected to specify the database location (full path, including the database name). When database is accessed remotely, the user specifies the server name, port, and database name, but not the path. The server itself should know where the database files are. Eugene.
Joined: May 14, 2002
Eugene, Yes. But when the server is started, on the command line the path to db.db should be specified by the admin. I realize that the remote client does not have to provide it, correct?
Joined: Oct 08, 2001
But when the server is started, on the command line the path to db.db should be specified by the admin.
The best thing to do is to avoid setting the path on the command line. Instead, you could require in your instructions that db.db file should be located in the same directory as your server.jar file. Eugene.