Home > Database > Mysql Tutorial > 行转列:SQL SERVER PIVOT与用法解释

行转列:SQL SERVER PIVOT与用法解释

WBOY
Release: 2016-06-07 17:37:20
Original
1132 people have browsed it

在数据库操作中,有些时候我们遇到需要实现行转列的需求,例如一下的表为某店铺的一周收入情况表: WEEK_INCOME(WEEK VARCHAR(10) ,INCOME DECIMAL )

在数据库操作中,有些时候我们遇到需要实现“行转列”的需求,,例如一下的表为某店铺的一周收入情况表:

WEEK_INCOME(WEEK VARCHAR(10),INCOME DECIMAL)

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template