[HN Gopher] Lightweight SQLite Editor for Windows
       ___________________________________________________________________
        
       Lightweight SQLite Editor for Windows
        
       Author : bbkane
       Score  : 120 points
       Date   : 2023-04-18 19:06 UTC (3 hours ago)
        
 (HTM) web link (github.com)
 (TXT) w3m dump (github.com)
        
       | gnoffa wrote:
       | Personally I really love SQLiteStudio which I use pretty much
       | daily: https://sqlitestudio.pl/
        
       | account-5 wrote:
       | Oh this looks good. I've been using: https://sqlitebrowser.org/
       | 
       | This seems to offer way more.
        
         | jdthedisciple wrote:
         | Been using the same, and I've been very content with it too.
         | 
         | Curious about this one.
        
           | MPlus88 wrote:
           | [dead]
        
         | chasil wrote:
         | I've never tried this, but it appears to be possible to use
         | Oracle SQL Developer to browse SQLite tables.
         | 
         | https://github.com/Trivadis/sqldev-jdbc-proxy
         | 
         | Oracle SQL Developer is a Java clone of Toad from Quest
         | software:
         | 
         | https://www.oracle.com/database/sqldeveloper/
         | 
         | Toad also bears a resemblance to the Windows app in the post.
        
         | precompute wrote:
         | >sqlitebrowser
         | 
         | Been using this for years. Fantastic tool.
        
       | akisej wrote:
       | Looks very cool! We use logicloop.com to connect across
       | databases, use ChatGPT to write, fix and explain SQL queries too
        
       | psychphysic wrote:
       | Was just looking for this! There is a decent viewer on the store
       | (aka can install in a pinch while in S mode).
       | 
       | But you couldn't even copy paste!
        
       | TehShrike wrote:
       | This looks inspired by the excellent SQLYog, which is one of the
       | apps I missed most when I switched from Windows to macOS. I still
       | haven't found a good macOS equivalent.
        
         | pbowyer wrote:
         | Same. I've tried DBeaver (its UI is an abomination) and
         | TablePlus (some of the UI is better but e.g hiding the database
         | search where they do - why?) and TablePlus is the one I'm
         | sticking with, but I still miss SQLYog. Especially the
         | permissions editor for database users.
        
           | TehShrike wrote:
           | TablePlus is the best I've found so far too. I tried Sequel
           | Pro for a couple years. Haven't found anything that competes
           | with SQLYog for browsing the schema while writing a query.
        
       | justsomehnguy wrote:
       | Kudos to the author for a meaningful screenshot right at the
       | start.
       | 
       | And with a basic Win32 GUI I can bet my pumpkin latte what it as
       | fast as SQLite itself.
        
         | haunter wrote:
         | >Kudos to the author for a meaningful screenshot right at the
         | start.
         | 
         | I was thinking about this recently that so many projects on
         | Github missing screenshots. I was thinking to make PRs to at
         | least show some basic functionality.
        
       | rr808 wrote:
       | Wish there was a great free open source GUI which works for for
       | Sybase or even jdbc.
        
       | pkage wrote:
       | I strongly recommend TablePlus for sqlite/postgres/other
       | databases, it's made my life significantly easier.
       | 
       | https://tableplus.com/
        
       | solarkraft wrote:
       | Windows-only seems to me like the most rapidly shrinking market.
        
         | roywashere wrote:
         | But it is a huge market!!! And o so many people I work with in
         | telcos and such work on their company provided windows laptops
        
         | adamrezich wrote:
         | which is a shame because I miss old-school highly-functional
         | win32 apps like this--bursting with soul and a flagrant
         | disregard for modern app design/development principles.
        
           | mrguyorama wrote:
           | You know, a tool, made by a tool maker, in the relevant
           | trade, making a tool meant to be used by tool makers.
           | 
           | As opposed to the stuff nowadays that seem to be marketed
           | first, made by whoever has the least power to ignore the job,
           | and using some abysmal javascript GUI framework that can't
           | even keep up with desktop framerate.
           | 
           | I also miss the days when the tools I used to do my job
           | didn't HIDE shit from me, like error messages. Sure, I might
           | not know what "ExtremelyExplicitNullException in doFrobThrob"
           | means, but when I paste that error message in the support
           | email, the engineer on the other side knows the exact line of
           | code that error was generated on, and which variable was
           | broken, and 9/10 times that's enough to actually find the
           | root cause and fix it. No telemetry required. I'm so tired of
           | vague, numbered error messages that nobody knows what line of
           | code it corresponds to and nobody cares anyway because it's
           | just going into a giant pile in the telemetry system that
           | nobody except one mediocre PM is allowed to pull bugs from.
        
         | 2h wrote:
         | What a selfish comment. Shame on you. It's open source. You
         | don't like it, you're welcome to add support for another OS, or
         | use something else.
        
           | roywashere wrote:
           | Adding support to a tool for a different is that is developed
           | for winapi is really not a thing. If it was written for GTK
           | or Qt or electron then it is possible. But I would guess you
           | should just best write a new app instead?
        
           | Brian_K_White wrote:
           | It was neither selfish nor a demand. It was an observation.
        
         | ezconnect wrote:
         | Don't worry the PC market is shrinking.
        
         | cozzyd wrote:
         | haven't tried, but it almost certainly works fine in wine...
         | 
         | edit: tested it, and yes it works (though sometimes you have to
         | resize window to get updates for some reason...)
        
       | anditherobot wrote:
       | I love that it's just 12 files, straight to the point, no
       | unnecessary boilerplates
        
         | whizzter wrote:
         | You didn't happen to look at those files? main.cpp is 8900
         | lines, dialogs.cpp something almost as long. It's probably
         | super performant but I wouldn't volounteer to maintain that
         | codebase unless getting paid (And the commit history only shows
         | the author...)
        
       | petepete wrote:
       | I love that this looks very much like Query Analyzer, the
       | lightweight querying tool that came with SQL Server 2000. Back
       | then, server management, querying and profiling were handled by
       | separate utilities that did one thing well.
       | 
       | They were all replaced with SSMS, which was a slow abomination.
       | 
       | Query Analyzer is my favourite SQL editing environment to this
       | day. It was incredibly snappy, could render thousands of rows
       | without skipping a beat and had a nice explain visualisation
       | built in. If there was a modern rewrite that supported
       | PostgreSQL, I'd buy it in an instant.
       | 
       | There are screenshots in these articles if anyone's interested:
       | 
       | http://etutorials.org/SQL/microsoft+sql+server+2000/Part+II+...
       | 
       | https://www.sqlservercentral.com/articles/using-query-analyz...
        
         | smackeyacky wrote:
         | If you want an abomination, the Azure data studio makes SSMS
         | look like query analyzer.
        
         | chrismeller wrote:
         | I don't think it has the explain visualization, but otherwise
         | these screenshots look a lot like DBeaver to me. Perhaps worth
         | a try if you haven't stumbled upon it yet.
        
           | vetinari wrote:
           | Dbeaver is many things, but I would not call it lightweight.
           | It is written in Java, after all.
           | 
           | It is great, but Query Analyzer-alike it is not.
        
             | leke wrote:
             | dBeaver is written in Java, but it feels very lightweight.
             | I'm running it on a Linux desktop I've been using since
             | 2014. It's also cross platform so I run it at work on a
             | Windows laptop.
        
       | cellularmitosis wrote:
       | I've been wanting to dip my toes into old-school Win32
       | development for a while now, this codebase looks like a great
       | example to pore over.
        
         | bena wrote:
         | It looks like a pretty clean example from what I can recall.
         | 
         | WinMain builds the window and starts the message pump. The pump
         | is implement starting at line 425. It's basically a while loop
         | that reads the next message on the stack, translates it, then
         | sends it to the object it belongs to.
         | 
         | It's the precursor to today's modern event-driven designs.
         | Basically, this is now done for you by the runtime.
         | 
         | The bulk of the action happens in the created window's
         | "wndproc", cbMainWindow (Line 455 - 2897).
         | 
         | There's a giant switch statement, with each handled message
         | being a separate case. There's also a WM_COMMAND message, which
         | is essentially a message holding another message inside.
         | 
         | This is probably the best book on Win32 API programming out
         | there.
         | 
         | https://www.amazon.com/Programming-Windows%C2%AE-Fifth-Devel...
        
         | jansommer wrote:
         | Use ChatGPT! It's night and day for Win32 dev in my experience,
         | and the code it produces is really good.
         | 
         | One thing to note before going into Win32: You're going to have
         | a pixelated, upscaled ui if you don't take care of high dpi
         | support yourself, and that involves patching system controls.
         | So prepare yourself for lots of dpi-work if that's a concern.
         | (One thing I've been experimenting with is superclassing the
         | system controls and "overwriting" the original by registering a
         | superclass of eg. the edit control as simply "edit". This makes
         | other system controls, like the combobox, use your dpi
         | scaled/custom version).
        
           | dataflow wrote:
           | I'm confused. Are you sure high DPI needs patching system
           | controls to avoid pixelation? Doesn't dpiAwareness avoid the
           | pixelation? I certainly haven't needed to patch anything for
           | this in the past. If you have an example you could point to,
           | that would be great, since I don't know if I'm missing
           | something here.
           | 
           | Also, question: do you know of a good way to test for high-
           | DPI mode on a low-DPI screen?
        
           | zerr wrote:
           | Exactly my experience. In general, for the sane person, it is
           | impossible to write more than a few lines of Win32 API code
           | without copy/paste... ChatGPT came quite handy here.
        
         | waselighis wrote:
         | Dave's Garage on YouTube has a couple good videos that I can
         | recall.
         | 
         | https://www.youtube.com/watch?v=JlZe2JwrJqM
         | 
         | https://www.youtube.com/watch?v=CyJw2MumgTQ
        
           | hansoolo wrote:
           | Oh! I gonna dive into this pretty soon. Thank you!
        
       | hochmartinez wrote:
       | Linux version, please!
        
         | trelane wrote:
         | If it were written for Linux first, it would even be available
         | for Windows simultaneously.
        
         | whizzter wrote:
         | This codebase is very much tied to the win32 API, maybe with
         | the winelib wrapper but otherwise I wouldn't bother.
         | 
         | Sibling post here mentioned using under wine but I'm not sure
         | if that's the best idea since wine might not translate locking
         | semantics in the same way and those might be plenty important
         | to avoid corruption with SQLite databases.
        
         | leke wrote:
         | dbeaver is cross-platform and is a great general db client. I
         | highly recommend it.
        
         | themodelplumber wrote:
         | This has the intuitive scent of a project that works directly
         | in Wine without any problems. Haven't tried it myself though.
         | 
         | Kinda like OpenMPT...indicate the supported Wine version in the
         | Downloads maybe, and then after seeing it running just fine,
         | one could argue that there's not even much point to a Linux
         | port.
        
       | ijidak wrote:
       | This is awesome! I've been looking for a good SQL Lite GUI!
       | 
       | A lot of times, I just want a tool to do ad-hoc CSV work, and
       | don't want to fiddle with a terminal.
        
       | guavaNinja wrote:
       | At my last job, I built a SQLite editor as an internal tool with
       | C++ and ImGUI. It had custom features/views for our custom needs.
       | 
       | It was super fun and the code was super easy to read and edit.
       | Immediate mode made our job much easier.
        
       ___________________________________________________________________
       (page generated 2023-04-18 23:00 UTC)