Great directors and actors

Just a list for myself, because I keep forgetting names.

Directors
  • Darren Aronofski: Pi, Requiem For A Dream, The Wrestler
  • Christopher Nolan: Memento, Insomnia, Batman Begins, The Prestige, The Dark Knight
  • Clint Eastwood: The Bridges Of Madison County, Mystic River, Million Dollar Baby, Letters From Iwo Jima, Changeling, Gran Torino
  • David Fincher: Se7en, The Game, Fight Club, Zodiac, The Curious Case Of Benjamin Button
Actors
  • Christian Bale: Empire Of The Sun, Equilibrium, The Machinist, Batman Begins, Harsh Times, The Prestige, 3:10 To Yuma, The Dark Knight
  • Joseph Gordon-Levitt: Mysterious Skin, Brick, The Lookout

Oracle SQL Developer screen redraw glitch

Perform the following steps to fix the redraw, or screen refresh, bug that can occur in Oracle SQL Developer when used on Windows Vista and Windows 7. They occur for example when scrolling horizontally or vertically through the records of a table when the records don't fit the window.

Start with just the sqldeveloper.conf adjustment. If that doesn't fix it, then perform all steps.

Steps to solve the issue:

  • Add or replace the attribute of the following config file.
    ..\sqldeveloper\bin\sqldeveloper.conf
    AddVMOption -Dsun.java2d.noddraw=true
  • Install the most recent jdk.
    Last seen here: http://java.sun.com/javase/downloads/index.jsp
    Select the Java SE Development Kit (JDK). At this time, JDK 6 Update 16 is the most recent version. Install it in C:\Program Files\Java\jdk1.6.0_16
  • Add or replace the attributes of the following config files.
    ..\ide\bin\jdk.conf
    SetJavaHome C:\Program Files\Java\jdk1.6.0_16
    ..\ide\bin\ide.conf
    AddVMOption -Xmx256M
    AddVMOption -Dsun.awt.keepWorkingSetOnMinimize=true

Remove visual rings / circles from pen tablet in Windows 7

When using a pen in stead of a mouse in Windows, rings or circles may appear when you click. This happens at least in Vista and Windows 7. I am using a Wacom Graphire pen and wanted to deactivate those. This is not as straightforward as it seems. The rings are part of the Tablet PC Input functionality of the OS - not of the Wacom drivers or application.

How to disable these rings in Windows 7?
  • Disable the "Tablet PC Input Service".
    This solved the problem for me for a while... until the rings came back for no apparent reason. I suspect because of an automatic update or updated Wacom driver, that reactivated the tablet pc ring feature.
  • Uninstall Tablet PC Components.
    Control panel -> Programs and Features -> Turn Windows features on or off -> uncheck Tablet PC Components. Windows needs to be restarted after this.
  • Kill the wisptis.exe process, e.g. via taskmanager.
    Then 1) rename \windows\system32\wisptis.exe to wisptis.bak, 2) create a textfile called wisptis.exe with nothing in it. Alternatively: open properties for wisptis.exe, go to security tab and "deny full control" for the "everyone" account. If "everyone" is not visible, click edit, click add, type in "everyone" and click ok.
I am not using a tablet pc, so these actions might have a negative impact when using one.

UPDATE 20100305: The wisptis.exe process still comes up when running some .Net applications. Even when the above tip is applied. Most probably it is copied from the protected cache / version history Windows keeps. To prevent this, download the tool "process blocker":

http://www.processblocker.com/download.html

Configure it to block "wisptis.exe" and now the rings are REALLY gone forever.

UPDATE 20120718: There is a registry fix to disable the rings:

http://viziblr.com/news/2011/8/14/the-ultimate-guide-to-making-your-wacom-tablet-work-on-windo.html

Download the fix from step 5. Try this first and if it doesn't work, then use the process blocker application.

UPDATE 20130410: ... or disable it via a group policy:
  1. Open Local Group Policy Editor:Run... gpedit.msc
  2. Navigate to User Configuration - Administrative Templates - Windows Components - Tablet PC - Cursors
  3. Enable the Turn off pen feedback setting.

Limited connectivity using wireless internet in Vista Home SP1

I've had an issue with "limited connectivity" on my Vista Home SP1 installation. It is a laptop that connects wirelessly (WiFi) to a router. The router is connected to the internet via DSL. The router is working fine and the connection to the internet is ok. However, after using the internet for some time, sometimes half an hour, sometimes minutes, the wireless connection displays a yellow exclamation mark with the message "limited connectivity". It is not the router, since rebooting the laptop fixes the issue... for some time, and then it happens again. After that, trying to open network connections, or any other application related to the network, hangs that application.

