Click here to Skip to main content
15,122,218 members
Home / Discussions / Database
   

Database

 
GeneralRe: A query with lot of inner queries Pin
Jörgen Andersson30-May-14 4:15
professionalJörgen Andersson30-May-14 4:15 
GeneralRe: A query with lot of inner queries Pin
indian14330-May-14 10:08
Memberindian14330-May-14 10:08 
GeneralRe: A query with lot of inner queries Pin
Jörgen Andersson30-May-14 10:24
professionalJörgen Andersson30-May-14 10:24 
GeneralRe: A query with lot of inner queries Pin
indian14330-May-14 10:05
Memberindian14330-May-14 10:05 
GeneralRe: A query with lot of inner queries Pin
Mycroft Holmes30-May-14 13:46
professionalMycroft Holmes30-May-14 13:46 
QuestionProblem with tempdb - MSSQL Pin
Milan K SK28-May-14 5:32
MemberMilan K SK28-May-14 5:32 
AnswerRe: Problem with tempdb - MSSQL Pin
Kornfeld Eliyahu Peter28-May-14 7:39
professionalKornfeld Eliyahu Peter28-May-14 7:39 
QuestionSQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss27-May-14 12:10
MemberSeuss27-May-14 12:10 
Hi all,

I am in desperate need of help please.

I have created a stored procedure with a while loop using a hard coded date 31-12-2014 to compare against current date produced in a while loop. I need to make the hard coded date reflect every two years i.e. 31-12-2016, 31-12-2018 etc.
How can the date be automatic instead of hard coded please?
i.e While (currdate <= '31-12-2014')

Second issue, how do I make the stored procedure to run every two years as well?

SQL Agent Job doesn't have a yearly frequency at all.

Can someone please offer an example coding and suggestions to those two issues which I will be grateful please.
Confused | :confused:

Thank You!
AnswerRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Mycroft Holmes27-May-14 13:45
professionalMycroft Holmes27-May-14 13:45 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss27-May-14 21:10
MemberSeuss27-May-14 21:10 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Mycroft Holmes27-May-14 21:22
professionalMycroft Holmes27-May-14 21:22 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss27-May-14 23:14
MemberSeuss27-May-14 23:14 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
NitinDhapte16-Jun-14 2:55
MemberNitinDhapte16-Jun-14 2:55 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss27-May-14 23:28
MemberSeuss27-May-14 23:28 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Mycroft Holmes27-May-14 23:55
professionalMycroft Holmes27-May-14 23:55 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss28-May-14 0:00
MemberSeuss28-May-14 0:00 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss28-May-14 6:28
MemberSeuss28-May-14 6:28 
AnswerRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Chris Quinn27-May-14 23:53
MemberChris Quinn27-May-14 23:53 
GeneralRe: SQL Server 2012 Agent Job & stored procedure issue URGENT Pin
Seuss28-May-14 0:01
MemberSeuss28-May-14 0:01 
QuestionHow to select the records who are completed exactly years comparing with joining date and todays date Pin
ven75326-May-14 7:09
Memberven75326-May-14 7:09 
AnswerRe: How to select the records who are completed exactly years comparing with joining date and todays date Pin
jschell26-May-14 9:11
Memberjschell26-May-14 9:11 
GeneralRe: How to select the records who are completed exactly years comparing with joining date and todays date Pin
ven75326-May-14 22:27
Memberven75326-May-14 22:27 
AnswerRe: How to select the records who are completed exactly years comparing with joining date and todays date Pin
Mycroft Holmes26-May-14 13:52
professionalMycroft Holmes26-May-14 13:52 
GeneralRe: How to select the records who are completed exactly years comparing with joining date and todays date Pin
Sunasara Imdadhusen26-May-14 22:30
professionalSunasara Imdadhusen26-May-14 22:30 
AnswerRe: How to select the records who are completed exactly years comparing with joining date and todays date Pin
NitinDhapte16-Jun-14 3:18
MemberNitinDhapte16-Jun-14 3:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.