Thursday, January 31, 2013

How to Run the MySQL Query Through the Command Prompt?

1 comments 1/31/2013
Check out useful posts regarding MySQL optimization
  • How to Backup/Restore/Crate/Drop the MYSQL Data Base through the Command Prompt?
  • how to optimize the Stored Procedure?
  • how to avoid the Cursors inside the Stored procedure?

  • To run the query directly from the command Prompt:
    mysql –u[Username] –p[Password] -e "select * from tbl_emp where emp_id=2" [DataBaseName]
    -e’ :- execute the query
    Even we can store the result to file
    mysql –u[Username] –p[Password] -e "select * from tbl_emp where emp_id=2" [DataBaseName] > D:\test.log
    Read More»

    Tuesday, January 29, 2013

    How to Backup/Restore/Crate/Drop the MYSQL Data Base through the Command Prompt?

    2 comments 1/29/2013
    There are no of IDEs (SQLyog) are to handle the MySQL Databases, but it’s always better to use command prompt instead of IDE. It will reduce the processing time as well as burden on the server. we discussed about how to optimize the Stored Procedure? and how to avoid the Cursors inside the Stored procedure?.
    To backup the Database:
    mysqldump –u[Username] –p[Password] --database [DatabaseName] > D:\DBBackup.sql
    To take backup with all the Databases :
    --all-databases :- use to take backup all DataBases
    mysqldump –u[Username] –p[Password] --all-databases > D:\DBBackup.sql
    To take backup with Stored procedures, functions, triggers, views :
    --routines :- Use to take backup with all Stored procedures, functions, triggers, views.
    mysqldump –u[Username] –p[Password] --routines --database [DatabaseName] > D:\DBBackup.sql
    Read More»

    Saturday, January 26, 2013

    How to Avoid the Cursor in Stored Procedures

    1 comments 1/26/2013
    What is Cursor?
    A cursor is a temporary work area,it will create in memory when a SQL statement is executed. A cursor holds set of records accessed based on a select statement. This temporary work area is used to store the data retrieved from the database, and manipulate/process this data row by row. A cursor can hold more than one row, but can process only one row at a time. The set of rows the cursor holds is called the active set.
    Why we need to avoid the cursor?
    Mostly we will use cursor inside Stored Procedures, we have seen how to optimize the stored procedure,Cursors are one of the most costliest operations in sql,it's better to avoid the Cursors. We can avoid the Cursors in following ways...
    Read More»

    Saturday, January 19, 2013

    Stored Procedure Optimization Tips in SQL

    1 comments 1/19/2013
    Avoid using temporary tables.
    If required use it in OLAP but NOT in OLTP. If required in OLTP, then plan on creating a permanent table. (Temporary tables eat up a lot of resources (CPU and memory) by the database engine. Temporary tables definition should have primary key, constraits and foreign keys if required.)


    We can divide IT systems into transactional (OLTP) and analytical (OLAP). In general we can assume that OLTP systems provide source data to data warehouses, whereas OLAP systems help to analyze it.

    Read More»

    Thursday, December 6, 2012

    Nokia Lumia 920 Vs HTC 8X : Winner Lumia 920

    0 comments 12/06/2012
    Here we are going to compare HTC 8X and Nokia Lumia 920 windows phone flagship models of HTC and NOKIA.We already wrote about Why Nokia Lumia 920 Worlds Most Innovative Phone?
    Windows Phone 8 is best mobile OS
  • Fluid and Seamless experience.
  • Best integration of social networks (Facebook,Twitter,LinkedIn).
  • IE10 (Common don't think abt old experience of IE,try once now IE10).
  • Camera apps(Apps integration into cam).
  • Most of the information right on ur home Screen.
  • Backup and Sync (Apps, Contacts, Photos, Videos, SMS).
  • I prefer Windows over Android(My first smartphone was Android).

  • Read More»
  • Friends

    Recent Posts

    New Comments

    Copyright 2008 All Rights Reserved Tech Tasks Template by Rajesh Kumar Chekuri

    Twitter Delicious Digg Stumbleupon Facebook More

    Connect to TT Facebook
    Back to Top