I've collected the following possible remedies. I'm not sure which one solved it in the end. Obvious remedies like "put the laptop wifi switch to ON", "put in a correct WEP key" (or any other encryption key) or "check if the router is turned on" are left out:
  • (20090618) I put this upfront, because all the tips that follow didn't resolve the issue for me, so I finally bought a new Wifi USB dongle. After buying a new laptop to add to my wireless network I noticed that the WEP encryption I was using didn't work for the new laptop. So in the end I changed protocols from WEP to the stronger WPA. After that, all PC's and even the Wii worked flawlessly. Even after switching back to the original wifi NIC on the laptop that first had the "limited connectivity" message, that laptop hasn't had the problem. So in short: try changing encryption protocols. Start with none (unsecured) to see if the problem is gone and then move on to stronger ones.
  • Update drivers. There is a great free tool to update almost all drivers on your system, called DriverMax. Just register and it can be used legitimately for 30 days. I am not sure why it is "freeware" if it states that you can "use it freely for 30 days". It is based around a community of users uploading drivers. It the tool detects a new driver, you can then update it. This is a bit tedious, but always better then scouring the internet manually. The current version of the driver that is going to be updated is uploaded to DriverMax first. It is stored in their driver base for other users.
  • Reset TCPIP stack. Execute the following statement at the command prompt:
    NETSH INT IP RESET
  • Reset Winsock. Execute the following statement at the command prompt:
    NETSH WINSOCK RESET. Or remove both winsock registry keys, reboot, and reinstall TCP/IP protocol: http://support.microsoft.com/kb/811259
  • Disable auto-tuning. Execute the following statement at the command prompt:
    NETSH INTERFACE TCP SHOW GLOBAL. Check if "Receive Window Auto-Tuning Level" is disabled. If not, then disable it:
    NETSH INTERFACE TCP SET GLOBAL AUTOTUNINGLEVEL=DISABLED. Re-enable with "=NORMAL".
  • Disable IP6 protocol. Uncheck IPv6 protocol on the network adapters and disable in the registry. HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip6\Parameters, add or change DWORD key "DisabledComponents", set to hex "FF".
  • Disable other protocols. Additionaly uncheck QoS Packet Scheduler, Link-Layer Topology Discovery Mapper I/O Driver, and Link-Layer Topology Discovery Responder.
  • Disable power management on NIC. Right click the wireless network adapter in Device Manager, select properties, tab "Power Management" and uncheck the box "Allow the computer to turn of this device to save power". In my case it was turned back on again at a later point in time, but that could be due to installing a new driver afterwards.
  • Change wireless channel. Try different channel numbers for the NIC. Each channel number (mostly between 1 and 13) corresponds to a different frequency. The property can be set on the advanced tab of the driver for the NIC in device manager. Set the adhoc channel accordingly in the wireless router configuration.
  • Disable and re-enable network adapter. Apparently, this sometimes fixes issues.
  • Reboot in Safe Mode. A solution like the previous one. Reboot the system, press F8, select "safe mode". After it has fully restarted, reboot again. Windows starts normally again.
  • Run the System File Checker utility. Execute the following statement at the command prompt:
    SFC /SCANNOW. This is not of much of use to the majority of laptop owners, since they often do not own a copy of their Windows OS installation disk. When SFC finds a component (e.g. DLL) on the system, that is different from the one that was installed during the original installation, then it needs to get that original one from the installation disk.
  • Check eventviewer. I have error messages concerning a NTIOMIN service that cannot start, TCPIP.SYS signing issues, and Kerberos related messages (can supposedly be ignored when the laptop is not part of a domain). Still haven't figured out the first two. I'm also getting "informational" events about the NETw5v32 wireless driver. This is related to an incorrect driver.
  • Run registry or system cleaners: nice tools to run are HijackThis and CCleaner. The first can be used to remove questionable or corrupt services, browser helper objects, protocols, etc. The latter cleans the registry, removing orphanaged keys.
  • Repair wireless. Right click the wireless network icon in the notification area and select "diagnose and repair". Alternative method. Execute the following statement at the command prompt:
    %windir%\system32\rundll32.exe ndfapi,NdfRunDllDiagnoseIncident. Do this before "limited connectivity" message pops up. In my case it displayed a message: "TCP/IP settings not optimized", and it optimized them. Running it again didn't display the message again, so I guess it did something the first time.
  • Run Intel PROSet/Wireless diagnostics. If using Intel on-board wireless (I am using 3945ABG), then you can run the diagnostics utility. Execute the following statement at the command prompt:
    %windir%\system32\iPROSet.cpl. Run "diagnose" to check hardware, driver, radio, etc. Run "statistics" to check beacons, transmit errors, and power and power levels.
  • Downgrade driver. Sometimes the most recent driver is not the best one for your device. Some drivers available are: NETw3v32, NETw4v32 (11.5.0.34), NETw5v32 (12.2.0.11). In my case, the NETw4v32 driver gave 100% signal quality, while a NETw3v32 driver gave only 60%. The NETw5v32 filled my eventlog with messages (see remark elsewhere).
  • Set router to G-Only: put the router in network mode "G-Only". This way, the older B-mode is not supported, but throughput is improved.
  • (Run Network Diagnostics tool. Execute the following statement at the command prompt: NETSH DIAG GUI. Check all scanning options and start. This should work in Vista when the command prompt is started with admin rights, but I couldn't get it to work)
  • (NIC settings. If supported, try putting the adapter in full-duplex mode, or if it is already, in half-duplex mode. Experiment what works best. I cannot do this myself and wonder if this is even possible for a wireless adapter?)
  • (Run netdiag tool. Unfortunately, this tool is only availabe in Windows XP as part of "Microsoft Windows XP Support Tools". So, only for those using Windows XP, execute the following statement at the command prompt:
    NETDIAG /TEST:WINSOCK /V. Use the outcome of the test for further analysis.)

Links: http://ask-leo.com/what_is_limited_connectivity_and_how_do_i_fix_it.html

Simple way to read Excel or Access data in SQL Server

-- list of available providers
exec master..xp_enum_oledb_providers

-- Three ways to read in Access data (file: c:\db1.mdb, tabel: TEST)

1a) Using openrowset with older MS Access version:
SELECT * FROM OPENROWSET('MSDASQL', 'Driver={Microsoft Access Driver (*.mdb)};Dbq=C:\db1.mdb;Uid=;pwd=;','SELECT * FROM TEST')

