Translate

Dienstag, 17. Dezember 2019

APEX Einführung - 5 Teile - in Deutsch

Für deutsche APEX "Nofizen" fand ich gerade einen schöne Einführung, die ich Euch nicht vorenthalten möchte:
https://informatik-transparent.de/oracle-application-express/

Danke für die Mühe !!!

Die Teile im einzelnen:

Oracle APEX 18.2 Tutorial Teil 1 – SQL Workshop

Deutschsprachiges Einsteiger Tutorial für Oracle APEX 18.2. Tabellen mit dem
SQL Workshop erstellen. In dieser Beitragsreihe möchte ich Ihnen anhand ...
Weiterlesen …

Oracle APEX 18.2 Tutorial Teil 2 – SQL Commands

Im zweiten Teil des Einführungstutorials geht es um die Ausführung von DDL
Anweisungen über das Modul SQL Commander.  In diesem ...
Weiterlesen …

Oracle APEX 18.2 Tutorial Teil 3 – Application Builder

Anwendungen erstellen Sie in APEX mit dem Application Builder. Hierzu mehr im
3. Teil des deutschsprachigem APEX Einsteiger Tutorials. Application ...
Weiterlesen …

Oracle APEX 18.2 Tutorial Teil 4 – Page Designer

Im 4 Teil des deutschsprachigen Oracle APEX Einsteiger Tutorial geht es um die
Erstellung von Seiten mit dem Page Designer ...
Weiterlesen …

Oracle APEX 19 Tutorial Teil 5 – Process and Condition

Dieser Teil des Oracle APEX Tutorials zeigt Ihnen, wie Sie Prozesse und
Bedingungen ( Conditions ) in Ihren Anwendungen nutzen können ...

Donnerstag, 15. August 2019

Jasper Reports Studio 6.8 - Tipps & Tricks

some of my findings:

1. Number format, 2 decimals like 123,50 - Designer - sourceTab: <textField pattern="###0.00">

like:








Alternatively you can also place the pattern ###0.00 in the "pattern parameter" as can be seen below under 3.2


2. Report page with two columns: Main Report - Properties - Advanced - columns .. 2

like:



now you content or data will be displayed in two columns like in a newspaper.

First data will occupy the first column from top to down and subsequent data will go into the 2nd column etc.
















an alternative approach with images in columns... - images side by side... in 4. a 2 column page is shown.


3. Summarize fields of detail band:

3.1 My field is called "Kosten" (Format java.math.BigDecimal) -

create a variable called  "SumKosten" (Format java.math.BigDecimal) like below:























3.2 then place a "Textfield" (not "Static Text" !!!) somewhere in the report like:

















4. Image in Report

- In JR Studio Designer select the button to edit the sql sources
- in the lower part of the window select tab "fields" and edit the field e.g. "IMAGE" holding the BLOB of the table
- for class type click the '...' - select list and select image or "java.awt.Image" and OK/save.
- Back in the Studio drag and drop the "image" element from (right hand) "Basic Elements" to the canvas and that looks like:











last step: klick on the image object -  in Image:image "properties" - expression field will be "" (empty) - open the expression editor and select the image object like:













now test...

4.1 Image in report - SQL-statement (changes)

One thing I like to add:
When you change your SQL-Statement and add some fields using the "Dataset and Query Editor" you may want to use "Read Fields" in the upper right corner to populate the columns, which will become the Field names ... you will experience the phenomenon, that the "IMAGE" column (actually of type BLOB) will be populated as "java.lang.string"... !!!! beware of that !!!!
You will have to edit that field and assign the object type : "java.awt.Image" - pls see as under:
















Every time you use "Read fields" you will have to do the above with the IMAGE (blob) column.
An alternative is:
Change your SQL (add columns...) and manually add the fields in the lower part of the editor. Then the image-field will stay and the object-type is not changed.

Freitag, 2. August 2019

APEX 19 - GANTT chart challenge - resource planning

I have the biz challenge to visualize resource planning.

this is what I achieved so far, based on Patrick Monacos plugin for resource planning, but I like to make use of the APEX chart for GANTT based on Oracle Jet ( I like to stick to the APEX standards and OOTB features...JJJJ).

here is my achievement:


the gray colored weekends are based on the following style snippet (page attributes --> inline CSS):
  <style>
 /* alternating column backgrounds */
  .vis-time-axis .grid.vis-odd {
    background: #f5f5f5;
  }

  /* gray background in weekends, white text color */
  .vis-time-axis .vis-grid.vis-saturday,
  .vis-time-axis .vis-grid.vis-sunday {
    background: gray;
  }
  .vis-time-axis .vis-text.vis-saturday,
  .vis-time-axis .vis-text.vis-sunday {
    color: white;
  }
