JavaFX Database Application Guidance

I am thinking of using JavaFX for a desktop app that will let users to upload files. I was thinking what is the correct approach for this ? Should I use a mysql database to store the references to the files or just dump the files in a folder?

Coming from a web background this is a bit confusing. Also I could contain a JRE in the deployed app so it can run on any machine right (even though that machine does not have a jre)?


-------------Problems Reply------------

If you want everything to be self-contained, you could try an embedded database like ObjectDB. Here's a link to their 4-step tutorial.

What you can do is read in the file as a bytestream, store it in an entity with any other file parameters you'd like (the tutorial explains this), and store that entitiy in the database. ObjectDB will create a small database file for you that can be stored with your app.

Category:java Views:7 Time:2019-03-12
Tags: mysql java javafx

Related post

Copyright (C), All Rights Reserved.

processed in 0.189 (s). 11 q(s)