[REPOST]从表中传递ID [英] [REPOST] To Pass ID from the table

查看:83
本文介绍了[REPOST]从表中传递ID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

cmd.CommandType = CommandType.Text;
string str = "Select ID from Team_Registration where UserName= '" + Session["New"] + "'";
int N = Convert.ToInt32(str);
cmd.Parameters.AddWithValue("@Name", txtName.Text.ToString());
cmd.Parameters.AddWithValue("@Mobile", txtMobile.Text.ToString());
cmd.Parameters.AddWithValue("@Address", txtAddress.Text.ToString());
cmd.Parameters.AddWithValue("@UserId", N);
cmd.ExecuteNonQuery();







如何将Team_registration ID存储在另一个表UserId



请给我一个答案.....




How can I store the Team_registration ID in another table UserId

Please give me a answer.....

推荐答案

你已经有很多这里的答案:如何存储一个表ID在另一个表 [ ^ ]
You already got plenty of answers here: How Can I Store One Table Id In Another Table[^]


这篇关于[REPOST]从表中传递ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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