gosora/schema/mssql/query_users.sql
Azareal da6ae8d7d4 Gosora now supports MSSQL (Microsoft SQL Server).
Fixed a bug with MemoryUserStore's length counter.
The upsert API is currently a confusing mess, we'll have it all fixed up soon.
Added the Delete method to the User struct.
Improved the test coverage for the user subsystem.
2017-10-16 08:32:58 +01:00

27 lines
958 B
SQL

CREATE TABLE [users] (
[uid] int not null IDENTITY,
[name] nvarchar (100) not null,
[password] nvarchar (100) not null,
[salt] nvarchar (80) DEFAULT '' not null,
[group] int not null,
[active] bit DEFAULT 0 not null,
[is_super_admin] bit DEFAULT 0 not null,
[createdAt] datetime not null,
[lastActiveAt] datetime not null,
[session] nvarchar (200) DEFAULT '' not null,
[last_ip] nvarchar (200) DEFAULT '0.0.0.0.0' not null,
[email] nvarchar (200) DEFAULT '' not null,
[avatar] nvarchar (100) DEFAULT '' not null,
[message] nvarchar (MAX) DEFAULT '' not null,
[url_prefix] nvarchar (20) DEFAULT '' not null,
[url_name] nvarchar (100) DEFAULT '' not null,
[level] smallint DEFAULT 0 not null,
[score] int DEFAULT 0 not null,
[posts] int DEFAULT 0 not null,
[bigposts] int DEFAULT 0 not null,
[megaposts] int DEFAULT 0 not null,
[topics] int DEFAULT 0 not null,
[temp_group] int DEFAULT 0 not null,
primary key([uid]),
unique([name])
);