• Skip to main content
  • Skip to header right navigation
  • Skip to site footer
CDP Studio logo

CDP Studio

The no-code and full-code software development tool for distributed control systems and HMI

  • Doc
  • Why CDP
    • Software developers
    • Automation engineers
    • Managers
  • Products
    • Automation Designer
    • HMI Designer
    • CDP Linux
  • Services
  • Use cases
  • Pricing
  • Try CDP

CDP Studio Documentation

  • PostgresDB C++ Classes
  • IPostgresDBConnection
  • 5.1.1

IPostgresDBConnection Class

(PostgresDB::IPostgresDBConnection)

Implements PostgresDB support for CDP2SQL. More...

Header: #include <IPostgresDBConnection>
Inherits: CDP2SQL::IDatabaseConnection
  • List of all members, including inherited members

Public Functions

virtual bool IsNativeParameterBindingEnabled() const = 0
virtual void SetNativeParameterBindingEnabled(bool useNative) = 0
  • 14 public functions inherited from CDP2SQL::IDatabaseConnection

Detailed Description

Implements PostgresDB support for CDP2SQL.

Member Function Documentation

[pure virtual] bool IPostgresDBConnection::IsNativeParameterBindingEnabled() const

Returns whether native PostgreSQL parameter placeholders are expected.

If this returns true, SQL passed to statements is expected to use PostgreSQL native placeholders ($1, $2, ...).

If this returns false (default), the library accepts ? placeholders and converts them to $1, $2, ... when a statement is compiled. In this mode one has to use ?? to escape a literal question mark in the SQL (for example, when using the ? operator in JSONB queries).

[pure virtual] void IPostgresDBConnection::SetNativeParameterBindingEnabled(bool useNative)

Sets whether SQL statements should use native PostgreSQL parameter placeholders.

When enabled, SQL passed to statements must use $1, $2, ... placeholders.

When disabled, SQL may use ? placeholders and the library will convert them on compile. In this mode one has to use ?? to escape a literal question mark in the SQL (for example, when using the ? operator in JSONB queries).

Note: This setting must be changed before creating a prepared statement object on the connection.

The content of this document is confidential information not to be published without the consent of CDP Technologies AS.

CDP Technologies AS, www.cdpstudio.com

Get started with CDP Studio today

Let us help you take your great ideas and turn them into the products your customer will love.

Try CDP Studio for free
Why CDP Studio?

CDP Technologies AS
Hundsværgata 8,
P.O. Box 144
6001 Ålesund, Norway

Tel: +47 990 80 900
E-mail: info@cdptech.com

Company

About CDP

Contact us

Services

Partners

Blog

Developers

Get started

User manuals

Support

Document download

Release notes

My account

Follow CDP

  • LinkedIn
  • YouTube
  • GitHub

© Copyright 2026 CDP Technologies. Privacy and cookie policy.

Return to top