     raise exception 'not supported i_partition_period: %', i_partition_period;
   end if;
 
+  if length (_table) = 0 then
+    _table := _schema;
+    _schema := 'public';
+  end if;
+
   for _part in
     select quote_ident (t.schemaname) ||'.'|| quote_ident (t.tablename)
       from pg_catalog.pg_tables t

  in i_retention_period interval,
  in i_partition_period text
)
  returns setof text
as $$
-------------------------------------------------------------------------------
--  Function: londiste.drop_obsolete_partitions(2)
--
--    Drop obsolete partitions of partition-by-date parent table.
--

--    i_parent_table        Master table from which partitions are inherited
--    i_retention_period    How long to keep partitions around
--    i_partition_period    One of: year, month, day, hour
-------------------------------------------------------------------------------
declare
  _schema text not null := lower (split_part (i_parent_table, '.', 1));
