Browsing "Older Posts"

Browsing Category "APEX issues"

Check inside your APEX application if debug mode is enabled

Von Tobias Arnhold → 6.08.2018
Sounds like a simple task but whenever I have the requirement to add a region and make it conditional to check if APEX is running in debug mode. I always search for half an hour finding the right solution.

Search example on Google: "Oracle APEX check debug mode conditional PL/SQL"
Trying this or 30 different other ways it always ends up with the wrong results.

But it is so easy - Conditional PL/SQL Expression:
APEX_APPLICATION.G_DEBUG

G_DEBUG returns true or false!
The documentation is a bit imprecise because it says 'Yes' or 'No'.

Anyway it is all well documented in the APEX documentation
> APEX_APPLICATION > Global Variables:
https://docs.oracle.com/database/apex-18.1/AEAPI/Global-Variables.htm#AEAPI29544




APEX 5 - File Upload Bug

Von Tobias Arnhold → 2.18.2016
Today I had to suffer on a real APEX 5 bug.

When you upload a file the NLS settings in your current APEX session will be set to AMERICAN.
I check for issues like that and found a forum post where someone else was experiencing the same problems as I did:
File browse changes some NLS settings - possible bug

My purpose was to upload a CSV file and transforming it to table data. Now I couldn't handle NUMBER values anymore. I always experienced the following error:
ORA-06502: PL/SQL: numeric or value error: character to number conversion error

APEX 5 Migration - Part 3 - The Universal Theme Migration

Von Tobias Arnhold → 1.12.2016
The last part of my APEX 5 migrations series:

- APEX 5 Migration - Part 1 - Requirements and Installation
- APEX 5 Migration - Part 2 - Common application issues after the migration
 
This part is about the best and hardest migration:
The Universal Theme migration (UT)!

Most of the developers love the new theme and its functionality but what makes it so different to the old ones? What is the value of the extra costs for the UT migration? Which rules should be followed? And what are the most common problems you will have to face?

Page Designer bug in combination with APEX plugin settings

Von Tobias Arnhold → 10.28.2015
Yesterday evening I struggled with a strange issue inside the Page Designer.

One APEX application created on each page of the Page Designer the following javascript parsing error:

Error: parsererror - SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data

It only happened in 1 of several applications I currently check after an APEX 5.0.2 migration.

What I did to find the issue (Thanks to Denes for some really good tips):
 - Copied the application into a new ID --> error could be reproduced
 - I dropped every page in the application --> error still occurred
 - My application had only one new empty page (page 1) and I switched to Universal Theme --> error still occurred
 - I checked several "Supporting Objects" and found the issue in one plugin
   - After deleting the plugin the parsing error disappeared
   - Unfortunately this plugin was referenced in 8 pages so I looked deeper into it
 - The issue was a wrongly referenced "Label appearance"



 - After I changed the setting to "- Not Depending -" the Page Designer run as expected

jQuery dialog z-index problem after migrating to APEX 5

Von Tobias Arnhold →
After migrating an APEX 4 application to APEX 5.0.2 I got an issue with the plugin called "Dialog Region".


The modal dialog wasn't accessible because the overlay effect was on top of my dialog.

Luckily some CSS code fixed the issue:

body div.ui-widget-overlay {
    z-index: 1;
}


The issue comes from the plugin in combination with an old theme. Actually it is easy to fix and no reason not to upgrade to APEX 5.0.2. :)

-----------------------------------------------------------------------------------------------------------------------------------

Btw.: The return to page function don't work in the "edit page" view.

APEX 4.2.5 Tabular Form - Komischer Bug

Von Tobias Arnhold → 2.27.2015
In einem meiner Projekte habe ich etwas intensiver auf Tabular Forms gesetzt.

In gewissen Konstellationen habe ich immer wieder folgende Meldung nach einem Validierungsfehler erhalten:
Aktuelle Daten für tabulare Forms sind zu alt; die Quelldaten wurden geändert.
Klicken Sie hier, um Ihre Änderungen zu verwerfen und die Daten aus der Datenbank neu zu laden.


Eventuell auch in Englisch:
Current tabular form data is too old; the source data has been modified.
Click here to discard your changes and reload the data from the database.


Direkt kam mir der Gedanke mit der Sprache und der Number-Spalte (., Setzung). Habe auch danach gesucht:
https://community.oracle.com/thread/2458512

Aber mein Fehler hatte nix mit der Sprache zu tun, sondern lag an einem Unique Constraint.
https://community.oracle.com/thread/2143396

Sobald ich diesen gelöscht habe, gab es dieses Phänomen nicht mehr! Habe ich Ihn wieder hinzugefügt, so habe ich den Fehler direkt wieder erhalten. :(




APEX Anwendungen importieren und exportieren mit Hilfe des SQL Developers

Von Tobias Arnhold → 2.20.2015
Wussten Sie das der Oracle SQL Developer eine sehr gute APEX Integration bietet? Ich möchte dies Anhand der Import und Export Fähigkeit näher demonstrieren.

Im SQL Developer gibt es im Navigationsmenü neben den üblichen Verdächtigen (Tabellen, Funktionen, Triggern, ...) auch einen Punkt Namens: Application Express
Wenn Sie diesen öffnen, dann sehen Sie alle installierten APEX Anwendungen die auf das Schema referenziert sind.

Export
Über die Rechte Maustaste > Schnell-DDL > In Datei schreiben... können Sie die Anwendung exportieren.

Import
Rechte Maustaste auf Application Express, anschließend "Anwendung importieren..." auswählen. 
 Natürlich können Sie auch im SQL Developer alle Installations-Optionen wie in APEX mitgeben.
Und nun kommt etwas Neues!
Wenn die Installation gestartet ist, dann können Sie die komplette Installation im Log nachverfolgen.

Diese Info hat mir schon einmal mehrere Stunden Suche gespart. Denn falls Sie es hin bekommen eine APEX Anwendung zu zerstören, so dass der Import nicht mehr funktioniert. Können Sie mit Hilfe des SQL Developer's die genaue Stelle des Fehlers herausfinden und anschließend die Anwendung korrigieren und erneut exportieren.
APEX-AT-WORK no image

Scroll to the top of your page/report

Von Tobias Arnhold → 1.19.2014
In case you use partial page refresh inside your reports you may have encountered an issue that you always stay on the bottom of the page even after the refresh of the report.  One of my customer marked this as a bug and meant that after the refresh the display position should be at the beginning of the report.

Seems complicated but worked out to be really easy:
Add a dynamic action: After refresh of your report execute this javascript statement

/* Scroll to Top */
$("html, body").animate({ scrollTop: 0 }, 0);

or in case you have the exact position of your report:
/* Scroll to the beginning of the report, starts at 221 */
$("html, body").animate({ scrollTop: 221 }, 0);

I found the solution in this post:
http://stackoverflow.com/questions/1144805/how-do-i-scroll-to-the-top-of-the-page-with-jquery