13,175 reputation
12151
bio website
location Munich, Bavaria
age
visits member for 3 years, 8 months
seen 43 mins ago

Jul
17
revised how to view the Image in mysql DB
edited tags
Jul
16
comment Primary key with randomly varying increments (so it cannot be guessed easily)
@frlan: there is an additional module that supplies functions to generate UUIDs: postgresql.org/docs/current/static/uuid-ossp.html
Jul
16
awarded  Good Answer
Jul
16
comment execute .sql script inside an anonymous pl/sql block which is invoked by a shell script
Why not just move the @... lines after the PL/SQL block?
Jul
16
revised execute .sql script inside an anonymous pl/sql block which is invoked by a shell script
added 74 characters in body; edited tags
Jul
15
answered Postgresql: set default psql client encoding
Jul
15
comment Split two rows into two columns
@gh0st_h4wk: the group by m.id, t.name will not show "rows double" - at least not rows with the same combination of (id, name). If this is not what you want, you need to supply a better example (ideally the two tables populated with some sample data). My first version assumed that your table has a column count until I realized that your example "table" isn't your table but the result of your query
Jul
15
comment Split two rows into two columns
Just a side note: Postgres 8.4 is end of life. You should really plan an upgrade to a supported version (e.g. 9.3). postgresql.org/support/versioning
Jul
15
answered Split two rows into two columns
Jul
15
revised Streaming replication Postgresql 9.3 using two different servers
Improved formatting
Jul
14
comment How to make a table name an attribute in PostgreSQL?
Nice trick with the string_agg(). Inheritance won't help here I think as you can't add the column identifying the "source table" when using inheritance without changing the structure of the tables.
Jul
14
comment How to make a table name an attribute in PostgreSQL?
@dd_a see my edit
Jul
14
revised How to make a table name an attribute in PostgreSQL?
added 1665 characters in body
Jul
14
answered How to make a table name an attribute in PostgreSQL?
Jul
14
comment Promotion of PostgreSQL standby and application reconnection
We are using a virtual IP and Pacemaker. The clients always connect to the same (virtual) IP address. Similar to this setup: clusterlabs.org/wiki/PgSQL_Replicated_Cluster
Jul
11
comment what is '#' in create table statement?
It always helps to read the manual: technet.microsoft.com/en-us/library/…
Jul
11
revised Pass the unix variable to the ddl command inside a pl/sql block
added 48 characters in body; edited tags; edited tags
Jul
10
comment Creating unique constraint to be validated from input
@NanoJava Because to_char() is not marked as immutable (that's why you can't use it in an index definition) and you can not change a built-in function.
Jul
10
answered Creating unique constraint to be validated from input
Jul
9
answered Building a Trending query