Search This Blog

August 30, 2007

Error 1721: Installing AdventureWorksDB 2008 is not working

Today I went to the following website to download the AdventureWorksDB databases. I wanted to attach it to my SQL Server 2005 in my windows XP with SP2. Finally it was not working for me.

http://www.codeplex.com/MSFTDBProdSamples

When I installed, it had the following error.

Error 1721. There is a program with this windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: InstallDatabase, location:..\AdventureWorks_log.ldf) FOR ATTACH;”


After the install, the sample files were really under C:\Program Files\Microsoft SQL Server\100. They were not useful because when I opened SQL Server 2005 and tried to attach it, it didn’t work. There is nothing to do with windows installer package. It proves the latest AdventureWorksDB is only for SQL Server 2008.

If you really want to use it in SQL Server 2005, just download AdventureWorksDB of SQL Server 2005 as follows:

http://www.codeplex.com/MSFTDBProdSamples/Release/ProjectReleases.aspx?ReleaseId=4004

You can finish your task.

August 29, 2007

SQL Server 2005 Issue: ERROR 1706 Setup cannot find the required files.

If you have office 2007 in your PC, and you want to install SQL Server 2005, you may have the following error:

ERROR 1706 Setup cannot find the required files. Check your connection to the network, or CD ROM! For other potential solutions to this problem, see c:\Program Files\Microsoft Office\Office11\1033\Setup.chm

You must download Office 2003 web components first and then you can install SQL Server 2005 successfully.

August 23, 2007

Comments on Using Picasa- One interesting issue!

2 months ago, I read one of the articles in PC Magazine that introduced one of Google’s free software, Picasa. I found it was so interesting and useful that I told Christine to download and gave it a try because she likes to try some useful software such as Photoshop, InDesgin , Photo Impact, etc.

After she downloaded and launched Picasa, she followed its instruction. Finally she regretted. Picasa made her PC down. She swore that she will never use it in the future. What happened to her PC?

This is a good interesting issue I like to mention here.

When you use Picasa for the first time, it has the small dialog box which lets you scan your photos. You cannot say no. But when you click “yes”, it will automatically scan all of your pictures in your hard drive. If you have many pictures in different folders, but the total storage is more than 40 GB, do you think it will finish scanning as soon as possible?

If you have many digital photos in your hard drive like Christine, will you use Picasa as your tool in your PC? I don’t believe so.

I don’t know why Picasa wants to scan all of the pictures in the beginning. Why not add another function to let users add directories later?

I hope they can improve this function in the future!

August 21, 2007

How to Use Auto Logon in Windows Server 2003?

Why do we use auto logon in Windows Server 2003? People will say: It is not secure, and I don’t want to use it. I will say: This function is so useful, but only for the specific purpose such as testing and some automated jobs.

Just imagine that if you want to run some automated jobs, but they will cause the reboot, will you spend time waiting in front of your PC in order to manually logon to your PC and move on to the next step? Probably not.

What if these jobs cause the reboot many times? Do you still want to wait? Therefore, the best way is to use auto logon!

How do we configure the function of auto logon? It is so simple as follows:

1. Click Start, run, and enter regedit.

2. Go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon. You can see AutoAdminLogon and DefaultUserName.

3. Just create a name DefaultPassword and add your password.

4. Just set AutoAdminLogon=1.

Next time when you restart your PC, it will automatically logon to your PC.

The only disadvantage is that when someone logons to your PC, he can know your password in the registry key. So be careful when you want to use this function.

August 19, 2007

Do we really need a foreign key in the table?

If you worked on database design before and now I ask you a question:
Do we really need a foreign key in the table?” , you will definitely say: Of course!
Foreign keys are important in database design. We need to follow normalization(First normal form, Second normal form and third normal from).

If you get a chance to ask Database Administrators in large companies, they might tell you: we don’t want foreign keys.

Is this the big conflict between SAs and DBAs?

Just imagine one situation:

If ABC Company has a famous website that sells many products to customers, their network traffic is very heavy. When customers place orders and want to receive their orders as soon as possible, how can ABC Company handle it?

ABC must have many database servers, but the data on the main server needs to be replicated to other servers quickly. Only 3-5 minutes, the data must be updated automatically and they can ship the products quickly. If the network traffic is so heavy and many tables have many foreign keys, the replication will be very slow and might cause failure.

Just imagine another situation:

Many companies have the daily build or weekly milestone build for developers and testers to test if their products are reliable. If there are so many tables including so many foreign keys in the database, how can DBAs setup the new build as soon as possible? If they can’t set it up immediately, many people will say: they block my task. No wonder that many DBAs say: Foreign keys are the burden of replication.


