Column headings in SQL

JPFred

Registered User.
Local time
Today, 13:40
Joined
Oct 29, 2017
Messages
47
I have written an sql query (below) and need to have a user friendly column heading displayed with each field. I a retired senior programmer analyst and have been retired for 10 years. I know there is something I have forgot to accomplish my issue. Any help will be appreciated.


Code:
SELECT accession, spineselect, deweynum, checkedoutby, gradelevel, title, checkedoutdate, duedate, gradelevel
FROM main
WHERE duedate < date() and late = "Yes"
ORDER BY gradelevel, checkedoutby, duedate;
 
Why? Users should not work directly with tables and queries so doesn't matter what the field names are. Build a form or report and use whatever text you want in labels.

Are you exporting to Excel?

Use alias:

SELECT accession AS [This Is Alias FieldName], ...
 
if you are using the access tables, you can use the field caption property. However this can be confusing (same as lookups) when looking at the result whilst still developing queries- but will autopopulate labels when they are created.

A mixed blessing. I still advocate them as a device you can use once tables/relationships have been created but before building forms/reports. Better than having spaces in field names, but otherwise agree with June
 

Users who are viewing this thread

Back
Top Bottom