On 2/4/09 1:33 PM, "Bob Sneidar" <[email protected]> wrote:
> So using your method, my queries for a table of 25 employees with the
> associated departments data would look something like this:
>
> -- employee data
> put "SELECT employees.deptid FROM employees LIMIT 25" into
> mEmployeeQuery
>
> -- department data
> put "SELECT * FROM departments WHERE departments.deptid IN (" &
> mEmployeeQuery & ")" into mDepartmentQuery
Actually, Bob, you don't need to do two queries... you can do it in one...
also, you don't need to use LIMIT unless you specifically want less records
than what would normally be returned:
SELECT * FROM departments WHERE departments.deptid IN (SELECT
employees.deptid FROM employees)
HTH,
Ken Ray
Sons of Thunder Software, Inc.
Email: [email protected]
Web Site: http://www.sonsothunder.com/
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution