May 2025 Discount: Comprehensive Database Performance Health Check | Testimonials

Home
  • Consulting
  • Training
  • Free Videos
  • All Articles
    • Interview Questions and Answers
    • SQL Tips and Tricks
    • SQL Performance
    • SQL Puzzle
    • Big Data
    • Blog Stats
    • SQL Books
    • Search SQLAuthority
  • Downloads
  • Hire Me
  • Health Check

Database – Beginning with Cloud Database As A Service

August 11, 2014
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
MySQL
I love my weekend projects. Everybody does different activities in their weekend – like traveling, reading or just nothing. Every weekend I try to do something creative and different in the database world. The goal is I learn something new and if I enjoy my learning experience I share with…
Read More

MySQL – Export the Resultset to CSV file

August 2, 2014
Pinal Dave
SQL, SQL Tips and Tricks
CSV, MySQL
In SQL Server, you can use BCP command to export the result set to a csv file. In MySQL too, You can export data from a table or result set as a csv file in many methods. Here are two methods. Method 1 : Make use of Work Bench If…
Read More

MySQL – UDF – Validate Integer Function

July 26, 2014
Pinal Dave
SQL, SQL Tips and Tricks
MySQL, SQL Function
There is a default function in SQL Server called ISNUMERIC to determine if the string is numeric. In SQL Server ISNUMERIC returns 1 for non numerials also. Ex ISNUMERIC (‘,’) returns 1. To avoid this you can write a user defined function as shown over here. In MySQL, there is…
Read More

MySQL – How to Format Date in MySQL with DATE_FORMAT()

July 19, 2014
Pinal Dave
SQL, SQL Tips and Tricks
MySQL, SQL DateTime
MySQL supports formatting the datetime values into a different formats using DATE_FORMAT() function. This function accepts date/datetime values as a first parameter and returns into a specific format defined as a second parameter. Let us explore this with the following examples which are self-explanatory Define a DATETIME variable SET @date:='2014-06-16…
Read More

MySQL – How INSERT() Function Works for MySQL

July 12, 2014
Pinal Dave
SQL, SQL Tips and Tricks
MySQL
You know there is an INSERT statement which is used to add data to a table. But did you know that there is an INSERT function which will replace certain characters within a string? INSERT() function in MySQL is used to insert a substring at the specified position up to…
Read More

MySQL – Add a Column at Particular Ordinal Position in Table

June 28, 2014
Pinal Dave
SQL, SQL Tips and Tricks
MySQL, SQL Scripts
Sometimes you may need to add a column at a particular ordinal position in the table. In SQL Server there is no option to do it via SQL although you can use Designer from SQL Server Management Studio. In MySQL you can do it as part of ALTER TABLE statement.…
Read More

MySQL – Dynamic SQL with EXECUTE and PREPARE Statements

June 20, 2014
Pinal Dave
SQL, SQL Tips and Tricks
MySQL
MySQL supports Dynamic SQL with the help of EXECUTE and PREPARE statements. Suppose you have a scenario where you need to pass table name as parameter value and returns all column values, you can use Dynamic SQL. Let us create this table and data. CREATE TABLE TestTable (ID INT, Col…
Read More
Previous 1 … 5 6 7 8 9 10 11 … 17 Next
  • SQL Interview Q & A
  • Testimonials
  • Search
  • Privacy Policy

© 2006 – 2025 All rights reserved. pinal @ SQLAuthority.com

Go to mobile version