1. Create a database with the same name.
2. Set the test data to offline.
3. Delete the log file test_Data.LDF. The subsequent process is not enough.
4. Log On As a Super User in the query analyzer and execute the following stored procedures. You
Standard SQL statement type
1. query statement: mainly completed by the select keyword
2. transaction control statement: mainly completed by three keywords: commit, rollback, and savepoint
3. DML statements: these statements are mainly completed
When talking about the transaction log, you have to talk about the Checkpoint, or CKP for short. The transaction log and the Checkpoint both exist for the rapid recovery of the database. We need to know what the checkpoint is and what it has to do
Calculation Method of ID card verification code
1. Multiply the 17 digits of the previous ID card number by different coefficients. The number of I-bits is [2 ^ (18-i)] mod11. The coefficients from the first digit to the second digit are 7 9 10 5 8
The Code demonstrates brute-force cracking of MSSQL accounts and passwords, including the sa password of the administrator account.
There is a stored procedure for SQL Server Sa password cracking on the Internet. The method is to brute force crack
Our important data is stored in the MDF file. If the LDF file is lost and the MDF file is not, the data can be restored. If the LDF file is not lost, the MDF file is lost, and the LDF file is complete, you can also restore the data by some
Useful firstCopy codeThe Code is as follows:Use DatabaseUpdate news set author = 'jb51 'where author is nullIf you are incorrect, it means that you have made a mistake. Taking a closer look, we strongly recommend that you back up the database before
You must have had such troubles. The same table and different databases cannot be added to select insert.Therefore, you must enter a stored procedure to indicate that the insert statement will generate data for you.Of course, the number of data
Copy codeThe Code is as follows:-- Create a function with two parametersCreate FUNCTION [dbo]. [SplitToTable](@ SplitString nvarchar (max), -- input string@ Separator nvarchar (10) = ''-- segmentation Condition)-- The returned data is a
1. Start SQL Server Management Studio and log on using Windows authentication.
2. In the object Resource Manager window, right-click the server and select Properties to open the server Properties dialog box.
3. On the "Security" page, under
Database lock
Locks are a very important concept in databases. They are mainly used to ensure database integrity and consistency in multi-user environments. We know that data inconsistency occurs when multiple users can manipulate data in the same
DECLARE @ Date DATETIME
SET @ Date = GETDATE ()
-- The day before, the day before the given date
Select dateadd (DAY,-1, @ Date) AS 'previous Day'
-- The next day, the day after the given date
Select dateadd (DAY, 1, @ Date) AS 'Next Day'
GO
--
There is such a requirement that it creates an SQL Server query, including the cumulative value based on the event time. A typical example is a bank account, because every time you save and withdraw money at different times. For any account, you
1. Import or export data using the DTS designer
The DTS designer is powerful and supports multi-task operations. It is also a visual interface and easy to operate. However, there are not many people who know it. If you only want to move the table
Solution to SQL Server2000 suspension prompt:
1: Click Run in the Start Menu, enter regedit, and open the registry.
2: Expand HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/Session Manager
Click the FileRenameOperations key to delete the
One of the first relational dbms I used was Microrim 'sr: Base4000.R: Base. What is different from PC competitor dBase is that it is a real relational database management system, developed as a PC version of The NASARIM
In viewing Mysql file operations, it operates on files on different operating systems, in addition to using standard C Runtime library functions, including open, close, seek, etc, the file and directory operation functions under Win32 use CreatFile,
SQL Server port, we can use "Server network trial tool" and "client utility"To set, the setting method is:
Use "server network trial tool" and "client utility" respectively"Set the default port in "general options"-> "enabled protocol"-> "TCP/IP"-> "
LEAD and LAG functions in SQL SERVER
LEAD and LAG Functions
LEAD
Access Data in subsequent rows of the same result set, instead of using the self-join in SQL Server 2012. LEAD provides row access based on the given physical offset after the current
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.