Searching database

  • Thread starter Thread starter Brian Royston
  • Start date Start date
B

Brian Royston

I have a membership database I am using to store members details one of the
questions asked is are your happy to let other members see your contact
details a simple yes no answer on the registration form.

What I would like to do is setup a search using first and second name or
both, which I have done using the wizard but can't work out how to only
return the results if the person being searched for has agreed to share
their details.

So how do I return the details only if the yes no field = YES?
 
In your DB it is best to make the Yes/No Field a TRUE/FALSE field
- default FALSE, set it to True in their registration update
In your SQL string to select results (say the Field is named "ContactOK") use a criteria for the field

Select * FROM TableName WHERE ContactOK=TRUE AND ...other criteria here...

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
_____________________________________________


|I have a membership database I am using to store members details one of the
| questions asked is are your happy to let other members see your contact
| details a simple yes no answer on the registration form.
|
| What I would like to do is setup a search using first and second name or
| both, which I have done using the wizard but can't work out how to only
| return the results if the person being searched for has agreed to share
| their details.
|
| So how do I return the details only if the yes no field = YES?
|
|
 
Back
Top