3 ms·
A CGo-free port of SQLite/SQLite3
- pstuart 5mo agoSo is this a handmade port vs the translated port done by modernc?
- yodon 5mo agoSeems like there are some trademark issues with just calling this SQLite.
- downrightmike 5mo agoSQL would have been SEQL if not for trademark issues, the torch is passed
- 9rx 5mo agoSEQUEL. It was a play on QUEL [https://en.wikipedia.org/wiki/QUEL_query_languages https://en.wikipedia.org/wiki/QUEL_query_languages].
- tptacek 5mo agoIt's cznic/sqlite in Go-land; this is just a quirk of HN titling.
- gnabgib 5mo agoA quirk of this submitter's choice? We've seen it several times before without the trademark violation: 2023: Go port of SQLite without CGo (255 points, 118 comments) https://news.ycombinator.com/item?id=35488980 https://news.ycombinator.com/item?id=35488980 2020: Cznic/sqlite: Sqlite in pure Golang (no CGO) (6 points, not interesting for discussion.. this project is old) https://news.ycombinator.com/item?id=24358826 https://news.ycombinator.com/item?id=24358826 (7 other similar submissions)
- tptacek 5mo agoI don't care, I just wrote to clarify the project, in the Go community, isn't called "sqlite". That wouldn't make sense; there are multiple (pin-compatible) sqlite interfaces for Go.
- jsherer 5mo agoI was confused a few weeks ago. Check out the go pkg: https://pkg.go.dev/modernc.org/sqlite https://pkg.go.dev/modernc.org/sqlite 1. gitlab.com/cznic/sqlite is the primary repo 2. github.com/cznic/sqlite was the github mirror but it moved 3. github.com/mordernc-org/sqlite is the read-only mirror of the primary repo Cheers!
- porjo 5mo ago> 3. github.com/mordernc-org/sqlite is the read-only mirror of the primary repo Typo, should be: github.com/modernc-org/sqlite
- ftgffsdddr 5mo ago[flagged]
- slopinthebag 5mo ago[flagged]
- bananamogul 5mo ago[flagged]
- wild_egg 5mo agoNo it doesn't.
- zzo38computer 5mo agoI agree that it would be better to not require JavaScripts. (But, I think it can be helpful to have mirrors on other services as well, for this and other reasons.) However, there are some work arounds to some situations. Git could (presumably) still be used, if you have that (although you might not want the entire repository and only some files, so that is a possible issue with this). If you have a URL of a specific file that you can change "blob" to "raw" in the URL to access the raw file (this works on other services as well and is not specific to Gitlab). For commits, you can add ".patch" or ".diff" on the end of the URL (this also is not specific to Gitlab).
- deleted 5mo ago[deleted]
- qweqwe14 5mo agoJust use a real web browser or enable JS, it's not that hard buddy. "Why do you keep hitting yourself?"
- usrnm 5mo agoThe readme really lacks the answer to the "why" question. What's the use case, why should I prefer it over real sqlite?
- blubber 5mo agoBecause it's cgo-free maybe?
- usrnm 5mo agoCgo overhead is trivial compared to what's happening inside a database engine, totally not worth it
- figmert 5mo agoAbsolutely not. Maybe runtime overheads are minimal, but builds are so much harder to do. And yes, you need to figure it out maybe once, but it is still a lot more effort than just pulling in a new dependency. Now repeat that same effort for every new application, vs pulling that into every new application.
- anupcshan 5mo agoIt's not just about overhead/performance. cgo-free means no need to set up a cross-compiler if targeting other devices. Just "go build" with the right GOARCH and GOOS will let you compile a binary that will run on most devices.
- usrnm 5mo agoI'm pretty sure that C is a much better choice if you really care about binaries that run on most devices
- Ferret7446 5mo agoDepends on what you mean by "most". The cross compile story for Go is far superior to C for the platforms it supports.
- ncruces 5mo agoThere's also my take on this [1], which does machine translation from C to Go via Wasm using [2]. It's a somewhat less faithful translation, since I manually ported the VFS (SQLite OS abstraction layer). OTOH, each SQLite connection is sandboxed (can't access/corrupt Go memory, or other SQLite connections). And it should run everywhere Go runs. 1: https://github.com/ncruces/go-sqlite3 https://github.com/ncruces/go-sqlite3 2: https://github.com/ncruces/wasm2go https://github.com/ncruces/wasm2go
- pjjpo 5mo agoThis project seems to get shared every month or so. It's really sad that HN's signal to noise has fallen this hard... While I continue to have it in my feed, I'm more and more opening up Reddit since it just feels more robust now adays.