在数据库中插入记录以验证存在之前? [英] Before inserting a record in the database to validate that there is?

查看:95
本文介绍了在数据库中插入记录以验证存在之前?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在数据库中插入记录以验证存在之前,例如我有一个包含两个字段的表,带有Customer的表字段VA,首先,如果没有客户注册,我想验证该字段,如果有insert

Before inserting a record in the database to validate that there is, for example I have a table that has two fields, table fields VA with Customer, First, I want to validate the field if there is no customer registration and if there insert

推荐答案

您可以使用触发器。


你好,



你可以使用IF NOT EXISTS WAN .......
Hello,

You can use IF NOT EXISTS AS WELL....


这篇关于在数据库中插入记录以验证存在之前?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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