</style>

Montag, 17. Juni 2019

XMLTABLE Tipp - concatenate - verbinden von XML-tags mit string-join - extract mit [last()]

Im Rahmen einer Schnittstellen-Entwicklung, wo ich in einem FTP-Verzeichnis täglich eingehende XML-Dateien parse mittels pl/sql und UTL_FILE und XMLTABLE, wollte ich gerne mehrere tag-Inhalte zusammenfassen...., um sie in eine Tabellenspalte zu schreiben - dies ist selten bis gar nicht dokumentiert... also jetzt hier:

meine tags/Segmente:

<row>
   <pickup>
       <location>
            <name>Leergut GmbH</name>
            <street>Lange Reihe 22</street>
            <zipCode>25912</zipCode>
            <city>Schulau</city>
            <phone>04321-12345-0</phone>

      <location>
   </pickup>
<row>

Die fett formatierten tag-Teile sollen nun "concateniert" werden mit "string-join"

die entsprechende Zeile bei COLUMNS lautet dann:

 location varchar2(200) PATH 'string-join(row/pickup/location,",")'

meine vollständigen (gekürzten) Abfrage:

SELECT xt.*
  FROM XMLTABLE(
   PASSING XMLTYPE(BFILENAME('XML_DIR', fileName), -- parsen der Dateinamen
--   PASSING XMLTYPE(BFILENAME('XML_DIR', 'v_53_1_16166.xml'), -- zum Test 1 Datei
      nls_charset_id('AL32UTF8') ) 
COLUMNS
 seq,
 ......
 location varchar2(200) PATH 'string-join(row/pickup/location,",")',
 .......
 ) xt;

Ergebnis:
Spalte location:
Leergut GmbHLangeReihe2225912Schulau04321-12345-0

I: lediglich den "Trenner "," nimmt pl/sql bzw. xml nicht...


Ein weiterer Tipp:
Gibt es mehrere "Details" zu einem Tag, konnte ich den "letzten" mit [last()] herausfiltern:
Beispiel: es gibt 2 Adressen-Details bei "location", dann wird die letztere herausgefiltert:

location varchar2(200) PATH 'row/pickup[last()]/location',




Donnerstag, 9. Mai 2019

Jasper Reports 6.6 - java.lang.NullPointerException - no data found


APEX 19.1 - TIBCO Jasper Reports Studio 6.6

HTTP Status 500 -


type Exception report
message
description The server encountered an internal error that prevented it from fulfilling this request.
exception
java.lang.NullPointerException
note The full stack trace of the root cause is available in the Apache Tomcat/8.0.27 logs.


Sehr hässlich ist diese Fehlermeldung für die Endbenutzer.

Hintergrund:
Ich starte in APEX einen Prozess, der die Ausgabe eines Jasper_Reports als pdf anschiebt.
Das SQL findet keine Daten... (weil die Umstände halt so sind...).

Durch einen kleinen Trick kann man das etwas benutzerfreundlicher gestalten:

Man kann in Jasper Reports Studio 6.6 einstellen, was bei "NULL" (data) passieren soll....

Report --> oben auf den Tabreiter (Namen des Reports) klicken --> dann rechts "Properties"

da habe ich jetzt bei "When no data type" ausgewählt: "All sections - no details"
standardmäßig steht das auf <NULL>

Dann kommt das Dokument nur mit Kopfzeile, Fusszeile - aber ohne weitere Daten...

- dann muss der Benutzer sich fragen, warum das PDF leer ist...

Hope that helps !

Samstag, 4. Mai 2019

Preview PDF in APEX Region

Cross-post - thanks to "Thinking Anew  - aber sorry, ich finde es interessant genug, es auch hier nochmals zu erwähnen.

Ich stolperte gestern über ein interessantes Feature zum Thema PDF:
Anzeige eines PDF-Dokumentes "inline" auf einer APEX Seite/Region:

Es basiert auf pdf.js von Mozilla und ist eine Kombination von SQL, Javascript und JQuery...

Schaut selbst hier https://fuzziebrain.com/content/id/1722/ (mit detaillierter Anleitung)

Dort ist auch eine Demo und ein Downloadlink der Demo hinterlegt:

Link: https://apex.oracle.com/pls/apex/f?p=34781
Username: demo
Password: demo
In der demo ist auch das "Blättern" in einem mehrseitigen PDF (NextPage, PrevPage) realisiert

Great Job Anew !!! Thanks a lot !

Ich habe es auf meine "eigene" Tabelle (MEINE_DATEIEN) angepasst...
das obige Beispiel basiert auf APEX_APPLICATION_TEMP_FILES

My environment: APEX 18.2, 19.1