Tuesday, December 18, 2012

Force statistics computation

For the whole table:
analyze table unrated_usage.ft_unrated_usage_o compute statistics;
For one given partition:
analyze table unrated_usage.ft_unrated_usage_o partition(P0) compute statistics;

Saturday, December 15, 2012

Install a QNAP network HP C5280 printer on Mountain Lion

First of all, install the 3 packages to be found here: macosx/hpijs
This will install the HP Photosmart C5200 series drivers.
Then proceed as usual to add a printer: System Preferences, then Print & Scan, then (+) in the Printers list, and pick the correct model from the proposed list.

Friday, December 14, 2012

Count number of rows in partitions

SELECT table_name,
partition_name,
high_value,
num_rows
FROM SYS.ALL_TAB_PARTITIONS
where table_name = 'SMSC_CDR_MT'
and num_rows != 0
ORDER BY partition_name;

Thursday, December 6, 2012

Show a user's objects grants

SELECT * FROM DBA_TAB_PRIVS WHERE GRANTEE = 'my_user';