Monday, September 14, 2009

Installing Modules in Drupal

In my previous posts, Ive explained about the installation and configuration of Drupal and WAMP.
Now, lets hit it...
When we install drupal, there are a lot of modules that come with it. But to use the complete power of drupal, we must use the freely available modules on drupal.org.
Here we go...

1.Goto drupal.org and download the module of your choice which comes as a tar.gz file.
2.Unzip the file.
3. Create a folder called modules in C:\wamp\www\drupal\sites\all\
4. Thats it.
5. Now on your drupal menu, goto Administer- Site Buliding.
6. Scroll down the page to see whether your module name appears or not.
7. Check the box to enable the module.

In my next post Ill write about the installation of themes.

Monday, September 7, 2009

Starting WAMP

In this post, Im gonna discuss about the WAMP issue which I faced when I got my hands on it. In the previous posts, Ive described the WAMP and drupal installation, configuration etc.
But after doing all this, when i restarted my computer and double clicked on WAMP, I wasn't able to open the http://localhost/drupal. I checked out services.msc, and I was amazed that inspite of double clicking on WAMP, there was no entry for wampmysqld and wampapache. WTF ...

So I re-installed everything and faced the same problem again on restarting my computer.
I decided to google it and found that WAMP has come issues with Skype , but I had no skype on my computer.
So, I disabled all the firewalls and anti virus on my system, started computer in safe mode with networking, checked ports and what not... Huff... I got tired of searching so I thot of trying it my way...And I did it finally......
So here it goes:

Starting WAMP

1. Double click on wamp. You'll see and icon for WAMP where the time appears on Win XP.
2.Click on the WAMP icon.Goto APACHE- Services- Install Service. A command window opens up, hit enter and it'll be gone.
3.Click on the WAMP icon.Goto MySQL-Service-Install Service.
4. Now goto APACHE- Services-Start/Resume Service.
5. Now goto MySQL- Services-Start/Resume Service.

BINGO !!! Its done now.. Now everythings gonna work. You can check services.msc and ull see wampmysqld and wampapache...

The steps look damn easy but they blow the mind of someone jus starting wid it...

WAMP and Drupal - Installation

Now lets start with the WAMP installation.

Installing WAMP is a child's play. Just do a couple of nexts in the installation wizard and ure on.

Setting up drupal

1. After you download drupal form drupal.org, unzip the file and rename the folder as drupal. After this, paste this folder in C:\wamp\www. ( Assuming your WAMP resides in C:\)
2.Now go to C:\wamp\www\drupal\sites\default and rename the file default.settings.php as settings.php.
3. Now start your wamp by double clicking. The WAMP icon appears at the place where you see the time on Windows XP.
4. Click on WAMP and click on phpMyAdmin.
5. Now on http://localhost/phpmyadmin/ page in your browser, give a database name and click on create.
6. Now type http://localhost/ on the address bar of your browser and just so a couple of next. After performing all the steps, you have drupal installed on your computer.

Ill write more about using drupal in my next post.

Introduction to Drupal

Ok guyz... Its been long since Ive written ( or shud I say its been long since Ive learnt somthing) on my blog. So, as they say, Im back with a bang and this time...Its DRUPAL...I recently got a chance to learn it (thanks to my friends) so thot i shud share it...

What is Drupal ?
Well, drupal is an open source CMS ( Content Management System). This means that using Drupal, we can build and manage websites in no time. Just download Drupal and use the freely available modules available on drupal.org. No need to learn HTML,DHTML and to scratch your head on css.

How to start?
Ok, to start with, we need to download WAMP (Windows, Apache, MySQL and PHP).All these four things come bundled in WAMP. So visit http://www.brothersoft.com/wampserver-70590.html and download WAMP 2.0 h.

Next, you need to download Drupal ver 6.x from http://www.drupal.org .

In my next post, Ill teach u how to install these.

Saturday, July 4, 2009

SELECT COUNT(*) v/s SELECT COUNT(1) - FASTER??

I was writing a PL/SQL code one day using select count(*) from Table_name when somebody told me that select count(1) is better and faster. Although, he couldn't tell me the reason but he gave me a fact. So i jumped upon to search the reason.

Select count(*) uses a TABLE SCAN ie all the rows are looked upon one by one based on your WHERE CLAUSE whereas select count(1) uses an INDEX SCAN which has better performance as the scan is based on indexes.

TABLE scan is faster if the table is small.

Saturday, June 27, 2009

PL/SQL Developer- Setting Path in Preferences

What is PL/SQL Developer?
Well, PL/SQL developer is like an IDE for ORACLE. You can connect PL/SQL Developer to ORACLE database and then create and compile procedures and function, create users, views,tables and much more that you do with ORACLE.

Setting the path
When you use it for the first time, you need to set the path in the Preferences. Set the following paths:
Oracle Home: This path contains the path of your database:
For example - C:\oracle\product\10.2.0\db_1
OCI Library: This contains the path of the file oci.dll in the BIN directory.
C:\oracle\product\10.2.0\db_1\BIN\oci.dll

Reopen PL/SQL developer so that the changes take place effectively.
Thats it, happy developing !!!

Friday, June 26, 2009

ORACLE- Tablespaces and datafiles





Tablespaces:
It is a unit of storage where ur database is kept. There may be one or more tablespaces depending on the size of ur database.
Datafiles:
Each tablespace comprises of one or more datafiles.To increase tablespace, you need to add datafiles to the tablespace.

Types of tablespaces:
---- SYSTEM tablespace contains the data dictionary.
----USERS tablespace is used to store user data(table, indexes etc)
----The SYSAUX tablespace provides a single location for all non-essential database metadata. In the past the schema objects to support many database features were located in the SYSTEM tablespace. These have now been moved to the SYSAUX tablespace. As a result the SYSTEM tablespace is less cluttered and suffers less contention.
----TEMPORARY tablespaces are used to manage space for database sort operations and for storing global temporary tables. For example, if you join two large tables, and Oracle cannot do the sort in memory space will be allocated in a temporary tablespace for doing the sort operation
----UNDO tablespaces are special tablespaces used solely for storing undo information. You cannot create any other segment types (for example, tables or indexes) in undo tablespaces.