I have a database where the tables are as follows:
Table name: Name: Table Name: In a PHP page, I type __ < Em> _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ While I want that the resellers under that server ID To show the list. I'm not understanding how to write a MySQL query. Can you please help me? please? I have no way of changing the database table structure. I can not understand the query. Select Error: # 1242 - Subquery returns more than 1 line You can use it for your questions: userDB < / Code>
Column name: user_id (customer ID),
reseller_id (reseller who has contact with customer)
ServerDB
Column name: server_id (server id),
status (position above or below - if below 1 if 0 UP)
Usage DB_University
My name: user_id (customer ID),
server_id (server id)
table name: use db_desus Column name:
user_id (customer ID),
server_id (server id)
Note: useDB_january < There are 12 tables from / code> to
useDB_december .
server_id which is at the bottom (position 1)
| Serial no | Server ID below.
1 | 28839 |
2 | 20283 |
_ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ __ _ _
reseller_id
to userDB
WHERE user_id = (
select User_id from to
useDB_january
ou server_id like '17, 090 union
selection
User_id
to useDB_feb Feb
WHERE server_id as of '17090'
);
Select user_id, server_id, useDB_january to reseller_id, join userDB, useDB_january.user_id = userDB.user_idUnion Selection user_id, server_id , Reseller_id useDB_free Join with UserDB on usageDB_february.user_id = userDB.user_idUnion // ... all other months
No comments:
Post a Comment