4D v13Data Manipulation with 4D Server |
||||||||||||||||||||||||||
|
4D v13
Data Manipulation with 4D Server
|
Last Name | First Name | Salary | Department |
Howard | Mike | 39500 | Engineering |
Smith | John | 32500 | Production |
Doe | Jane | 43000 | Engineering |
Harrison | Bill | 34250 | Production |
Jones | Louise | 35000 | Production |
5. If all the six records are not shown, choose Show All from the Records menu and resize the window or columns if necessary.
You should have:
The records are now stored in the database on the server machine. If a second remote 4D were connected to the server machine, it could display the records you have just added. Conversely, if other clients were also entering records, you could choose Show All from the Records menu to display all the records, including the ones they had entered. Records stored on the server are accessible to all users.
Once you have entered records in the [Employees] table, you can search, sort, print, and otherwise manipulate the records. For example, let’s look for the employees of the Engineering department.
1. Click on the Querybutton in the toolbar.
The Query Editor appears:
2. Click on Department in the Fields list, on “is equal to” in the Comparisons list, then enter Engineering in the Value area.
3. Click Query.
The query is sent to 4D Server, then 4D Server replies to 4D. In the output form, you now have only the employees who work in the Engineering department.
4. To show all the records again, choose Show All from the Records menu.
1. Choose Charts... from the Tools menu.
The Chart Wizard appears:
You are going to create a 2D Column chart (which is the chart type selected by default).
2. Click on the Next > button.
You must select the data that you want to use to create a new chart.
3. Drag and drop the field Last Name to the area Categories (X Axis) and the field Salary to the list Values (Z Axis):
4. Click OK.
A Chart window appears, displaying the chart created according to your settings.
In just a few minutes, you have created a server database, defined a table, added records, then made a query and a chart using the data entered in the database.
It is now time to add a custom menu bar to your database. Go to the Adding a Custom Menu Bar section.
Product: 4D
Theme: 4D Server in 10 minutes