Offline DB Viewer

Take command of air and naval assets from post-WW2 to the near future in tactical and operational scale, complete with historical and hypothetical scenarios and an integrated scenario editor.

Moderator: MOD_Command

Post Reply
Twistedpretzel
Posts: 73
Joined: Sun Sep 06, 2020 2:31 pm

Offline DB Viewer

Post by Twistedpretzel »

https://github.com/twistedpretzel/cmo-d ... tag/v1.0.1

1. Go to the Releases page and download build_dashboard.exe from the latest release.

2. Copy it into your game's DB folder — the one that contains DB3K_517.db3. On a typical Steam install that's:
...\steamapps\common\Command Modern Operations\DB\
Double-click build_dashboard.exe. It finds the newest database automatically, builds the dashboard (about ten seconds), and opens it in your browser. Done.

That's the whole process — no Python, no command line, nothing to type.

First run: a blue "Windows protected your PC" box may appear. That's SmartScreen being cautious about a new file from an unknown indie author — it is expected here and does not mean anything is wrong. Click More info → Run anyway. If you'd like to confirm the download first, each release includes a build_dashboard.exe.sha256 checksum you can verify.

The generated DB3K_517_dashboard.html is saved right next to the game's database — it's a permanent file, not just a browser view. Keep it in the DB folder (so it can find the unit photos) and double-click that .html, or bookmark it, to reopen any time — you don't need to rebuild. Only re-run the tool when your game database updates.

Want an older database? Double-clicking always builds the newest. To build a specific one instead, drag its .db3 file onto build_dashboard.exe (or, from a terminal, build_dashboard.exe DB3K_515.db3). The dashboard is written next to whichever database you pick.

"Windows protected your PC" on the .exe → expected for an unsigned indie tool; click More info → Run anyway.

https://github.com/twistedpretzel/cmo-db-dashboard

I'd like to provide the full prebuilt html for ease of use, but providing this includes game data from the DB files which violates the EULA, so there is some user effort required to get it up and running.

A single-file, offline HTML dashboard for browsing and analysing the Command: Modern Operations unit database.

You point the included script at the database from your own CMO install and it generates a self-contained .html file you can open in any modern browser.

Every number is extracted from the database. Where a value is a modelled estimate rather than a stored field — notably the RCS-scaled radar detection ranges — the page says so and shows the method, so you can sanity-check it. Treat radar/IR ranges and threat rings as clean-air planning envelopes: they don't account for terrain masking, jamming, or the game engine's full dynamic detection model. Browse all five platform types plus sensors and weapons, with fast search, sortable columns, and rich filters (guidance, features/codes, damage points, target class, sensor capability/band, "carries weapon family", operator, era, and more). One-click CSV export of any filtered list.

Detail pages with type-aware visualisations — radar frequency strips and detection envelopes, optics/IR zoom, sonar depth envelopes, ESM direction-finding, weapon engagement envelopes and warhead breakdowns, per-aspect signatures, propulsion speed-by-altitude curves, and the mounts/magazines/loadouts each platform carries.

Compare up to four platforms, sensors or weapons side by side with overlaid envelopes.

Systems tools: an Electronic Warfare explainer (OECM/DECM), a Detection matchup calculator (at what range does X detect Y, by radar/IR/EO, per aspect), and Threat rings (a platform's search / engagement-radar / SAM envelope, scaled to a chosen target's radar cross-section).

Analysis tools: a Trend explorer (plot any metric against any other), and Leaderboards (top-N by speed, range, stealth, quietness, etc., with a service-era timeline).
DB Dash 4.jpg
DB Dash 4.jpg (405.37 KiB) Viewed 337 times
DB Dash 3.jpg
DB Dash 3.jpg (355.77 KiB) Viewed 337 times
DB Dash 2.jpg
DB Dash 2.jpg (250 KiB) Viewed 337 times
DB Dash 1.jpg
DB Dash 1.jpg (337.52 KiB) Viewed 337 times
Last edited by Twistedpretzel on Fri Sep 04, 2026 10:55 pm, edited 3 times in total.
serjames
Posts: 209
Joined: Sun Feb 21, 2016 11:48 am

