473,386 Members | 1,708 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

design question - several related variables - in one database field or separate fields

Say you want to display and search "services offered". There are a finite
number of services offered. You want to be able to search the database for
each service offered separately.

Given the above requirements, is it better to group them in one field and do
a LIKE % query or have each a seprarte database field?

I think separate fields but want opinions as I am somewhat new to this.

Thanks!
Jul 17 '05 #1
2 1540
On Fri, 23 Jul 2004 16:36:59 -0400, "NotGiven" <no****@nonegiven.net>
wrote:
Say you want to display and search "services offered". There are a finite
number of services offered. You want to be able to search the database for
each service offered separately.

Given the above requirements, is it better to group them in one field and do
a LIKE % query or have each a seprarte database field?

I think separate fields but want opinions as I am somewhat new to this.

Thanks!


if it's a finite number then use seperate fields.

if the possibilities are YES or NO for each service then use binary
fields (1 or 0) - eg. INT(1), CHAR(1) or something like that - this
will speed up searches considerably (as long as you remember to index
all the fields you will be including in your 'WHERE' statement).

Jul 17 '05 #2
good advice - thanks
"Herbie Cumberland" <sp******@skipraider.com> wrote in message
news:f3********************************@4ax.com...
On Fri, 23 Jul 2004 16:36:59 -0400, "NotGiven" <no****@nonegiven.net>
wrote:
Say you want to display and search "services offered". There are a finitenumber of services offered. You want to be able to search the database foreach service offered separately.

Given the above requirements, is it better to group them in one field and doa LIKE % query or have each a seprarte database field?

I think separate fields but want opinions as I am somewhat new to this.

Thanks!


if it's a finite number then use seperate fields.

if the possibilities are YES or NO for each service then use binary
fields (1 or 0) - eg. INT(1), CHAR(1) or something like that - this
will speed up searches considerably (as long as you remember to index
all the fields you will be including in your 'WHERE' statement).

Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

36
by: toedipper | last post by:
Hello, I am designing a table of vehicle types, nothing special, just a list of unique vehicle types such as truck, lorry, bike, motor bike, plane, tractor etc etc For the table design I am...
8
by: mark | last post by:
Access2000 How do I write a query that combines the CTC field from each record below into one record? I need to concatenate the CTC field with a separator, like below: ...
3
by: cassandra.flowers | last post by:
I'm designing a database because I have to do it for the preperation work for my A-Level ICT exam. The database is for a building company. It has to store information on building projects...
8
by: Stewart Allen | last post by:
Hi Just asking for ideas on table design. The design I have is as follows: *tblBuildData* BuildID (PK) AutoNumber ManufactureDate SerialNumber
3
by: James Armstrong | last post by:
Hi all, (warning - long post ahead) I have been tasked with designing a database for my company which will store trade information (it is a financial firm). It will need to export this info...
9
by: Hasan O. Zavalsiz | last post by:
Hi , i am trying to figure out which approach is better to use . let me explain the scenario. i am using the "Nortwind" database . in this database i have "Customers " table .The following is the...
29
by: MP | last post by:
Greets, context: vb6/ado/.mdb/jet 4.0 (no access)/sql beginning learner, first database, planning stages (I think the underlying question here is whether to normalize or not to normalize this...
23
by: JohnH | last post by:
I'm just recently come to work for an auto brokerage firm. My position involves performing mysterious rites, rituals and magick in order to get information out of their access database. This is...
12
by: nyathancha | last post by:
Hi, I have a question regarding best practices in database design. In a relational database, is it wise/necessary to sometimes create tables that are not related to other tables through a...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.