Solved

Network Programming Concept

Posted on 2003-12-01
7
260 Views
Last Modified: 2010-04-17
I am to design a program with master-child relationship. The batch (master) part consist of info on the batch and transactions (child) part consist of info on the transactions.
The database is located in a server and this program is meant for a network environment.

My problem is when a user create a new batch, do I create a temporary local database in the user PC during this session or do I use the database in the server for the session. Or do I transfer the whole database into the local hard disk.  Can someone advise me on which concept to use. I am new to this type of programming. Thank-you
0
Comment
Question by:tsluu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
7 Comments
 

Expert Comment

by:amitm
ID: 9856258
This type of programming is called Client-Server programming.
Client can access (transactions) the database remotely. There is no need to copy the entire database or a part of it on client side. This will work without any problems until you consider time constraints in some cases. If you want to access (only read) some portion of database frequently, then you can cache that part in local machine, but this will be complicated if you are changing that part of database from other client at the same time. In the beginning, you can leave that optimization.
0
 
LVL 9

Accepted Solution

by:
bhagyesht earned 100 total points
ID: 9856617
hmmm that depends on the number of client users and the database you are using. I assume you are using VB and if you are using components then I can suggest you use DCOM to achieve this so that the clients call the server's components and do the database interaction. DCOM in VB is very easy if you have knowledge of COM in vb instead of using
createobject("prj.class")
 u use
createobject("prj.class", "servername")

remember the components need to be present at both places.

now comming to non component programming.
you can fire queries directly to the database with transactions using ODBC if you are using access the you can use jet by sharing the file on the network too but better would be to upgrade to MSDE which prevents someone from deleting the file accidently (I faced this problem)

if u need more info feel free to write
0
 

Author Comment

by:tsluu
ID: 9863315
I am using VB and Access *.mdb as my database in the server. What I have done is:

* For new master record
a new record is added in the Master table,
new transactions are added in the Details table, referencing to the Master table,
if user decides to exit without saving then I delete all transactions with reference to the Master record

* For existing master record
user edits transaction the record directly

bhagyesht, I dont know whether this is a practical way to do it. Kindly advise. Thanks.
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9864048
if you are expecting under 20 simultenous clients its fine. but never the less I would suggest have a look at MSDE besides offering scalability it offers you an option to migrate to MSSQL server at a later date without any significant code change.
0
 
LVL 9

Expert Comment

by:bhagyesht
ID: 9864053
just ensure that all the clients are generating different primary key for the master table
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A short article about problems I had with the new location API and permissions in Marshmallow
This is about my first experience with programming Arduino.
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question