development, when you want to write a query sql, you encounter such a problem: in the
project, there is a user table that stores users with different identities, and a similar field is probably uid (user id), name (user name), identity (user identity). There is another table external query this table, according to different identities to obtain different user information, how to achieve this situation in a sql statement?
here"s the thing. There is a table that stores fields similar to id,uid1,uid2, and both uid1 and uid2 correspond to the uid, of the first table. The uid, wants to find a result like id,uid1.name,uid2.name in a query
.