Solved Wanted Data dictionary display for MySQL (MariaDB) databases - Now solved


jimbo45

Well-known member
Pro User
VIP
Local time
8:08 AM
Posts
4,032
Location
Hafnarfjörður IS
OS
Windows XP,7,10,11 Linux Arch Linux
Hi folks
Is there a decent windows program which displays the data dictionary for tables in a MariaDB / MySQL database. PhpMyAdmin does it but I don't want to install that on Windows and I need this type of info on a Windows host. I know it can be done manually but that's a pain. I would like something like this that I can export into EXCEL workbooks. PhpMyAdmin especially over remote isn't that secure either.

Screenshot_20230721_093213.png
there must surely be some I.T applications programmers out there somewhere who've done this type of thing.##

Thanks
jimbo
 

My Computer

System One

  • OS
    Windows XP,7,10,11 Linux Arch Linux
    Computer type
    PC/Desktop
    CPU
    2 X Intel i7

My Computers

System One System Two

  • OS
    Windows 10 Home x64
    Computer type
    PC/Desktop
    Manufacturer/Model
    Custom
    CPU
    INTEL Core i5-11400
    Motherboard
    ASUS PRIME H570-PLUS
    Memory
    KINGSTON HyperX Fury Black DDR4 16GB (2 x 8GB) 3200MHz, CL16
    Graphics Card(s)
    EVGA GeForce GTX 750 Superclocked 1GB 128-Bit GDDR5
    Monitor(s) Displays
    LG 32MA68HY 32" IPS
    Screen Resolution
    1920 x 1080
    Hard Drives
    SAMSUNG 250GB 970 EVO Plus NVMe, M.2 SSD, Crucial 250GB MX500, SEAGATE 500GB Barracuda® 7200.12, SATA 3 Gb/s, 7200 RPM, 16MB cache
    PSU
    CORSAIR RM550x 80 PLUS Gold 550W
    Case
    ANTEC P10 FLUX
    Cooling
    be quiet! Pure Rock 2, 5 x 120 mm Case Fans
    Internet Speed
    480 + Mbps Up/ 12+ Mbps Down
    Browser
    Vivaldi Snapshot
    Antivirus
    Avast
  • Operating System
    Windows 10 Home x64
    Computer type
    PC/Desktop
    Manufacturer/Model
    Custom
    CPU
    Intel Core i5-750
    Motherboard
    ASUS P7P55D
    Memory
    Kingston HyperX Fury Black 8GB (2x4GB) DDR3-1600MHz CL8
    Graphics card(s)
    MSI GeForce GT 240 N240GT-MD1G/D5 1 GB DDR5
    Monitor(s) Displays
    LG 32MA68HY 32" IPS
    Screen Resolution
    1980x1040
    Hard Drives
    Samsung Electronics 840 EVO 120GB, SEAGATE 500GB Barracuda® 7200.12, SATA 3 Gb/s, 7200 RPM, 16MB cache
    PSU
    Antec TruePower New TP-550 550W
    Case
    Antec 300
    Cooling
    Cooler Master Hyper 212+, 4 Noctua NF-P12 120mm, 1 Noctua NF-P14 FLX
    Internet Speed
    480+ Mbps Down/12+Mbps Up
    Browser
    Vivaldi Snapshot
    Antivirus
    Avast
All geek to me :wink:



A Guy
Hi there
thanks for the reply but the MySQL syyntax is not the same as MariaDB for the MySQL reference. The other tools are "free trial" only.

I think I'll see if I can do a bit of debugging with phpmyadmin to see how it does it -- one can get the source on git-hub as well -- give me something to do today.

Cheers

jimbo
 

My Computer

System One

  • OS
    Windows XP,7,10,11 Linux Arch Linux
    Computer type
    PC/Desktop
    CPU
    2 X Intel i7
Hi again
I've downloaded the source code -- there is a data dictionary section that looks if I run it on linux I can put a break point in it and try some old fashioned debugging -- not done for 20 years or more now !!!!!!

Screenshot_20230721_111217.png


open the source index.twig : and putting a few break points might yield results.

Screenshot_20230721_111724.png

I'd prefer to do it in Windows but I haven't a clue on how to compile / make etc stuff on windows or set break points. I've installed this on Linux from compile and it works so I'll eneter my break point, abend (crash) function re-compile and have a go with it and should have a play -- I can always cause a kernel crash with dump at the end of routine to get the generated sql function for the dictionary if step through fails,

Anyway off for an early lunch / late breakfast.

Cheers
jimbo
 

My Computer

System One

  • OS
    Windows XP,7,10,11 Linux Arch Linux
    Computer type
    PC/Desktop
    CPU
    2 X Intel i7
Hi folks

Marking now as essentially solved. Linux debug saved the day !!!!

Think I've got it essentially cracked.Easy enough to show all the DB's in the database.

so for each DB


1) get all the tables - again easy enough.

2) for each table show the main definition and indexes as follows


Screenshot_20230721_142814.png

finally show the linked columns / foreign keys if any

Screenshot_20230721_144026.png

Now all I need is a script to go through each database in turn run the queries in each table and push the output into a csv file or whatever for excel. I've done the hard bit in getting the data - the other should just be elementary "loop" type coding.

I'm marking as Solved now as I've got all the required data and done the hard bit. The rest is just bash scripts etc. - if anybody wants to do a Windows project on that -- fair do's.

By the way easy enough to run the sql queries on windows from a remote Linux server hosting MariaDB -- just SSH into the server and run the commands as per above from the windows command line. You need to ensure though the MarioaDB / Mysql DB allows remote access if server is not local -- change that in the mariadb / mysql config file (or get the DBA admin to do it if you don't have those rights. On a test laptop shouldn't be a problem to a test server - Windows can even be a VM.

change config to : (uncomment bind address and restart the DB server).
#innodb_autoinc_lock_mode=2
#
# Allow server to accept connections on all interfaces.
#
bind-address=0.0.0.0 <======================
#
# Optional setting
etc etc

I think I deserve some Beer after that one. !!!! Or even something stronger -- maybe some Scottish "Amber Nectar". !!


Cheers
jimbo
 
Last edited:

My Computer

System One

  • OS
    Windows XP,7,10,11 Linux Arch Linux
    Computer type
    PC/Desktop
    CPU
    2 X Intel i7

Latest Support Threads

Back
Top Bottom