Re: Multilayer applications
From: SP (egatsecneserp(reverse)_at_hotmail.com)
Date: 07/25/04
- Next message: SP: "Re: How to dynamically instantiate a class"
- Previous message: TC: "How to copy an MS Excel graphic from the system clipboard to an image control and obtain its source reference in .Net with either VB.Net or C#"
- In reply to: Just D: "Re: Multilayer applications"
- Next in thread: Just D: "Re: Multilayer applications"
- Reply: Just D: "Re: Multilayer applications"
- Messages sorted by: [ date ] [ thread ]
Date: Sat, 24 Jul 2004 22:30:21 -0400
"Just D" <no@spam.please> wrote in message
news:8iyMc.7643$BX.720@lakeread08...
>
> > business object is not constrained in needing to contain
> > the actual "display" data, e.g Your Employee object has a EmployeeName
and
>
> Not exactly, it depends what data do you need at this moment, but you
easily
> can add a column manually and add some calculated data to this column.
Exactly my point, you need to handle that particular situation "manually". I
prefer "automatic".
> > DepartmentName properties. But
> > internally the Employee object only knows the Department key and is
really
> > calling DepartmentsCollection[key].DepartmentName to provide the
> > "display" data. Getting the same behavior from a dataset is not so easy.
I
> > like the ability to make my business objects "self serving".
>
> Not so easy?! Why? What about sql queries (and maybe subqueries) providing
a
> comprehensive information? You can join on this DepartmentKey a few tables
> getting all required stuff into additional DataSet column and reflect this
> column in the DataGrid automatically just from one database call, it's
> easier than retrieve the whole information in two or more datasets, then
> make a foreach loop every one when you need to compare two or more tables.
> In a SQL solution everyting should be solved by SQL engine itself.
I tend to disagree with this. At a certain point the complexity of what you
are doing in the
SQL engine increases and crosses into the business rules.
In the example I gave you would have a grid with the EmployeeName and their
Department.
If I want to be able to change the department using a dropdown, how easy is
that to implement using your datasets.
Once you use a join to create a dataset you can not use the dataadapter to
persist the
changes made in that dataset directly back to the database. This was the one
thing that was most frustrating
about datasets.
> > But selecting an employee from a dropdown list of 1000 employees can be
> > handled with some javascript and a hidden field.
> Yes, but these is only one solution, You can use LIKE '%!@!#!@#%' in your
> queries to get only required records by mask, you can sort them by the
> alphabet and return only required group, there are many different methods.
> You also can use browse feature of SQL queries, etc.
I was refering to this as something that can be handled "quickly" by using
viewstate on the
dropdown which will slow down the page and the postback, or can be handled
with
a hidden field and javascript and will make a much faster loading webpage.
SP
- Next message: SP: "Re: How to dynamically instantiate a class"
- Previous message: TC: "How to copy an MS Excel graphic from the system clipboard to an image control and obtain its source reference in .Net with either VB.Net or C#"
- In reply to: Just D: "Re: Multilayer applications"
- Next in thread: Just D: "Re: Multilayer applications"
- Reply: Just D: "Re: Multilayer applications"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|