Skip to main content

Posts

What is difference between data profiling and query profiling

Data profiling Data profiling is the process of analyzing the source data to better understand, what is the condition of data. This task basically used in beginning of the development life cycle in OLAP or ETL application. So its related to OLAP and activities related to this process is data cleanings analysis, pattern analysis, number or nulls, aggregations, group , distinct values etc. Data Profiler is a tool available to do this. Query profiling SQL Server or any database technology provides utility or tool that help to discovery query and slow running queries. Query profiling is related to OLTP applications. This helps to performance tunning and optimizations. We do analysis on index scan/seek, query IO/CPU/Memory usage , physical and logical reads etc. Profiler is the tool in SSMS to do this.

Why JSON Came into Picture

What is JSON ? JSON stands for JavaScript Object Notation, and was first formalized by Douglas Crockford. JSON is a data format interchange - method of storing and transferring data. Mostly its uses such as data conversion (JSON to SQL) and exporting data from proprietary web apps or mobile apps. XML was a big buzzword in the early 2000’s, JSON become the buzzword in later few years.  Why JSON came into picture ? After 2005 applications & user requirements started growing rapidly, Hardware and software developed, the advent of Single Page Applications and modern mobile/web apps that we know today needed some kind of data interchange to function seamlessly. To fulfill user requirement technology started shifting into  new language-independent data interchange format that time JSON came into the Picture. JSON gained rapid popularity because it makes transferring data very easy. It’s also lightweight and easy to read and understand. There are few other reasons that JSON make

How to load huge amount of data from csv to postgre

Recently I got a defiance from a some developers regarding postgresql server is slow performance. In his opinion it is not able to fetch 5 lac record from CSV files. They show there aplication which was using (node.js+sequlize ORM). When executed it was really sucking in middle. 5 lac records are really in huge amount but postgre is alos being for high performance application. There is no question we can say that it can not able to fetch this amount of data. So I suggested him to start importing from short amount of records like top 6 then top 600 then top 6000 then 60000. Yeah he did and really it stopped after 60000 records. It failed from application, program is running, running and keep running.. So boll goes in my bucket then I started digging on database server configuration parameters like effective_cache_size, work_memory, Shared_buffers, Maximum_number_Connections, wal_buffers etc, given appropriate values as per best practices and current system resources. Then re

Backup oracle database using RMAN

RMAN (Recovery Manager) is a backup and recovery manager supplied for Oracle databases (from version 8) created by the Oracle Corporation. It provides database backup, restore, and recovery capabilities addressing high availability and disaster recovery concerns. How to start recovery manager in and connect to database? just go to bin folder of oracle and then execute C:\oraclexe\app\oracle\product\11.2.0\server\ rman target / <enter> or start-run-rman <enter> connect target / <enter> After connecting how to check configurations ? SHOW ALL; How to perform backup operation. BACKUP AS BACKUPSET DATABASE PLUS ARCHIVELOG; BACKUP AS BACKUPSET DATABASE How to check backup history? LIST BACKUP SUMMARY;

Real Life Oracle Fiction over a Large data set

After being SQL DBA 4+ years now since 2 years I am trying to be a DBA mean cross platform database administrator. So trying multiple technologies. MySQL, mongodb and Oracle too. My today's post is on oracle, true fiction working on large data-set. Actually I was testing CRUD and aggregations on oracle 11g over 21 millions records (21326826). I had a table employee having huge amount of data and there is a column city which have null values on 21 millions records. The story begins when I was trying to update these null value with some information. Column have already secondary index we have created on city column because result of group by was slow on city so for better response time we have created index on city column. Physical architecture of database and tables space are default . Table is present in user tablespace. We have not changed any configuration of oracle before, I am totally new on oracle.

Migrating MongoDB data to MySQL using Python

The database developers/DBAs go through the task of database migration very often in various projects. Most of the times, such tasks have source and destination using the same technology, for example, MS SQL Server to MS SQL Server or MySQL to MySQL, etc. But, in some challenging projects, we encounter some situations in which, the source and destination technologies differ, leaving us in a mess, for example, MySQL to MongoDB, etc. Even this situation can be handled, where we have to migrate from structured to non-structured database technology. But, when it comes to move data from non-structured to structured technology, it becomes a tedious task, for example, MongoDB to MySQL.  As a database developer, I was working on one such project where I was required to migrate data from MongoDB to MySQL. I tried the following steps at the initial level for connecting the source (MongoDB) to destination (MySQL) using Python Requirements : 1. Python 2.7 2. MongoDB 3.2 3. MySQL 5.7 4. My

CRUD Operations with MongoDB

CRUD operations indicates to the basic Insert, Read, Update and Delete operations. It is the most common requirement for any database how this will input and output. Today I want to share how to do CRUD operation with mongodb database, which is fast growing NoSQL Database. 1.) How to create or open any database in mongodb use <Database> 2.) How to list all collections show collections 3.) Read / find / search from documents all documents db.emp.find() where dept = CS db.emp.find({Dept:"CS"}) db.emp.find({"_id" : ObjectId("53eb50ab3bcd8479d0c302e3")}) Search name only db.EmpDetail.find ( { },  { name: 1 }) 3.) Search Documents Where dept = cs and parent is pradeep db.emp.find({Dept:"DOT", parent:"Avinash"}) 4.) Search Documents where Parent is Deepak or dept is java db.emp.find( { $or:[{parent:"Deepak"},{Dept:"java"}] } ) 5.) How to update to all users db.use