Thursday, June 10, 2010

FREE

FREE ADVICE!

What happens if you delete default database for a user in sql server?
--You will get an error msg as : Cannot open user default database
--Easy solution:  
1- Click options in login window



Login Screen in SQL Server Management Studio


2-Set database to master or model

Change database for connection


3-This will fix your login problem. Next step is to find your default database and change that. It is normally located in security> logins> your loginname



Find your Login settings in security tab

4-Change your default database if it is not changed. 


Now, you can fix the problem with your default database. Here is the cause of the problem from Mic:
The user default database is unavailable at the time of connection. It is possible that the database:
  • Is in suspect mode.
  • No longer exists.
  • Is in single user mode and the only available connection is already being used by someone else or by something else.
  • Has been detached.
  • Has been set to the RESTRICTED_USER state.
  • Is offline.
  • Is set to emergency status.
  • Does not have the login account mapped to a user or the user has been denied access.
  • Is part of a database mirror.
Additionally, the login account may be a member of multiple groups and the default database for one of those groups is unavailable at the time of connection.-->
http://support.microsoft.com/kb/307864


Saturday, May 15, 2010

Eclipse Php Zend Debugger

How to Debug PhP Code in ECLIPSE?
If you want to see variable values with mouse over and change them to see the effect in your program without echo statements, you need debugging. You can follow the steps below to set up a php editor with debugging. You can email me for questions.

  1. Install apache server
  2. Install Php from www.php.net
    1. Select all necessary items such as mysql, openssl, dba
  3. Download ZEND plugins for eclipse
    1. Copy zenddebugger.dll to PHP directory
    2. Add these to your php.ini file
              zend_extension_ts=.\ZendDebugger.dll
              zend_debugger.allow_hosts= 127.0.0.1
              zend_debugger.expose_remotely=always

You may want to run phpinfo() script to see your actual php.ini file. You may have one copy at C:Windows directory.

4. Download Eclipse php editor with debugger. It will show you xdebug and zend for debugging.
5. Setup your work directory
6. Configure your debug options: it may launch at http://localhost. This is fine for the default settings.
7. Restart apache server after changing php.ini file
8. When you run in debug mode, Eclipse will ask you to load in perspective show detail debug screen
9. If you get error about php.ini directives, you should check you php.ini file. You can add phpinfo(); command line to list all properties of PHP. It will show you the address of php.ini file.

Summary: If you see zend debugger properties in your PHP property list, you have the debugging. Disable Xdebug if you have that. Zend and Xdebug may not work properly at the same time.

I am happy to have debugging in php. I guess no more "echo this echo that"

Best Regards,

        Thursday, May 13, 2010

        ASP Hosting

        I am looking for asp hosting. Most of the hosting providers are offering similar services.
        Check the list:
        http://www.hosting-review.com/hosting-directory/top-10-lists/Top-10-ASP-Hosting-Companies.shtml

         IX Web Hosting looks good with the low price tag. 




        1-How much does it cost to use asp hosting with sql server 2008? 
        --It looks like with 36 month plan, they charge around 10$ /month at IX web hosting.
        2-Reliability ?


        3-Support ?


        4-Speed


        5-Bandwidth limits



        I will look into more details about this...Let me know your favorite Hosting provider for Windows!!!

        Another info: http://www.dotnetpanel.com/ is open source now. You can download that and use it for hosting management.