如何将aspnet_db表与我自己的db表一起使用 [英] how to use aspnet_db tables with my own db tables

查看:43
本文介绍了如何将aspnet_db表与我自己的db表一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的测试系统Web应用程序中

i已将aspnet_db注册角色memebership等表添加到我的数据库中。

并发了三个角色

1管理员

2.老师(他会做的创造测试功能)

3.学生



现在如果我想检查哪些管理员或教师工作(做了测试或添加了主题详细信息)然后我需要将用户ID添加到我的所有表中?还是我需要做的其他事情?

in my test system web application
i have added aspnet_db registration role memebership etc tables into my database.
and made three roles
1. admin
2. teacher (creat test function he will do)
3. student

now if i want to check which administrator or teacher work did (made test or added subjects details) then i need to add user ID into my all table ?? or any thing else i need to do?

推荐答案

AoA,





如果你正在制作一个像你正在处理学生,教师和管理员的角色的桌子,那么你可以做这样的事情



创建表格角色



- user_id

- user_name

- user_role即表示像老师,管理员,学生

- 添加更多你想要的东西





当你在列表中使用它们时gridview,你可以在表格中隐藏user_id

PS:Jahan tak mujhe samajh ayi mein ne solution de diya ...:P
AoA,


If you are making one table like roles in which you are handling students,teachers and administrators all, then you can do something like this

create table roles
(
-- user_id
-- user_name
-- user_role i.e say a label like "teacher,admin,student
-- add more things u want
)

and when you are using them in list or gridview, you can hide user_id in the tables
P.S : Jahan tak mujhe samajh ayi mein ne solution de diya... :P


这篇关于如何将aspnet_db表与我自己的db表一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