473,399 Members | 2,858 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

How to Update ignoring validation rule

Experience is highly requested.

I can't find solution for the following problem:
I am making VBA code for moving/modifying data from "old" tables into
"new" ones. In fact, this is part of the upgrade module for a data entry
product. In the existing tables at customers' site there could be some
values in some fields, which violate validation rules. I have to copy
them as they are, in the new tables, in the fields having the same
validation rule.
I can't do this, at line with update - the error 3316 is coming.

--
Vlad
Nov 13 '05 #1
2 2352
On Tue, 06 Sep 2005 17:57:18 +0300, Vladi <vl******************@ktl.fi> wrote:
Experience is highly requested.

I can't find solution for the following problem:
I am making VBA code for moving/modifying data from "old" tables into
"new" ones. In fact, this is part of the upgrade module for a data entry
product. In the existing tables at customers' site there could be some
values in some fields, which violate validation rules. I have to copy
them as they are, in the new tables, in the fields having the same
validation rule.
I can't do this, at line with update - the error 3316 is coming.

Hi
I assume this is table-level validation.
You will have temporarily change the ValidationRule property for the tabledef
or field object while doing the importing (this is possible provided it is a non-
attached JET table) and then change it back again - I believe that if the latter
is done in codetthe database will not validate existing data though it
may tell the user this or ask whether it is required, you would need to test it.

It would be better if you could take some remedial action during the import to
correct errors or put them in some other table.

Nov 13 '05 #2
Thank you very much for your reply.
Situation is as simple. Since I don't know which field could be
corrupted. In that particular case I have learned, that one member of
local team has extended list of valid values, violating the golden rule
of centralized data collection - "no local modifications in data entry
routines". What I think about now is, how, if possible, to lock any
changes in fields ' attributes in the tables sent out to the
participating centres.

polite person wrote:
On Tue, 06 Sep 2005 17:57:18 +0300, Vladi <vl******************@ktl.fi> wrote:


Hi
I assume this is table-level validation.
You will have temporarily change the ValidationRule property for the tabledef
or field object while doing the importing (this is possible provided it is a non-
attached JET table) and then change it back again - I believe that if the latter
is done in codetthe database will not validate existing data though it
may tell the user this or ask whether it is required, you would need to test it.

It would be better if you could take some remedial action during the import to
correct errors or put them in some other table.

--
Vlad
Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Doslil | last post by:
I am trying to validate the fields in my database.I have already validated the fields to check for not null.Here is what I have written for Numeric and text field. Private Function EENUM() On...
2
by: Joey P | last post by:
Hi all, I am doing a project for university whereby i have to implement a simple database related to a frozen foods company. I am having some trouble though creating a validation rule for one...
9
by: James Butler | last post by:
Our setup: Online db: MySQL Inhouse db: MS Access 97 with MySQL tables linked via ODBC Our issue: Almost every field updates successfully, except one. A scenario: Information is written to...
6
by: Chuck | last post by:
A97. A database has a table: tblA which has a single text field, B. It is a primary field, indexed and no duplicates. It is used as a lookup for table tblC. A form based on tblA is used to add...
4
by: ron | last post by:
I have a access based guest book. I want to create a validation rule to block certain words or parts of a srting. How do i do this? ie: this is a nice site. come visit my porn site at www.abc.zy...
10
by: gweasel | last post by:
What is the best way to apply a Validation Rule - or rather, where is the best place to put it? Is there an advantage to putting it on the field in the table vs setting the validation rule on the...
7
by: sharsy | last post by:
Hi guys, I would like to setup a validation rule for a database in microsoft access that restricts data entry so that a certain field can only be filled in if another field has a specific answer...
1
by: MLH | last post by:
Anyone remember if A97 append query failure would ever report data breaking validation rule when such was not the case. I have an old SQL statement - several years old now. I've encountered a case...
18
by: ChipR | last post by:
I have a text box with a validation rule and validation text. When entering a new record, if I put in invalid text, the validation text is displayed in a message box, but after clicking OK, another...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.