Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Database > SQL Language
|
SQL Language SQL Language discussions not specific to a particular RDBMS program or vendor.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Language section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 14th, 2005, 06:15 PM
Authorized User
 
Join Date: Jan 2005
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
Default inserting installments in a query or table


Hello, everyone!

My problem is based in a row obtained in a query as in the following example:

Cost NumberOfInstallments First Payment Last Payment
 120 6 1-Jan-05 1-Jun-05

(All these where properly given or calculated.)

What I need to do? Dividing 120 by 6, I need to create a table
with the following fields/rows:

Cost Date
20 1-Jan-05
20 1-Feb-05
20 1-Mar-05
20 1-Apr-05
20 1-May-05
20 1-Jun-05

In other words, when a payment is known to be accrued and the number of installments is given (1=only one payment, at the date given) , I need to create a table with all first days of successive months till the last payment and at each date the same value to be considered charged. (If you pay annually for a magazine, I want to consider it paid month by month, ok?!)

How should I proceed?

Thanks a lot,
fskilnik






Similar Threads
Thread Thread Starter Forum Replies Last Post
Inserting new field to a table elygp SQL Language 3 March 19th, 2008 12:03 PM
inserting data into a table NovieProgrammer Access VBA 7 April 7th, 2005 11:26 PM
Inserting a value from one table to another Hudson40 Access VBA 1 February 25th, 2005 08:54 AM
copying from table 1 inserting in table 2 gilgalbiblewheel Java GUI 0 September 15th, 2004 03:40 PM
Inserting table in RichTextbox agarwalmk VS.NET 2002/2003 0 February 11th, 2004 05:16 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.