Archive for the ‘Database’ Category

Page 1 of 212

Understanding Primary Key(PK) Constraint in Oracle

Understanding Primary Key(PK) Constraint in Oracle
The Primary Key(PK) constraint is the most basic concept of any RDBMS (I am particularly interested in Oracle). Yet, I have noticed people getting confused when it comes to the practical usage and asking questions like: - I have disabled PK and now oracle is doing full table scan. - How PK constraints and indexes are related/different? - How ... Full story

Database Connection Pooling in Tomcat using Eclipse

Database Connection Pooling in Tomcat using Eclipse
Database Connection Pooling is a great technique used by lot of application servers to optimize the performance. Database Connection creation is a costly task thus it impacts the performance of application. Hence lot of application server creates a database connection pool which are pre initiated db connections that can be leverage to increase performance. Apache Tomcat ... Full story

Fast data copy with “Create Table Select From” in PL/SQL

Fast data copy with
Although I work mainly in Java/J2EE, recently I had a requirement in Oracle to take temporary backup of a table and compare the data of original table with this backup table. So I had to copy the data from table A to a temp table TA. First I tried creating temp table normally and copied the ... Full story

Fetch Random rows from Database (MySQL, Oracle, MS SQL, PostgreSQL)

Fetch Random rows from Database (MySQL, Oracle, MS SQL, PostgreSQL)
Ever thought why would one need to fetch random rows from a database table? You may want to display some random information (like articles/pages/links) to your user. I had a requirement wherein I had to fetch 10 random rows from MySQL database and display it on screen. I used following simple query for retrieving random records ... Full story

Full-Text Search using MySQL: Full-Text Search Capabilities

Full-Text Search using MySQL: Full-Text Search Capabilities
Have you ever thought how does the search functionality is implemented in all the websites! Most of the internet blogs and websites are powered by MySQL database. MySQL provides a wonderful way (Full-text Search) of implementing a little search engine in your website. All you have to do is to have MySQL 4.x and above. MySQL ... Full story

Generating Tag cloud with PHP and MySQL

Generating Tag cloud with PHP and MySQL
The basic idea this time is to present a way to form a tag cloud from user input text and text entered in the past. A tag cloud is a visual depiction of user-generated tags, or simply the word content of a site, used typically to describe the content of web sites. for this we will create an HTML form that will accept user text & also ... Full story

MARIA, An extended MyISAM engine for MySQL

MARIA, An extended MyISAM engine for MySQL
Let us talk about Maria.. no no not Maria Sharapova, its new version of MyISAM engine for MySQL which is claimed to be crash safe and provides more concurrency. It aims at becoming fully transactional (ACID). Following are the features of Maria. Features ul.myPost li{text-decoration:none;border:none;list-style-type:disc;margin-left:10px;} ACID (Atomicity, Consistency, Isolation, Durability) Commit/Rollback Concurrent selects (via MVCC) Row locking Group commit Although Maria itselft is ... Full story

MySQL Database Backup using mysqldump command.

MySQL Database Backup using mysqldump command.
Since its release in 1995, MySQL has became one of the most commonly used database in Internet world. A lot of small and medium businesses uses MySQL as their backend db.  Its popularity for use with web applications is closely tied to the popularity of PHP, which is often combined with MySQL. Wikipedia runs on ... Full story

How to: Reset MySQL root password

Resetting the root password of a MySQL database is trivial if you know the current password if you don't it is a little trickier. Thankfully it isn't too difficult to fix, and here we'll show one possible way of doing so. If you've got access to the root account already, because you know the password, you can change it easily: gaurav@gaurav:~$ mysql --user=root --pass mysql Enter password: mysql> update ... Full story

Problem with comparison of float or double column in MySQL

Problem with comparison of float or double column in MySQL I had a problem in comparing the number with decimal point with a float column in MySql. After some investigation I came to know that, in most of the computer architecture, the value of floating point numbers is stored as approximation. So if you compare the 21.40 with the given column, it actually compare the value ... Full story
Page 1 of 212
Copyright © 2010 ViralPatel.net. All rights reserved.