Matching Dates

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Ok guys fairly complicated one here...
I have a single table with 20,000 transactions within it. Each transaction
has a date attached to it.
I have another table which contains 3 fields, a StartDate, a FinishDate and
a WeekNumber. i.e.:

startdate finishdate weeknumber
01/01/2007 08/01/2007 1

What I need to be able to do is take each transactions from the transactions
table and link it to this calendar table to get the weeknumber of when each
transaction occured.
How on earth can I produce this?

Many thanks.
Ash.
 
hi,
Ok guys fairly complicated one here...
Not really:)
I have a single table with 20,000 transactions within it. Each transaction
has a date attached to it.
I have another table which contains 3 fields, a StartDate, a FinishDate and
a WeekNumber. i.e.:
startdate finishdate weeknumber
01/01/2007 08/01/2007 1
You need a Join:

SELECT t.*, w.WeekNumber
FROM Transactions t
INNER JOIN Weeks w
ON t.TransactionDate BETWEEN w.StartDate AND w.FinishDate

http://office.microsoft.com/en-us/access/HP010984841033.aspx
http://www.mvps.org/access/datetime/date0012.htm

mfG
--> stefan <--
 
You need a Join:

SELECT t.*, w.WeekNumber
FROM Transactions t
INNER JOIN Weeks w
ON t.TransactionDate BETWEEN w.StartDate AND w.FinishDate

If OP is to do that -- and the suggestion is a good one -- then they
should make the data in their calendar table more like

startdate=#2007-01-01 00:00:00#
finishdate=#2007-01-08 23:59:59#
weeknumber=1

With their existing data (i.e. one day granularity), the value
#2007-01-08 12:00:00# might return weeknumber=2 or, worse, no
weeknumber at all!

Alternatively, they could ensure that every DATETIME value encountered
is of one day graularity (e.g. only use SQL stored procs with strongly
type DATETIME parameters always 'rounded') but it's must easier to
accept the fact that all DATETIME values are of one second graularity
and code accordingly.

Jamie.

--
 
All Date values in Access are not granular to 1 second. It is up to the
developer to determine and control whether a time value is included. That is
why there are three different functions.
Date() returns only the date portion.
Now() returns date and time.
Time returns only the time.

What is not clear here is which date to use for the week. There are two
dates, but the OP did not say which should be used to return the week. In
the example, the start date is week 1, but the end date is certainly not.

Additionally, is there any reason the DatePart function can't be used to
determine the week rather than having to maintain a table? It would be
faster.

=DatePart("ww",SomeDate)
 
Thanks for the input.
DatePart could not be used as our company calendar runs from October -
September, i.e. 01/10/2007 - 07/10/2007 is Week1 etc etc. Thats why I have
decided that this seperate table is necessary - correct me if I am wrong.
The only other suggestion I have had is to create a table with every single
date of the year in it and assign week numbers to each indivudally, possible
a long winded way of doing things but never the less I could see it working.
Many thanks again.
 
It is up to the
developer to determine and control whether a time value is included. That is
why there are three different functions.
Date() returns only the date portion.
Now() returns date and time.
Time returns only the time.

No!

Standard SQL has DATE and TIME date types, plus some others, but
Access/Jet has but one temporal data type, named DATETIME (close to
Standard SQL's TIMESTAMP data type but nothing like SQL Server's). The
clue's in the name...

In Access/Jet, Date() always returns a time portion, being midnight;
Time() always returns a date portion, being of 30th of December
eighteen hundred and ninety-nine. You can hide certain date/time
elements using formatting but that doesn't make the underlying values
disappear. This is newbie stuff and you know it :)
All Date values in Access are not granular to 1 second.

