 |
 |
 |
|
|
 |
 |
 |
|
 |
 |
 |
|
|
| Firefox | 1241 | | IExplorer | 1597 | | Linux | 108 | | Windows | 2888 | | Total Views | 49318 | |
|
| | BCHR |
| | CMS_TS (100MB) |
| | DB (XE) (5GB) |
| | PGA (256MB) |
|
|
|
| Undocumented Packages for Backup & Restore [2008.01.22] Bookmark (1.0.0.0) Finally overcoming my writing blockade, here's something I found recently.
During a discussion in the OTN XE Forum (which, unfortunately, requires additional authentification) in the thread ISV - Bundle Oracle XE install into Software Install I suggested to use a seed db for software installation as shown in the installation process of XE.
Since Oracle provides said installation procedure as shell scripts (both Windows and Linux), I took a peek at the script rmanRestoreDatafiles.sql in the directory /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/config/scripts. Seems like this installation process uses an internal package for recovering the necessary tablescripts instead of a RMAN call, as shown in the shell scripts backup.sh or restore.sh in the same directory.
The name of that installation script hints that DBMS_BACKUP_RESTORE is a wrapper for RMAN, however I couldn't find a chapter on this in the 10g2 documentation, only a few references, for example an error message. Anyway, according to that script DBMS_BACKUP_RESTORE has several procedures/functions with names that seem self explanatory:
deviceAllocate
restoreSetDataFile
restoreDataFileTo
restoreBackupPiece
deviceDeallocate
| | Debugging an APEX application [2008.01.09] Bookmark (1.0.0.0) While developing my CMS lite app I sometimes need to have a look at the state of certain regions or package function/procedures results. Thanks to the chapter Debugging an Application in the Application Express User's Guide I started with the #timing# tag, which does provide some information on the execution time (per region) which you can see at the bottom of my page. But I wanted also some output on packages, so I searched OTN and found a nice introduction at Injecting custom debug output into debug mode. The rest is easy, using a debug procedure (which is part of a package) that will work both inside SQL*PLUS (or any other tool) and APEX:
PROCEDURE Debug(
p_Message IN VARCHAR2
)
IS
BEGIN
IF v_Debug_Mode
THEN
DBMS_OUTPUT.PUT_LINE(p_Message);
ELSIF wwv_flow.g_debug
THEN
htp.p(p_Message || '<br>');
END IF;
END Debug;
and placing debug statements in my packages. While going through the OTN Application Express forum I found an even better solution in Debug comments cannot be seen: wwv_flow.debug (in my opinion this information should be mentioned in the APEX debug chapter)
Changing my Debug procedure to
PROCEDURE Debug(
p_Message IN VARCHAR2
)
IS
BEGIN
IF v_Debug_Mode
THEN
DBMS_OUTPUT.PUT_LINE(p_Message);
ELSIF wwv_flow.g_debug
THEN
wwv_flow.debug(p_Message);
END IF;
END Debug;
now also shows timings of each debug line, such as this:
Daily insights of a database application developer 0.14: show report 0.14: determine column headings 0.14: parse query as: L2IS 0.14: binding: ":P3_ID"="P3_ID" value="" 0.14: binding: ":P3_NAME"="P3_NAME" value="" 0.14: binding: ":P3_SEARCH_TEXT"="P3_SEARCH_TEXT" value="" 0.14: print column headings 0.14: rows loop: 2 row(s) 0.15: --- cm_parse.bbcode_to_html --- 0.15: --- cm_parse.bbcode_to_html --- 0.16: --- cm_parse.bbcode_to_html --- 0.18: --- cm_parse.bbcode_to_html --- 0.19: --- cm_parse.bbcode_to_html --- 0.20: --- cm_parse.bbcode_to_html --- 0.20: --- cm_parse.bbcode_to_html --- 0.21: --- cm_parse.bbcode_to_html --- 0.21: --- cm_parse.bbcode_to_html --- 0.22: --- cm_parse.bbcode_to_html --- 0.22: --- cm_parse.bbcode_to_html --- 0.23: --- cm_parse.bbcode_to_html --- 0.23: --- cm_parse.bbcode_to_html --- 0.23: --- cm_parse.bbcode_to_html --- 0.24: --- cm_parse.bbcode_to_html --- 0.25: --- cm_parse.bbcode_to_html --- 0.25: --- cm_parse.bbcode_to_html --- which gave me some hints on how to improve the rendering on the main page. | | |
Entries rendered in: 0.20 s |
|
|
 |
 |
 |
|
 |
 |
 |
|
|
 |
 |
 |