473,405 Members | 2,279 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,405 software developers and data experts.

FIND_IN_SET only returns first record

If I've got:

Table: users
ID USERNAME EMAIL
1 syeargin st*****@yeargin.com
2 bwalkerton be**********@aol.com
3 rrandall rr@aol.com
....

Table: committees
ID COMM_NAME MEMBERS
1 legislative syeargin, bwalkerton
2 diversity syeargin, rrandall
3 executive syeargin, rrandall, bwalkerton
....
How can I write a query that follows the logic: Return all 'EMAIL'
values where 'COMMITTEE' is "legilsative"?
I've tried

SELECT COMM_NAME, EMAIL
FROM users INNER JOIN committees ON FIND_IN_SET(users.USERNAME,
members)
WHERE COMM_NAME = "legislative"
ORDER BY USERNAME ASC
But it only returns:

USERNAME EMAIL
syeargin st*****@yeargin.com

Or whatever the first value is. Any ideas?
---

Stephen Yeargin
st*************@gmail.com
Jul 20 '05 #1
0 1289

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

Similar topics

0
by: ebobnar | last post by:
Since find_in_set only searches by a single string, like: find_in_set('a', 'a,b,c,d'); is there a way to achieve functionality like you would if find_in_set could search by multiple strings,...
0
by: R U B'n | last post by:
Hi everyone, I have to make a (case-insensitive) search from a form with only one search string, e.g. "Doe Peters english California", which will search in several fields of my table for each...
0
by: Stephen Yeargin | last post by:
If I've got: Table: users ID USERNAME EMAIL 1 syeargin stephen@yeargin.com 2 bwalkerton benwalkerton@aol.com 3 rrandall rr@aol.com .... Table: committees
6
by: BlueDragon | last post by:
Grrr! I'm trying to run a script: print 'Declaring cursor' declare cInv cursor forward_only static for select distinct inv.company, inv.contact, inv.address1, inv.city,
6
by: Bob Hairgrove | last post by:
We are having problems retrieving diagnostic information from a DB2 database (server is 7.1.x, client is 8.1). The SQLGetDiagRec() function, when called on a valid DB2 statement handle, always...
1
by: db | last post by:
I am trying to build a db in Access2000 that will allow me to calculate month end returns on investments. I am about to try VBA for the first time, but wonder if I can do what I want by using...
4
by: kathy | last post by:
Working in a form, I have an Iif statement where if a date is not filled in, another field will show as a blank. If the date IS filled in, the 2nd field will show its actual value. The following...
0
by: Solution Seeker | last post by:
Hi, We are using vb.net for creating a Windows Application. We are using layered approach, with a UI layer, Logic, Db Access layer etc. we are encountering a peculiar problem when we try to...
7
by: Jimakos Bilakis | last post by:
Hi guys! I'm using the C++ Builder 6 Enterprise Edition where I create some tables in Paradox and with the help of a structure i pass my data from the form (Edit boxes) to the Paradox table with...
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: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.