2006/11/28

Maximum column name length in SQL Server 2005

I was asked about this problem today and I could find it neither in SQL Server documentation nor online, so I checked it experimentally.

The name
'test1test1test1test1test1test1test1test1test1test1test1test1test1test1test1
test1test1test1test1test1test1test1test1test1test1test1test1test1test1test1'
is invalid because it is empty, contains invalid characters, or contains
more than 128 characters.


Maximum allowed column name length in SQL Server 2005 is 128 characters.

UPDATE:

As phorku wrote in his comment, the maximum column name length can also be determined by checking properties of the sysname data type:
sysname is a system-supplied user-defined data type that is functionally equivalent to nvarchar(128) and is used to reference database object names

2006/11/26

Installing Ubuntu on ASUS A6RP-AP069 notebook

There were three problems that me and my girlfriend encountered while installing Ubuntu 6.10 (Edgy Eft) on ASUS A6RP-AP069 notebook.
  1. Starting the installation
    There was no problem to boot the laptop from the Ubuntu CD, it showed the available option, but after choosing any of them it... froze after a few seconds.
    We tried 3 or 4 different version of Ubuntu and Mandriva. Every time it hung as soon as Using hpet for high-res timesource message showed. (It is worth noticing that Ubuntu 6.10 does not show such information to the user by default, while its older version do.)
    We found the solution here - adding hpet=disable to the kernel parameters worked like a charm.
  2. Connecting to the wireless network
    Ubuntu correctly detected the wireless card. We entered all necessary configuration parameters (SSID, key, etc.), activated the card and... it couldn't connect to the network no matter how many time we re-checked its configuration and restarted it.
    Finally, we found this post. It's really great! We followed the instructions and the WiFi network was up and running in no time.
  3. Enabling sound
    That was the hardest part. Everything looked fine - Ubuntu detected the sound card, Amarok looked like it was playing a song, but... there was no sound. We tried to play files in different formats, we checked the headphones, we found countless posts telling to uncheck some External Amplifier option in KMix, but we found no such option.
    Late at night after a lot of googling I (my girlfriend went to sleep earlier) found this post. Another great post! I recompiled alsa-driver, alsa-lib and alsa-utils packages and the sound problem was gone.
  4. Headphones
  5. WPA

HOWTO: Configure SQL Server 2005 to allow remote connections

I know it doesn't seem a very hard task, but it really took me quite a lot of time to configure a SQL Server 2005 instance running on Windows XP SP2 machine to allow remote connections.

This KB article describes step by step what you have to do to be able to connect remotely to a SQL Server 2005.

In my case, there were two problems:
  1. I disabled SQL Server Browser service (which has to be running if you want to use a named instance),
  2. I didn't know that in Windows Firewall you can create exceptions for particular applications (and not only ports).