Unexpected Delete
Thanks, John.
I still don't know whether it is truly important to narrow the selection of
fields. If it is (as I would think), and since field names tend to be
somewhat lengthy despite our best efforts, then it seems odd being limited by
the length of the string for a query. One would think by now there would be
some sort of behind-the-scenes mechanism to circumvent this limitation.
Thanks Again,
Pew
"John W. Vinson" wrote:
On Mon, 15 Feb 2010 12:13:01 -0800, oldblindpew
wrote:
Would this argue for using shorter field names?
That, or alias the tablenames and fieldnames: rather than
SELECT [LongTableNameA].[ThisIsABigFieldName],
[LongTableNameB].[AnotherBigFieldName]
FROM [LongTableNameA] INNER JOIN [LongTableNameB]
ORDER BY [LongTableNameA].[ThisIsABigFieldName]
you can use
SELECT [A].[ThisIsABigFieldName] AS BigA, [b].[AnotherBigFieldName] AS BigB
FROM [LongTableNameA] AS A INNER JOIN [LongTableNameB] AS B
ORDER BY BigA;
In a large many-field query with long fieldnames this can save you a whole lot
of characters.
Also, if a fieldname is unambiguous you don't need to qualify it with the
tablename; i.e. instead of
WHERE [LongTableNameA].[SomeUniqueField] = criteria
just use
WHERE [SomeUniqueField] = ...
--
John W. Vinson [MVP]
.
|