Example 3 - SQL Data Source

Required apps

  • Power Custom Fields PRO™ or
  • Power Custom Fields


SQL Data Source has the following fields:

  • JNDI  represents the resource name of the database used
    Before setting the JNDI, configure it as described on the Data Source Configuration page. 
  • SQL Initial Script — represents the initial script which filters the result from the database for custom fields with or without autocomplete and "0" set for Min. chars.
  • SQL Autocomplete Script  represents the script made by user for custom fields with autocomplete. 


The following examples work for huge data sets.

For instance, you own a store and sell car parts and you have thousands of products and have to work with huge data sets. Power Custom Fields™ helps you save your time tremendously because you no longer need to go through a list of all products to select the necessary one. 

The app enables you to intervene in the process of data build-up even in the stages of the autocomplete. 

Example 1

Description

SQL Initial Script


The script above returns the following result:

 


SQL Autocomplete Script


The script for autocomplete returns the following results:

 

Example 2

Description

Note: you need to set the JNDI. Before setting the JNDI, configure it as described on the Data Source Configuration page.

SQL Autocomplete Script


The script for autocomplete returns the following results:

 


Example 3

Description

Note: you need to set the JNDI. Before setting the JNDI, configure it as described on the Data Source Configuration page.

SQL Initial Script 


The script returns the following results:

 

See also