The jBASE Query Language (jQL) is a powerful and easy to use facility, which allows you to retrieve data from the database in a structured order and to present the data in a flexible and easily understood format. You can enter jQL Commands from your terminal or embed jQL Commands in applications programs, procs and paragraphs to access data in jBASE files. The language is characterized by the use of intuitive Commands that resemble everyday English language Commands. You might for instance manage a retail department and need to review a particular set of figures, which requires the phrase: "Show me the sales figures for January sorted in date order."
The jQL Command would look like this:
LIST SALES WITH MONTH = "JANUARY" BY DATEBy using the jQL Command LIST with a file named SALES and your predefined data definition records such as MONTH and DATE, you can construct complex ad-hoc reports directly from the Command line interface (>). You can also choose how you want the information presented; displayed directly to your printer or to your screen; listed in date order, or in descending or ascending order. The choice is yours as jQL contains a rich range of commands for listing, sorting, selecting and controlling the presentation of your details and is a safe language for end users. With the exception of the "EDELETE" Command, jQL will not alter the contents of the source data files.
All jQL Command sentences begin with a verb-like Command such as LIST or SELECT, followed by a file name such as SALES or PERSONNEL, and then a series of qualifiers and modifiers with which you control elements such as eligible data, report formatting, any totals that you want to appear and so on.
Most data files on the system will have two assigned storage areas:
- For the data (the data section) and
- For the data definition records (the dictionary section)
FOR EXAMPLE:
- They allow you to specify the position of the data in a record (its field number)
- A narrative to be used as a column heading any input or output conversions required (such as for dates) the data type (left or right justified, or text that will break on word boundaries)
- A column width, used in the reports
- Input and output conversion codes can also be used to manipulate the data by performing mathematical functions, concatenating fields, or by extracting specific data from the field.
0 comments:
Post a Comment