shuttle-hq / synth

The Declarative Data Generator
https://www.getsynth.com/
Apache License 2.0
1.36k stars 106 forks source link

SurrealDB Support #370

Open iamwacko opened 1 year ago

iamwacko commented 1 year ago

Required Functionality I like SurrealDB.

Proposed Solution Add a new integration with SurrealDB.

Use case SurrealDB is a database written in Rust, and ecosystem integrations are interesting.

AlexMikhalev commented 1 year ago

Looking at https://surrealdb.com/docs/surrealql it needs a client adapter to connect, but more importantly different import and generate templates for data.

iamwacko commented 1 year ago

This is a goal for far into the future. I just opened the issue because of SurrealDB's recent surge in popularity.

AlexFrid commented 1 year ago

@AlexMikhalev I'd be interested to know more about what you mean by different import and generate templates for data. Is there somewhere I could see what is needed, without just digging into the code?

iamwacko commented 1 year ago

@AlexFrid There aren't really any resources other than the code. You can look at contents synth/src/datasource/postgres_datasource.rs for examples of templates. But in short, most of the templates are SQL and SurrealDB's query language isn't identical to SQL.