Quick SQL 2000 Query Help Needed

Joined
Oct 7, 2008
Messages
3
Reaction score
0
Hi All,

I know this isn't really an asp.net question, but I couldn't find a proper place for this question (SQL Server questions). I figured I'd find the most seasoned MS developers here--I hope you can help.

I am using a SQL Full Text Catalog for a simple search of multiple tables on my website. I wrote a simple stored procedure that searches each table for the search text using contains(*, @searchText).

I am trying to modify one of the queries but cannot figure out the correct syntax:
Code:
SELECT c.ID, TABLENAME = 'CHAPTERS' from Chapters LEFT OUTER JOIN CASESTUDIES cs on cs.Id = c.caseId where cs.isPublished = 1 AND where contains(*, @searchText) 
		UNION ALL

Basically, I want to search the chapters table, but only to return the result when the chapter (Chapter.caseId FK -> Casestudies.Id PK) belongs to a published case study. Can anyone point me in the right direction?

Thanks in advance! Please let me know if you need any clarification.

Cheers,
Brett
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,012
Latest member
RoxanneDzm

Latest Threads

Top