OpenOffice.org 2.x Guía de usuario Pagina 399

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 508
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 398
Chapter 7: Databases and Data Sources
6. Click Save.
An OpenOffice.org Base window will open for the new database. At this point, we have
created an empty database file.
Creating a table
An empty database file is not much use. The next step is to create a table in which to store the
data. In previous versions of OpenOffice.org Base, we would connect to an external data
source such as Adabas, JDBC, ODBC, dBase, ADO, Text, Spreadsheet, or Address Book. We
can still do this (as discussed below) but, as mentioned above, we can also create HSQL
tables that will reside in the database file itself.
Each field in a table is represented in the design of that table by a row. Each row has fields
for Field Name, Field Type and Description. Description is an optional field that can be
used to provide a description of what the field is used for.
Additionally, each of the table fields have Field Properties. These vary based on the type of
field.
The main table in our Calendar database is the Appointments table and the
following steps explain how that table was created.
1. In the database window, click the Tables icon in the left-hand column.
2. In the Tasks pane at the top of the window, click the Create Table in Design view
icon. A Table Design window opens.
3. In the first row in the Table Design window, in the Field Name box, type ID and hit
the Tab key on the keyboard.
4. In the Field Type box that the cursor jumps to, choose Integer [INTEGER].
5. In the Field Properties section at the bottom of the window, change the value for
AutoValue to Yes.
6. Create the fields listed below by repeating steps 3 through 5 using the information in
the table. Obviously, do not go back to the first row in the design window and do not
set the AutoValue option on any other fields to Yes.
Field
Name
Field Type Field Properties
Subject Text [VARCHAR] Entry Required = Yes; Length = 50
Location Text [VARCHAR_
IGNORECASE]
Entry Required = No; Length = 50
Start date Date [DATE] Entry Required = Yes
OpenOffice.org User Guide for 2.x 365
Vista de pagina 398
1 2 ... 394 395 396 397 398 399 400 401 402 403 404 ... 507 508

Comentarios a estos manuales

Sin comentarios