modulepackage
0.0.0-20210517153601-8b18a7b76669
Repository: https://github.com/mactsouk/restdb.git
Documentation: pkg.go.dev
# README
rest-db
Working with a database
Creating database schema:
psql -U mtsouk postgres -h 127.0.0.1 < create_db.sql
# Functions
No description provided by the author
DeleteUser is for deleting a user defined by ID.
FindUserID is for returning a user record defined by ID.
FindUserUsername is for returning a user record defined by a username.
InsertUser is for adding a new user to the database.
IsUserAdmin determines whether a user is an administrator or not.
No description provided by the author
ListAllUsers is for returning all users from the database table.
ListLogged is for returning all logged users This was created by mistake - the server uses ReturnLoggedUsers() instead!.
ReturnLoggedUsers is for returning all logged in users.
UpdateUser allows you to update user name.
# Variables
PostgreSQL Connection details
We are using localhost as hostname because both the utility and PostgreSQL run on the same machine.
PostgreSQL Connection details
We are using localhost as hostname because both the utility and PostgreSQL run on the same machine.
PostgreSQL Connection details
We are using localhost as hostname because both the utility and PostgreSQL run on the same machine.
PostgreSQL Connection details
We are using localhost as hostname because both the utility and PostgreSQL run on the same machine.
PostgreSQL Connection details
We are using localhost as hostname because both the utility and PostgreSQL run on the same machine.