Re: Offline DB Viewer

Post by serjames »

Wow... Seriously cool I love the visualisations too. You should add them to the wishlist - I think they'd be great in game
Parel803
Posts: 969
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Offline DB Viewer

Post by Parel803 »

Thank you for sharing.
regards GJ
Twistedpretzel
Posts: 73
Joined: Sun Sep 06, 2020 2:31 pm

Re: Offline DB Viewer

Post by Twistedpretzel »

Thanks. I'm definitely open to feedback, but with the current state of AI tooling I'm sure people can tweak it to fit their desires.

Regarding the trend explorer and leaderboard, I don't know if there is a practical use case but they show some stats which may of be interest.
Parel803
Posts: 969
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Offline DB Viewer

Post by Parel803 »

first thing comes to mind, don't know about possibilities, would be filter; only seeing present ones on units.
if its in I didn't check enough (I will)
regards GJ en very nice tool indeed.
Twistedpretzel
Posts: 73
Joined: Sun Sep 06, 2020 2:31 pm

Re: Offline DB Viewer

Post by Twistedpretzel »

Parel803 wrote: Fri Sep 04, 2026 3:16 pm first thing comes to mind, don't know about possibilities, would be filter; only seeing present ones on units.
if its in I didn't check enough (I will)
regards GJ en very nice tool indeed.
Good feedback, you're correct that needs to be changed. Thanks.
JFS737
Posts: 191
Joined: Fri Sep 08, 2017 4:04 am

Re: Offline DB Viewer

Post by JFS737 »

This sounds amazing, quick access to the DB of CMO!?
I may need a touch of help :)
I downloaded the files and put them into the CMO DB directory which has DB3K_517.db3.....

CMO Database Python README.md
cmo_db_dashboard.template.html
build_dashboard.py


I have Python 3.14 installed on my computer (in appdata). When I run the

python build_dashboard.py DB3K_517.db3 command, I get a syntax error. (I tried 2 ways, both w error)

here it is...
Python 3.14.7 (tags/v3.14.7:823f032, Aug 5 2026, 10:51:32) [MSC v.1944 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> python build_dashboard.py DB3K_517
File "<python-input-0>", line 1
python build_dashboard.py DB3K_517
^^^^^^^^^^^^^^^
SyntaxError: invalid syntax
>>> build_dashboard.py DB3K_517.db3
File "<python-input-1>", line 1
build_dashboard.py DB3K_517.db3
^^^^^^^^
Also, I simply ran the script from the folder with the 517.db3 in it... double click... and nothing happens except a window pops up and vanishes too quick for me to see what it it. But no HTML is created.

I'm missing something simple naturally. Not so good with Programming. Any ideas?
Parel803
Posts: 969
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Offline DB Viewer

Post by Parel803 »

no programming knowledge at all. I changed mine to db 515 since I'm currently not on beta. Also asked my AI what I should do.
regards GJ
Nikel
Posts: 3359
Joined: Tue Mar 24, 2009 10:51 am

Re: Offline DB Viewer

Post by Nikel »

This was the error here.
"build_dashboard.py", line 7 <!DOCTYPE html>

^SyntaxError: invalid syntax

I had no idea so asked the AI, suggested to download the raw files from the github site and that was correct.


Thanks for the effort Twistedpretzel :)

Perhaps you can do something similar with the logs files.

All the information stored in them presented in a clear and beautiful format?


DBV.gif
DBV.gif (1.58 MiB) Viewed 175 times
JFS737
Posts: 191
Joined: Fri Sep 08, 2017 4:04 am

Re: Offline DB Viewer

Post by JFS737 »

I downloaded the 3 files from github.... can you be more specific? I placed them in my db folder. I then double clicked the script with no luck and then tried to manually run the command via python itself with no luck.

