S
S
swcalc2018-09-13 21:09:33
MySQL
swcalc, 2018-09-13 21:09:33

How to write and read data in a file using MySQL as an example?

Hello, I am writing an application that must operate with data, but the end user is not provided with the opportunity to install a server.
Using the MySQL file as an example, I would like to know how to correctly write data to a file and read it back, if we have such a thing, I understand, like hexadecimal, but how to represent it in human form?
For example, data from a .frm file where tables are stored is the same in .ibd.

fe01 091c 0300 0010 0100 0030 0000 1000
f500 0000 0000 0000 0000 0002 0800 0800
0005 0000 0000 2100 0000 0000 0000 0010
0000 00c4 c500 0029 0000 0000 0000 0000
2f2f 0000 2000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000
0000 0000 0000 0000 0000 0000 0000 0000

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
swcalc, 2018-09-14
@swcalc

Thanks dimonchik2013 for the direction, I found what I was looking for https://habr.com/post/60317/

D
Dimonchik, 2018-09-13
@dimonchik2013

sqlite and analogues

A
Alexey Cheremisin, 2018-09-14
@leahch

Take www.h2database.com/html/main.html
And if you just need a key-value store in the form of a file, then mvstote www.h2database.com/html/mvstore.html
If you need to copy the object tree to disk and back, then I recommend kryo https://github.com/EsotericSoftware/kryo
And yes, you don't need to parse mysql files, it's Sisyphean work.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question