While choosing to define one” Dynamic menu'' based on one database of type OLEDB or ODBC. For information, examples of syntaxes are proposed.


Basic type

Examples of syntax

 

To enter the chain of connection, example:


DRIVER= {SQL Server}; server=AXRD-myPDMtools \ EPDM; uid=sa; pwd=axcdazerty; database=myPDMtools_2015;


To click on the button  to create pull-down menus.

For each pull-down menu, to inform the name of the property to be created and to click on  in order to inform request SQL to be carried out.


  


We use the text''VAL'' followed by the number of the menu to use the value of a preceding menu.

Here the result got in PropertyManager. The user selects in the list the first property” AX_MyCAD_Niv1_SQL'' then, according to the table SQL, the other properties gets information automatically:


 


Possible examples of requests :

Case with 2 drop-down lists displaying the families and under families.

  • Request for the families: select distinct FAMILY from DynamicList_SQL
  • Request for under families: select SOUS_FAMILLE from DynamicList_SQL where FAMILLE=' VAL1'
  • Request for the list: select distinct SOUS_FAMILLE_2 from DynamicList_SQL where FAMILLE=' VAL1' and SOUS_FAMILLE=' VAL2'

Case with 4 lists.

  • Request for the families: select distinct FAMILY from TABLE_FAMILLE
  • Request for under families: select distinct SOUS_FAMILLE from TABLE_FAMILLE where FAMILLE=' VAL1'
  • Request for the list: select distinct SOUS_FAMILLE_2 from TABLE_FAMILLE where FAMILLE=' VAL1' and SOUS_FAMILLE=' VAL2'
  • Request for the list: select distinct SOUS_FAMILLE_3 from TABLE_FAMILLE where FAMILLE=' VAL1' and SOUS_FAMILLE=' VAL2' and SOUS_FAMILLE_2=' VAL3'