1b) For 2010 or more recent (*.accdb)
SELECT * FROM OPENROWSET('MSDASQL', 'DRIVER={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=C:\db1.mdb;Uid=;pwd=;','SELECT * FROM MAANDEN')

2) Using opendatasource:
SELECT * FROM OPENDATASOURCE('Microsoft.Jet.OLEDB.4.0','Data Source=C:\db1.mdb;')...[TEST]

3) Using a linked server called TEST for 2010 or more recent:

EXEC sp_addlinkedserver
@server= N'TEST',
@srvproduct = N'MSDASQL',
@provider= N'MSDASQL',
@provstr= N'DRIVER={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=C:\db1.mdb;Uid=;pwd=;'

-- Read in Excel (file: c:\employee.xls, worksheet: TEST)
SELECT * FROM OPENROWSET('MSDASQL', 'Driver={Microsoft Excel Driver (*.xls)};Dbq=C:\employee.xls;Uid=;pwd=;','SELECT * FROM [TEST$]')

-- Insert into text file
insert openrowset( 'Microsoft.ACE.OLEDB.12.0', 'Text;HDR=yes;Database=c:\tmp\', 'select * from test.csv') (testname, testaddress) select testname, testaddress from vw_test;

Note:
  • MS Access needs to be installed on the same server where SQL Server is installed
  • Make sure that the use of ad hoc names is allowed:
    exec sp_configure 'show advanced options', 1;
    RECONFIGURE;
    exec sp_configure 'Ad Hoc Distributed Queries', 1;
    RECONFIGURE;
Possible error messages and solutions:

OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" returned message "Unspecified error"

Give read/write access to "everyone" on the server to the following folder:
C:\Users\<SQL Server Service Account>\AppData\Local\Temp

Make sure this is set on the server where the code is running, i.e. on the client PC where the code is executed within Management Studio.

Converting WAV DTS to MP3

A WAV DTS file contains a multi-channel encoded digital format called DTS and has .wav as extention. Playing such a file in Zoomplayer or WinAmp typically produces a static sound. This is because a filter and/or decoder are not installed.

For Zoomplayer a filter can be installed (Gabest AC3), but a separate DTS decoder is still needed. Ffdshow contains such a decoder, but setting up this mapping in advanced options -> customized media playback -> source filters and splitters didn't help. Zoomplayer keeps displaying the "An ERROR has occured!" messagebox when trying to play the WAV DTS file.

Foobar2000 used to have an additional component, foo_dts.dll, that could be downloaded from the site, but it is no longer available. I was unable to find out why it is no longer supplied. After searching the internet I found a version of the library, but foobar2000 0.9.5 refused to load it, reporting that it was an outdated version.

A player that can play them out-of-the-box is VLC player. This player has a built-in filter and decoder to play WAV DTS files. It can also transcode files, e.g. to MP3 format, but when I use it on a WAV DTS file, the program terminates unexpectedly.

So, in the end, I was unable to find a "one-click" solution. Here is how I finally managed to convert a WAV DTS file into a MP3 file:

For the example, I use a WAV DTS file named c:\wavdts.wav

  1. Download BeSplit (http://www.afterdawn.com/software/audio_software/audio_tools/besplit.cfm). I used version 0.9b6.2.
  2. Extract the zip file to c:\
  3. Start BeSliced.exe
  4. Drag and drop wavdts.wav onto the besliced canvas
  5. Select "DTS" when asked to select a format
    BeSplit is now ripping the DTS stream from the WAV DTS file.
    To use BeSplit without BeSliced, execute this command at the command prompt:
    BeSplit.exe -core( -input c:\wavdts.wav -fix -logfile C:\BeSliced.txt -type dtswav -output c:\wavdts_Fixed.dts ) -profile( BeSliced v0.3 )
    A file called c:\wavdts_Fixed.dts is created.
  6. Download DTSDec (http://www.rarewares.org/others.php). I used version 0.0.2.7.
  7. Extract the zip file to c:\
  8. Execute this command at the command prompt:
    dtsdec -o wav > regularwav.wav wavdts_Fixed.dts.
    DTSDec is now transcoding multi-channel DTS to a regular two-channel WAV file called regularwav.wav
  9. Use your favorite MP3 converting tools, e.g. AudioGrabber with LAME, to convert this WAV file to a MP3 file.