Monday, February 16, 2009

Select Nth Row

SQL Query:
SELECT TOP 1 name FROM (SELECT TOP 9 name FROM master..syslogins ORDER BY name ASC) sq ORDER BY name DESC -- gets 9th row

MSSQL Injection Cheat Sheet

Looping in MSSQL
declare @index integer
set @index = 0
while @index < 10
begin
select 'loop counter = ', @index
set @index = @index + 1
end

Friday, February 6, 2009

Find computer using IP

On command prompt we can type this:

NSLOOKUP

it will show the computer name.

Tuesday, February 3, 2009

Cannot delete file: cannot read from source file or disk


When we receive this kind of error what to do??
The files within this folder is somehow corrupted.
First step is to fix it.
1. Open command prompt (Start -> Run -> cmd)
2. Type chkdsk /F E:\
It will fixed by itself.