My Blog List

hotinit.com. Powered by Blogger.

Search This Blog

About Database

Friday, 4 May 2012

What is a Database?

Database is an organized way of storing information, making it easy to get the information at later time.
Eg, storing organized data in Excel file(.xlsx file extension) is called Excel database. storing data in microsoft sqlserver file(.mdf file extension ) is called Sql database.

What is database software ?

Database Software is a tool to store organized data. Examples of database software will be
Excel, Sql Server, Mysql, Sqllite, postgresql,Apache Cassandra , google big table etc.,

Types of Database

Hierarchical Databases -- data is organized like a Pyramid. Oldest method of storing data.Used in IBM mainframe Computers
Network Databases - same like hierarchical database but this has an hierarchical structure. 
Relational Databases - This is used in sql server where the data are linked by relationships (using keys)
Object Oriented Databases - This kind of database can be used to store variety of media sources such as images,text,videos etc.,

Free Database Softwares

MySQL-- MySQL is a widely used opensource Database.
SQLite-- SQLite is a  opensource Databas which is widely used in Mobiles phones and ipads .
PostgreSQL--  This is another Famous open source database.

All the above three databases are cross-platform which means it support multiple operating systems like linux,Windows,Mac OS X, Solaris , FreeBSD etc.,

SPLIT FUNCTION Comma Seperator with RowId

Monday, 19 December 2011


CREATE FUNCTION [dbo].[fn_Split](@locationlist varchar(5000))                   
RETURNS @ParsedList Table (Rowid int,location Varchar(100))                   
AS                   
BEGIN   
 Set @locationlist = @locationlist + ','   
 DECLARE @location varchar(100), @Pos int                   
 declare @cnt int               
 SET @location =replace((LTRIM(RTRIM(@locationlist))),'''','')           
 SET @Pos = CHARINDEX(',', @locationlist, 1)                     
 Set @cnt = 1                     
 IF REPLACE(@locationlist, ',', '') <> ''                     
 BEGIN                     
  WHILE @Pos > 0                     
  BEGIN                     
   SET @location = LTRIM(RTRIM(LEFT(@locationlist, @Pos - 1)))                     
   IF @location  <> ''                     
   BEGIN                     
    INSERT INTO @ParsedList (Rowid,location)                      
    VALUES (@cnt,@location) --Use Appropriate conversion                
 Set @cnt = @cnt + 1                    
   END                     
   SET @locationlist = RIGHT(@locationlist, LEN(@locationlist) - @Pos)                     
   SET @Pos = CHARINDEX(',', @locationlist, 1)                     
                     
  END                     
 END                      
 RETURN                     
END
 

Blogger news

Blogroll

Most Reading

8.6/10