Monday, October 23, 2017

Query to List all Empty Tables

  SELECT    'select '''
         || owner
         || ''' owner,'''
         || table_name
         || ''' table_name  '
         || CHR (10)
         || 'FROM '
         || owner
         || '.'
         || table_name
         || ' where rownum<2 having count(*)=0; '
            sql
    FROM all_tables
   WHERE     owner NOT IN ('SYS',
                           'SYSTEM',
                           'OUTLN',
                           'WMSYS')
         AND SUBSTR (owner, 1, 4) <> 'OPS$'
ORDER BY 1;

No comments:

Post a Comment

SupplierAddressImportTemplate.xlsm South Africa Suburb Field mapping in POZ_SUPPLIER_ADDRESSES_INT

Suburb mpping in Supplier Address Import Template will be mapped to Address Element Attribute2 (HZ_LOCATIONS. ADDR_ELEMENT_ATTRIBUTE2)