In the real world, you can have many chances to see if my opinion is right. Do we really need a foreign key in the table? Obviously, it depends on the situation.

I will say:

No replication, need foreign keys.
Need replication, no foreign keys.

August 14, 2007

My ideal blogger.com —user friendly functions are the best.

Blogger.com seems very popular now. Many people want to give it a try.

When I use it, I should say: blogger.com doesn’t provide user-friendly functions for users. Some special functions need time to search; some are in other domain websites. They assume that users are professional and will find the functional answers by themselves. Do they really spend a lot of time searching the information and just add those functions to their blogs? Probably not.

My ideal blogger.com is just simple. Blogger .com should collect useful user-friendly functions and users can add them directly. They don’t need to know HTML/JavaScript. They don’t have to worry about those functions so much.

What are people’s useful functions now in their blog?

1. Provide many useful templates of 2 columns or multiple columns directly.

2. Provide functions of showing visitor counts, recent posts, recent comments, and recent articles.

3. Provide functions of showing article categories, article search, my subscriptions and horoscope directly.

4. Provide functions of calendar, weather, google map, oil price..etc.

5. Provide the function of uploading multiple photos to the blog one time. Copying texts and photos from Microsoft Word or Google documents to the blog is also the best way.

Are these functions basic?

I want to mention: User friendly! User friendly! User friendly!

No HTML/JavaScript.Users have no time to search.

I really hope that blogger.com can know what users need and what they want.

I really hope those basic functions should be realized in the upcoming days.

C-マンション

August 11, 2007

Garbled Characters in English Windows Operating System

If you have the English Windows Operating system and want to install non-English software in your PC, you may suffer from one situation:During installation, you see garbled characters, make you feel frustrated and want to cancel the installation.

When you open the notepad written by non-English characters, it shows garbled characters too. How do you solve the problem?

Go to control panel, click regional and languages option. You can solve the problem. But many users say: I clicked that and installed languages I wanted already. But I still can't make it.


You need to configure 3 parts: Regional Options, Languages and Advanced .

Select the languages you want like these 3 figures and reboot your PC. You will solve the problem. Is that easy for you?

Comments on uploading multiple photos to blogger.com

Today I wanted to upload photos to my tour blog in blogger.com, and I found I couldn’t find a way to upload multiple photos to my blog. I felt very disappointed. Blogger.com doesn’t provide a good way for users to get the job done as soon as possible. Therefore, I used my ways and searched many ways online as follows. I also want to make some comments here.

Solution 1: Login to blogger.com and use dashboard to upload one photo one time.

Comment: A very stupid way. If you have 100 photos, do you think users will upload 100 times? Who will do it like this?


Solution 2: Download Picasa and click BlogThis!

Comment: I tried it and found it didn’t work. Finally I know BlogThis! doesn’t support the new blog in blogger.com. A very bad function now.


Solution 3: Copy photos and paste them to blogger.com

Comment: It doesn’t work. Blogger.com doesn’t support copy and paste functions for photos.


I feel so disappointed about the function of uploading multiple photos. Finally I find a new way by myself. I would like to share it with you.

1. Login to your blogger.com

2. Click settings --> email --> add the email address you want in Mail-to-Blogger Address

3. Open your Picasa, sort by file name, select many photos, and click “Email”. It will pop up the small window. Please add the email address you mention above.

4. Click send. It will send all photos to your blog quickly.

5. You can edit this post and add some text you want.

Do you think blogger.com provide a good way for users to upload multiple photos?
Blogger.com can ask me to test the functions for them.

C-マンション

August 8, 2007

Adding a Resource File Is So Good!


If you need to create an xml file or a text file in your project, you might want to use it all the time. How can you know its complete path? Is it in C drive or D drive? Do you need to hardcode the path? Probably not!

The simple idea is that we can create a new resource file, and add a text file or an xml file in it. When we run the program, the file will be under the folder of bin\debug. Later we can use C# function to get the complete file path and load the data as follows:

string CurrentDirectory = Directory.GetCurrentDirectory();

string resourceFilePath = CurrentDirectory + @"\" + "test.xml";

Is it a piece of cake?

August 3, 2007

Create a new folder and a new file using C#

If you need to create a new directory under the folder of program files, how do you know it is in the path of C or D drive? Can you write C# to create a new folder? You can use ExpandEnvironmentVariables to get the path:

public string DataPath = Environment.ExpandEnvironmentVariables(@"%ProgramFiles%\TestData");

If you want to create a new folder , you can use this key word: Directory.

if (!Directory.Exists(DataPath))

{

Directory.CreateDirectory(DataPath);

}

If you want to add a new file, you can use this key word : File

File .Create(DataPath + @"\test.txt");

C-マンション