- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
What is the use of MySQL UNHEX() function?
As its name suggests, it is the opposite of HEX() function. Basically, UNHEX() function converts the hexadecimal number into the byte represented by the number. The value returned by it would be a binary string.
Syntax
UNHEX(str)
Here, str is a string which is to be converted into the byte represented by the number. The characters in the str must be a valid hexadecimal digit.
Example
mysql> Select UNHEX('5475746F7269616C73706F696E74'); +---------------------------------------+ | UNHEX('5475746F7269616C73706F696E74') | +---------------------------------------+ | Tutorialspoint | +---------------------------------------+ 1 row in set (0.00 sec)
- Related Articles
- What is the PHP equivalent of MySQL's UNHEX()?
- What is the use of MySQL FROM_UNIXTIME() function?
- What is the use of MySQL GET_FORMAT() function?
- What is the use of MySQL LAST_INSERT_ID() function?
- What is the use of MySQL CONCAT_WS() function?
- What is the use of MySQL TRUNCATE() function?
- What is the use of MySQL SUBSTRING_INDEX() function?
- What is the use of MySQL CHAR() function?
- What is the use of FIND_IN_SET () function in MySQL?
- What is the use of LOCATE() function in MySQL?
- What is the use of MySQL IFNULL() control flow function?
- What is the use of MySQL NULLIF() control flow function?
- What MySQL returns if I provide a non-hexadecimal number as an argument to UNHEX() function?
- What is the use of JavaScript eval function?
- What is the use of Math.hypot() function in JavaScript?

Advertisements