Archive for Web

Liked WP-SpamFree so far

During my to WordPress 2.6.2, I decided to use the default spam plug-in, Akismet.

After a few days of usage, there were still a few trackbacks slipped through, creating additional emails and work for me. So I wasn’t too satisfied and searched for an alternative spam plug-in.

I decided to try WP-SpamFree. So far it has been working great. In fact, I will remove Akismet now and let WP-SpamFree handles all my spamming needs.

Let me know if you have problems commenting, by writing an email at haidong.ji gmail.

Comments

Played with Google Chrome

Google Chrome Beta is available for download today. I played with it. I am not impressed at the moment and will not convert from Firefox. I may give it another whirl in a few months.

The strength of Firefox, in my view, is its many available extensions, which practically spoil and pamper me to the point that I do not feel comfortable in other browsers like IE, Safari, Opera, etc.. For example, I have Ad Block Plus. As a result, I hardly see any flashy, scrolling, popping advertisements on any sites, which is almost like a different reality as opposed to IE, Google Chrome, and Safari’s rendering. (Yes, I am aware that it is possible to block those ads in other browsers.)

Another extension that I won’t give up is Vimperator, which uses VI commands for browsing. Closing a tab is a simple press of the letter d. Searching and opening URL can be done with O, o, T, t commands and tab completion, so Google Chrome’s OmniBox didn’t impress me. I even have a little suspicion that Vimperator inspired the OmniBox idea.

This is not to say that Firefox is perfect, mind you. It still crashes once in a while for me, especially when attempting to connect to intranet sites while not on corporate network. But given all its advantages, I feel I can live with it.

It looks Google Chrome has API for extensions and customizations. So Chrome, give me some nice plug-ins, or at least some samples like Ad Block Plus and Vimperator. Then we can talk.

Comments (5)

Migrating from one RDBMS to another

Here is some of my thoughts on migrating MySQL to Sql Server. It came out of an email discussion. I’d love to hear your thoughts on migrating to a different database platform, not just MySQL to Sql Server.

I actually thought about writing a white paper or even a course on migrating from MySQL to Sql Server, but never got the time to do it. Sometimes a project doing similar things can serve as a launchpad for this endeavour, but that never came along, at least not yet. I am very interested in database interoperability field though. I’ve done MySQL and Oracle admin in the past and have published some MySQL and Oracle stuff in blogs. I have much better technical skills on Sql Server than any other RDBMS platforms, primarily because I’ve worked on it longer.

Here are some of my thoughts. I think most of it applies equally on migration from Oracle, DB2, Sybase, Postgresql, etc., to Sql Server, or the other way around. It might be slightly easier to migrate from Sybase to Sql Server, considering their common root.

1. It is not easy to migrate existing app, unless the app is a simple one. Even for that, there are enough quirks that can throw people off and cause enough frustration to derail the whole projects. I’ve seen that happening twice, having engaged in moving 2 apps from Sql Server to Oracle;

2. Therefore, the best way to migrating to a new database RDBMS, in my opinion, is to start from a new initiative, probably not big initially. When you start things from a clean slate, you don’t have the historical garbage to worry about. Furthermore, you will give the team enough time to learn the new platform, and prepare the team for future migration, if you choose to do so;

3. Having open-minded team members is crucial to a migration project’s success. Too often people have emotional attachments to the platform they are familiar with, possibly out of job security concerns and lack of general curiosity toward new things.

I generally adopt a platform agnostic attitude, and don’t get religious and too carried away on the platform I work on. Having said that, I think these are points that marketing people can spin for persuasion purposes:

1. MySQL has too many storage platforms: MyISAM, InnoDB, MaxDb, and the newly introduced Maria. This can be viewed as a plus, as it provides choice. The downside of it is that it causes confusion for end users;

2. MySQL’s support for relational model is fairly recent. For example, for a long time, MySQL didn’t support Stored Procedures, Views, Triggers, Foreign Keys, etc. One could argue that MySQL is not mature in this area since it is new for them, but I think it is difficult to find evidence to substantiate that claim. Also, running the risk of offending some people, I think the importance of relational model got overblown a bit;

3. Sql Server offers the CLR integration. This can be a great selling point;

4. Sql Server offers tight integration with Visual Studio, Windows network, and all other things Microsoft. This is a huge advantage.

5. Too many people find *nix environment intimidating. Although MySQL works on Windows, but the perception in the marketplace is MySQL works better on *nix.

As far as migrating MySQL to Sql Server in a hosting web environment, my honest opinion is Sql Server will be fighting an uphill battle, because MySQL excels in this arena, especially for small and medium-sized, or departmental organizations, with the proliferation of such LAMP app like blogs, wikies, discussion boards, etc. I believe Microsoft’s weapon of choice in this arena should be SharePoint. Given Microsoft’s clout, it is certainly a battle worth fighting.

Comments (5)

Internet connection problem when Symantec anti-virus software is not running

I noticed there were a lot of bloated Symantec anti-virus junk installed on a workstation I work with. So I disabled most of them in Windows services.

The next day I came back, I couldn’t connect to the web with my Firefox anymore, but could connect via Internet Explorer. In addition, connecting to remote Sql Server database servers was not successful either.

The thing wasted me at least one hour, and disrupted me from getting into the flow of things much of the day. Finally I figured out that Symantec AntiVirus service needs to be started, and all was happy.

In other news, things are really busy for us. My better half will finish her Ph.D in Life Science (microbiology) in a few weeks, and is looking for a job. If you have any leads, I’d appreciate it if you could pass that along to me.

