mysql> describe skin; +--------------+------------------+------+-----+---------+----------------+ | Field | Type | Null | Key | Default | Extra | +--------------+------------------+------+-----+---------+----------------+ | skinid | int(10) unsigned | NO | PRI | NULL | auto_increment | | skin_name | varchar(15) | NO | | NULL | | | skin_way | varchar(32) | NO | | NULL | | | date_skin | int(10) unsigned | NO | MUL | NULL | | | skin_count | int(10) unsigned | NO | | NULL | | | uid_skinfrom | int(10) unsigned | NO | MUL | NULL | | | skcatid_skin | int(10) unsigned | NO | | NULL | | +--------------+------------------+------+-----+---------+----------------+ It is necessary to drag out the values ​​from this TB, in one line, but in TWO columns:
Need to get the value of skin_count but for different skinid. In the example I will give two requests that need to obezhenit. I know that you can use the reassignment of the parameters mysqli_stmt_bind_param (), but is it possible to pull out two values ​​in one line?
Here are examples of requests (they need to be combined into one, well, uh, if this is possible?):
select skin_count from skin where skinid=$_SESSEION['cur_skin']; select skin_count from skin where skinid=$new_skinid; I want to get something like
+--------------+-----------+ | oldcount | newcount | +--------------+-----------+ | 48 | 25 | +--------------+-----------+ How to do this as ʻami or nested questions or something else?