The Where clause is great. It helps you filter out items from a table, leaving only the records you want. But sometimes you are not looking for the actual records. 196 more words
Tags » SQL Query
How to Calculate Age though Sql?
MyTableName:- field is Id, Name, DateOfBirth.
Select CONVERT(int,ROUND(DATEDIFF(hour,DateOfBirth,GETDATE())/8766.0,0)) AS AgeYearsIntRound from dbo._ABEntity1
Select CONVERT(int,ROUND(DATEDIFF(day,DateOfBirth,GETDATE())/369,0)) AS AgeYearsIntRound from dbo._ABEntity1… 23 more words
When we need to execute any SQL statement with other user context we have to use EXECUTE AS statement to impersonate other user access.
Impersonation can be done as different login or different user.This is similar to RunAs in windows context… 99 more words
In this article we are going to cover How to Quick Search Anything in Database.
191 more words
In this post we are going to discuss following points:
As SQL query performance improvement is a very debating topic between developers and the other user community. Users always wants a fast response on their data retrieval action and developers put forth their best efforts to provide the data in the minimum time span, however, there is no straightforward way to define what is the best performance. 1,091 more words