In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-23 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "the method of sql multi-table row transfer and cascade row transfer". Interested friends may wish to have a look at it. The method introduced in this paper is simple, fast and practical. Now let the editor to take you to learn the "sql multi-table row transfer and cascading row transfer method"!
There are two tables A, A, B, A, B, A, A, B, B, A, B, A, B, B, A, B, Table B is required to display a list of clicks on all items of the day with the following code: declare @ sql varchar (2000) set @ sql='select CONVERT (varchar, a. [Time], 23) as time, total count (b.title) as' select @ sql= @ sql+' Sum (case b.title when''+ Title+''' then 1 else 0 end) as'+ ['+ Title+'] 'from (select distinct title from B) as B set @ sql=@sql+' from An as a left join B as b on a.AId=B.Aid group by CONVERT (varchar, a. [Time], 23) order by CONVERT (varchar (100), a. [Time], 23) desc' exec (@ sql)
Display result time Total Commodity 1 Commodity 2 Commodity 32013-11-1151042013-11-10132111
At this point, I believe that everyone on the "sql multi-table row transfer and cascade row transfer method" have a deeper understanding, might as well to the actual operation of it! Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.