Forgive me if I've made a stupid mistake here, I'm quite new to mysql, and programming in general.
Anyways I'm doing a query to find "username" (primary key) from a table named user where "username" is not equal to "username" (primary key) in a table named admin.
Here's my query:
SELECT user.username FROM user, admin WHERE user.username <> admin.username
The result from this is used to build a check list of all the users who are not admins, and when checked and submitted the username is entered into the admins table, and the non-admin user list is built again
This seemed to work the first time I tried it, but I only had one username in admin. After that the same query returned huge lists of duplicate values 😕
So where'd I go wrong? Is there a way I can successfully execute this script?
Any help would be greatly appriciated
🙂 thanks