
{"id":1458,"date":"2013-09-12T17:22:29","date_gmt":"2013-09-12T16:22:29","guid":{"rendered":"http:\/\/dasini.net\/blog\/?p=1458"},"modified":"2016-03-25T21:22:02","modified_gmt":"2016-03-25T20:22:02","slug":"generate-html-with-the-mysql-client","status":"publish","type":"post","link":"https:\/\/dasini.net\/blog\/2013\/09\/12\/generate-html-with-the-mysql-client\/","title":{"rendered":"Generate html with the mysql client"},"content":{"rendered":"<p><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">I\u2019m a big fan of the MySQL command line tool ie the default text client modestly named: <\/span><\/span><\/span><a title=\"mysql \u2014 The MySQL Command-Line Tool\" href=\"http:\/\/dev.mysql.com\/doc\/refman\/5.5\/en\/mysql.html\" target=\"_blank\"><span style=\"color: #1155cc;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\"><span style=\"text-decoration: underline;\">mysql<\/span><\/span><\/span><\/span><\/a><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">. I use it everyday because you can do almost everything with it (DML, DDL, DCL, administrative tasks,&#8230;).<\/span><\/span><\/span><\/p>\n<p><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">It has many options including generate xml or html output.<\/span><\/span><\/span><\/p>\n<pre class=\"lang:sh decode:true\">$ mysql --help | grep \"\\--html\"\r\n -H, --html          Produce HTML output.<\/pre>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">So you can easily script it and generate an HTML document:<\/span><\/span><\/span><\/p>\n<p>&nbsp;<\/p>\n<pre class=\"lang:sh decode:true\">$ mysql -e\"SELECT now() as DATE;\" --html\r\n&lt;TABLE BORDER=1&gt;&lt;TR&gt;&lt;TH&gt;DATE&lt;\/TH&gt;&lt;\/TR&gt;&lt;TR&gt;&lt;TD&gt;2013-09-11 19:25:41&lt;\/TD&gt;&lt;\/TR&gt;&lt;\/TABLE&gt;<\/pre>\n<p>&nbsp;<\/p>\n<p><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">It\u2019s very simple and it\u2019s valid HTML but it is <\/span><\/span><\/span><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\"><b>not valid XHTML<\/b><\/span><\/span><\/span><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">!<\/span><\/span><\/span><\/p>\n<p><span style=\"color: #000000;\"><span style=\"font-family: Arial;\"><span style=\"font-size: medium;\">Why, in 2013, a tool generates HTML rather than XHTML ?<\/span><\/span><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I\u2019m a big fan of the MySQL command line tool ie the default text client modestly named: mysql. I use it everyday because you can do almost everything with it (DML, DDL, DCL, administrative tasks,&#8230;).<\/p>\n<p>It has many options including generate xml or html output.<\/p>\n<p>$ mysql &#8211;help | grep \u00ab\u00a0\\&#8211;html\u00a0\u00bb<br \/>\n -H, &#8211;html          Produce HTML output.<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"footnotes":""},"categories":[207],"tags":[],"class_list":["post-1458","post","type-post","status-publish","format-standard","hentry","category-misc"],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p9LfWW-nw","jetpack-related-posts":[{"id":6752,"url":"https:\/\/dasini.net\/blog\/2024\/08\/07\/heatwave-genai-your-ai-powered-content-creation-partner\/","url_meta":{"origin":1458,"position":0},"title":"HeatWave GenAI: Your AI-Powered Content Creation Partner","author":"Olivier DASINI","date":"7 ao\u00fbt 2024","format":false,"excerpt":"Generative artificial intelligence (GenAI) is reshaping the content creation landscape. By training on vast datasets, these \"intelligent\" systems can produce new, human-quality content across a multitude of domains. Oracle's HeatWave GenAI (starting with version 9.0.1) is at the forefront of this revolution, offering an integrated platform that combines in-database large\u2026","rel":"","context":"Dans &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/dasini.net\/blog\/category\/ai\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=700%2C400&ssl=1 2x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=1050%2C600&ssl=1 3x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2024\/07\/hw_product_image.png?resize=1400%2C800&ssl=1 4x"},"classes":[]},{"id":7711,"url":"https:\/\/dasini.net\/blog\/2025\/04\/15\/build-an-ai-powered-search-engine-with-heatwave-genai-part-3\/","url_meta":{"origin":1458,"position":1},"title":"Build an AI-Powered Search Engine with HeatWave GenAI (part 3)","author":"Olivier DASINI","date":"15 avril 2025","format":false,"excerpt":"In this latest post, the final part of my series on building an AI-powered search engine with HeatWave GenAI, I dive into enhancing AI-powered search by embedding full article content into HeatWave. By cleaning HTML, chunking content, generating embeddings, and running semantic similarity searches directly within HeatWave, we unlock highly\u2026","rel":"","context":"Dans &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/dasini.net\/blog\/category\/ai\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":8442,"url":"https:\/\/dasini.net\/blog\/2025\/10\/14\/querying-the-unstructured-natural-language-to-sql-for-json-data\/","url_meta":{"origin":1458,"position":2},"title":"Querying the Unstructured: Natural Language to SQL for JSON Data","author":"Olivier DASINI","date":"14 octobre 2025","format":false,"excerpt":"Bridging natural language processing with semi-structured data brings both opportunity and complexity. MySQL HeatWave GenAI\u2019s NL2SQL feature shows how natural language can simplify data interaction \u2014 even for JSON documents. Yet, because JSON embeds both data and metadata within a single column, LLMs may struggle without explicit schema cues. By\u2026","rel":"","context":"Dans &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/dasini.net\/blog\/category\/ai\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/10\/Querying-the-Unstructured-Natural-Language-to-SQL-for-JSON-Data-400.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":8285,"url":"https:\/\/dasini.net\/blog\/2025\/09\/30\/ask-your-database-anything-natural-language-to-sql-in-mysql-heatwave\/","url_meta":{"origin":1458,"position":3},"title":"Ask Your Database Anything: Natural Language to SQL in MySQL HeatWave","author":"Olivier DASINI","date":"30 septembre 2025","format":false,"excerpt":"Natural Language to SQL in MySQL HeatWave makes data accessible to everyone, not just SQL experts. By turning plain English into optimized queries, it removes barriers and speeds up insights. While best practices help ensure accuracy, the feature already shows how LLMs are transforming the way we work with data.\u2026","rel":"","context":"Dans &quot;AI&quot;","block_context":{"text":"AI","link":"https:\/\/dasini.net\/blog\/category\/ai\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=700%2C400&ssl=1 2x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=1050%2C600&ssl=1 3x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2025\/09\/nl2sql-demo3.gif?resize=1400%2C800&ssl=1 4x"},"classes":[]},{"id":6061,"url":"https:\/\/dasini.net\/blog\/2022\/07\/18\/iris-data-set-with-mysql-heatwave-machine-learning-zeppelin\/","url_meta":{"origin":1458,"position":4},"title":"Iris Data Set with MySQL HeatWave Machine Learning  &#038; Zeppelin","author":"Olivier DASINI","date":"18 juillet 2022","format":false,"excerpt":"During the last 20 years MySQL has democratized the usage of transactional databases. Now with MySQL HeatWave we are in the process of democratizing Analytics and Machine Learning. With MySQL HeatWave, valorizing your data has never been so easy! In this article I will show you how easy it is\u2026","rel":"","context":"Dans &quot;MySQL&quot;","block_context":{"text":"MySQL","link":"https:\/\/dasini.net\/blog\/category\/mysql-en\/"},"img":{"alt_text":"MySQL HeatWave a MySQL in-Memory Query Accelerator","src":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2022\/06\/HW_ML.png?fit=1012%2C431&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2022\/06\/HW_ML.png?fit=1012%2C431&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2022\/06\/HW_ML.png?fit=1012%2C431&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2022\/06\/HW_ML.png?fit=1012%2C431&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":4774,"url":"https:\/\/dasini.net\/blog\/2021\/08\/24\/discovering-mysql-database-service-episode-4-dump-your-mysql-data-into-an-object-storage-bucket\/","url_meta":{"origin":1458,"position":5},"title":"Discovering MySQL Database Service &#8211; Episode 4 &#8211; Dump your MySQL data into an Object Storage bucket","author":"Olivier DASINI","date":"24 ao\u00fbt 2021","format":false,"excerpt":"This is the fourth episode of \u201cDiscovering MySQL Database Service\u201c, a series of tutorials where I will show you, step by step, how to use MySQL Database Service and some other Oracle Cloud Infrastructure services. In the previous episode we\u2019ve created our Virtual Cloud Network, that provides you with complete\u2026","rel":"","context":"Dans &quot;Cloud&quot;","block_context":{"text":"Cloud","link":"https:\/\/dasini.net\/blog\/category\/cloud\/"},"img":{"alt_text":"MySQL Database Service","src":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2021\/06\/MDS_car_801x600.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2021\/06\/MDS_car_801x600.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2021\/06\/MDS_car_801x600.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dasini.net\/blog\/wp-content\/uploads\/2021\/06\/MDS_car_801x600.png?resize=700%2C400&ssl=1 2x"},"classes":[]}],"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/posts\/1458","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/comments?post=1458"}],"version-history":[{"count":5,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/posts\/1458\/revisions"}],"predecessor-version":[{"id":1617,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/posts\/1458\/revisions\/1617"}],"wp:attachment":[{"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/media?parent=1458"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/categories?post=1458"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dasini.net\/blog\/wp-json\/wp\/v2\/tags?post=1458"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}