|
chukxy
|
I developed an inventory application using microsoft access as my data base(Java based). My problem now is to transfer this application to different users using different systems. Do I need to creat data base in any system i want to transfer the application for its subsequent use or is there any better way to do it? Suggestions are welcomed.
Thank you.
|
|
|
|
|
|
javalove (m)
|
do u mean u want the inventory to run on a network.? if so, all u have to do is to create a DSN (Data Source name) to allow other systems connect to the database. the system where the database file acts as the server,
|
|
|
|
|
|
malone5923 (m)
|
do u mean u want the inventory to run on a network.? if so, all u have to do is to create a DSN (Data Source name) to allow other systems connect to the database. the system where the database file acts as the server, javalove is right just create a dsn from the odbc data source administrator remember to chose microsoft driver because that what your using.
|
|
|
|
|
|
chukxy
|
It is meant to be a desktop application.
|
|
|
|
|
|
kanirip (m)
|
I think that what you need is to package the application with the Database in a jar file and then deploy the application.
If you need any speciific help or have any more questions, post in this topic.
Rip
|
|
|
|
|
|
Ghenghis (m)
|
you could package the db in an archive and distribute , your app simply checks the users home dir for the db, if its not there extract the archive one to the user dir ,
so even users on the same machine would have different DBs
|
|
|
|
|
|
javalove (m)
|
you could package the db in an archive and distribute , your app simply checks the users home dir for the db, if its not there extract the archive one to the user dir ,
so even users on the same machine would have different DBs
that is if its not a network app
|
|
|
|
|
|
Ghenghis (m)
|
It is meant to be a desktop application.
Yeah, if its desktop
|
|
|
|
|
|
chukxy
|
My good people, I'm so much pleased with your suggestions. The problem i have now is to package the application in a jar file. Please direct me on how to package the application.
Thank you.
|
|
|
|
|
|
ade2kay (m)
|
The problem i have now is to package the application in a jar file. Please direct me on how to package the application.
Thank you.
Use the jar tool.
|
|
|
|
|
|
javalove (m)
|
My good people, I'm so much pleased with your suggestions. The problem i have now is to package the application in a jar file. Please direct me on how to package the application.
Thank you.
In making a jar file, first create a manifest file like this - Open an empty notepad -Type this Manifest-Version: 1.0 Main-Class: <Your Class Name Here>-When you are done, press enter once to go to the next line. -Save the file as whatever.mft. -The second step, open command prompt. -Navigate to your project folder -Make sure the path is set to point to the jdk/bin folder -Then do this: jar cfm yourmanifestfile.mft yourjarfilename.jar *.class <and all other stuffs u want to add separated by space>-Press enter when done. -Check your project folder, an angel must have placed a jar file there for you  you can also add other stuffs but u must separate them with a space. For example if you have an images folder and in ur code, ur images were gotten like: ImageIcon ic= new ImageIcon(getClass().getResource("images/javaadict.jpg"));
then u have to add your images folder to the argument when making the jar. Just say images.* Did i make sense?
|
|
|
|
|
|
A-40 (m)
|
@javalove You are good!!
All you need is a JDBC driver and a Datasource since its java based
|
|
|
|
|
|
logica
|
The fact that it's a desktop app doesn't mean it cannot connect to a DB on the network. Best design is to have all the desktop appĀ instances connect to a central DB server. And yes, you can distribute the app as a jar or use a java app installer of which there are several - some even allow you to create MSI & EXE files.
Read up on Java Web Start for details.
|
|
|
|
|
|
Kobojunkie
|
@Poster, are all those to connect to this database in the same organization?? I suspect what you are trying to do here is have every instance of your application connect to the same Database so changes made are propagated to the central DB, are my wrong?? If that be the case then you do not need to package the DB but instead have every user connect their instance of the app to the database on the network.
If you could provide additional info, would help in troubleshooting this.
|
|
|
|
|
|
|
|