oracle
我想用sqlplus
和batch
文件创建新表。
sqlplus user/password @create_tables.sql
成功了
但这不是我想要的。我希望用户输入年份。我的批处理文件看起来像:
@echo off
set /p year=__YEAR (YYYY)?
sqlplus user/password
create table data%year%
(Nama varchar2(25),
value number);
echo Successfull
pause
脚本在这里停止
SQL*Plus: Release 10.2.0.1.0 - Production on Sun Aug 25 06:07:26 2013
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL>
怎么了?