Questions tagged [postgresql-9.1]
PostgreSQL version 9.1
279 questions
0
votes
0
answers
421
views
pg_restore fails with ERROR: could not create directory "pg_tblspc/16400/PG_11_201809051/16403": Invalid argument
Trying to migrate PG9.1 data to PG11.5
I did initdb using the following command.
"<path>\bin\initdb.exe" --locale="English_Malaysia.1252" -D "<path>\pgupgrade"...
0
votes
1
answer
2k
views
Cannot restore data using Postgres WAL files
I'm a newbie at PostgreSQL.
I'm trying to setup a streaming replication (postgresql 9.1).
And I want to test backup & restore on local.
I also made backup files successfully (I think so) by using ...
0
votes
0
answers
136
views
Allowing other host to connect to postgresql-9.1 and restart services in postgresql-9.1
We need to add few Ip address in our pg_hba.conf file so that some new servers can connect to our postgresql database. We did the changes to pg_hba.conf like below
old pg_hba.conf
# TYPE DATABASE ...
0
votes
1
answer
744
views
How to change pg_largeobject data from psql? (posgresql-9.1)
16-byte password hashes of some application are stored in the postgresql-9.1 database as LOB data. (I don't know why)
So I can get hash:
# select * from pg_largeobject where loid=16916;
loid | ...
10
votes
3
answers
2k
views
Is the keyword "ALIAS" actually used?
According to PostgreSQL 7.1 through 9.1 (now unsupported), ALIAS is listed as a reserved word, at least for SQL-99. Later versions do not show it - suggesting that it has been dropped as a reserved ...
2
votes
1
answer
174
views
ExclusiveLock on related table due to update?
Recently ran into the following:
Consider the tables created by this:
create table table_a (
id bigserial not null,
last_update timestamp,
primary key (id)
);
create table ...
1
vote
2
answers
621
views
Strip longest common suffix and concat in Postgres
Given a table t:
id | name
------------
1 | abcfug
1 | deffug
1 | hijfug
2 | etc
How can I do something like:
select string_agg(strip_lcs(name), ', ') from t where id = 1
returning:
abc, def, ...
0
votes
2
answers
77
views
select newest update record among similar record
I have 2 tables segments and summaries.
I want to list the shows in a date interval and just show the latest updated segments (in bold) since it is the freshest copy of the segment for that person.
...
0
votes
2
answers
971
views
Number of times PostgreSQL database restarted
How to get how many times my PostgreSQL database restarted and how to get each restart time?
I do not want to get the details from the log file. Is there any other way to get those details?
-1
votes
1
answer
342
views
To get rid of heavy archive logs in PostgreSQL 9.1
In our production server which is having PostgreSQL 9.1 installed, too heavy archive logs are being generated, approximately 41 GB/day. Heavy updates, deletes and inserts are the cause of this. Can ...
3
votes
1
answer
7k
views
Fragmentation in PostgreSQL 9.1
How can I check for fragmentation in PostgreSQL 9.1?
1
vote
1
answer
153
views
Hive metrastore Database in Postgresql External [closed]
We recently migrated hive metastore database from embedded postgresql(coming with cloudera hadoop) to external postgresql(standalone in vm server). After that we notified that there is increase of 5 ...
0
votes
1
answer
641
views
Problem joining two tables on date field?
im using following query with PostgreSQL 9.1.13:
SELECT
day::DATE AS date,
COUNT(s.id) AS sale_count,
COUNT(c.id) AS claim_count
FROM
GENERATE_SERIES('2017-08-10', '2017-08-13', ...
1
vote
0
answers
285
views
Postgres not able to recover in replication mode
Because of manual cleanup of WAL files, my DB is corrupted. PostGres is throwing this error :
2017-08-10 20:44:41.887 UTC 2661 LOG: database system was interrupted;
last known up at 2017-08-03 ...
1
vote
2
answers
3k
views
postgres 9.1: role public does not exist
I understand public is not a typical role in postgres:
dav-gis=# \duS public
List of roles
Role name | Attributes | Member of
-----------+------------+-----------
But why can I revoke ...