DATA ACCESS COMPONENT (OBJECT ORIENTED)

D

DRU

Hi People

I have a design issue

I have atleast 6 to 7 forms whose main functionality is to
add a new record , delete a record and update records

zipcodeform -- front end form variables( zipcode.text ,
zipstate.text)

citycodeform-- front end form variables(citycode.text ,
cityname.text,cityregion.text)

addressform -- front end form variables(address1.text ,
address2.text,telephone.text)
..
..
..
----
..
..
----
..
..


The above forms have the same functionality as in adding a
new record , updating old records or deleting some records

So wont it be easy to write a class with 3 methods

DBinsert()
DBupdate()
DBdelete()

and over load these functions to

get desired result instead of having a class like
zipcodeclass , citycodeclass and addressform class and
having
to repeat the same functionality

instead I am having a basedbclass and the overlaoding the
methods

Is it the rite way to do this


Suggestions , comments of any type accepted


Thanks
DRU
 
S

Steve C. Orr, MCSD

Sounds like a fairly standard approach if I understand you correctly.
You have a few business objects (zipcode, citycode and address) that in turn
use your data access class that encapsulates the database work.
Pretty typical 3 tier system. Nothing wrong with that.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top