Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Which is better for performance

Status
Not open for further replies.

phunkyb

Technical User
Dec 30, 2003
14
0
0
AU
Hello everyone
i am creating a sports database and the games can take place at day or night. Do you think that using a true/false statement or creating another table for day/night would be better?
Thanks for your input
 
From a pure performance perspective, the boolean field will be faster. But that won't be a concern in the kind of database you're building. I would make it a text field that gets either "Day" or "Night" in there. As long as your users only touch forms you won't have to worry about typos, because you can just put those values in a combo box (no real need for a lookup table with only two values that won't ever change).

Jeremy

==
Jeremy Wallace
AlphaBet City Dataworks
Access Databases for Non-Profit Organizations

Please post in the appropriate forum with a descriptive subject; code and SQL, if referenced; and expected results. See thread181-473997 for more pointers.
 
If you do do this, keep it on one table if that's it.

Use Day/Night or even 1 2 (you could lik this to a table that just supplies the data, but not realy needed)

In either case, set the field to the lowest possible size
Text/5 char or Number/Byte and set the indexed to Yes (duplicates allowed)

TBH, Access is pretty quick until you start calling complex code that loops about 20 times for each record on a report with 5,000 records on it....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top