Mohammad Towhidul Islam

    22-Aug-20 04:20:56 pm

    Automatically delete records in child table when delete record in parent table using mysql trigger

    Automatically delete records in child table when delete record in parent table using mysql trigger
    delimiter // drop trigger if exists ad_question_bank// create trigger ad_question_bank after delete on mcq_bank_master for each row begin delete from mcq_bank_details where question_id=old.id; ...

    Read More


    Mohammad Towhidul Islam

    22-Aug-20 03:40:46 pm

    Create mysql user with specified database of all privileges

    Create mysql user with specified database of all privileges
    For the latest version create database if not exists wdpf_40_alam; drop user if exists alam@localhost; flush privileges; create user alam@localhost identified with mysql_native_password by '...

    Read More


    Mohammad Towhidul Islam

    22-Aug-20 03:06:42 pm

    Copy mysql table rows from one table to another table

    Copy mysql  table rows from one table to another table
    Copy to existing table with same structure including related table
    INSERT IGNORE INTO question_bank_certification SELECT * FROM mcq_bank_master where subject_id in(136); INSERT IGNORE INT...

    Read More


    Mohammad Towhidul Islam

    23-Dec-16 10:15:10 pm

    Query to swap row values in mysql

    Query to swap row values in mysql
    First you have to create a tmp_field update item_uom_factor set factor=(select factor from item_uom_factor where item_id=5 and level=3) where level=2 and item_id=5 update item_uom_factor ...

    Read More


    Mohammad Towhidul Islam

    11-Dec-16 11:14:18 am

    How to update field by increment in mysql

    How to update field by increment in mysql
    SET @a = 0; UPDATE item_master set order_by=(@a:=@a+1); ...

    Read More


    Mohammad Towhidul Islam

    17-Oct-15 11:41:49 am

    Understanding MySQL Cursor

    Understanding MySQL Cursor
    In this tutorial, you will learn how to use MySQL cursor in stored procedures to iterate through a result set returned by a SELECT statement. What is Cursor? Cursor in MySQL is almost same as cu...

    Read More


    Mohammad Towhidul Islam

    07-Oct-15 09:43:58 am

    MySQL Data types and Attributes Example

    MySQL Data types and Attributes Example
    1. Date and Time Data Types: a) DATE: create table student( id int(10) primary key auto_increment, name varchar(20) not null, date_of_birth date // Date datatype column ...

    Read More


    Mohammad Towhidul Islam

    26-Jul-15 03:18:25 pm

    MySQL Descriptive Questions and Answers, WPSI, IDB-BISEW

    MySQL Descriptive Questions and Answers, WPSI, IDB-BISEW
    1. What are MySQL clients? Answer: The MySQL server is used to persist the data and provide a query interface for it (SQL). The mysql clients purpose is to allow you to use that query interfac...

    Read More


    Mohammad Towhidul Islam

    30-Jun-15 12:03:28 pm

    Dump and restore a single table from MySQL

    Dump and restore a single table from MySQL
    Dumping from a localhost database Dump: mysqldump -u <db_username> -p db_name table_name > table_name.sql Restore: mysql -u <user_name> -p db_name mysql> source <full_p...

    Read More


    Mohammad Towhidul Islam

    21-Jan-15 07:34:35 pm

    How To Set Up Master Slave Replication in MySQL

    How To Set Up Master Slave Replication in MySQL
    About MySQL replication MySQL replication is a process that allows you to easily maintain multiple copies of a MySQL data by having them copied automatically from a master to a slave database. T...

    Read More


First123Last
1 of 3 pages