Solved

select query I want to select 'today's date' as part of my select

Posted on 2008-06-09
3
250 Views
Last Modified: 2010-04-21
select account_id, ***date- Todays date**** format YYYYMMDD with no spaces etc from cashmgmt_payment

also how can I make it so there are no 'header' or footer records so the output is something like:

123   20041224

no reference to rows selected or no header before JUST the result set.
0
Comment
Question by:MyDanes
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 21744733
the "header" is the output settings of the query tool...

the rest should be like this:
select account_id, convert(varchar(10), getdate(), 112) from cashmgmt_payment

Open in new window

0
 
LVL 60

Expert Comment

by:chapmandew
ID: 21744735
select convert(varchar(10), getdate(), 112)
from tablename

as for the headers, view the results as text.  Go to tools, options...there is an option for not showing the headers.
0
 

Author Closing Comment

by:MyDanes
ID: 31465463
Thank you so much  - as usual PERFECT help
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you find yourself in this situation “I have used SELECT DISTINCT but I’m getting duplicates” then I'm sorry to say you are using the wrong SQL technique as it only does one thing which is: produces whole rows that are unique. If the results you a…
Confronted with some SQL you don't know can be a daunting task. It can be even more daunting if that SQL carries some of the old secret codes used in the Ye Olde query syntax, such as: (+)     as used in Oracle;     *=     =*    as used in Sybase …
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question