Category: MYSQL

Concatenate all values of a column in mysql

Mysql group concatenate select to string In select query if you want to concatenate all values of a column(all cells) in a single string with a separator. Then you can use a pre...

Mysql match first n characters

Many time we have a series of number in rows and we want to match only first 4 or 5 numbers in that row then we can use mysql inbuilt function. For example I have a doctor table...

MYSQL basic for command line Part Two

Ok lets start with Part Two…In part one you got enough information how to start with SQL command line. So keep walking and try out other major basic stuff of SQL. I am providing...

MYSQL basic for command line Part One

For a beginner there is a list of all basic mysql commands. If you are working on command prompt or shell then you should have to learn these basics. I am listing some of basic not...

MySqli Connection Class

class Db_Mysqli { static $hostname; static $username; static $password; static $port; static $database; static $connection; /** * * @param String $hostname * @param String $username...

Mysql command line import-export single table

Go to terminal window To export type following command “mysqldump -u USERNAME -p dbname tableName > tableName.sql” Here mysqldump           is default mysql command...