Keyboard Face
msgbartop
when you find QWERTY imprinted on your cheek – it’s time to go to bed.
msgbarbottom

31 Jul 06 ODBC and ASP to connect to a MySQL database.

My God!
This took hours to figure out. Here is the solution to using ODBC and ASP to connect
to a MySQL database.

1. Install the latest MySQL engine. I believe it is currently 4.1.9

2. Install the MySQL Admin and MySQL Query Browsers – these are just helpful – not essential.

3. Install MyODBC-Standard-3.51.9-win.msi (or exe) Note this is NOT the latest version. The latest version doesn’t work.

4. In MySQL Admin, connect to your database and make sure that “Use Old Passwords is checked.”

5. Follow the instructions here:

Open the MySQL commandline utility (located in MySQL Admin and elsewhere) and type:

mysql> USE mysql
mysql> UPDATE user SET Password = OLD_PASSWORD(’mypass’)
-> WHERE Host = ‘localhost’ AND User = ‘root’;
mysql> FLUSH PRIVILEGES;

SOURCE: http://mysqld.active-venture.com/Old_client.html

That’s it. It should work.

24 Mar 06 Regular Expression Search Engine

Wow! This is a great site: RegExLib (Regular Expression Library)

Excuse my exuberance, but I’ve been creating a lot of long regular expressions from scratch lately and it’s time consuming! This is a great resource for anyone wanting to use regular expressions in their code.

21 Nov 05 VBScript Array Length

Apparently there is no direct method to determine the length of an array in VBScript. The best way I could find is to use UBound(ArrayName). This will return the upper limit of the array. Unfortunately, it doesn’t account for empty items in the array. In the example below Length will be equal to 10, not 1.

Dim NewArray(10)
NewArray(0) = "Apple"
Length = UBound(NewArray) ‘Length is equal to 10, not 1

Here is a good link to VBScript Array functions.

http://www.shocknet.org.uk/defpage.asp?pageID=30

If you know of a better way to determine the length, please let me know.