Archive | February, 2010

How to delete/drop/select all the tables from SQL Server Database?

I stumbled on a thread at MSDN titled “How to delete/drop all the tables from SQL Server Database without using Enterprise Manager?” when trying to look for a way to drop all tables from a SQL server database.

Here are some of the nuggets from the thread:

1) How to drop all tables from the database

EXEC sp_MSforeachtable @command1 = “DROP TABLE ?”

2) How to delete all data from all the tables in the database

EXEC sp_MSforeachtable @command1 = “DELETE FROM ?”

3) How to truncate all data from all the tables in the database

EXEC sp_MSforeachtable @command1 = “TRUNCATE TABLE ?”

4) How to select all the rows from all the tables in the database

EXEC sp_MSforeachtable @command1 = “SELECT * FROM ?”

5) How to print the names and owners of all the tables in the database

EXEC sp_MSforeachtable @command1 = “PRINT ‘?'” –Just print the tables names with owner(dbo)

Some caveats, like referential integrity rules and foreign keys references will have to be kept in mind when attempting to truncate data. Also, some of the changes can not be rolled back.

Facebook Chat with Pidgin

Earlier this month Facebook announced that their chat feature now supports XMPP (Extensible Messaging and Presence Protocol). What I truly appreciate about Facebook’s support for XMPP is how they have integrated the Friends Lists to selectively decide which friends show up online.

To connect to Facebook Chat from Pidgin follow the instructions below:

1) Create your Facebook username by going to http://www.facebook.com/username

2) Open Pidgin

3) Click Accounts

4) Click Manage Accounts and you should see the following appear:

5) Click Add

6) Set the following options under the Basic tab:

Protocol: XMPP

Username: Username you created in Step 1

Domain: chat.facebook.com

Password: Enter your password

6) Set the following options under the Advanced tab

Require SSL/TLS: Unchecked

Connect port: 5222

Connect server: chat.facebook.com

7) Click Save

Paddington Station Lansdowne

Paddington Station is now open!

Indeed, downtown Lansdowne now has a new antiques store. They still don’t have a website setup (perhaps I’ll drop them a line and offer my services) but in the mean time call (484) 461-7770 for store hours, or e-mail the store owners at [email protected] for more information, or stop by the store at 12 S. Lansdowne Ave. Lansdowne PA.


View Larger Map