12,154 reputation
11947
bio website
location Munich
age
visits member for 3 years, 5 months
seen 55 mins ago

Oct
20
comment Insert of select id on multiple tables
stackoverflow.com/q/1109061/330315
Oct
20
comment Database with only text fields
Data validation is the most important reason for choosing the correct data type. Try to prevent storing an invalid date like 2014-02-29 into a varchar column. You can also rely on a column of type integer to never have a value of foobar in it.
Oct
20
comment Is there a faster way to get UNION ALL behavior in Postgres?
@ErwinBrandstetter: good catch. But based on the sample data I assumed t1_id would never be null
Oct
20
comment Where to download (Dutch) Postgresql Fulltext Search dictionaries
You can use the hunspell dictionaries from the OpenOffice/LibreOffice project: hunspell.sourceforge.net
Oct
18
comment Postgres blocking UPDATE on new column?
As a general rule of thumb: just don't quote any identifiers.
Oct
18
comment dynamic table can't be accessed by the users
Which DBMS are you using? Postgres? Oracle?
Oct
17
comment PostgreSQL how to change to Repeatable read
If in doubt, read the manual: postgresql.org/docs/current/static/…
Oct
17
comment Why is MySQL Server software so huge?
You only think it's huge until you download Oracle: that's approx. 4.5 GB
Oct
17
comment Join 3 tables and return only distinct values for max datetime
@DeLL It seems you are using a DB2 version that does not support window function. I though all DB2 versions - including the host based ones - support this (it is definitely valid for DB2 LUW)
Oct
17
comment Join 3 tables and return only distinct values for max datetime
@ypercube: the condition WHERE A.TRANNO=(SELECT MAX(TRANNO) FROM tableA A where A.CASENO=B.CASENO) implies partition by a.caseno to me.
Oct
17
comment How to handle big table?
"it would take one day" - how did you com to this conclusion? Please read this: wiki.postgresql.org/wiki/SlowQueryQuestions and add the missing information (namely: the execution plans)
Oct
17
comment Join 3 tables and return only distinct values for max datetime
"where a.date between 140124 and 140331" - are you really storing dates as integers like that? And why do you split the date and the time into two different (integer) columns? It will be much better to use a proper timestamp column instead.
Oct
16
comment PostgreSQL return second 'Group' as an array
@DaveB: you are right. I forgot that.
Oct
16
comment Postgres top-k with ties
@Alexandros: sorry, I have no idea what you mean. Can you add more sample data to your question?
Oct
16
comment Rows are not getting deleted from MySQL Table
Does the "federated" storage engine support transactions? Maybe you are simply missing a commit?
Oct
16
comment PostgreSQL return second 'Group' as an array
@ClaesMogren: good point, fixed.
Oct
16
comment Where does mysql store data?
@Konrad: that's actually pretty common. Oracle and SQL Server also store everything in a single file (although you can configure them differently)
Oct
16
comment Self Join? Or am I wrong?
I think this is because MINUS was introduced in Oracle long before this was defined in the SQL standard.
Oct
16
comment Self Join? Or am I wrong?
minus is Oracle specific. The SQL standard defines except
Oct
16
comment Postgres top-k with ties
@Alexandros: see my edit. By doing this in two "steps", this *could*(!) be faster. But you will have to check the execution plan with your real life data.