Design
แนะนำใหม่ในบทเรียนนี้
| English | ความหมาย |
|---|---|
| validation/ˌvælɪˈdeɪʃn/ | |
| coding/ˈkəʊdɪŋ/ | |
| data type/ˈdeɪtə taɪp/ | A classification of values that determines their representation and permitted operations. |
| Boolean/ˈbuːlɪən/ | |
| field length | |
| check digit/tʃek ˈdɪdʒɪt/ | Last digit of a bar code. |
| range check/reɪndʒ tʃek/ | |
| type check/taɪp tʃek/ | |
| data capture form |
Plan every field
- Design decides the file structure, the validation 有效性检查 and the layouts before anything is built.
Fields and coding 编码
| decide | example |
|---|---|
| field name | Date_of_birth |
| data type 数据类型 | text, integer, decimal, date, Boolean 布尔型, currency |
| field length 字段长度 | Postcode: 8 |
- Coding: M/F, S/M/L. Saves space, speeds entry, eases validation; codes must be learned and detail can be lost.
What is an advantage of coding data, such as M and F?
ความยาก 1/5 · 100 เหรียญ + บอนัสน้อยๆ เมื่อทำสำเร็จครั้งแรกในวันนี้
Codes must be learned, and detail can be lost.
Validation
- Validation checks data is reasonable, not that it is correct.
| check | example |
|---|---|
| range | 0–100 |
| length | 8+ characters |
| type | age is a number |
| character | no digits in a name |
| format | DD/MM/YYYY |
| presence | not empty |
| check digit 校验位 | last digit of a bar code |
Shoe_size: whole sizes 1–13. Type integer; range check 范围检查 1 ≤ size ≤ 13; type check 类型检查.
Match each validation check to an example.
ความยาก 2/5 · 140 เหรียญ + บอนัสน้อยๆ เมื่อทำสำเร็จครั้งแรกในวันนี้
Each check tests a different property.
Validation checks that data is correct.
ความยาก 1/5 · 100 เหรียญ + บอนัสน้อยๆ เมื่อทำสำเร็จครั้งแรกในวันนี้
It checks that data is reasonable and sensible, not correct.
Which check uses an extra digit calculated from the others?
ความยาก 1/5 · 100 เหรียญ + บอนัสน้อยๆ เมื่อทำสำเร็จครั้งแรกในวันนี้
Used on bar codes and ISBNs.
Input and output formats
- Data capture forms 数据采集表: title, instructions, labelled boxes, drop-downs and tick boxes, logical order.
- Screen and report layouts: headings, clear fonts, spacing, only what is needed.
Which features make a good on-screen data capture form?
ความยาก 2/5 · 140 เหรียญ + บอนัสน้อยๆ เมื่อทำสำเร็จครั้งแรกในวันนี้
Clarity, not decoration.
A range check needs both limits. "Mark must be ≥ 0" alone lets 150 through.
Design each field's name, data type and length; use coding to save space; choose validation checks to keep data sensible; design clear forms and layouts.
เกิดปัญหาอะไรขึ้น? เฉพาะทีมเว็บไซต์เท่านั้นที่เห็นข้อมูลนี้