Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Tamar Granor
  Where is Tamar Granor?
 Elkins Park
 Pennsylvania - United States
 Tamar Granor
 To: Patrick Danso
  Where is Patrick Danso?
 Accra
 Ghana
 Patrick Danso
 Tags
Subject: RE: Append Selected Records to another Table
Thread ID: 345480 Message ID: 345494 # Views: 36 # Ratings: 0
Version: Visual FoxPro 9 Category: Databases, Tables and SQL Server
Date: Wednesday, May 23, 2012 10:58:47 PM         
   


> Hi Friends,
> I have a table called Payments as shown below;
> Memberid date Name chq_bank amount
> 001 01/01/2012 John PLC Bank 150
> 005 15/01/2012 Fred SSB Bank 285
> 001 01/02/2012 John SSB Bank 680
> 005 20/01/2012 Fred PLC Bank 1000
> 010 01/01/2012 Hook SSB Bank 360
> 016 15/01/2012 Rita SSB Bank 750
> 001 01/01/2012 John PLC Bank 1500
> 001 15/03/2012 John PLC Bank 150
> 005 15/04/2012 Fred SSB Bank 285
> 001 28/04/2012 John SSB Bank 680
> 005 27/05/2012 Fred PLC Bank 1000
> 010 18/05/2012 Hook SSB Bank 360
> 016 23/02/2012 Rita SSB Bank 750
> 001 11/05/2012 John PLC Bank 1500
>
> I want to select and append one record each from the table to another table called Mypayment.
> Can i get some code to do it.

Sounds like you need

INSERT INTO MyPayment ;
  SELECT * FROM Payments WHERE <whatever the condition is>


Tamar

ENTIRE THREAD

Append Selected Records to another Table Posted by Patrick Danso @ 5/23/2012 7:16:48 PM
RE: Append Selected Records to another Table Posted by Tamar Granor @ 5/23/2012 10:58:47 PM
RE: Append Selected Records to another Table Posted by Anders Altberg @ 5/23/2012 11:44:12 PM