## 1st London Oracle Developer Meetup

Monday night (18th December) I co-hosted with Luis Weir the first London OracleDeveloperMeetup. Despite being a Monday evening in the run up to Christmas where a lot of people will attending Christmas events, needing to finish present shopping or event started their holiday we still had a tremendous turn out. With nearly 50 people out of almost 100 registrations coming to the Oracle London Office.

The evening kicked off just after 6pm with beer, pizza (more...)

## That demned elusive PQ slave

With apologies to Emma Orczy for stealing a line from “The Scarlet Pimpernel” …

# Introduction

We ran into a strange situation at a customer site this morning. A customer asked us to kill two stuck sessions on one of their 11.2.0.4 RAC Exadata environments, normally something they have sufficient knowledge and access to be able to handle themselves. Well this time round, every time they issued an “ALTER SYSTEM KILL SESSION ‘xxx, (more...)

## Content- My Year in Review, 2017

So where did 2017 go?!?!?  I really, really would like to know…  Needless to say, it’s time to do a year in review already and I actually have time to do it this year!

### DBAKevlar Blog

I wrote over 100 blog posts this year between DBAKevlar, Delphix and partner sites, but I’ve enjoyed sharing with the different communities.  There’s significant changes going on in the IT world regarding the future of the (more...)

## Oracle Content & Experience Cloud: Document Search

If you read my first post on Oracle Content & Experience Cloud (Oracle CEC), you would have come away impressed with the capabilities and features of the product. Features for organizations to manage and share high-value content that could be used to build content-rich, omni-channel websites. However, as I’ve continued to work with Oracle CEC over the last four months, some features need improvement. Most notably in my opinion, is search. I’ll explain the (more...)

## Top N biggest tables (with lobs, indexes and nested table)

