格式化输出: input格式化输出: name = input('请输入姓名:') name = input('请输入姓名:') Age = int(input('请输入年龄:')) job = input('请输入职业:') Hobby = input('请输入爱好:') msg = ''' ------------ info of %s Li ----------- Name : %s Age : %d job : %s Hobbie: %s ------------- end ------
create table ta1 ( id int identity(1,2) not null, name nvarchar(20) not null, identify varchar(18) primary key, birthday datetime not null, salary money not null check(salary >=0 and salary <=10000) ) //简单解释:创建“ta1”表: “id”列为自动增长数
) declare @cou int ) ' set @sql='select @count=count(*) from emp where id=@id' exec sp_executesql @sql, N'@count int out,@id varchar(20)', @cou out ,@id print @cou @cou接收 @count传出的值