Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

CHAPTER 16: Connecting via Code > Connecting with Excel or Excel Visual Basic f...

Connecting with Excel or Excel Visual Basic for Applications (VBA)

The simplest and quickest tool in this chapter to access your data is Excel. By completing a handful of clicks, you can connect to your database, choose a specific table, or execute a stored procedure, and the data will be returned and placed within an Excel workbook and data displayed ready to send out. This is why Excel is a quick and easy tool and used by so many users and developers for reporting purposes.

You can connect to SQL Server using several methods, but the two that this chapter will concentrate on are through the Data ribbon and Visual Basic for Applications, commonly known as VBA. Using the Data ribbon, there are also a number of different methods to connect to SQL Server from different options on the ribbon. These will be demonstrated within the example shortly, but these first few statements show the flexibility of Excel and the security dangers that can exist.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint