Supported MySQL Statements and Uses

Supported MySQL Statements and Uses

MySQL is used in the following All On Mobile functionality:

  • Visibility
  • Paging
  • Off-line Databases' for dropdown menus and validation
  • Simple calculations (+ / - *)
  • Validation of a Field’s contents

Supported SQL Statement

MySQLExamplesNotes
SELECT, LIKE & WHERESELECT Employee_Name, Employee_DOB FROM Employees WHERE Employee_Name LIKE ‘Dave%’ LIMIT 20

It is important to LIMIT the results when the SELECT or LIKE functions are used. This prevents to many results from being displayed and slowing the mobile device.

NOTE:
Nested or chained SELECTS are not supported.

Where you are likely to return over 50 results use LIMIT to restrict the returned results to a manageable number.

=, !=, >, <, >=, ==, <>
  • SELECT * FROM Products WHERE Item_Id == 1
  • SELECT * FROM Products WHERE Price >= 30
  • SELECT * FROM Products WHERE Category != ‘Pet_Food’

A list of SQL Operators and their function can be found at:

https://www.w3schools.com/sql/sql_operators.asp

AND & ORSELECT * FROM Customers WHERE Country = 'Germany' AND (City = 'Berlin' OR City = ‘München')Remember to use parenthesis to form complex expressions otherwise you may end up with conflicting logical operators.
+ & - SELECT ${Price} + ${VAT} - ${Discount}Simple addition and subtraction operators.

It should be noted that mobile devices provide different versions of SQL Lite with the OS. Therefore the use of all SQL should be thoroughly tested in multiple data scenarios and on multiple device types prior to live use.