Tag : MySql

ItSolutionStuff.com have tutorials for MySql tag, here you can study articles of MySql tag, MySql tag posts collection, most popular and useful tutorials of MySql tag, here you can find list of all relevant posts and example about MySql tag, we have lists of tutorials and examples about MySql tag. very simple and quick example collection of Latest MySql tag.




How to get last 2 days records from table using Mysql Query?

How to get last 2 days records from table using Mysql Query?

We may sometimes require to get few days ago records from table like last 2 days, last 3 days, last 10 days or last 15 days etc. Most of developer choose other logic but we can easily get using mysql query(using CURDATE and INTERVAL). In this example mysql query i have one table "elements" and colu.....

By Hardik Savani | July 22, 2016 | Category : PHP MySql

How to get current year rows using MySql Query PHP?

How to get current year rows using MySql Query PHP?

If you require to get all the records of current year using mysql query. for example you have one table "items" and columns are id, title, description, created_at and update_at, Now you want to get all records of this year. so you can fetch fields value using DATE_SUB and INTERVAL of mysql. In follo.....

By Hardik Savani | June 14, 2016 | Category : MySql


How to calculate age from date of birth column in mysql?

How to calculate age from date of birth column in mysql?

Sometimes, we require to get age from birthdate using mysql select query, we can do it in programming like php,.net and etc framework but if we can do it using mysql query. In bellow example mysql query you can learn how to get age from date field. We can get age value from using mysql DATEDIFF(). S.....

By Hardik Savani | June 1, 2016 | Category : MySql

How to rename column name foreign key constraint in MySql Query?

How to rename column name foreign key constraint in MySql Query?

This is more one post on mysql query, I don't remember exactly time but i had need to change name of foreign key constraint column field. We can rename field name easily if we didn't set foreign key constraint. But if you set foreign key constraint then you can't rename easily. I had rename directly.....

By Hardik Savani | May 4, 2016 | Category : MySql

How to execute mysql query in laravel?

How to execute mysql query in laravel?

Sometimes, we require to run directly mysql query on Laravel for example if you need to copy one table to other table using mysql query. I also need in one project and that's why i am fetching problem. But you can use sql query on laravel using db statement in bellow example you can learn how to run.....

By Hardik Savani | May 2, 2016 | Category : Laravel

Connection for controluser as defined in your configuration failed - Ubuntu phpmyadmin Resolve?

Connection for controluser as defined in your configuration failed - Ubuntu phpmyadmin Resolve?

When i was working on my PHP project since last 1 year on my current system and phpmyadmin was working very well. but one day i was working on my prjects and electricity off suddenly and when electricity on, i start my system again and open localhost/phpmyadmin, then i found following error: <pre>Co.....

By Hardik Savani | April 8, 2016 | Category : Ubuntu

Example of trigger on after delete with update query mysql

Example of trigger on after delete with update query mysql

Sometimes we need to fire trigger like after delete update some fields of another tables. for example if you have chat_message tables and when remove row on this table then we need to update "remove_counter(remove_counter + 1)" on users table. i did give you bellow example you can see how to write t.....

By Hardik Savani | April 5, 2016 | Category : PHP MySql SQL

Laravel 5 database backup using Laravel Backup Package

Laravel 5 database backup using Laravel Backup Package

In this post, i want to show you how to take database backup using Laravel backup package. this package will provide command to take backup from your live server and that command you can use in crontab file on server, that way you can get backup daily on every hourly etc as you want. Database backup.....

By Hardik Savani | March 28, 2016 | Category : Laravel

How to get current month data in MySql PHP ?

How to get current month data in MySql PHP ?

If you require to get all the records of current month using mysql query. for example you have one table "items" and columns are id, title, description, created_at and update_at, Now you want to get all records of this month. so you can fetch fields value using DATE_SUB and INTERVAL of mysql. In fol.....

By Hardik Savani | March 17, 2016 | Category : PHP MySql

Sql function remove numeric characters from column example

Sql function remove numeric characters from column example

Mysql custom fucntion is a very prety and intresting concept. In this posts i want to create one custom mysql function for remove numeric characters from table field value. this function through you can also remove numeric characters from string in mysql. in following sql query fire in your mysql or.....

By Hardik Savani | March 12, 2016 | Category : PHP MySql SQL MSSQL