📄 benchmarkdataload.cmd
字号:
@Echo Off
REM ***************************************************************************
REM ** File: _BenchmarkDataLoad.cmd
REM ** Name: BenchmarkDataLoad
REM ** Desc: Load data for Benchmark.
REM **
REM ** Date: 11/6/2001
REM **
REM **************************************************************************/
REM Use the following section to set the server and sa password
REM of the SQL Server on which you want to create the database.
setlocal
REM set SERVER=%1
REM set LOGIN=%2
REM set PWD=%3
set SERVER=localhost
set LOGIN=sa
set PWD=
set DBNAME=petshop
@Echo.
@Echo *******************************************************************************
@Echo * Microsoft.NET PetShop Blueprint Application - Benchmark Database Setup *
@Echo * *
@Echo * BENCHMARK DATA LOAD *
@Echo * 50,000 rows will be inserted into the Items table *
@Echo * 50,000 rows will be inserted into the Inventory table *
@Echo * 1,000 rows will be inserted into the Products table *
@Echo * *
@Echo * DATABASE CHANGES *
@Echo * Search results are limited to the top 25 results. *
@Echo * Get Item results are limited to the top 25 results. *
@Echo * Get Product results are limited to the top 50 results. *
@Echo * *
@Echo * This script will load the database with data for the Benchmark *
@Echo * If you wish to cancel, press [CTRL]-C and terminate the batch job. *
@Echo * *
@Echo *******************************************************************************
@Echo.
pause
@Echo.
@Echo.
@Echo *******************************************************************************
@Echo * Delete original Data... *
@Echo *******************************************************************************
@Echo.
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i TruncateTables.sql
@Echo.
@Echo.
@Echo *******************************************************************************
@Echo * Inserting the Benchmark Data... *
@Echo *******************************************************************************
@Echo.
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "Create 1,000 Products.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "Create 50,000 Items.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "Create 50,000 Inventory.sql"
@Echo.
@Echo.
@Echo *******************************************************************************
@Echo * Updating the Stored Procedures... *
@Echo *******************************************************************************
@Echo.
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upItemGetList_ListByPage_Benchmark.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upProductGetList_ListByPage_Benchmark.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upProductSearch_ListByPage_Benchmark.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upItemGetList_Benchmark.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upProductGetList_Benchmark.sql"
osql -S %SERVER% -U %LOGIN% -P %PWD% -d %DBNAME% -i "upProductSearch_Benchmark.sql"
@Echo.
@Echo *******************************************************************************
@Echo * *
@Echo * Benchmark Database Setup Script Complete *
@Echo * *
@Echo *******************************************************************************
@Echo.
pause
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -