SS-Unit
graphjin
SS-Unit | graphjin | |
---|---|---|
1 | 61 | |
9 | 2,847 | |
- | - | |
10.0 | 5.5 | |
over 4 years ago | 10 days ago | |
TSQL | Go | |
MIT License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
SS-Unit
-
Ask HN: How do you test SQL?
Back in the mid-noughties I decided to see if I could write SQL in a test-first manner (i.e. TDD). This resulted in me writing a 100% T-SQL based unit testing framework for SQL Server [1] which we then used for the SQL back-end at an investment bank.
On the back on that professional use I wrote a blog post [2] explaining why you might choose to go down this route as it wasn't the way database was developed way back then (SQL wasn't developed in the same way as the other front-end and back-end code).
A few years later I gave a short 20-minute talk (videoed) to show what writing SQL using TDD looked like for me. It's hard to show all the kinds of tests we wrote in practice at the bank but the talk is intended to show how rapid the feedback loop can be using a standard DB query tool and two code windows - production code and tests.
Be kind, it was a long time ago and I'm sure the state of the art has improved a lot in the intervening years :o).
Chris Oldwood
---
[1] SQL Server Unit: https://github.com/chrisoldwood/SS-Unit
[2] You Write Your SQL Unit Tests in SQL?: https://chrisoldwood.blogspot.com/2011/04/you-write-your-sql...
[3] Test-Driven SQL: https://www.youtube.com/watch?v=5-MWYKLM3r0
graphjin
- [Golang] Super Graph GraphQL au compilateur SQL renommé GraphJin et prend maintenant en charge MySQL
-
Does Go, has something similar to Laravel eloquent (ORM) ?
This one looks interesting if you like GraphQL… https://graphjin.com
-
Looking for library recommendations: Django -> Golang port
You're right. Django made a ton of tables, and it's pretty insightful to think about all the stuff it's trying to consider and a nightmare to migrate that framework. Django might have simplified some stuff, but it's still too opaque for my taste and the overall end goals of the project. Currently, I'm testing using graphjin (it doesn't have the best documentation, but it does boast an SQL generation capability that I philosophically think is the best way to do things).
-
Advice on ORMs with REST/GraphQL & Hasura/PostGraphile implementation
Checkout GraphJin it's an automatic GraphQL to SQL compiler, you write your database queries in GraphQL instead of SQL and it compiles them into efficient SQL on the fly. Works as a library in GO and NodeJS. https://github.com/dosco/graphjin
-
Ask HN: How do you test SQL?
In GraphJin an automatic GraphQL to SQL compiler we use the gnomock library it startups a database instance (docker) then create the schema and tests data and finally our code connects to it and runs a series of tests. We run these across Mysql, Postgres and a few other DB's. Gnomock supports a wide range of them. Right now we don't take down the db for every test only between test runs but its fast enough that we could. This whole thing runs of a simple `go test -v .` command and we run it on every commit using a githook. https://github.com/dosco/graphjin/blob/master/tests/dbint_te...
- Should I use GraphQL for a public facing API (in place of a REST API)?
- GraphJin 2.0 - A new kind of ORM for GO
-
Multiple subscriptions fom apollo aclient.
This was a bug in GraphJin it has since been fixed. The issue was that you were trying to have multiple subscriptions over a single websocket this did not work (it should) and now it does. https://github.com/dosco/graphjin/commit/43e619b2ff392dd42b99a4d56074a041a54b0e1c
-
Is graphql-request a good tool for only client side api? Share your feedbacks. Thanks 🙏
Not exactly GraphQL is just a format to define what data you want back from someplace. You can use it in a browser app to request data from a backend GraphQL server or you can use it as an ORM within your backend app to fetch data from a database using a library like GraphJin. https://github.com/dosco/graphjin
- Graphjin.js - An easy-to-use, zero dependency Node.js library to build APIs quickly
What are some alternatives?
dbt-unit-testing - This dbt package contains macros to support unit testing that can be (re)used across dbt projects.
Hasura - Blazing fast, instant realtime GraphQL APIs on your DB with fine grained access control, also trigger webhooks on database events.
squire
graphql-go - GraphQL server with a focus on ease of use
datajudge - Assessing whether data from database complies with reference information.
gqlgen - go generate based graphql server library
integresql - IntegreSQL manages isolated PostgreSQL databases for your integration tests.
asciinema - Platform for hosting and sharing terminal session recordings
Flyway - Flyway by Redgate • Database Migrations Made Easy.
graphql-benchmarks - GraphQL benchmarks using the-benchmarker framework.
sqlx - 🧰 The Rust SQL Toolkit. An async, pure Rust SQL crate featuring compile-time checked queries without a DSL. Supports PostgreSQL, MySQL, and SQLite.
node-pg-migrate - Node.js database migration management for PostgreSQL