get a date from two date field

how to use a stored procedure to get a date which is start_date + due_date.

stare_date and due_date are data field. dats type are smalldatetime. database is SQL 2000.  

12/12/2005 8:45:23 PM 93655 articles. 6 followers. Follow

4 Replies

Similar Articles

[PageSpeed] 22

Give an example of what you want.....
Do you want something like 12/12/2005 12/25/2005 ?

Eric Ramseur
Rainbow Portal 2.0 Admin
Download Rainbow 2.0!!
Rainbow Code
Rainbow Portal Community
C# 2005 Group
12/13/2005 4:51:56 AM

I need a date, 60 days before start date +  due days.

For example, start is 12/03/2005(smalldatetime) Due days is 20(int).  

start date + due day - 60 is 10/23/2005. that's what I need. Thanks.

12/13/2005 3:52:29 PM

Thanks, I got it

I am using a query to call user defined  function. like that.

select a, b, C
from table B
where = user_defined_function(a, b)

is it right? I mean, can I pass a variable from select command into a used defined function?

12/14/2005 6:34:19 PM

Similar Artilces:

Get the dates between two dates
Hi all, I want to get all the date between two dates. For example I have a StartDate="12/5/2003" and a EndDate="12/7/2003" the result should be 12/5/2003 12/6/2003 12/7/2003 Ant help is appreciated Thanks for ( DateTime theDate=StartDate ; theDate<=EndDate ; theDate.AddDays(1) ) { // Do something...theDate.ToShortDate() would give the string... } Starting with ASP.NET 2.0? Look at:Programming Microsoft Web Forms My Blog I get a syntax error as :"For loop variable cannot be of type Date" Hmm. The below work...

Dates, Dates, Dates!
Hello all... I am in the process of building an appointment system, and I am trying to see if I can get some pointers on which way to go on this. The first version of this appointment system was very lo-tech, and it stored all of the possible dates/times in the database. Once a user booked an appointment, their information was logged to that date/time, and then that date/time would no longer show in the list of possible openings. This was great for a temporary fix, but with having to pre-populate all of the dates/times, the system would eventually have to be updated to continue on pa...

How to get all Dates b/w two dates
Hi, How can i display all the dates b/w two dates in or -------------------------------------------------------------------------  Example: Date_1: 12/01/2009        Dates_2: 14/01/2009 Results: 12/01/2009 13/01/2009 14/01/2009 -----------------------------------------------------------------   Do you just want to get the dates, or are these dates stored in a database somewhere?David WierMCP/ - where to look first!Please Vote for ASPNet101 - 'Best Community Resource'!Control Grouper -...

getting a date picker widget for a date field
The tutes say to bind the field to an xsd:date to get a date picker. I do that. The example works fine for static pages. Great. However when I try to incorporate this into my form, where the instance is loaded dynamically like this: <xf:submission action="retrieve.php" method="post" replace="instance" instance="mydata" id="retrieve" /> I get the form and data filled out fine, but no date picker for date fields. Ok so maybe I need to bind after the submit is done, so I add this: <xf:send submission="re...

date field = date
i made an news table and i made and option to add and update and delete news from it i need one thing that when someone try to add news the time that he insert the news will be in teh date field of the table and dont the costumer write it   hope that u understand me Hi, did you mean you want to add a column that get current date as its value automaticly? If so, you can do the following in Access2003: 1. add a column with 'Date/Time' data time 2. In the 'Field Properties'->'General' pannel, add a 'Default Value' for it, 3. In the 'Expression Builder', double cli...

No date in Date field
I have just installed thunderbird on my system. I migrated from outlook express. All the mail that was there before shows both the date and the time in the date field. However, all mail received by thunderbird only has a time stamp, no date. How do I correct this?? Thanks, Roger _Roger Bailey_ spoke thusly on 29/08/2006 10:09 PM: > I have just installed thunderbird on my system. I migrated from outlook > express. All the mail that was there before shows both the date and the > time in the date field. However, all mail received by thunderbird only has ...

How to convert a chinese date to english date in web form?
Hi ASP.NET Proz,  I try to convert a chinese charater date (18-一月-2008) to english date (18-Jan-2008) from a web form. Is that possible?  Thanks in advance for the Proz!  * .NET Proz always make impossible to possible Try this one:   System.Globalization.CultureInfo nlCulture = new System.Globalization.CultureInfo("zh-CHT"); // Chinese Traditional DateTime date = DateTime.MinValue; DateTime.TryParseExact(chineseDateString, "dd-MMM-yyyy", nlCulture, System.Globalization.DateTimeStyles.None, out date); ...

From Date and To Date
 In my application i have two textboxes.One for From date and the other one for To date.I need to check whether the From date is lesser than To Date..Date formats will be either(DD-MM-YYYY) or (DD/MM/YYYY).and i have used calendar extender for selecting dateI need the script code to do this...Thanks in advance See this thread: Naeem"Please mark as answer if it helped you"  <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server"> </...

from date to date
I am working on a form for livestock. one of the things in the form is a checkbox to let me know if they qualify or not. the second is I have a created record field entered into the database... now my question is I am doing a search on this and cant figure it out since i am new to all this...i have a query that selects the qualification checkbox (where qualify = 'true') then another query that selects the created record date... and the search is that I want to get the information in the livestock that are qualifyed (have the checkbox qualify = to 'true') between  one dat...

Auto Filling a Form Date Field With Today's Date
Can anyone tell me how to automatically insert today's date into a date field on a web form? I'm coding in VB using Visual Studio. Thanks myTextbox.Text = DateTime.Today.ToShortDateString()Darrell Norton, MVPDarrell Norton's BlogPlease mark this post as answered if it helped you! Dim myDate as DateTime=DateTime.Now now - assuming your field is a textbox: textbox1.text=myDate.DateDavid WierMCP/ - where to look first!Please Vote for ASPNet101 - 'Best Community Resource'!Control Grouper - easily control properties for multiple controls with one...

Setting the date on a date field
Hello, How do I get SQL server to insert the current date on inserting a record in a field of datetime? Thanks GrantGrant Krieger cmd.Parameters("@Date").Value = DateTime.NowSushila Bowalekar PatelVisual ASP/ASP.NET MVP Alternately, you could set the Default value of the column to GETDATE(). This would put the current datetime of the SQL Server into the column. TerriTerri MortonEngagement Manager, NeudesicHow to ask a question...

getting date in between 2 date
how do i get the date in if it is within the 2 date? er... don't know how to phrase i think my sql is something like this: SELECT * From Transaction WHERE Date BETWEEN 01/08/1900 AND 31/08/2000 BTW i declare my Date as date/time(short date) is it possible with the sql? it display Syntax error in FROM clause. SELECT * From [Transaction] WHERE [Date] BETWEEN #01/08/1900# AND #31/08/2000# Now, this presumes that the machine in question is expecting dates in dd/mm/yyyy format. Note that Transaction and Date are likely reserved words, and so I have enclosed them in [ and ...

Getting dates between 2 dates
Hi all, Would like to make an enquiry, if i have 2 dates, how can can i get all the dates between these 2 dates. Thanks for the help.   You will probably need to loop through the dates;               DateTime startdate;            DateTime enddate;            List<DateTime> allDates = new List<DateTime>();            allDates.Add(startdate);         ...

Default date in date field
I have an .aspx file with an input form linked to an MS Access database.  The date field receives a value of yesterday's date except for Monday which will have input for Friday, Saturday and Sunday. I'd like to have a default date of yesterday in the date field but also the ability to change it.  Is there a place in the properties to set the default date or must it be done in the code? I'm not sure about the property, but you could certainly have it set in the code behind like this on page_load... this.txtDateBox.text = DateTime.Now.AddDays(-1).ToShortDateAsString...

Web resources about - get a date from two date field -

Field - Wikipedia, the free encyclopedia
Field (computer science) , a smaller piece of data from a larger collection (e.g., database fields) Text is available under the Creative Commons ...

Snipers lurking in the shadows in a week of off-field drama at the Brumbies
It's sniping season at the ACT Brumbies, and no one is safe. But it's time for calm as the club searches for stability.

Can the GOP field out-psycho Trump tonight? We're about to find out
Can the GOP field out-psycho Trump tonight? We're about to find out by digby I previewed the debate for Salon this morning: If you haven’t ...

NEW WSJ/NBC POLL: Trump and Cruz Running Away From the Field
... Wall Street Chamber of Commerce Journal , a glum Janet Hook reports that Donald Trump and Ted Cruz are now dominating the national GOP field ...

Beach Slang, Tim Kasher and Field Mouse played Knitting Factory
photos by Amanda Hatfield, words by Andrew Sacher Beach Slang / Tim Kasher / Field Mouse @ Knitting Factory - 12/17/15 "Hey we're Beach Slang ...

CNN GOP debate leaves field unsettled - Business Insider Deutschland
Within minutes, it was clear that the fifth Republican presidential debate, on CNN, would be perhaps the most contentious yet.

Poll: Trump leads GOP field with widest margin yet
Going into fifth Republican debate tonight, survey finds Trump's lead over his rivals increasing

The GOP Presidential Field Abandons Fiscal Restraint At The Pentagon
The United States is spending more on average now than we have at any time during the Cold War.

Rugby Dude Gets 4 Teeth Knocked Out Of His Head, Fumbles Around For Them On Field
Thoughts I would have before I, unlike LOU’s Jérémy Gondrand, got up and started calmly looking for the four teeth that had just been smashed ...

Could A Nepalese Reality Show Help Restore Faith In Track And Field?
The real problem in track and field might not be the endemic corruption, but defeatism, the feeling that everybody’s in on it—administrators, ...

Resources last updated: 12/21/2015 2:57:08 PM