sqlDataSource... do I need it ?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • TimVtoo
    New Member
    • Jul 2008
    • 22

    sqlDataSource... do I need it ?

    Hi, and thanks in advance for your time.

    I recently made the move this year to asp.net (vb) from classic asp.
    To help get me started, I bought a book based on version 1.1 as I didn't know any better.

    When talking to databases I am generaly using Stored Procedures with sqlCommands and DataReaders or maybe the odd DataAdapter etc....

    My question is:
    Is what I'm doing an outdated approach. When and why should I be considering using the sqlDataSource thingymagig... or is what I'm doing Ok??

    Thanks

    Tim
  • BeemerBiker
    New Member
    • Jul 2008
    • 87

    #2
    I made extensive use of SqlDataSource in a dotnet 2 app that used postgresql on a linux server. We used the free ODBC driver but as a result there were no postgre sql components in the VS2005 component designer. We looked at NPGSQL (not free as I recall) which included pgresqlCommand, pgresqlConnecti on,etc, and other common sql components but did not need that functionality enough to buy the product.

    Every page had at least one SqlDataSource and the connections strings were all identical DSN=odbcdrivern ame. Every page could be displayed and tested "in the browser" without generating a connection error. I was originally looking for "sqlCommand " and thought it would be awkward coding without those but any SqlDataSource can have the SelectCommand set to access any table and you just do a databind to read the data and cast a DataView to access the rows and columns (or whatever) and I did not miss the sqlCommand.

    HTH

    Comment

    Working...