|
|
|
|
Menu |
|
|
Home |
| |
|
Discussions |
| |
|
Tools |
| |
|
Affiliates |
| |
|
Content |
| |
|
Info |
| | |
|
|
|
|
|
User Info |
|
Membership:
Latest: MichaelSnaRe
New Today: 0
New Yesterday: 0
Overall: 9144
People Online:
Visitors: 63
Members: 0
Total: 63
|
|
|
|
|
|
Full disclosure |
|
|
|
|
|
|
|
|
|
IT Security and Insecurity Portal |
|
|
Union... |
|
Posted: Thu Nov 29, 2007 10:30 pm |
|
|
guitarist809 |
Regular user |
|
|
Joined: Nov 29, 2007 |
Posts: 6 |
|
|
|
|
|
|
|
I understand most MySQL syntax, but when I found about unions, I became lost. If someone could explain them to me I'd be happy
Help will be greatly appreciated
Thanks,
Guitarist809 |
|
|
|
|
Posted: Wed Jan 23, 2008 2:29 pm |
|
|
ploert |
Regular user |
|
|
Joined: Jan 23, 2008 |
Posts: 21 |
|
|
|
|
|
|
|
A UNION simply chains the result of two SELECT statements
Given table ADMINS
id...name...password
01..admin1..blabla
02..admin2..blabla
Given table USERS
id...name...password
01..user1...blabla
02..user2...blabla
SELECT name FROM ADMINS UNION SELECT name FROM USERS
will produce:
admin1
admin2
user1
user2 |
|
|
|
|
www.waraxe.us Forum Index -> MySql
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
All times are GMT
Page 1 of 1
|
|
|
Powered by phpBB © 2001-2008 phpBB Group
|
|
|
|
|
|
|