A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Commenting in SQL



 
 
Thread Tools Display Modes
  #1  
Old February 22nd, 2010, 06:23 PM posted to microsoft.public.access.queries
VWP1
external usenet poster
 
Posts: 7
Default Commenting in SQL

Is there any "comment" characters I can use in SQL which will be ignored,
similar to HTML's !-- comment -- ?

VWP1
  #2  
Old February 22nd, 2010, 06:35 PM posted to microsoft.public.access.queries
Jerry Whittle
external usenet poster
 
Posts: 4,732
Default Commenting in SQL

Unfortunately not in Access. I have heard of some comvoluted workarounds such
as running the SQL in code where you can make it happen.
--
Jerry Whittle, Microsoft Access MVP
Light. Strong. Cheap. Pick two. Keith Bontrager - Bicycle Builder.


"VWP1" wrote:

Is there any "comment" characters I can use in SQL which will be ignored,
similar to HTML's !-- comment -- ?

VWP1

  #3  
Old February 22nd, 2010, 09:22 PM posted to microsoft.public.access.queries
John W. Vinson
external usenet poster
 
Posts: 18,261
Default Commenting in SQL

On Mon, 22 Feb 2010 10:23:01 -0800, VWP1
wrote:

Is there any "comment" characters I can use in SQL which will be ignored,
similar to HTML's !-- comment -- ?

VWP1


We've been yelling at MS for years to add this feature, but... at present, no.

About all you can do is a snarky getaround: creating a phony calculated field,
e.g.

SELECT "This isn't a real field, just a comment" AS IgnoreThis, other fields
FROM mytable...

--

John W. Vinson [MVP]
  #4  
Old February 22nd, 2010, 09:34 PM posted to microsoft.public.access.queries
Albert D. Kallal
external usenet poster
 
Posts: 2,874
Default Commenting in SQL

"John W. Vinson" wrote in message
...
On Mon, 22 Feb 2010 10:23:01 -0800, VWP1
wrote:

Is there any "comment" characters I can use in SQL which will be ignored,
similar to HTML's !-- comment -- ?

VWP1


We've been yelling at MS for years to add this feature, but... at present,
no.


Yes, come to think of it is something I've been forgetting to yell about!


About all you can do is a snarky getaround: creating a phony calculated
field,
e.g.

SELECT "This isn't a real field, just a comment" AS IgnoreThis, other
fields
FROM mytable...


Well, at least I can say I'm very proud of you, since you've added the word
snarky to above statement.
(no question, the above is a last chance saloon type of solution).


--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:01 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.