Monday, December 2, 2013

PowerShell - list all documents under directory

Few days ago i had to read some docs in solution, so i decided to write simple script to list all *.doc and *.docx files under specyfic directory. Here it is: # View all text files $Dir = get-childitem E:\ClientSolution -recurse # $Dir |get-member $List = $Dir | where {($_.extension -eq ".doc") -or ($_.extension -eq ".docx")} $List | format-table fullname

Wednesday, September 5, 2012

ASP.net Version 4 with IIS7

http://stackoverflow.com/questions/6104230/asp-net-version-4-with-iis7

Monday, July 2, 2012

TSQL - Reset Table Identity

http://blog.sqlauthority.com/2007/03/15/sql-server-dbcc-reseed-table-identity-value-reset-table-identity/

Sunday, March 18, 2012

Awesome Regex tester

Regular expression is an important issue in .NET. Here we can find a fine tool to check our patterns, enjoy

Saturday, December 3, 2011

Drop all constraints from database

-- Drop all constraints declare @sql varchar(1024) declare curs cursor for select 'ALTER TABLE '+tab.name+' DROP CONSTRAINT '+cons.name from sys.objects cons,sys.objects tab where cons.type in ('C', 'F', 'PK', 'UQ', 'D') and cons.parent_object_id=tab.object_id and tab.type='U' order by cons.type open curs fetch next from curs into @sql while (@@fetch_status = 0) begin exec(@sql) fetch next from curs into @sql end close curs deallocate curs

Friday, December 2, 2011

Svn Error: Server sent unexpected return value (403 Forbidden) in response to OPTIONS

The fix is to navigate to All Programs --> TSVN --> settings -->Saved Data ---> Clear the Authentication Data. Secondly we should enter proper credentials and the problem should vanish. For more read the discussion at StackOverflow