Sheen Space

Get table row count – the fast way

leave a comment »

How to get row count of a table in SQL Server quickly? Easist way, of course, is “SELECT COUNT(*) FROM <Table Name>”, most of you would say. However, there is another way, even easier and faster, that is “sp_spaceused <Table Name>”. It is shorter, and more importantly, it returns instantaneously when you try to get information of a huge table (millions of lines).

Experiment on a table with 2.8 million rows shows that time spent with COUNT(*) method is 3 seconds. Actual time taken is dependent on your hardware environment.

MSDN link: http://msdn.microsoft.com/en-us/library/ms188776.aspx

A good article explaining how it works: http://www.sqlservercentral.com/articles/T-SQL/67624/

Written by Ying

04/10/2012 at 09:18

Posted in Technology

Tagged with

Cloud based Team Foundation Server is out

leave a comment »

This might be good news to users of Microsoft Team Foundation System. The cloud based system is in preview stage. Everyone can sign up and try it out. The trend of cloud computing, or “utility computing”, name I like more, is unstoppable.

https://tfspreview.com/

Written by Ying

02/10/2012 at 09:08

Posted in Technology

Tagged with ,

Extraordinary Achievement by Michael Phelps May Be Due to Arsenic in His DNA

leave a comment »

http://xichenqbb.blogspot.co.uk/2012/08/extraordinary-achievement-by-michael.html

The physical and physiological limitations of human athleticism are of great interest for both scientific and sociological reasons. An efficient method to test such limitations is having human participants compete in sports such as those included in the Olympic Game. Recently American swimmer Michael Phelps showed extraordinary athleticism in the Olympic Game, winning over 20 medals among which 16 are gold. This greatness has never been achieved before and therefore is highly likely due to factors other than training, which all previous athletes have undergone. This seemingly impossible achievement is reminiscent of the robust growth of the recently discovered bacteria GFAJ-1 in arsenic-rich media. Since the existence of arsenic in the DNA of GFAJ-1 has not been conclusively disproved, it is reasonable to assume, or at least to suspect, that the DNA of GFAJ-1 contains arsenic. Similarly, we propose that part of the DNA of Michael Phelps consists of arsenic, and that this element strongly contributed to his success. Although our theory has no evidence, it can nevertheless be ruled out. Our finding illustrates an exciting opportunity to enhance the athleticism among humans, although safety and ethic issues should be fully addressed prior to its worldwide application.

I hereby show my finger to the disgusting Nature magazine and all other defaming western media.

Shame On You Nature

Written by Ying

03/08/2012 at 20:03

Posted in Technology

Tagged with ,

Improved hardware-accelerated graphics in Windows 8 (Compared to Windows 7)

leave a comment »

A very good article describing improved hardware-accelerated graphics in Windows 8 is published on Microsoft “Building Windows 8″ blog today. It is a long, but definitely not tedious technical post. Have a read and you will be excited, for one more reason, about Windows 8.

Hardware accelerating everything: Windows 8 graphics

Written by Ying

23/07/2012 at 22:32

Posted in Technology

A good programming series – “Quality Matters”

leave a comment »

Quality Matters
by Matthew Wilson

Written by Ying

12/07/2012 at 17:30

Posted in Technology

Link: 2012-June

leave a comment »

A brief note on object mortality

Joe Duffy

Author explains “premortem finalization” .Net uses and its disadvantages comparing to “postmortem finalization”. Although .Net doesn’t provide way to use postmortem finalization, things we can learn is that keep finalizable class simple.

Sayonara volatile

Joe Duffy

Volatile is evil

Anatomy of a Stack Smashing Attack and How GCC Prevents It

Oliver Mueller

Latest good article explaning how stack overflow attach works and modern C++ compilers’ detection mechanism.

Scope Regions in C++

Dan Saks

This is a very good and clear article about C++ scope and linkage for beginners. Sometimes it is not bad for experienced C++ programmers to go back and briefly review these concepts. The other parts of this series are posted here:
Linkage in C and C++
Storage class specifiers and storage duration

Written by Ying

23/06/2012 at 16:42

C++ Accelerated Massive Parallelism: Digest

leave a comment »

C++ AMP is coming with Visual Studio 2011. Here are information and good articles introducing it:

Herb Sutter: Heterogeneous Computing and C++ AMP

MSDN overview page

PDF: “C++ AMP : Language and Programming Model” – the specification

A list of articles:

http://blogs.msdn.com/b/vcblog/archive/2011/06/15/introducing-amp.aspx

http://msdn.microsoft.com/en-us/magazine/hh882446.aspx

http://msdn.microsoft.com/en-us/magazine/hh882447.aspx

Written by Ying

26/05/2012 at 22:46

Posted in C++, Programming, Technology

Tagged with

Follow

Get every new post delivered to your Inbox.