如何在C#中自动创建表 [英] How to create table automatically in C#
问题描述
假设如果用户注册到网站,则必须自动为C#&中的数据库中的登录帐户创建表。表名应该是用户ID名称...自动它必须使用名称来创建表...
我尝试过:
请任何人帮帮我....怎么做
suppose if a user is signup into website, automatically table has to be created for their login account in database in C# & the table name should be user id name...automatically it has to use the name to create table...
What I have tried:
please any one help me....how to do this
推荐答案
你是严重?每个新注册的新表格?没有!它应该是数据库表中每个新注册的新记录。建议您先阅读数据库设计数据库设计简介 [ ^ ],然后散步 - 通过这个 ASP.Net中的简单用户注册表单示例 [ ^ ]
Are you serious? A new table for every new sign-up? No! it should be a new record for every new signup in a database table. Suggest you read up on database design first Introduction to database design[^], then take a walk-through with this Simple User Registration Form Example in ASP.Net[^]
我想要完整的代码
你只想有人做你的工作。尝试雇用一名真正的程序员。
聘请自由职业者&在线查找自由职业者 - 自由职业者 [ ^ ]
You only want someone to do your job. Try to hire a real programmer.
Hire Freelancers & Find Freelance Jobs Online - Freelancer[^]
假设用户注册网站,必须自动为其登录创建表格数据库中的帐号
suppose if a user is signup into website, automatically table has to be created for their login account in database
看起来你需要学习如何设计数据库,你想要使用它的方式就是打败所有的优化。
Looks like you need to learn how to design databases, the way you want to use it simply defeat all optimizations.
你好,
请参考以下网址,并在代码中将用户名作为表名。
以编程方式创建和删除SQL Server表ADO.Net,C#和VB.Net [ ^ ]
谢谢,
:)
Hi,
Please refer below url and just pass username as table name in the code.
Create and Drop SQL Server Table programmatically using ADO.Net, C# and VB.Net[^]
Thanks,
:)
这篇关于如何在C#中自动创建表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!