I guess I was summarizing my conclusions based on experience rather
than stating a solid fact; sorry for not being clear. Time is in
continuum, periods can be infinitely divided and in this regard the
floating point nature of Access/Jet's DATETIME functionality is a good
fit; pity it's not practical. Unless prevented, someone can put sub-
second values in a DATETIME column but to operate on it would have to
roll their own temporal functionality (non-trivial to say the least)
because the smallest useable time granule in Access/Jet's own is one
second. If you take the aforementioned prevention approach it gets to
be a pain too, not so bad for table columns where engine-level
validation rules can be used but really onerous for input parameter
values (I shudder to contemplate the consequence if you're a 'dynamic
SQL' person).

Similarly, someone could roll their own fixed point temporal data
type; this is not so fanciful: we see many people here trying to use
text data types to achieve the same and the result usually a horrible
mess.

Of course, most designers use DATETIME, take no action at all but
assume all dates will be of one day granularity, and we see many of
them in the groups wondering out loud why their rows disappear when
JOINed on DATETIME columns and the answer is they allowed time
elements other than midnight and consequently got them.

My conclusions are to use DATETIME for instants, a pair of DATETIMEs
for periods,use engine-level validation rules to ensure DATETIME
columns' values are of known granularity no smaller than one second
(but often larger granules) and either 'round' parameter values to the
same granularity of the column they are being compared while allowing
sub-second values to be implicitly rounded (fine by me: it's not my
fault that DATETIME is not based on fixed point so I shouldn't be
expected to fix it!) I can then used closed-closed representation for
periods e.g. period for the current month would be represented as

[#2007-08-01 00:00:00#, #2007-08-31 23:59:59#]

The OP is also using closed-closed but would represent the same period
as

[#2007-08-01 00:00:00#, #2007-08-31 00:00:00#]

which begs the question, where does the value #2007-08-31 00:00:00#
fall? No where probably.

Now you may ask where does the value 39325.999994213 fall in my
version and I tell you that 39325.999994213 is not a valid DATETIME
value (!!) and if the front end designer or user allowed it to be used
as if it were on then that's their problem (of course I could ensure
the values were always rounded but it would result in a complex and
less flexible system -- and I repeat I shouldn't be expected to fix
the DATETIME data type's floating point 'problem'). I don't think the
OP could use the same defence because valid DATETIME values other than
midnight are far more commonly encountered and there no real excuse
for not anticipating them e.g. as a I suggested they could make their
end DATETIMEs have time element one second before midnight OR use
closed-open representation e.g.

[#2007-08-01 00:00:00#, #2007-09-01 00:00:00#)

and how hard is that said:
What is not clear here is which date to use for the week. There are two
dates, but the OP did not say which should be used to return the week. In
the example, the start date is week 1, but the end date is certainly not.

Additionally, is there any reason the DatePart function can't be used to
determine the week rather than having to maintain a table? It would be
faster.

=DatePart("ww",SomeDate)

Is there any reason the DatePart function can't be used? You seem to
have answered your own question: using DatePart is fair enough when
your definition of week start date and week end date happens to
coincide with Microsoft's; if not, you've got to roll your own.

SQL (the language) was designed for data storage and data retrieval
and not surprisingly it excels in this area. It was not designed as a
calculation engine, hence doesn't do so well in this area. It stands
to reason to prefer a data-driven solution, using data stored in
permanent tables joining to other tables etc, over a calculation.
Putting the logic into a UDF, for example, obscures the logic of the
application and can only run inside the Access user interface, whereas
a calendar table style solution is clear and available to all. It also
has a many uses e.g. finding the number of enterprise days between two
dates; identifying overlapping periods (JOIN to the calendar table and
GROUP BY calendar day), etc.

Maintenance isn't usually a problem because the calendar tends to be
quite stable <g>! Also consider it's easier to change data in a table
than it is to make a code change to a UDF. Further, the table-driven
approach ports well to other SQL DBMSs.

Jamie.

--
 
hi,
DatePart could not be used as our company calendar runs from October -
September, i.e. 01/10/2007 - 07/10/2007 is Week1 etc etc. Thats why I have
decided that this seperate table is necessary - correct me if I am wrong.
I would encapsulate this in a function. Cause it is easier to maintain.
Just take a look at the common week number algorithms and use it for
your definition of a year.



mfG
--> stefan <--
 
I would encapsulate this in a function. Cause it is easier to maintain.
Just take a look at the common week number algorithms and use it for
your definition of a year.

Funny, I find it easier to change data in a table (or even alter a
database object) in the database than to roll out a code change
(certainly costs us less money!) Consider a FE/BE split: is it easier
to change data in the BE or change *all* the FEs?

I use the Calendar table approach and it works well.

Do you think it could be the case that you find it easier to write
procedural code than to devise a set-based, table driven approach? :)

Jamie.

--
 
hi Jamie,

Jamie said:
Funny, I find it easier to change data in a table (or even alter a
database object) in the database than to roll out a code change
(certainly costs us less money!) Consider a FE/BE split: is it easier
to change data in the BE or change *all* the FEs?
The distribution is not a real argument, as we are in the phase of
creating (designing and implementing) an application.
I use the Calendar table approach and it works well.
When this kind of week number calculation is needed only once, you may
be right.

But i suppose this is not true. Just consider report printing with week
numbers. This would mean you have to use a bunch of these joins just for
a simple week number in the page footer/header. Okay, you may use a
DLookup() replacement, but I think this quite equivalent to a join.
Do you think it could be the case that you find it easier to write
procedural code than to devise a set-based, table driven approach? :)
This kind of functionality needs a larger degree of abstraction. This is
covered by my functional approach.

Just my 2 cents.


mfG
--> stefan <--
 
The distribution is not a real argument, as we are in the phase of
creating (designing and implementing) an application.

I was responding to your point about ease of maintenance.
When this kind of week number calculation is needed only once, you may
be right.

But i suppose this is not true. Just consider report printing with week
numbers. This would mean you have to use a bunch of these joins just for
a simple week number in the page footer/header.

My way involves retieving data, not a calculation. If I want to use a
retirieved value multiple times I will cache it (e.g. disconnection
recordset) rather than make multiple database round trips.

I use a proferssional 'industrial strength' report writer myself and
I'm pretty sure it uses a locally cached resultset and hits the
database just the once.

Despite the non-applicable example you picked, I really don't see the
problem. If a table JOIN was an issue then we'd all have very
denormalized databases <g>. And if looking up a value in a table was
an issue we'd all be stuffed <vbg>!

Jamie.

--
 
Jaime,

I wonder why you bother to use Access at all. You seem not to like it very
much. You use an "industrial strength" report writer and you try to impose
SQL Server techniques on Jet and give newbies answers based on Non Access
products. I think this only leads to confusion.

As to whether to use code or data retrieval... In 30 years of multiple
languages and database engines, I have yet to find one where data retrieval
is faster than a code calculation. As to your deployment issue, if you use
an auto FE updater, it is absolutely no problem. It would seem to me to be
more problematic to have to take the database down for a schema change and
then be sure the table is correct and up to date.

As a humorous aside, I saw this happen in 1982. The bank I was working at
had a calendar table on the DEC PDP 1170's we used for ATM and manned teller
processing. At 3:00 PM on December 31 when cutover occurred, the table had
no 1983 data. Before we got the system down, it captured 450 ATM cards
including the president of the bank.

IMHO if it can be calculated, it should be.
--
Dave Hargis, Microsoft Access MVP


Jamie Collins said:
It is up to the
developer to determine and control whether a time value is included. That is
why there are three different functions.
Date() returns only the date portion.
Now() returns date and time.
Time returns only the time.

No!

Standard SQL has DATE and TIME date types, plus some others, but
Access/Jet has but one temporal data type, named DATETIME (close to
Standard SQL's TIMESTAMP data type but nothing like SQL Server's). The
clue's in the name...

In Access/Jet, Date() always returns a time portion, being midnight;
Time() always returns a date portion, being of 30th of December
eighteen hundred and ninety-nine. You can hide certain date/time
elements using formatting but that doesn't make the underlying values
disappear. This is newbie stuff and you know it :)
All Date values in Access are not granular to 1 second.

I guess I was summarizing my conclusions based on experience rather
than stating a solid fact; sorry for not being clear. Time is in
continuum, periods can be infinitely divided and in this regard the
floating point nature of Access/Jet's DATETIME functionality is a good
fit; pity it's not practical. Unless prevented, someone can put sub-
second values in a DATETIME column but to operate on it would have to
roll their own temporal functionality (non-trivial to say the least)
because the smallest useable time granule in Access/Jet's own is one
second. If you take the aforementioned prevention approach it gets to
be a pain too, not so bad for table columns where engine-level
validation rules can be used but really onerous for input parameter
values (I shudder to contemplate the consequence if you're a 'dynamic
SQL' person).

Similarly, someone could roll their own fixed point temporal data
type; this is not so fanciful: we see many people here trying to use
text data types to achieve the same and the result usually a horrible
mess.

Of course, most designers use DATETIME, take no action at all but
assume all dates will be of one day granularity, and we see many of
them in the groups wondering out loud why their rows disappear when
JOINed on DATETIME columns and the answer is they allowed time
elements other than midnight and consequently got them.

My conclusions are to use DATETIME for instants, a pair of DATETIMEs
for periods,use engine-level validation rules to ensure DATETIME
columns' values are of known granularity no smaller than one second
(but often larger granules) and either 'round' parameter values to the
same granularity of the column they are being compared while allowing
sub-second values to be implicitly rounded (fine by me: it's not my
fault that DATETIME is not based on fixed point so I shouldn't be
expected to fix it!) I can then used closed-closed representation for
periods e.g. period for the current month would be represented as

[#2007-08-01 00:00:00#, #2007-08-31 23:59:59#]

The OP is also using closed-closed but would represent the same period
as

[#2007-08-01 00:00:00#, #2007-08-31 00:00:00#]

which begs the question, where does the value #2007-08-31 00:00:00#
fall? No where probably.

Now you may ask where does the value 39325.999994213 fall in my
version and I tell you that 39325.999994213 is not a valid DATETIME
value (!!) and if the front end designer or user allowed it to be used
as if it were on then that's their problem (of course I could ensure
the values were always rounded but it would result in a complex and
less flexible system -- and I repeat I shouldn't be expected to fix
the DATETIME data type's floating point 'problem'). I don't think the
OP could use the same defence because valid DATETIME values other than
midnight are far more commonly encountered and there no real excuse
for not anticipating them e.g. as a I suggested they could make their
end DATETIMEs have time element one second before midnight OR use
closed-open representation e.g.

[#2007-08-01 00:00:00#, #2007-09-01 00:00:00#)

and how hard is that said:
What is not clear here is which date to use for the week. There are two
dates, but the OP did not say which should be used to return the week. In
the example, the start date is week 1, but the end date is certainly not.

Additionally, is there any reason the DatePart function can't be used to
determine the week rather than having to maintain a table? It would be
faster.

=DatePart("ww",SomeDate)

Is there any reason the DatePart function can't be used? You seem to
have answered your own question: using DatePart is fair enough when
your definition of week start date and week end date happens to
coincide with Microsoft's; if not, you've got to roll your own.

SQL (the language) was designed for data storage and data retrieval
and not surprisingly it excels in this area. It was not designed as a
calculation engine, hence doesn't do so well in this area. It stands
to reason to prefer a data-driven solution, using data stored in
permanent tables joining to other tables etc, over a calculation.
Putting the logic into a UDF, for example, obscures the logic of the
application and can only run inside the Access user interface, whereas
a calendar table style solution is clear and available to all. It also
has a many uses e.g. finding the number of enterprise days between two
dates; identifying overlapping periods (JOIN to the calendar table and
GROUP BY calendar day), etc.

Maintenance isn't usually a problem because the calendar tends to be
quite stable <g>! Also consider it's easier to change data in a table
than it is to make a code change to a UDF. Further, the table-driven
approach ports well to other SQL DBMSs.

Jamie.
 
In 30 years of multiple
languages and database engines, I have yet to find one where data retrieval
is faster than a code calculation.

I'm specifically referring to calculations performed in the SQL (the
classic straw man example being amortization calculations).
Regardless, a calculation doesn't have to bee too involved before it's
cost exceeds that of a read; I've seen plenty of examples! I doubt
that in the OP's case either makes too much of a difference and is
down to personal preference: SQL code or VBA code (and there are
wizards to write both).
you try to impose
SQL Server techniques on Jet and give newbies answers based on Non Access
products. I think this only leads to confusion.

I don't come here to tell people to use SQL Server (or any other SQL
DBMS) by rote; you may be thinking of a certain KAaron empf. SQL
Server is based on SQL (the language), Jet is based on SQL (the
language), and in these groups I post SQL which is as close to the
SQL-92 standard as Jet allows. Therefore, it is of no coincidence that
many approaches which work well in SQL Server will also work well in
Jet but that doesn't mean I'm imposing 'SQL Server techniques'
inappropriately.

I've no intention of accusing you of accusing me of something <g> but
I would really appreciate it if you could post some specific examples
of where you think I've caused confusion by posting something 'non
Access' because I'm a little baffled by your comments which I know you
make in good faith. TIA.
I wonder why you bother to use Access at all. You seem not to like it very
much.

How could anyone feel anything but unconditional love for Access? Its
forms and controls look really state of the art, even on Vista. The
quality of the average Access application is so high that I often
forget I'm not looking at a website! Its reports are so pretty and end
users really appreciate the interactive output, able to dynamically
alter the layout and so on. As a designer I really value the fact that
Jet is the most state of the art relational database around and
compliant with full ANSI standard SQL-92. It's just great that bugs in
the engine are fixed quickly and released as service packs on a near
weekly basis. And it's fortunately that I'm so in love with Access
because there are simply no alternative software development tools in
the marketplace with data aware controls, data binding, visual
designers for database objects, etc. Excuse me, I need to find some
water because my pants are on fire.

PS great story about the bank :)

Jamie.

--
 
Was I halucinating or did I just read a post where you were praising Access?

No, Jamie I don't have any specific examples of confusion. It is just a
general tone. When you give ANSI answers, a lot of the posters here don't
really understand the difference and may try to apply a solution that Jet
can't handle. Most have little or no experience true database design or
software development. Too many are admin types who happen to be a bit more
savy than their coworkers and so were assigned duties beyond their experience
by managers who don't know any different. It happened even in my own family.
When Dbase III was the hot desktop database application, my wife was sent to
a beginner class. Upon her return, her boss said, "okay, now you know DBase,
write us a library management system to keep track of all our documentation."
She thought she could until she tried to do it. Well, to shorten the story,
I wrote it for her.

So, that is why I think it is important to assume the poster has little or
no experience unless the content of the post leads me to believe otherwise.
Therefore, I scope my answers accordingly.

Access does get beat up a lot and has little respect in the "real"
application world. To some degree, that is justifiable. It was never
intended to by C++, Oracle, Crystal Reports, or Dot Net. It is to allow
small to medium scale application development at an affordable cost and be
managed by knowledable users.

Part of its design goal, however, is overly optimistic. Users who have no
experience with software development start of lost. But, Access didn't
invent this misconception of user capability. COBOL was written so users
could create their own programs without having to rely on programmers.

But, for what it does, it does well. A seasoned professional can do some
pretty amazing things with it. I work for a software development and
services company. The products, services, and web sites we provide are all
SQL Server and dot net. (Pure MS) But, the company' internal operational
business (an 800 Million dollar company) is all in Access except for
accounting.

One comment really puzzles me. I haven't seen a situation where a disc seek
is faster than a calculation. It would have to be a really complex
calculation for that to happen. Not saying it can't, but it would IMHO be
unlikely.
 
One comment really puzzles me. I haven't seen a situation where a disc seek
is faster than a calculation. It would have to be a really complex
calculation for that to happen. Not saying it can't, but it would IMHO be
unlikely.

I suspect you may be thinking of a specific definition of calculation.
I can fetch 100K rows from an mdb into a recordset in a fraction of a
second but to loop through from BOF to EOF to sum the values in a
field would take several minutes. I have an Excel spreadsheet here
that fetches a few hundred rows from a SQL database in no time at all
but its thousands of cell formulas take several seconds to
recalculate; it's not the most efficient calculation method but it
does show all its workings out at every intermediate stage which is
what the client wants.

In the case of the OP, I don't think there would be any noticeable
difference in performance between DATEPART, a similar UDF and a
fetching some rows from a table via a join.
Was I halucinating or did I just read a post where you were praising Access?

No, Jamie I don't have any specific examples of confusion. It is just a
general tone. When you give ANSI answers, a lot of the posters here don't
really understand the difference and may try to apply a solution that Jet
can't handle. Most have little or no experience true database design or
software development.

I'm here for generally the same reasons as everyone else: take on a
challenge, get some practice in, altruistic warm fuzzy feelings
inside, perhaps glean something new along the way. I also want to give
the sort of advice I wish I'd got when I first started using Access
e.g. awareness that Jet has rich SQL DDL syntax via its ANSI-92 Query
Mode. I'm slightly bothered by seeing the same old answers
regurgitated on a seemingly daily basis, especially when the language
used is of the style, "You have to use DAO to do this." But not as
bothered as I am by seeing the same flawed answers e.g. a validation
rules that pay no regard to alternative mode wildcard characters. But
what can one do? I plug away, posting original answers in Jet dialect
SQL (not ANSI) and refuting apparent fallacies with examples and links
to articles. I've seen some of the approaches I've introduced being
adopted, even by some regulars, but I don't seek to take credit and I
can't take a compliment (fortunately I don't get many <g>).

I think the most exciting (if that's the right word) thing about the
Jet engine is that, because there have been so few details published
about it, we must *discover* how things work (and keep on
rediscovering what others have forgotten) without knowing much about
how they are supposed to work.

Take CHECK constraints: they were announced in the Jet 4.0 release,
another brief article was published with a (flawed) usage example, and
that was about it. They have never AFAIK been mentioned in the Help
and we have no detail on how they should behave. Should they be
checked on a row-by-row basis, even though this makes no sense for
table level constraints (note the aforementioned examples provided by
MSFT are *multi* table level)? If the ANSI-92 standard specifies they
should be checked at the SQL statement level, and MSFT tells us that
Jet is nearly-but-not-quite entry level SQL-92 (table level CHECK
constraints -- those that may contain subqueries -- are a feature of
*full* SQL-92) and I can show that they are tested by Jet on a row-by-
row, table-by-table basis, how can I determine whether this is a
feature or a bug? So why so I feel like I'm the Lone Ranger here about
an important feature in a popular SQL DBMS. A very interesting
situation.

Jamie.

--
 
So why so I feel like I'm the Lone Ranger here about
an important feature in a popular SQL DBMS. A very interesting
situation.
I think the problem is that the Access query interface does not support many of
the things you talk about. If the interface supported them, then I think we
would see the MPVs using them and championing them. Users here imitate what
they see the MPVs using. The MPVs here have a huge reputation. If a person
asks about table constraints and an MPV says to forget that and use form event
code, then that is the definitive word on the subject. That is what you are up
against.
 
I think there is a small misunderstanding. When I say a calculation is
faster than a disck fetch, I mean exactly that. If you can calculate a value
in memory it is much faster than a disc fetch to retrieve the value from a
table. As to your statment regarding a recordset as opposed to looping
through from BOF to EOF, I am assuming you mean using ans SQL query as
opposed to recordset processing. I would agree with that.

As to the differences, I did some testing with this scenerio. In an
application I inherited, there was a table that defined the beginning and
ending of each accounting period. In a case where the accounting periods are
not aligned with the calendar, this may be necessary. I had one of those
once, too. But, this for this app each record had 3 fields - the period
(200708), the first day of the month as a date, and the last day of the month
as a date. Each time a form opened, it hit the database to determine the
beginning and ending period dates. Determining the first and last days of a
month are so simple to calculate, one wonders why the need for the table at
all, other than not knowing how to use date handling functions. The
comparision was the the calculations were 80% faster than the fetch.
 
Michael, I believe most MVPs are as willing to listen as they are to preach.
I have learned more in these groups than I have taught.
Most of the MVPs here have many years of experience in Access and most have
a general background in IT using other platforms, languages, and database
engines.
No one technique is perfect in all circumstances. You have to use your
experience, knowledge, and judgement to make a decision on how to do
something.

I think if you read enough posts, you will find that not all MVPs agree on
every point. I have seen and been involved in some heated arguments on
certain points. Sometimes, I have been convinced my approach was, after all,
not the best. We all come from different backgrounds and have our own
prejudice.

The validation level you bring up is one of those. Some will argue it
should always be done at the database engine level and others prefer the form
level. There are valid argument for both. If Jet were a Client Server
databae engine, then database level would be preferred. But, it is not
Client Server, it is File Server. Therefore, there is no performance
advantage to database validation. All the processing happens at the client.
But, if you plan to upsize.... Okay, good point, but how many times does that
actually happen. The performance advantage using Jet is with Form or Control
level validation. That is because the error is caught before the call to Jet.

But, other MVPs and others as well, would argue the point with me. Okay,,,
they can do it however they want and I am happy to hear their arguments. I
may be convinced to switch. But, until one of them is signing my paycheck or
has convinced me to switch., I will do it my way.

So, regardless of what anyone MVP or not says in these groups, make your own
judgements, but be willing to listen.
 
I think the problem is that the Access query interface does not support many of
the things you talk about. If the interface supported them, then I think we
would see the MPVs using them and championing them.

I've seen you've written a few table-level CHECK constraints yourself
and I assume you are familiar with the Access query builder tool thing
(consider what you need to do to get the designer to use a subquery)
with its expression builder tool thing: can you imagine how complex a
table-level CHECK constraint builder tool thing would be <g>?! I
really don't think such a beast would practical, therefore I think
writing SQL will always be a prerequisite to be able to write a table-
level CHECK constraint.

Don't forget about the DAO problem, with its hard-coded assumption
that all constraints are implemented using an index -- and you know
how the Access MVPs love their DAO said:
Users here imitate what
they see the MPVs using. The MPVs here have a huge reputation. If a person
asks about table constraints and an MPV says to forget that and use form event
code, then that is the definitive word on the subject. That is what you are up
against.

I can't decide whether you are urging me not bother or proposing me
for MVP <vbg>.

Jamie.

--
 
I can't decide whether you are urging me not bother or proposing me
for MVP <vbg>.
Microsoft has their criteria, but I have my own, and some people who are not
MPVs meet my criteria. Not that it actually matters.
 
Back
Top