17.11.2014 Views

ChemOffice.Com - CambridgeSoft

ChemOffice.Com - CambridgeSoft

ChemOffice.Com - CambridgeSoft

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Creating Fields<br />

Administrator<br />

4. From the Machine Data Source tab, select the<br />

ODBC data source to access, and then click<br />

OK.<br />

NOTE: The ODBC data source dialog box shows all<br />

data sources known to ODBC, including ChemFinder,<br />

Access, and other file-based data sources. If you attempt<br />

to open one of these through the ODBC dialog, you get<br />

an error message. File-based data sources must be<br />

opened using Open Database, as described above.<br />

Whether you created a new database or are working<br />

in an existing one, you can add or remove fields in<br />

the selected table.<br />

You can choose from the following types of fields:<br />

Text field—Allows you to enter text such as<br />

names, comments, and references. A text field is<br />

fixed in length, and requires that you choose a<br />

maximum length (“width”) for any data item to be<br />

stored in the field. If you enter a width of 50, then<br />

you can’t store any item with more than 50<br />

characters in that field.<br />

You can specify widths of text fields as large as 254<br />

characters. If this is insufficient, you need to create<br />

a Memo/Rich Text field instead.<br />

Because the text field width cannot be modified<br />

after a field is created, it is often wise to err on the<br />

side of caution and make it longer than you need<br />

initially. On the other hand, larger field widths also<br />

create larger files and slower search times.<br />

NOTE: If the ODBC data source dialog does not<br />

show the database you seek, you may need to create a<br />

new data source. You can do this using the New button.<br />

For details, click the Help button in the ODBC dialog<br />

box.<br />

5. If you are prompted for a user name and<br />

password, enter it. If you don't know what<br />

name and password to use, see your System<br />

Administrator.<br />

6. Click on the name of the table you want to<br />

attach, then click OK.<br />

The source of the data to display on the form is<br />

indicated, but the form is still blank. To access the<br />

data, you need to draw some data boxes, and<br />

indicate what data to show in each of those boxes.<br />

NOTE: Non-ASCII characters will not display correctly<br />

in a data table text field.<br />

Integer field—Used for whole numbers such<br />

as ID's. All integers in ChemFinder are long, so can<br />

accommodate billions of values (2 32 of them).<br />

Double field—Used for real numbers such as<br />

physical constants and unit prices. Real numbers in<br />

ChemFinder are double-precision.<br />

Picture field—Allows you to store a Windows<br />

metafile, such as a spectrum or experimental setup,<br />

as a data item in a database.<br />

NOTE: A Picture box on a form may be used to display a<br />

static, decorative picture attached to the form, or it may be<br />

used to show pictures stored in the database which change as<br />

you move from record to record.<br />

290•Working with Data<br />

<strong>CambridgeSoft</strong><br />

Creating a Database

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!