wwUserSecurity::CreateTable

Creates the User table if it doesn't exist. Called by the Open method.

To create a new table:

o = CREATEOBJECT("UserSecurity")
o.CreateTable()  && default table defined in `.cFilename`

o.CreateTable("someotherDb") && custom table

Table Structure Change in v6.10

The table structure of this table was changed in v6.10 and has to be adjusted in order for authentication to continue to work. Field sizes went to VarChar() and field data now needs to be trimmed.

The table structure used is:

CREATE CURSOR usersecurity ;
(    PK          V (40),;
   USERNAME    V (80),;
  PASSWORD    V (80),;
  FULLNAME    V (80),;
  MAPPEDID    V (40),;
  EMAIL       M ,;
  NOTES       M ,;
  PROPERTIES  M ,;
  LOG         M ,;
  LEVEL       Y ,;
  ADMIN       L ,;
  CREATED     T ,;
  LASTON      T ,;
  LOGONCOUNT  I ,;
  ACTIVE      L ,;
  EXPIRESON   D )

If updating from old versions make sure you replace all fields with TRIM()ed values.

REPLACE ALL pk with TRIM(pk), ;
           username with TRIM(username), password with TRIM(password), ;
           MappedId with TRIM(MappedId)
o.CreateTable(lcFileName)

Parameters

lcFileName


See also:

Class wwUserSecurity

© West Wind Technologies, 1996-2022 • Updated: 10/08/18
Comment or report problem with topic