|
-
Mar 22nd, 2001, 02:38 AM
#1
Thread Starter
Junior Member
Hi
I'm trying to familiarise myself with N-Tier architecture.
I understand how business objects can be modelled on the tables in your db and that they can then be passed to the ui, in order to shield your ui from any data access that is required
However what do you do when you need to select data based on a sql query that only selects a few fields from a table.
Do you need to create a Business object for each query that you may generate or is there a better way?
many thanks
Mark Foster
Vb6 sp4
Sql server 7
win 2k
-
Mar 22nd, 2001, 04:34 AM
#2
There are an absolute myriad of ways to do what you are asking. Ideally, you would create a group of objects that matched the query, but that makes the overhead huge (creating a spearate object for each query when you may have 3000 queries obviously doesn't make sense. Alternatively, you could create an object heirarchy using the complete objects, but only access te actual data you need (which means you're getting a lot of excess data which places unnecessary load onthe server). The list goes on...
While I could spend days giving a full(ish) answer, I'll be quick. Have a look at two books from Wrox press - One by a guy called Lhotka - "VB6 Business Objects" I thin it is called, and another called "Enterprise Application Architecture" by a guy called Moniz. Both are good (the Lhotka one in particular)
- gaffa
-
Mar 27th, 2001, 03:39 PM
#3
New Member
Hey check out Wrox VB 6 Business Objects written by Rockford Lhotka. He has plenty of examples of the how tos related to your question.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|