Solved

User database

Posted on 2003-10-28
5
162 Views
Last Modified: 2010-04-01
Can anyone point me in the direction of the SQL DDL for a standard website user database? E.g. username, password, address etc.
 
Perhaps as part of a larger ecommerce db?
0
Comment
Question by:CEHJ
  • 3
  • 2
5 Comments
 
LVL 3

Expert Comment

by:krispols
ID: 9648384
create table USERS(
USR_ID numeric(10,0) identity,
USR_LOGIN varchar(20) not null,
USR_PWD varchar(15) not null,
USR_PWD_PHRASE varchar(100) null,
USR_PWD_ANSWER varchar(100) null,
USR_EMAIL varchar(50) not null,
USR_EMAIL_OK char(1) not null,
USR_CREATED_DATE datetime not null,
USR_CHANGE_DATE datetime not null)

the field USR_EMAIL_OK is must be set to 'N' until user confirm his email address by answer to the confirm email, then set to 'O'.

regards
0
 
LVL 86

Author Comment

by:CEHJ
ID: 9652799
OK thanks. I'm toying with the notion of there being no id column though. Possibly email as PK...
0
 
LVL 3

Accepted Solution

by:
krispols earned 50 total points
ID: 9662328
hello CEHJ,

Carrefull with PK on varchar type, it's really slowest than on numric type. It's also consume more disk space to build the index.

regards
0
 
LVL 86

Author Comment

by:CEHJ
ID: 9665975
That's a point, thanks.
0
 
LVL 86

Author Comment

by:CEHJ
ID: 10226152
Thanks. Although i've still not come  to a decision on how these things should be done!
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

In this article, I will show you HOW TO: Install VMware Tools for Windows on a VMware Windows virtual machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, using the VMware Host Client. The virtual machine has Windows Server 2016 instal…
Moving applications to the cloud or switching services to cloud-based ones, is a stressful job.  Here's how you can make it easier.
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now