Deprecated: Function set_magic_quotes_runtime() is deprecated in /nfs/c01/h08/mnt/2939/domains/ on line 14 Cidamon: Blog - Solution Cidamon Sat, 04 Nov 2017 23:32:49 GMT Get Keys of Dictionary data in c# A very simply way to collect the keys of a dictionary object to iterate through them is given bellow –

List<string> keyList = new List<string>(myDictionary.Keys);
for (int i = 0; i < keyList.Count; i++)
    int myInt = myDictionary[keyList[i]];
]]> Sun, 07 Nov 2010 09:13:50 GMT Hawk,2010-11-07:07eb181f72038e0cb54dbb0c8c485ee6/a718eef574f46e5d21f6611349579c4a
Dictionary, Hashtable and HashSet First of all HasSet is different then Dictionary and Hashtable cause it does not allow duplicate value and elements inside a HashSet cannot be accessed through indices, only through an enumerator (which is an iterator).

Now the difference between Dictionary and Hashtable is though Hashtable takes in a key/value pair, but it does so as generic objects as opposed to typed data in Dictionary. And another difference between Dictionary and Hashtable is, Hastable does not preserve the order in which items are added. On the other hand, the Dictionary data structure does keep items in the same order. Because of this behavior Hashtable is faster then Dictionary.

So, ultimately if we require a unique list without key/value pair we should use HashSet (it has been introduced from Framework 3.5). But if we need key/value pair and does not require to preserver the order items are being added we should use Hashtable. We should use Dictionary when we need to use key/value pair and also need to preserver the order items are being added into the list.

]]> Sun, 07 Nov 2010 09:12:29 GMT Hawk,2010-11-07:07eb181f72038e0cb54dbb0c8c485ee6/6cded68573cacfc72c46127ab7f4761b
HashSet in dot net 3.5 HashSet has been introduced in framework 3.5. It inherits the ICollection interface. HashSet cannot be accessed through indices, only through an enumerator.
HasSet is modeled upon mathematical set. It has methods such as Union, Intersection, IsSubsetOf, IsSupersetOf.
Add method of HashSet is boolean unlike List. HashSet allows only unique values. So, if the value already exists then “Add” method returns false.
So, if the list requires to contain unique values then it is better and faster to use HashSet instead of List.

]]> Sun, 07 Nov 2010 09:10:23 GMT Hawk,2010-11-07:07eb181f72038e0cb54dbb0c8c485ee6/893f4a25a69805b62370799ae4ddef45
Simple use of sqlplus Bellow are the steps required to execute a sql script using sqlplus

Start listener
$ lsnrctl start

Login to sqlplus
$ sqlplus username/password (if using sys then “sys/password as sysdba”)

Start the database

Turn on spool
sql>Spool on

Set output file
sql>Spool /home/oracle/log1

Execute sql script

Turn spool off
sql>Spool off

Shutdown database
sql>shutdown immediate

Exit sqlplus

Stop listener
$ lsnrctl stop

]]> Tue, 14 Sep 2010 13:57:41 GMT Hawk,1969-12-31:07eb181f72038e0cb54dbb0c8c485ee6/f9dbd153006401f1f213e66b9299e117
Wordpress &ndash; disabling Nofollow option in links First go to settings->Privacy settings. Select the following option -

“I would like my blog to be visible to everyone, including search engines (like Google, Sphere, Technorati) and archivers”.

Then go to appearance->editor and select Header.php. Here you may find something like “Robots:Noindex, nofollow” among the meta tags. Remove it.

]]> Wed, 07 Jul 2010 15:52:07 GMT Hawk,1969-12-31:07eb181f72038e0cb54dbb0c8c485ee6/c5250225339b04511664a922ef75eebb