O'Reilly logo

PostgreSQL by Susan Douglas, Korry Douglas

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

Chapter 10. The PostgreSQL C++ API—libpq++

You can build PostgreSQL client applications using a variety of programming languages. In Chapter 8, “The PostgreSQL C API—libpq (Client Applications),” and Chapter 9, “A Simpler C API—libpgeasy,” you looked at two of the APIs that you can conveniently use from a C program (libpq and libpgeasy). This chapter introduces you to the libpq++ API. libpq++ is an API designed for use from within a C++ client application. To demonstrate the capabilities provided by libpq++, you'll build a number of client applications in this chapter:

  • client1—A simple example that shows how to connect a C++ application to a PostgreSQL database.

  • client2—Next I'll show you how to catch runtime errors that might occur when you ...

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