This type of box is used to visualize various types of large object fields (images, SVG, text, HTML code, etc.) stored in the database. Unlike the SQL-OBJ type, this box is capable of displaying multiple rows and columns. In other words, the SQL statement which defines the content of the box can return multiple rows, which will be displayed in the form of pages. In addition, multiple columns can be shown in each row, which will appear as tabs.
 

1 Introduction

This component is used to represent different documents saved to binary large object (BLOB) fields in different ways. This component is able to show various types of documents: image, SVG, video, plain text, email, audio, and PDF.


SQL-Blob can be used on Axional Forms. The possibilities are numerous:

  • Show multiple documents on a scrolling image reel. Images can be selected to expand the document and display it at a larger size:
  • Document Navigation: Show different documents with a pagination bar.
  • Image List: Show a list of images.
  • Select Document: Shows documents which can be selected, then executes statements upon selection, as shown below:

As a starting point, SQL-Tree requires the basic Axional Studio infrastructure, which includes:

  • Axional Studio Server, properly set up.
  • Dictionary database
  • A target database

** The previous configuration is explained in detail in the Axional Studio/Setup section.

 

2 Architecture

SQL-BLOB allows statement execution. Statements will return a result set with documents and their information.

The blob is configured on an object (wic_jrep_box_sqlblob) which contains various fields:

  • Options: Configures general features.
  • Preview: Configures the preview list shown.
  • Data: Configures the result set fields where the following elements are saved: document, document name, document media type, document information, and document preview.
 

2.1 Physical Model

wic_jrep_box_sqlblob
Label Description
ID Box identifier
Preview rows Preview rows

  • Default: 1
  • Values:
    • 0: All. All
    • 1: .
    • 2: .
    • 3: .
    • 4: .
    • 5: .
    • 6: .
    • 7: .
    • 8: .
    • 9: .
    • 10: .
Slide Indicates if the large display is shown

  • Default: 1
  • Values:
    • 0: Disable.
    • 1: Initially hidden.
    • 2: Initially visible.
Cache Cache

  • Default: 1
  • Values:
    • 1: Yes.
    • 0: No.
Select Select type

  • Default: 0
  • Values:
    • 0: None. None
    • 1: Single.
    • 2: Multiple.
Width preview Grid item width
Height preview Grid item height
Column image preview Column which contains the image preview. Required when Slide is disabled or hyde
Blob column Column which contains blob. If this column is empty, only the preview of the component will be shown.
Type This column is important for document display purposes.
Document name Document may be a file, image, etc.
Column title If this column is empty, titles will not be shown.
Description column Column with a statement containing blob description. To hide the description, this column must be empty.
SQL statement SQL statement

  • Format: SQLCOND_EXPR
User created User who created the record
Date created Date created
User updated User who last updated the record
Date updated Date updated
 

3 Implementation

The following sections show, step-by-step, how to create SQL blob components.

 

3.1 Show Multiple Documents on a Scrolling Image Reel

The user must open their dictionary application and go to the form object where they want to add a tree component, then follow these steps:

  1. Create an SQL-BLOB type box
  2. Enter the SQL-BLOB tab and add a new record with the following values:
    • Box Options:
      • Slide: Initially visible
      • Selection: None
    • Box Preview:
      • Row: 1
      • Grid item height: 0
      • Grid item width: 0
    • Box Data:
      • Column blob: blob_data
      • Document name: blob_name
      • Type: blob_type
      • Column title: blob_title
      • Column image preview: blob_img_preview
      • Column description: blob_description
    • Box SQL Statement:
 

3.2 Document Navigation: Show Multiple Documents with a Pagination Bar

The user must open their dictionary application and go to the form object where they want to add a tree component, then follow these steps:

  1. Create an SQL-BLOB type box
  2. Enter the SQL-BLOB tab and add a new record with the following values:
    • Box Options:
      • Slide: Initially visible
      • Selection: None
    • Box Preview:
      • Row: 1
      • Grid item height: 0
      • Grid item width: 0
    • Box Data:
      • Column blob: blob_data
      • Document name: blob_name
      • Type: blob_type
      • Column title: blob_title
      • Column image preview: (empty)
      • Column description: blob_description
    • Box SQL Statement:
 

3.3 Image List

The user must open their dictionary application and go to the form object where they want to add a tree component, then follow these steps:

  1. Create an SQL-BLOB type box
  2. Enter the SQL-BLOB tab and add a new record with the following values:
    • Box Options:
      • Slide: Initially visible
      • Selection: None
    • Box Preview:
      • Row: 1
      • Grid item height: 0
      • Grid item width: 0
    • Box Data:
      • Column blob: (empty)
      • Document name: (empty)
      • Type: (empty)
      • Column title: (empty)
      • Column image preview: blob_data
      • Column description: (empty)
    • Box SQL Statement:
 

3.4 Select Document: It is possible select the documents and execute statements with the selection

This process is used to select documents, then execute statements with them. The user must open their dictionary application and go to the form object where they want to add a tree component, then follow these steps:

  1. Create an SQL-BLOB type box
  2. Enter the SQL-BLOB tab and add a new record with the following values:
    • Box Options:
      • Slide: Initially visible
      • Selection: None
    • Box Preview:
      • Row: 1
      • Grid item height: 0
      • Grid item width: 0
    • Box Data:
      • Column blob: (empty)
      • Document name: (empty)
      • Type: (empty)
      • Column title: (empty)
      • Column image preview: blob_data
      • Column description: (empty)
    • Box SQL Statement:
    • Add JavaScript button using the function getBoxSelection(“BOX_ID”)
 

4 To Do

SQL-BLOB will soon offer new features with a wider set of functionalities and options, which are summarized below:

  • Add actions to each item.
  • Add links to each item.
 

5 Appendix

 

5.1 Selection of Documents:

The SQL BLOB uses the JavaScript function getBoxSelection to retrieve the documents selected.