Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
greatnimesh
Starting Member
3 Posts |
Posted - 2007-05-01 : 16:23:22
|
Hi all,does anybody know how to write store procedure for searching keyword from different table.Store Procedure accept keyword as input parameter and find record from different tables and return number of rows that match search keyword. If anybody know then plz give me sample code for this problem.Thanks in advance....Bye---------Nimesh Patel |
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2007-05-04 : 09:40:10
|
See if this helps:[url]http://vyaskn.tripod.com/search_all_columns_in_all_tables.htm[/url]Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2007-05-04 : 10:09:27
|
I always wonder why this is neededIs this due to poor design? MadhivananFailing to plan is Planning to fail |
 |
|
spirit1
Cybernetic Yak Master
11752 Posts |
Posted - 2007-05-04 : 10:44:06
|
madhi:probabaly yes or he's just looking for a value and can't remember where it should be.i know that in one of our db's we have guid's a PK's in every table.and for example we use db search to find all tables that contain one keygreatnimesh:you could also use full text indexing._______________________________________________Causing trouble since 1980blog: http://weblogs.sqlteam.com/mladenp |
 |
|
Kristen
Test
22859 Posts |
Posted - 2007-05-04 : 11:06:07
|
I saw Free Text (the Index Server thingie) searching being used the other day. The application had checkboxes for specific scenarios, which mapped neatly on to specific values in various columns etc., but also had a "keywords" field on the form which basically did an OR CONTAINS on every column in Index Server.So click some checkboxes, and get a fast resultset, or just type some words and get probably the same answer, but slower!I can;t argue with the fact that that approach suits all types of users though!Kristen |
 |
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2007-05-05 : 03:50:35
|
Thanks. I thought only situation you need this is when you have similar tables that are created everymonth and if you are not sure which table has the value that you are looking for MadhivananFailing to plan is Planning to fail |
 |
|
|
|
|