O'Reilly logo

Beginning Visual Basic 2015 by Bryan Newsome

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

13 Database Programming with SQL Server and ADO.NET

WHAT YOU WILL LEARN IN THIS CHAPTER:

  • About ADO.NET objects
  • Binding data to controls
  • Searching for and sorting in-memory data using ADO.NET DataView objects
  • Selecting, inserting, updating, and deleting data in a database using ADO.NET

WROX.COM CODE DOWNLOADS FOR THIS CHAPTER

The wrox.com code downloads for this chapter are found at www.wrox.com/begvisualbasic2015 on the Download Code tab. The code is in the 092117 C13.zip download and individually named according to the names given throughout the chapter.

Chapter 12 introduced SQL. You obtained data from a single table and multiple tables in a SQL Server database. You learned how to use queries to manipulate data.

This chapter dives much deeper into the topic of database programming. In this chapter, you explore how you can use the built-in capabilities of ADO.NET to retrieve and update data from databases. You will also learn to manipulate, filter, and edit data held in memory by the DataSet.

The data you extract will be bound to controls on your form, so you also need to explore binding. You will see how you can use controls to view one record at a time (for example, using text boxes) and how to navigate between records by using the CurrencyManager object.

You will also learn how to access SQL Server databases using the SqlClient data provider. SqlClient is significantly faster than OleDb, but it works only with SQL Server databases. To complete the exercises in this chapter, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required