tools
react-querybuilder to SQL converter
Paste a react-querybuilder query (RuleGroupType JSON) and export it to SQL, MongoDB or JsonLogic with qnot's codecs.
- free
- no sign-up
- runs in your browser
- MIT
input · react-querybuilder JSON
5 rules · 5 fields · converted Runs in your browser: nothing leaves it.
How it converts
The rqb codec reads react-querybuilder's RuleGroupType, including comma-separated list values, the doesNotBeginWith family and independent combinators. Disabled rules are dropped.
react-querybuilder stores many values as strings. The inferred schema treats a field as a number when the query compares it as one, so "28" in age > "28" is written as 28.
The same JSON works as a store format in qnot: give createQueryStore format: rqb and your saved queries load as they are.
Use it in your app
follows your input and settingsThe converter is qnot's codecs. Declare the fields once and the same two calls run on your server or in the browser, typed end to end.
Questions
- Is my query sent anywhere?
- No. The converter is qnot running in your browser: parsing, schema inference and conversion all happen on this page, and nothing you paste leaves your browser.
- Can I keep my saved react-querybuilder queries if I switch?
- Yes. qnot's rqb format reads and writes react-querybuilder's JSON, so a store can take your saved queries as its value and hand back the same shape on change.
- Why does it show a schema?
- qnot's codecs are typed by a schema. The tool infers a permissive one from your input (numbers, booleans, dates, lists, nested arrays), so you can paste any query. In your app you declare the fields once with defineFields and get the same conversion with exact types.
More converters
Every format qnot speaks- SQL → MongoDBSQL to MongoDB converter
- MongoDB → SQLMongoDB to SQL converter
- SQL → JsonLogicSQL to JsonLogic converter
- JsonLogic → SQLJsonLogic to SQL converter
- JsonLogic → MongoDBJsonLogic to MongoDB converter
- SQL → ElasticsearchSQL to Elasticsearch converter
- RAQB → SQL · MongoDB · JsonLogicRAQB tree to SQL converter