with
seg as (
select
owner,segment_name
,segment_type
,tablespace_name
,sum(blocks) blocks
,sum(bytes)  bytes
from dba_segments s
where  segment_type not in (
'TYPE2 UNDO'
,'ROLLBACK'
,'SYSTEM STATISTICS'
)
and segment_name not like 'BIN$%' --not in recyclebin group by owner,segment_name,segment_type,tablespace_name ) ,segs as ( select owner,segment_name ,case when segment_name like 'DR$%$%' then 'CTX INDEX' else segment_type end segment_type ,tablespace_name ,case when segment_name like 'DR$%$%' then (select table_owner||'.'||table_name from dba_indexes i where i.owner=s.owner and i.index_name (more...) ## asmcmd “connected to an idle instance” – not This is more a note to myself in case I’ll encounter a similar environment. But maybe it helps others – at least my search results weren’t suitable to Windows in the first place. Issue C:\> set ORACLE_HOME=C:\path\to\grid\home C:\> set ORACLE_SID=+ASM1 C:\> asmcmd connected to an idle instance. Environment Windows 2012R2 Oracle Grid Infrastructure 12.1.0.1 2 […] ## ORA-01450: maximum key length (3800) exceeded This is an oddity as essentially I have an index on a table but I cannot rebuild it because it suggests the block size should be bigger than 8K – however both the database and tablespace block size are 16K already. The maximum allowed index key length depends on your block size. So the minimum allowed size reported in ORA-01450 varies, depending on which block size your index is using: ORA-01450 maximum key length (758) (more...) ## “Collection iterator pickler fetch”: pipelined vs simple table functions Alex R recently discovered interesting thing: in SQL pipelined functions work much faster than simple non-pipelined table functions, so if you already have simple non-pipelined table function and want to get its results in sql (select * from table(fff)), it’s much better to create another pipelined function which will get and return its results through PIPE ROW(). A bit more details: Assume we need to return collection “RESULT” from PL/SQL function into SQL query “select (more...) ## Getting Ready I don't think it's any big secret that we're getting close to R13 of Oracle Cloud Applications. We've been talking about it publicly since Oracle OpenWorld 2017. Having seen R13 up close, I'm very excited to see it come to market. But, my excitement notwithstanding, I also know that existing customers get a bit antsy in the face of an impending upgrade. Because preparation for an upgrade is important, and that preparation requires information. What (more...) ## manage ORACLE_HOMEs and patches in a centralised way Managing many ORACLE_HOMEs in a complex environment can be tricky, especially when questions about their patches & bugs or comparisons should be done. It's required to understand the different types of patches available. This can be (according to the documentation & my interpretation). Especially the differences between SYSTEM PATCH (in our case only Bundle Patches), COMPOSITE and SINGLETON patches, and BUGs - of course. A way to handle all the information is to (more...) ## The hang manager Recently I was looking in the trace directory in the diag dest of my (12.2.0.1) instance, and found some trace files which were different from the others: $ ls | grep dia0
test_dia0_9711_base_1.trc
test_dia0_9711_base_1.trm
test_dia0_9711_lws_1.trc
test_dia0_9711_lws_1.trm
test_dia0_9711.trc
test_dia0_9711.trm


The dia0 ‘test_dia0_9711.trc’ file is fully expected. But what are these ‘..lws_1.trc’ and ‘..base_1.trc’ files? And ‘base’ is something that I understand, but (more...)

## DBMS_COMPRESSION can be run in parallel, at least from 11.2.0.4

I was trying to use DBMS_COMPRESSION on an 11gR2 (11.2.0.4 on RHEL 6.3) database the other day and was helped by this article from Neil Johnson. I was having some trouble with permissions until I read that article which nicely summarises everything you need to know – thanks Neil!

One thing I did notice is that Neil stated that you can’t parallelise the calls to the advisor since it uses the (more...)

## Oracle Code Online December 2017

This week Oracle Code will be having an online event consisting of 5 tracks and with 3 presentations on each track. This online Oracle Code event will be given in 3 different geographic regions on 12th, 13th and 14th December. I've been selected to give one of these talks, and I've given this talk at some live Oracle Code events and at JavaOne back in October. The present is pre-recorded and I recorded this video (more...)

## Oracle 12c and PHP

This answers “How you connect PHP programs to an Oracle 12c multitenant database. This shows you how to connect your PHP programs to a user-defined Container Database (CDB) and Pluggable Database (PDB). It presupposes you know how to provision a PDB, and configure your Oracle listener.ora and tnsnames.ora files.

CDB Connection:

This assumes you already created a user-defined c##plsql CDB user, and granted an appropriate role or set of privileges to the (more...)

## Type Dependent Tree

While trying to explain a student question about Oracle object types, it seemed necessary to show how to write a dependency tree. I did some poking around and found there wasn’t a convenient script at hand. So, I decided to write one.

This assumes the following Oracle object types, which don’t have any formal methods (methods are always provided by PL/SQL or Java language implementations):

CREATE OR REPLACE TYPE base_t AS OBJECT
( base_id  NUMBER  (more...)

## SQL*Plus tips #8: How to read the output of dbms_output without “serveroutput on”

When “serveroutput” is enabled, SQL*Plus executes “BEGIN DBMS_OUTPUT.GET_LINES(:LINES, :NUMLINES); END;” after each command.
That’s why I don’t like when it is always enabled: it adds extra calls and round-trips and it is inconvenient when I want to get a plan of the last executed query:

SQL> set serverout on;
SQL> select * from dual;

D
-
X

SQL> select * from table(dbms_xplan.display_cursor('','','allstats last'));

PLAN_TABLE_OUTPUT
--------------------------------------------------------------------------
SQL_ID  9babjv8yq8ru3, child number 0

BEGIN  (more...)

## Substitutable Columns

Oracle’s substitutable columns are interesting and substantially different than Oracle’s nested tables. The benefit of substitutable columns is that you can create one for an object type or any subtypes of that object type. Unfortunately, you can’t create the same behavior with nested tables because Oracle’s implementation of collection types are always final data types and you can’t extend their behaviors.

The Oracle Database has three types of collections. Two are SQL scoped collection types (more...)

## Bug with integer literals in PL/SQL

This interesting question was posted on our russian forum yesterday:

We have a huge PL/SQL package and this simple function returns wrong result when it’s located at the end of package body:

create or replace package body PKGXXX as
...
function ffff return number is
nRes number;
begin
nRes :=  268435456;
return nRes;
end;
end;
/


But it works fine in any of the following cases:
* replace 268435456 with power(2, 28), or
* replace (more...)

## Shooting the DBA isn’t a Silver Bullet to the Cloud

We’ve all been watching numerous companies view value in bypassing the Database Administrator and other critical IT roles in an effort to get IT faster to the cloud.  It may look incredibly attractive to sales, but the truth of it is, it can be like setting up land mines in your own yard.

Having the right people in the right roles, doing the right tasks is essential to having a complete cloud deployment.  (more...)

## Oracle Integration Cloud Update

As previously mentioned, ICS is going to be incorporated into Oracle Integration Cloud.  Since we have had the announcement we have had some more information about OIC released. The keypoints here are: OIC Standard Edition OIC Enterprise Edition What we used to know as Integration Cloud Service, which includes … Various integration patterns including Orchestration […]

The post Oracle Integration Cloud Update appeared first on Implementing Oracle Integration Cloud Service.