search table form

everwhat

Board Regular
Joined
Jul 23, 2002
Messages
189
Is there a way to seach the entire table instead of selected columns from a form?
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
63,982
Office Version
  1. 365
Platform
  1. Windows
Please provide more details.
Can you explain the structure of your table, and maybe five an example of what you would be looking for?
It sounds like it is possible that you have some table design issues if you are trying to do something like this.
 

everwhat

Board Regular
Joined
Jul 23, 2002
Messages
189
I trying to create a form where user can search the entire table and not by a column.
For example:

search all columns/or table where there is "br214" or "br214*"
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
63,982
Office Version
  1. 365
Platform
  1. Windows
What exactly is "br214"? Is it some kind of code for soemthing?

Usually, a code like this should only be located in one field (column) in a table. If not, you may have some serious flaws with your table design.

Database design should follow the rules of Data Normalization. When these rules are not followed, seemingly simple tasks (like this) become much more difficult than they should be.
 

everwhat

Board Regular
Joined
Jul 23, 2002
Messages
189

ADVERTISEMENT

Table is created from data imported from outlook.
The Fields are "to", "from", "subject line", "date","message", 'received", "attachment" and "ID".
I would like to do a search in the table where, for example, search wherever the text of "BR234" or maybe "James" appears in the table. These items could be found in any columns/fields in the table. I would like to create a form where the search command and be executed.
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
63,982
Office Version
  1. 365
Platform
  1. Windows
I see...

Do you know how to create a search form to search a single column?
If so, what method are you using?

If you are using the method that you are using the form to build SQL or criteria on the fly, you just to need to add to it to search every possible column, i.e. instead of having criteria like:
[Field1]="br214"
you would have something like:
[Field1]="br214" or [Field2]="br214" or [Field3]="br214" or ...
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
63,982
Office Version
  1. 365
Platform
  1. Windows
I am not sure which method they are using (I don't have time to watch the 10 minute video right now), but the way I do is to use VBA to build the necessary SQL code "on-the-fly". Here is an example of one I have done in the past: http://www.mrexcel.com/forum/showpost.php?p=1619906

If you search the Access forum for threads with "Search Form" in the title, you will find many more threads on this topic.
 
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,168,109
Messages
5,857,441
Members
431,879
Latest member
KiwDaWabbit

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top