Bài tậ p : Cơ sở dữ liệu Northwind
1. declare @v_proname char(40)
set @v_proname='konbu'
select * from products where productname=@v_proname
SELECT title_id FROM titles
2. declare @v_title char(30)
set @v_title='Owner'
select * from Customers where ContactTitle=@v_title
3. select lower(productname) from products
4. select datepart(dw,getdate()), datepart(dy,getdate()), datepart(yy,getdate()), datepart(qq,getdate()), datepart(hh,getdate())
5. select dateadd(dd,25, getdate())
6. select @@identity+1
insert into jobs values('New job', 10, 20)
select @@identity+1
7. exec sp_addlogin 'ten','ten'
Nuk ka komente:
Posto një koment