Do I double click the py file to run it or run it using Python?
If Python, what is the exact command to run?. build_dashboard.py DB3K_517.db3 is no good
and python build_dashboard.py DB3K_517.db3 is no good

I also tried the DB3K_515.db3 as well.... no good. Syntax error Seems that in red and underscored is DB3K_517 or 515.... flagging those?

Thanks for any help.... I'm a rock.
Parel803
Posts: 969
Joined: Thu Oct 10, 2019 3:39 pm
Location: Netherlands

Re: Offline DB Viewer

Post by Parel803 »

From my AI (hope it helps):

Steps to get it working
Get the two files. Download build_dashboard.py and cmo_db_dashboard.template.html from the GitHub repo.
Put them in your CMO DB folder — the one containing DB3K_517.db3 (and usually a CWDB_*.db3 and an Images folder). On a typical Steam install that's:
...\steamapps\common\Command Modern Operations\DB\
Run the script from that folder, requires Python 3.8+ (standard library only, nothing to pip install):
python build_dashboard.py DB3K_517.db3

Takes about 10 seconds and writes DB3K_517_dashboard.html next to it. Swap the filename for whichever .db3 version your install actually has (e.g. DB3K_518.db3, or CWDB_517.db3 for the Cold War database).
4. Double-click the generated HTML to open it in your browser (Chrome/Edge 80+, Firefox 113+, or Safari 16.4+ — it needs DecompressionStream support).

Keep the HTML inside the DB folder so it can find unit photos via relative path; moved elsewhere it still works, just without pictures.

Common snags:

Blank page / decompression error → update your browser.
"template not found" → run from the folder with the template file, or pass --template /path/to/it.
No unit photos → HTML isn't in the DB folder anymore (harmless, just cosmetic).

Note the generated HTML itself shouldn't be redistributed publicly (it embeds proprietary DB content) — only the script+template should be shared, which is exactly what's on GitHub.

----
You type that into a terminal (Command Prompt / PowerShell on Windows, or Terminal on Mac/Linux), opened inside your CMO DB folder — not into the game itself.

Easiest way on Windows:

Open File Explorer and navigate to the DB folder where you put the two files and where DB3K_515.db3 lives.
In the address bar at the top of the File Explorer window, type cmd and press Enter. This opens a Command Prompt already pointed at that exact folder.
In the black window that opens, type:
python build_dashboard.py DB3K_515.db3

and press Enter.
4. Wait about 10 seconds — it'll write DB3K_515_dashboard.html into that same folder.

If typing cmd in the address bar doesn't work, alternatively: hold Shift and right-click an empty space inside the folder, then choose "Open PowerShell window here" (or "Open in Terminal", depending on your Windows version) — same effect.

If you get an error like "'python' is not recognized", Python either isn't installed or isn't on your PATH. You'd need to install it from python.org (tick "Add python.exe to PATH" during install) and then reopen the terminal.

regards GJ
Nikel
Posts: 3359
Joined: Tue Mar 24, 2009 10:51 am

Re: Offline DB Viewer

Post by Nikel »

In the Command prompt.

Browse to the folder where the db are.

And paste the command, enter.
JFS737
Posts: 191
Joined: Fri Sep 08, 2017 4:04 am

Re: Offline DB Viewer

Post by JFS737 »

Yeah I did all that... it's in the read.me.... and I can read.
So I put the files in, ran the py and nothing....
Then tried Python and the commands.... errors....


What is does NOT say is that it must be run from the command line and Python must be closed and the the windows prompt must be on the directory with the db3's.

So for other Rocks..... it's this. In order to get it to work, you need to
1. Download the files and place them in the DB directory (you only need the .py and .html)
2. Download install Python 3
3. Close Python 3 if it's open using command in Python exit()
4. in command Prompt (type CMD in the start window to get to it) go to the directory that the CMD DB is in (Use DIR and CD commands to navigate to them)
5. Input this python build_dashboard.py DB3K_517.db3
6. Hit enter
7. HTML is constructed and placed inside the DB folder.... double click it.

