The following environment variables can be used to select default
   connection parameter values, which will be used by
   PQconnectdb, PQsetdbLogin and
   PQsetdb if no value is directly specified by the calling
   code.  These are useful to avoid hard-coding database connection
   information into simple client applications, for example.
   
      
      LTHOST behaves the same as the host connection parameter.
     
      
      LTHOSTADDR behaves the same as the hostaddr connection parameter.
      This can be set instead of or in addition to LTHOST
      to avoid DNS lookup overhead.
     
      
      LTPORT behaves the same as the port connection parameter.
     
      
      LTDATABASE behaves the same as the dbname connection parameter.
      
      
      LTUSER behaves the same as the user connection parameter.
     
      
      LTPASSWORD behaves the same as the password connection parameter.
      Use of this environment variable
      is not recommended for security reasons, as some operating systems
      allow non-root users to see process environment variables via
      ps; instead consider using a password file
      (see Section 32.15).
     
      
      LTPASSFILE behaves the same as the passfile connection parameter.
     
      
      LTCHANNELBINDING behaves the same as the channel_binding connection parameter.
     
      
      LTSERVICE behaves the same as the service connection parameter.
     
      
      LTSERVICEFILE specifies the name of the per-user
      connection service file
      (see Section 32.16).
      Defaults to ~/.pg_service.conf, or
      %APPDATA%\postgresql\.pg_service.conf on
      Microsoft Windows.
     
      
      LTOPTIONS behaves the same as the options connection parameter.
     
      
      LTAPPNAME behaves the same as the application_name connection parameter.
     
      
      LTSSLMODE behaves the same as the sslmode connection parameter.
     
      
      LTREQUIRESSL behaves the same as the requiressl connection parameter.
      This environment variable is deprecated in favor of the
      LTSSLMODE variable; setting both variables suppresses the
      effect of this one.
     
      
      LTSSLCOMPRESSION behaves the same as the sslcompression connection parameter.
     
      
      LTSSLCERT behaves the same as the sslcert connection parameter.
     
      
      LTSSLKEY behaves the same as the sslkey connection parameter.
     
      
      LTSSLROOTCERT  behaves the same as the sslrootcert connection parameter.
     
      
      LTSSLCRL  behaves the same as the sslcrl connection parameter.
     
      
      LTREQUIREPEER behaves the same as the requirepeer connection parameter.
     
      
      LTSSLMINPROTOCOLVERSION behaves the same as the ssl_min_protocol_version connection parameter.
     
      
      LTSSLMAXPROTOCOLVERSION behaves the same as the ssl_max_protocol_version connection parameter.
     
      
      LTCONNECT_TIMEOUT  behaves the same as the connect_timeout connection parameter.
     
      
      LTCLIENTENCODING behaves the same as the client_encoding connection parameter.
     
      
      LTTARGETSESSIONATTRS behaves the same as the target_session_attrs connection parameter.
     
The following environment variables can be used to specify default behavior for each LightDB session. (See also the ALTER ROLE and ALTER DATABASE commands for ways to set default behavior on a per-user or per-database basis.)
Refer to the SQL command SET for information on correct values for these environment variables.
The following environment variables determine internal behavior of libpq; they override compiled-in defaults.