• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NX: A confusion about specifying the location of the database file

 
Bigwood Liu
Ranch Hand
Posts: 240
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
My assignment said,
The program must allow the user to specify the location of database.
1.Does it mean that I can use "server"/nothing to indicate the databse is from network, or "alone" to indicate the database is in local machine, in this case the location is predefined? or
2.I have to choose a database through GUI either in network mode or in non network mode, thus in network mode there should be a GUI at the server side to choose the database file, while the client only need connect to it; in non network mode the user GUI can be used to choose the database file.
In addition, in network mode need I specify which host I will connect, need I specify the address of the host?
Thank you,
Regards,
Damu
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Pie
Posts: 11945
212
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Damu,
I think the consensus on this forum is that the client:
  • in standalone mode has to be able to choose a database file
  • in networked mode has to be able to specify the server


  • As well, the server has to be able to choose the database file.
    Regards, Andrew
     
    Bigwood Liu
    Ranch Hand
    Posts: 240
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Thank you Andrew!
     
    Bob Nedwor
    hangman
    Ranch Hand
    Posts: 215
    Eclipse IDE Oracle Ubuntu
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Andrew:
    So if this is still true, even for the B&S project, I pretty much need to prompt the user for the path and filename of the database file using a JFileChooser or something, when running in ALL modes. Is that correct?

    Thanks for your advice.
    --Bob
     
    Daniel Dalton
    Ranch Hand
    Posts: 146
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Hi Bob -

    No, a client connecting to your server probably has no need to know where the data file is located - it needs to know where the server is, but that's not the same as where the file is.
     
    Bob Nedwor
    hangman
    Ranch Hand
    Posts: 215
    Eclipse IDE Oracle Ubuntu
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    Thanks, Daniel! Yes, that makes sense. I will go with filechoosers on the other two modes, then.
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic