I am trying to execute postgresql query (\list) to get the list of databases using npsql.
string postgresQuery = @"\list"; 
            ICollection<Schema> schemas = new List<Schema>();
            string ConnectionString =
"Host=xxx;Username=postgres;Password=admin;Database=test;";
            NpgsqlConnection conn = new NpgsqlConnection(ConnectionString);
            NpgsqlCommand cmd = new NpgsqlCommand(postgresQuery, conn);
            conn.Open();
   NpgsqlDataReader dataReader = cmd.ExecuteReader();
While executing the query facing an issue that "syntax error at or near "\" ". The string contains double-slash as follow (\list) instead of single-slash (\list). Please let me know if there is any solution for this. Thanks in advance.
 
    