Posted in Programming, SQL Server on February 25th, 2009 No Comments »
I was looking for a way to find the first occurrence of 4 digit
year in a column containing free from text. The first thing I think of was to use regular expression. I did some research and came up with the following function. Once the function is created it can be used like […]
Posted in Programming, SQL Server on February 25th, 2009 No Comments »
A query to display all user tables in a database and sort them by decending order according to row counts is very useful when it comes to research and
discover where data are stored in a complex database. I found such query very helpful from time to time. I have collected a few of them […]
Posted in Programming, System Admin on February 24th, 2009 5 Comments »
After writing previous post about using window
batch command to rename all files in a folder I found using VB Script to do the same thing is much easier.
Let’s say you have a few thousand files named in the same pattern like transaction_xxxxx.txt in a folder called test. You want to rename all these […]
Posted in Programming, System Admin on February 23rd, 2009 5 Comments »
I was trying to write a batch file to rename all files in a folder on windows. And the following is what I came up with. It worked very well. I found one of the great usage of my blog was to archive whatever script I came up with. It could help someone to quickly […]
Posted in MySQL, SQL Server on February 23rd, 2009 4 Comments »
I found a lot of posts on the internet regarding how to set up a MSSQL link server to MySQL server. I didn’t find any of them gave a complete picture. So I wrote my own post and hope it can help.
The first thing need to do when setting up a link server to […]