Comments (2)

Get the documents out of SharePoint database

I recently helped a client to get the WSS 3.0 documents out, as the client’s SharePoint is broken and we couldn’t get it fixed in short time, but they really want the Word, Excel, and pdf documents out of there.

WSS 3.0, Windows SharePoint Services, uses Sql Server for data storage. The Sql Server version WSS uses is the Embedded Edition. By default, microsoft##ssee is what you will see listed in services. Usually, Sql Server client tools are not installed on the server. Therefore, it is difficult to control those files. So we installed Sql Server Management Studio on this box.

Then we had a hard time connecting to the instance. It turned out we can only connect to the SharePoint WSS 3.0 databases via named pipe. I used Windows authentication and put in \\.\pipe\mssql$microsoft##ssee\sql\query as server name, and finally got in.

For SharePoint, there are at least 2 databases involved: the configuration database, and the content database. By default, they are located at c:\windows\SYSMSI\SSEE\MSSQL.2005\MSSQL\Data

I then moved the content database to a regular Sql Server 2005 server, and decided to write a little program to suck the documents outside of the database. It turns out that somebody has already written the program. Follow the link here to get the C# source code of the program. Note that the sql statement used should be the one listed below, as mention at comment No. 9 of that post:

com.CommandText = “select [AllDocs].[DirName], [AllDocs].[LeafName], [AllDocStreams].[Content] from [AllDocs],[AllDocStreams] where (LeafName like ‘%.doc’ or LeafName like ‘%.xls’ or LeafName like ‘%.pdf’ or LeafName like ‘%.ppt’) and [AllDocStreams].[Content] is not NULL and [AllDocs].[Id] = [AllDocStreams].[Id]“;

Enjoy!

Comments

Vimperator: make your Firefox behaves like VI/VIM

I stumbled into this Firefox gem today: Vimperator. It makes your Firefox behaves like the venerable VI/VIM editor. Warning: if you are not a VI/VIM guy, don’t even try this. It will cause you grief. For VI/VIM aficionados like me, this is almost like the best thing since sliced bread, or, VI.

A couple of things that are important:

1. I (uppercase letter i, not yours truly, pun intended) will disable VIM commands. This is good for site such as GMail where it has its own keyboard binding with JavaScript, I presume. Or the text box where you need to do some editing.

2. o or t can be used to open a URL. If you just type in a word or words, it will present you with a search results based on those word(s) by your default search engine.

For friends who are interested: I am doing well. I have opened up my own company, currently doing consulting/training gigs on Sql Server, Oracle, MySQL and such. I expect to return to blogging, hopefully soon. Vimperator got me excited so I decided to give it a little plug and say hi to all my readers.

Comments (2)

Disable simple file sharing in Windows XP

Simple file sharing means that when you go to a property page of a folder, you will not see the Security and Sharing tabs. This is the default for Windows XP if the machine is not part of a domain.

This can be problematic, because you cannot add specific users and groups to access a folder. Case in point: if you are doing IIS and ASP.NET development, sometimes you need to add aspnet account to access the folder where IIS virtual directory points to. With the default simple file sharing under XP, you cannot do that. I learned this while doing some dnn work on a Windows XP machine.

Disabling simple file sharing is simple:
1. Open Windows Explorer;
2. Tools -> Folder Options -> View tab;
3. Uncheck User simple file sharing (Recommended) box.

Comments (3)

Give role authority to upload image files in DNN

I talked about roles and permissions in DotNetNuke (DNN) in this post.

Sometimes you want to grant a role authority so users with that role can upload image files for their documents. Here is how you do it:

1. From the Admin menu, usually at the far right of the horizontal menu bar, pick File Manager;
2. You will see File Manager, Windows Explorer style. Underneath it is a section called Security Settings. This is where you grant view and/or write access to folders on the server.

Comments

Great Flickr Greasemonkey Scripts

Update: Flickr changed its interface, so the scripts in step 2 and 3 no longer work. I will update this as I get more information.

If you have Flickr account and use Firefox, I found 2 Greasemonkey scripts that are very helpful. They make photo editing so much more easier. They are both focused on Flickr batch operations.

Here is what I did, hopefully somebody will find it helpful:

1. Download and install Greasemonkey extention for Firefox if you don’t have it already. Restart of Firefox may be necessary;
2. Install this Greasemonkey script for batch title, description, and tag editing;
3. Install this Greasemonkey script to pick pictures for batch editing.

If you are interested, I have a post on software that I always put on my own machines.

What are your favorite Flickr hacks?

Comments (2)

Notes on DNN (DotNetNuke) Roles and Permissions

1. From Admin menu, the right-most menu item before the search box, pick “Security Roles”;
2. You will see all the roles here. Click the pencil icon next to each role to edit it;
3. To create a new role, click on Security Roles downward triangle icon, which is next to the lock icon, and pick “Add New Role”;
4. For my purpose, I left “Public Role?” and “Auto Assignment?” unchecked. I also left Advanced Settings alone, where Billing Period, Service Fee, Trial Fee, and such are located. I honestly could not envision myself using any of them. Your mileage may vary;
5. To grant permissions to this role, browse to any page or module, then pick “Settings” after hovering you mouse over the downward triangle. You can grant permissions of this page / module to a role by un/checking boxes in the Permissions section within Basic Settings;
6. To grant a role to a user, go to Admin >> User Accounts. Edit the user you want to grant the role to, and click “Manage Roles for this User”. From there, you can check and roles for this user.

Comments (1)

« Previous entries