Hope this helps other rocks.
thewood1
Posts: 10393
Joined: Sun Nov 27, 2005 6:24 pm
Location: Boston

Re: Offline DB Viewer

Post by thewood1 »

"and I can read"

The guy is trying to help. How about a little common courtesy. Sheesh.
JFS737
Posts: 191
Joined: Fri Sep 08, 2017 4:04 am

Re: Offline DB Viewer

Post by JFS737 »

Was he really though? First he responded with this....
"no programming knowledge at all. I changed mine to db 515 since I'm currently not on beta. Also asked my AI what I should do.
regards GJ"

Hmmm.. cryptic at best for those outside the "know". And I'm not the best case... so of no use and a bit curt IMHO.

Then he posts the read.me... which I thought was a bit rude. Then I was rude... you are correct. Then I posted something helpful.

My apologies to Parel803.

Regards
Nikel
Posts: 3359
Joined: Tue Mar 24, 2009 10:51 am

Re: Offline DB Viewer

Post by Nikel »

This is all a confusion, lost in translation or whatever.

Parel803 is a gentleman, cannot imagine anyone in the forum as polite as him.

Lets go back to Twistedpretzel's tool :)
Twistedpretzel
Posts: 73
Joined: Sun Sep 06, 2020 2:31 pm

Re: Offline DB Viewer

Post by Twistedpretzel »

Every list dropdown is now faceted: its options are computed from the rows matching all your other active filters, so they only ever show values that actually exist in what's displayed, each with a live count. Verified against your exact example — with Family = Bomb, the guidance dropdown drops from the full list to just "Unguided (170)"; no more "Sonar (torpedo)" on bombs. It cascades both ways (picking guidance = Sonar narrows the family list to torpedoes/sonobuoys/mines) and applies to the platform, sensor, and weapon lists alike. (The Parel803 update)

You run one small tool against the database from your own CMO install and it generates a self-contained .html file you can open in any modern browser. (Quality of life installation update / the JFS737 update)


https://github.com/twistedpretzel/cmo-d ... tag/v1.0.1

1. Go to the Releases page and download build_dashboard.exe from the latest release.

2. Copy it into your game's DB folder — the one that contains DB3K_517.db3. On a typical Steam install that's:
...\steamapps\common\Command Modern Operations\DB\
Double-click build_dashboard.exe. It finds the newest database automatically, builds the dashboard (about ten seconds), and opens it in your browser. Done.

That's the whole process — no Python, no command line, nothing to type.

First run: a blue "Windows protected your PC" box may appear. That's SmartScreen being cautious about a new file from an unknown indie author — it is expected here and does not mean anything is wrong. Click More info → Run anyway. If you'd like to confirm the download first, each release includes a build_dashboard.exe.sha256 checksum you can verify.

The generated DB3K_517_dashboard.html is saved right next to the game's database — it's a permanent file, not just a browser view. Keep it in the DB folder (so it can find the unit photos) and double-click that .html, or bookmark it, to reopen any time — you don't need to rebuild. Only re-run the tool when your game database updates.

Want an older database? Double-clicking always builds the newest. To build a specific one instead, drag its .db3 file onto build_dashboard.exe (or, from a terminal, build_dashboard.exe DB3K_515.db3). The dashboard is written next to whichever database you pick.

"Windows protected your PC" on the .exe → expected for an unsigned indie tool; click More info → Run anyway.

Cheers.
boogabooga
Posts: 1026
Joined: Wed Jul 18, 2018 12:05 am

Re: Offline DB Viewer

Post by boogabooga »

Was CWDB support ever considered?
The boogabooga doctrine for CMO: Any intentional human intervention needs to be able to completely and reliably over-ride anything that the AI is doing at any time.
JFS737
Posts: 191
Joined: Fri Sep 08, 2017 4:04 am

Re: Offline DB Viewer

Post by JFS737 »

Wow, Thank you Twisted. You put me to shame with your level head, generosity and skill. It works Great! Well done.
Post Reply

Return to “Command: Modern Operations series”