如何在前台去更改后台数据库的登陆用户的密码,后台数据库为SQL Server 2000。

keiven 2004-06-24 04:38:12
如题。解答了马上给分。谢谢!!!
...全文
368 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
keiven 2004-06-28
  • 打赏
  • 举报
回复
多谢各位的帮助,问题已经解决。谢谢大家!
online 2004-06-24
  • 打赏
  • 举报
回复
http://www.china-askpro.com/msg47/qa39.shtml
可通过调用master的系统存储过程sp_password....
lsftest 2004-06-24
  • 打赏
  • 举报
回复
使用系统存储过程:sp_password....

sp_password (T-SQL)
Adds or changes a password for a Microsoft® SQL Server™ login.

Syntax
sp_password [[@old =] 'old_password',] {[@new =] 'new_password'}
[,[@loginame =] 'login']

Arguments
[@old =] 'old_password'
Is the old password. old_password is sysname, with a default of NULL.
[@new =] 'new_password'
Is the new password. new_password is sysname, with no default. old_password must be specified if named parameters are not used.
[@loginame =] 'login'
Is the name of the login affected by the password change. login is sysname, with a default of NULL. login must already exist and can only be specified by a member of the sysadmin fixed server role.
Return Code Values
0 (success) or 1 (failure)

Remarks
SQL Server passwords can contain from 1 to 128 characters, including any letters, symbols, and numbers.

The new password is updated and stored in an encrypted form so that no user, not even system administrators, can view the password.

sp_password cannot be used with Microsoft Windows NT® security accounts. Users connecting to SQL Server through their Windows NT network account are authenticated by Windows NT, therefore their passwords can be changed only in Windows NT.

sp_password cannot be executed within a user-defined transaction.

Permissions
Execute permissions default to the public role for a user changing the password for his or her own login. Only members of the sysadmin role can change the password for another user’s login.

Examples
A. Change the password of a login without the former password
This example changes the password for the login Victoria to ok.

EXEC sp_password NULL, 'ok', 'Victoria'



B. Change a password
This example changes the password for the login Victoria from ok to coffee.

EXEC sp_password 'ok', 'coffee'



See Also
sp_addlogin sp_revokelogin
sp_adduser System Stored Procedures
sp_grantlogin






(c) 1988-98 Microsoft Corporation. All Rights Reserved.
keiven 2004-06-24
  • 打赏
  • 举报
回复
我要在客户的程序界面去修改SA的密码,怎么修改?谢谢!
keiven 2004-06-24
  • 打赏
  • 举报
回复
现在关键是用户名和密码不是专门放在一个数据表中,而是放在系统的某一个地方。可能我也说不清楚。就举个例子,怎么修改超级用户 SA 的密码呢?
jackKun 2004-06-24
  • 打赏
  • 举报
回复
问题,说清楚点了,前台,后台,,只要连上了数据库有权限的话,都可以改的吧
keiven 2004-06-24
  • 打赏
  • 举报
回复
我顶!
keiven 2004-06-24
  • 打赏
  • 举报
回复
郁闷啊 ,等了这么久还没人来理会。
keiven 2004-06-24
  • 打赏
  • 举报
回复
没人知道吗?

1,217

社区成员

发帖
与我相关
我的任务
社区描述
VB 数据库(包含打印,安装,报表)
社区管理员
  • 数据库(包含打印,安装,报表)社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