Results 1 to 8 of 8

Thread: Application blocks.. benefits?

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    May 2002
    Posts
    1,602

    Application blocks.. benefits?

    I assume most people are familiar with the Microsoft Application blocks for database, exception handling and authorization... my question is:

    How did you incorporate these blocks into your companys applications? Was it a success or faliure in doing so? How many hours did you allocate in learning how to use them?

    Is it worth the time it takes to use them, rather than write your own exception, dbgateway and authorization class?? The application blocks are very extensive... and tha tisn't always what you need


    kind regards
    Henrik

  2. #2
    Fanatic Member
    Join Date
    Oct 2000
    Location
    Reading, UK
    Posts
    870
    www.vb-tech.com
    .Net Freelance Development
    http://weblog.vb-tech.com/nick
    My blog

  3. #3
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    I love the data access one. All our development from here on out will use the data access one. It is actually part of our code review process now. I can't think of much of a reason to not use it. If you have your own code already written, I would bet it doesn't even compare to the application block (at least 99% of the 'home' grown ones don't).

    I takes only about 3 hours of playing with it to fully understand it. I don't see time as an issue.


    Now, when we start talking about other blocks, well, that is up to you. I haven't used them all either, so I can't speak very well on them. I do know that the exception management block is pretty powerful and requires a little time investment to fully use it.

  4. #4
    Frenzied Member Magiaus's Avatar
    Join Date
    Mar 2002
    Location
    swamp land
    Posts
    1,267

    OK

    Bieng one of the few the proud the ignorant. Somebody clue me in.
    Magiaus

    If I helped give me some points.

  5. #5
    Frenzied Member Magiaus's Avatar
    Join Date
    Mar 2002
    Location
    swamp land
    Posts
    1,267

    I see said the blind man.

    I already made my own though and it is performing well it returns a DataObject that implicit moves Data between data objects (Readers, Arrays, DataSets, and I am considering doing some collections). It isn't slow because you exectue a storded procedure or SQL statement and the DataObject is setup as a type you passed in. Seems to be DataSet allot... Anyway. If you get data as a Reader(OLeDB or SQL) and you keep converting it between dataset and reader it doesn't hit the database again but it does have to manipulate data into what ever your casting it as.

    If that makes any since.... It's Like A Variant that can only be DataObjects but there is proccessing required for it to move from the intial object it repesents to the one you want it to actlike.... Anyway I like it just don't use one DataObject as an Array, a Reader and a DataSet all at the sametime because I know that would be slow.
    Magiaus

    If I helped give me some points.

  6. #6
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    That is what a lot of people have done...rolled their own. MS just took the best practices out there, and put them together in the Data Access Application Block.

    If your way works, then keep using it.

    I personally like a standard approach such as this. We can have every developer using this, and no having to go in and work out little bugs. For me, this block has been extremely error proof. Sure, there probably is one or two in there, but I think it is rock solid. It isn't hard to use either:

    dim ds as DataSet = SqlHelper.ExecuteDataset(strConn, StoredProcedure, "storedProcName")

    Or if I want a DataReader:
    dim ds as SqlDataReader= SqlHelper.ExecuteReader(strConn, StoredProcedure, "storedProcName")

    Not bad, and it is overloaded with almost anything you want to add. Supports transactions, parameter arrays, has the parameter cache object, etc....

  7. #7

    Thread Starter
    Frenzied Member
    Join Date
    May 2002
    Posts
    1,602
    Thank you for the replies... my main concern is that the people in my company that wear suits every day and earn ten times my money has decided to use oracle db even though we use MS for everything else, development, messaging, businses logic etc...

    And what I can figure out from reading through the data app block is that it can only identify stored procedure parameters on sql server? I saw that as a main advantage. Well it's no big deal to pass the parameters as some kind of name-value collection... but it was a nice feature. I will however start to play with the data app block.. and give it some workouts


    thank you for the replies...

    yours
    Henrik

  8. #8
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    Yes, the data application block is only for SQL Server. That is the downside.

    But, since all the source code is included, you could probably roll your own fairly quickly for Oracle.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width