Skip to content

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

order

a sql builder, database query tool for node and postgres database

documentation

order adopt O as namespace as $ in jquery and _ in underscore

connect

parameters

  • object config: can contain any of the following optional properties
    • string user:
      • default value: process.env.USER
      • PostgreSQL user
    • string database:
      • default value: process.env.USER
      • database to use when connecting to PostgreSQL server
    • string password:
      • default value: null
      • user's password for PostgreSQL server
    • number port:
      • default value: 5432
      • port to use when connecting to PostgreSQL server
      • will support unix domain sockets in future
      • used to initialize underlying net.Stream()
    • string host:
      • default value: null
      • host address of PostgreSQL server
      • used to initialize underlying net.Stream()
    • bool ssl:
      • default value: false
      • whether to try SSL/TLS to connect to server

tcp example

    O.connect(
      user: 'brianc'
      password: 'boom!'
      database: 'test'
      host: 'example.com'
      port: 5313
    )

end

will end the connection

run

you can run sql string directly, or run a sql object, which contains a prepare statement and it's parametars.

get

run to get single result

all

run to get collection result

#warning order is under heavy development.

About

a sql builder, database query tool for node and postgres database

Resources

Stars

1 star

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages