Archive for March, 2009

 

Mar 31, 2009 in Database, SQLServer

  • — Run ‘SQL Server Configuration Manager’
    — click on
    ‘… Network Configuration’
    ‘Protocols’
    TCP/IP,
    Properties
    ‘IP Addresses’ tab.
  • — SQL service info:

    net start “SQL Server (SQLEXPRESS)”

    net start “SQL Server Browser”

  • — sqlcmd info:

    http://msdn.microsoft.com/en-us/library/ms162773.aspx

    sqlcmd -S tcp:localhost,2248 -l 60

    sqlcmd -S tcp:localhost,2248 -i script.sql

Mono debug info ..

Mar 24, 2009 in Uncategorized

http://www.mono-project.com/Debugging

Notes on Java Collections..

Mar 23, 2009 in Java, JavaUsage, Uncategorized

Collections characteristics:

  • synchronized (hashtable-yes, hashmap-no, vector-yes, arraylist-no)
  • directionality (iterators)
  • allow null values (hashtable-no, hashmap-yes)
  • preserve insert order
  • duplicates (set-no, list-yes)

Notes:

  • Collections interfaces: Collection, Set, List and Map.
  • To synchronize HashMap:

    Map m = Collections.synchronizeMap(hashMap);

  • Some implementations: HashSet, HashMap, ArrayList, LinkedList, TreeSet and TreeMap.
  • An ArrayList is resizable, where as, an array is not.
  • Hashmap overrides?

    The methods to override are equals() and hashCode().

  • Difference between Enumeration and Iterator?

    Enumeration is read-only. Iterator provides remove and add methods
    and it is fail-fast in multi-threaded configurations.