hunk.code_window:         const tableNamesString = tableNames.map(name => "'" + name + "'").join(", ");
           const tablesSql      = `SELECT * FROM information_schema.tables WHERE table_catalog = '${this.dbName}' AND table_schema = '${this.schemaName}' AND table_name IN (${tableNamesString})`;
           const columnsSql     = `SELECT * FROM information_schema.columns WHERE table_catalog = '${this.dbName}' AND table_schema = '${this.schemaName}'`;
           const indicesSql     = `SELECT t.relname AS table_name, i.relname AS index_name, a.attname AS column_name  FROM pg_class t, pg_class i, pg_index ix, pg_attribute a, pg_namespace ns
   WHERE t.oid = ix.indrelid AND i.oid = ix.indexrelid AND a.attrelid = t.oid
   AND a.attnum = ANY(ix.indkey) AND t.relkind = 'r' AND t.relname IN (${tableNamesString}) AND t.relnamespace = ns.OID AND ns.nspname ='${this.schemaName}' ORDER BY t.relname, i.relname`;
           const foreignKeysSql = `SELECT table_name, constraint_name FROM information_schema.table_constraints WHERE table_catalog = '${this.dbName}' AND table_schema = '${this.schemaName}' AND constraint_type = 'FOREIGN KEY'`;
           const uniqueKeysSql  = `SELECT * FROM information_schema.table_constraints WHERE table_catalog = '${this.dbName}' AND table_schema = '${this.schemaName}' AND constraint_type = 'UNIQUE'`;
           const primaryKeysSql = `SELECT c.column_name, tc.table_name, tc.constraint_name FROM information_schema.table_constraints tc
  
hunk.labels: keep keep keep replace keep keep keep keep keep
hunk.after_edit:         const indicesSql     = `SELECT t.relname AS table_name, i.relname AS index_name, a.attname AS column_name, ix.indisunique AS is_unique, a.attnum, ix.indkey FROM pg_class t, pg_class i, pg_index ix, pg_attribute a, pg_namespace ns
  
hunk.file_path: src/driver/postgres/PostgresQueryRunner.ts
hunk.type: replace
file: import {ObjectLiteral} from "../common/ObjectLiteral";
  import {Brackets} from "./Brackets";
  
  /**
   * Query Builders can implement this interface to support where expression
   */
  export interface WhereExpression {
  
      /**
       * Sets WHERE condition in the query builder.
       * If you had previously WHERE expression defined,
       * calling this function will override previously set WHERE conditions.
       * Additionally you can add parameters used in where expression.
       */
      where(where: string, parameters?: ObjectLiteral): this;
  
      /**
       * Sets WHERE condition in the query builder.
       * If you had previously WHERE expression defined,
       * calling this function will override previously set WHERE conditions.
       * Additionally you can add parameters used in where expression.
       */
      where(where: Brackets, parameters?: ObjectLiteral): this;
  
      /**
       * Sets WHERE condition in the query builder.
       * If you had previously WHERE expression defined,
       * calling this function will override previously set WHERE conditions.
       * Additionally you can add parameters used in where expression.
       */
      where(subQuery: (qb: this) => string, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new AND WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      andWhere(where: string, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new AND WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      andWhere(where: Brackets, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new AND WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      andWhere(subQuery: (qb: this) => string, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new OR WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      orWhere(where: string, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new OR WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      orWhere(where: Brackets, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new OR WHERE condition in the query builder.
       * Additionally you can add parameters used in where expression.
       */
      orWhere(subQuery: (qb: this) => string, parameters?: ObjectLiteral): this;
  
      /**
       * Adds new AND WHERE with conditions for the given ids.
       *
       * Ids are mixed.
       * It means if you have single primary key you can pass a simple id values, for example [1, 2, 3].
       * If you have multiple primary keys you need to pass object with property names and values specified,
       * for example [{ firstId: 1, secondId: 2 }, { firstId: 2, secondId: 3 }, ...]
       */
      whereInIds(ids: any[]): this;
  
      /**
       * Adds new AND WHERE with conditions for the given ids.
       *
       * Ids are mixed.
       * It means if you have single primary key you can pass a simple id values, for example [1, 2, 3].
       * If you have multiple primary keys you need to pass object with property names and values specified,
       * for example [{ firstId: 1, secondId: 2 }, { firstId: 2, secondId: 3 }, ...]
       */
      andWhereInIds(ids: any[]): this;
  
      /**
       * Adds new OR WHERE with conditions for the given ids.
       *
       * Ids are mixed.
       * It means if you have single primary key you can pass a simple id values, for example [1, 2, 3].
       * If you have multiple primary keys you need to pass object with property names and values specified,
       * for example [{ firstId: 1, secondId: 2 }, { firstId: 2, secondId: 3 }, ...]
       */
      orWhereInIds(ids: any[]): this;
  
  
  }