12,099 reputation
11947
bio website
location Munich
age
visits member for 3 years, 5 months
seen 1 hour ago

Oct
8
comment Mysql, sql server, oracle tables get too large
You can either "hide" the harddisks behind an RAID array (that way it looks like one harddisk to the DBMS) or use e.g. tablespaces to distribute tables across different filesystems. This all depends highly on the DBMS, the operating system, the file system and the hardware being used.
Oct
7
comment Is DBCA in Oracle for a single database or the entire system?
If you have a running Oracle instance, you most probably do not want to create a new database. You just want to create a new schema (=user). A "database" in Oracle is something completely different than a "database" e.g. in Postgres, SQL Server or MySQL.
Oct
7
comment Altering a parent table in Postgresql 8.4 breaks child table defaults
@CurtisPoe: it is considered bad programming style when not explicitely stating the columns in an insert statement - with or without inheritance.
Oct
7
comment Tree structure hierarchical query sorting
As far as I can tell, all you need to do is to use an ORDER BY rank_key DESC. Btw: you don't need the columns tree_no and level, they can be generated on the fly while retrieving the data: sqlfiddle.com/#!12/be46b/2
Oct
7
comment Tree structure hierarchical query sorting
I still don't understand how your desired output should look like. Can you please post an example on what you want the output to look like based on the given sample data.
Oct
7
comment Cannot set MEMORY_TARGET for Oracle 11.2
@Ivan: sga_target is set to 0 (as you can see from the output) as for pga_aggregate_target I cannot set that to 0 (in contrast to the manual) to enable automatic memory management.
Oct
7
comment Tree structure hierarchical query sorting
The question already constains an example using a recursvie CTE.
Oct
7
comment Cannot set MEMORY_TARGET for Oracle 11.2
@Ivan: I can set memory_max_target to 8GB without problems, I just can not set memory_target to anything less than that (and I'm using 11gR2)
Oct
7
comment Tree structure hierarchical query sorting
Sorry, what exactly is your question? What output do you want to create?
Oct
4
comment Postgresql. Proxying queries and log them
Have a look at the pg_stat_statements module: postgresql.org/docs/current/static/pgstatstatements.html
Oct
3
comment message table schema - body TEXT or varchar
Sow which DBMS are you using? Postgres?
Oct
1
comment Performance difference between MySQL and PostgreSQL for the same schema/queries
@JavierValencia: if you were able to fix the problem, please add an answer describing what you did so that others can learn from that. You can also accept your own answer in order to mark this question as solved
Sep
29
comment How to create properly tree-hierarchy
The statement "Oracle does not include NULL in an index" is not entirely true. When indexing more than one column, the combination (1,NULL) will be put into the index. But in this case when you only index one column, you are of course right. (And I agree: NULL is the most reasonable choice to store into client_id for that situation)
Sep
27
comment Sharing a single primary key sequence across a database?
Which DBMS are you using? Oracle? Postgres? DB2?
Sep
27
comment Trigger - Add to a date using a subquery
But those are column names, not foreign key names.
Sep
27
comment Trigger - Add to a date using a subquery
@Olhinho: I don't understand your table structure anyway. Why is type_designation_extinguisher_type a text column? Shouldn't that be an integer referencing the "serial" column of the extinguisher_designation table? (assuming that is the primary key of that table)
Sep
24
comment Why does MySQL allow HAVING to use SELECT aliases?
My guess is, it's your second bullet point.
Sep
24
comment Do SQL Server or MYSQL contain JSON supporting functions?
Postgres has decent JSON support
Sep
23
comment How can a group track database schema changes?
Check out Liquibase or Flyway
Sep
23
comment Why is column default value not portable through different RDBMS?
ORMs ususally go for the least common denominator. And if there is only a single DBMS that doesn't support defaults, that's what the "reference" is. Same goes for check constraints or other "modern" SQL features (think recursive queries)