如何通过复选框插入数据库来防止已经插入的数据 [英] how to prevent already inserted data by checkbox to insert into database

查看:60
本文介绍了如何通过复选框插入数据库来防止已经插入的数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,



我有一个网格视图,在这个gridview 1复选框就在那里。我想将数据插入gridview的已检查行的数据库中。但是当我第二次插入带有旧格式视图行的2行或3行时,它应该跳过插入旧选定行的数据并插入新选行的数据...



请帮帮我..



谢谢......提前...

Hello,

I have a grid view and in this gridview 1 checkbox is there. i want to insert the data into the database of checked row of gridview. but when second time i insert 2 or 3 row with old checked row of gridview then it should skip to insert the data of old selected row and insert the data of new selected row...

please help me..

Thanks..In Advance...

推荐答案

在插入之前,请检查数据库中是否存在该记录。如果是,则不要插入记录。
Before you insert, check in the DB if that record exists. If so, then dont insert the record.


这篇关于如何通过复选框插入数据库来防止已经插入的数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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