当前位置:网站首页>Bi-sql select into
Bi-sql select into
2022-06-25 01:13:00 【Powerbi white tea】
SELECT INTO
SELECT INTO Statement can usually be used to create a backup . I believe that the small partners will not be unfamiliar with the concept of backup , We're doing it BI When reporting , Or build DAX Function procedures like to PBI File backup . occasionally , This is a good habit , We can roll back the version in time when an error occurs .
Again , stay SQL in , The concept of backup is also very important , For example, we need to back up the database regularly , Or you need to back up certain tables and data at certain times .
purpose
Can be used to select data and insert it into another table
You can create a backup of a table and archive it
grammar
SELECT Column (*) INTO New table [IN database ] FROM Source table
Using examples
Case data :
In the database of white tea machine , There is a name “TEST” The database of , There is a name “Customer” and “Fact” Case data for .
Example 1:
Create a “Fact20210814” Of Fact Table backup .
SELECT * INTO Fact20210814 FROM Fact
give the result as follows :
Example 2:
Create a “FactAmount” Of Fact Table backup , among Amount Greater than 1300.
SELECT * INTO FactAmount FROM Fact WHERE Amount>1300
give the result as follows :
Example 3:
take Fact Table and Customer Table for combined query backup , Name it FactDetail.
SELECT Fact.AMOUNT,Customer.* INTO FactDetail From Customer JOIN Fact ON Customer.IDKEY=Fact.IDKEY
give the result as follows :
This is white tea , One PowerBI Beginners .
边栏推荐
- 2022安全员-C证考试模拟100题及在线模拟考试
- 欢迎来到联想智能大屏的新世界
- How much commission does CICC wealth securities open an account? Is stock account opening and trading safe and reliable?
- The optimism about technology is making Dell achieve more than expected
- Simulation questions and answers of the latest national fire facility operator (senior fire facility operator) in 2022
- Preliminary understanding of qtoolbutton
- QT(36)-rapidjson解析嵌套的json
- Examination questions and mock examination for safety management personnel of hazardous chemical business units in 2022
- Mobile security tool apktool
- Programmer: did you spend all your savings to buy a house in Shenzhen? Or return to Changsha to live a "surplus" life?
猜你喜欢
Cobalt Strike安装教程
Text border format and text block of rich text
The latest QQ wechat domain name anti red PHP program source code + forced jump to open
Syntax highlighting of rich text
[redis realizes seckill service ④] one order for one person, and cannot be purchased repeatedly
Bi-sql between
Powerbi - for you who are learning
2022年危险化学品经营单位安全管理人员考试试题及模拟考试
Mobile security tool jar
[redis realizes seckill business ③] specific implementation of optimistic lock for oversold problem
随机推荐
placeholder
Introduction to smart contract security audit delegatecall (2)
I brush the question I - copy the linked list with random pointer
[microservices sentinel] cluster link | microservices cluster environment construction
Distinguish between i++ and ++i seconds
2022R1快开门式压力容器操作考题及答案
I 刷题 I — 复制带随机指针的链表
Add information on the left and add parts on the right of the status bar
Golang示例续期锁:Redis+Channel+sync.Mutex
Text editor for QT project practice - Episode 12
Use of file class filenamefilter & filefilter in io
Mobile security tool jar
Rich text tables, lists, pictures
重磅:国产IDE发布,由阿里研发,完全开源!(高性能+高定制性)
QT electronic clock
JS Chapter 1 Summary
Scala sample object
Scala classes inherit multiple attributes
Leetcode 1248. 统计「优美子数组」(害,突然发现只会暴力枚举了)
欢迎来到联想智能大屏的新世界