HowTo

Sql Server tips

Posted on

Here are some basic tips for the use of SQL SERVER:   1. NOCOUNT SET NOCOUNT = OFF Don’t count the number of rows affected for big queries with a lot of joins. This will significantly improve performance   2. DATEADD SELECT count(personId) FROM persons WHERE creationDate > DATEADD(DAY, -14, CURRENT_TIMESTAMP); SELECT count(personId) FROM persons […]

HowTo

How To: search with grep

Posted on

To search through text you can use the grep command. It searches files and returns the lines of the file that match a certain string. The command has the following format: grep [options] pattern [file]     Here are some of the useful options I use:   Examples You can also search multiple files eg. all files […]