How to enable SQL Server Agent XPs

Some time we want to run special tools in SQL Server like mentainance tools  but to run it you server must run sql server Agent XPs which on of advance configuration so to enable it we write followig SQL commands

 

sp_configure ’show advanced options’, 1;

Go;

reconfigure;

Go;

sp_configure ‘Agent XPs’, 1 ;

Go;

reconfigure;

Go;

 

and now we can run our sql server tools ;)

Action Script 3.0 Session Slides

This slides contain first session of AS 3.0 course training I gave in Sharek center

Download File

C# const DataType vs static readonly DataType

I always wondered about the differance between using const and static readonly data type declarion, where both used in the same way so I made some search about differance and when to use each one of it, and thereis what I found:

 

  • At a high level, obviously  constant dealt at compile-time, and static read-only field are set  at the time they are evaluated run-time.
  • Any change on constant value require recompile every library that use it because it reference to constant field value, while static read-only reference to the field not the value. so static read-only field maintainable.
  • Read-only types can hold reference types whereas  constant support value types plus .Net special ones string and null.
  • Rea-only can set wherever or however developer chose maintaining they can inside constructors, also read-only types can hold calculated values.

So from previous point I found the constant value should be used when it is unlike ever the data change or there is no external library/reference consumptions, in other situations use static read-only fields.