Rows Append

SjCc

Registered User.
Local time
Yesterday, 17:54
Joined
Oct 5, 2017
Messages
67
Hellow there!!

I have a table with field name Sdate (Short date dd-mm-yyyy)
In the same table i have another field I_Months (Numeric field)

now what i want that if i select todays date i.e. 12 Dec 2019 and select 6 in I_Months field means i want 6 rows to added in new table with month name like this as SDate would be the first start month (Its a installment DB)

Dec 2019 1
Jan 2020 2

so on till

May 2020 6


Any help would be appreciated
 
Hi. I think you can use a Tally table with a Cartesian query to get what you want.
 
would a cartesian actually work, guy? I've not used them much, so I would guess you might be right.

sjcc,

you can obviously do this with code as well, or by running 6 different INSERT INTO queries, one after the other, either through code or thru the interface.
 
Have a look here and follow the link in there as well for an example idea/approach.
yeah that's what I thought, guy. I read your stuff and I don't know if that's what this man wants. he only wants 6 records from ONE table. cartesians multiple things to very high levels of output, depending on the size of the 2 inputs.

you might be right though. lets wait to see what return response he's got for us.
 
Resolved after whole night wffort
 
Resolved after whole night wffort
sjCC,

It would do future browsers of this thread a lot of good if you posted the details of the answer you found.
 

Users who are viewing this thread

Back
Top Bottom