Home > Archive > Programming with dBASE > October 2005 > Loop thru tables in a directory









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Loop thru tables in a directory
Dan Goldberg

2005-10-27, 5:18 pm

Using dB+ I am adding features to an old accounting program written in clipper called abacas. Abacus creates tables for invoice batches naming them "BI023487, BI023488" etc. To give users the ability to browse data in theses batches I need to automate a
procedure to combine the data in these batch tables in one dbf table. I can copy the tables I want to work with in one directory. I than need to loop through each table and append the data. Any suggestions on how do this programmatically would be gr
eatly appreciated.


Todd Kreuter

2005-10-27, 5:18 pm



Dan Goldberg wrote:
>
> Using dB+ I am adding features to an old accounting program written in clipper called abacas. Abacus creates tables for invoice batches naming them "BI023487, BI023488" etc. To give users the ability to browse data in theses batches I need to automate

a procedure to combine the data in these batch tables in one dbf table. I can copy the tables I want to work with in one directory. I than need to loop through each table and append the data. Any suggestions on how do this programmatically would be
greatly appreciated.

Use an array:

a = new array()
a.dir(C:\SomePath\"bio?????.dbf")

Then you can traverse through the array and do as you need.

--
Todd Kreuter [dBVIPS]
Dan Goldberg

2005-10-28, 11:23 am

Todd Kreuter Wrote:

>
>
> Dan Goldberg wrote:
te a procedure to combine the data in these batch tables in one dbf table. I can copy the tables I want to work with in one directory. I than need to loop through each table and append the data. Any suggestions on how do this programmatically would b
e greatly appreciated.[color=darkred]
>
> Use an array:
>
> a = new array()
> a.dir(C:\SomePath\"bio?????.dbf")
>
> Then you can traverse through the array and do as you need.
>
> --
> Todd Kreuter [dBVIPS]


Thanks Todd. I have never worked with arrays before. This will give me the incentive I need to get started with them.
Dan

Todd Kreuter [dBVIPS]

2005-10-28, 8:23 pm

"Dan Goldberg" < dgolberg@fastlimited
.com> wrote in message
news:qYTZy582FHA.1236@news-server...
>
> Thanks Todd. I have never worked with arrays before. This will give me

the incentive I need to get started with them.

You're welcome, Dan.

Ask questions if you need help

Todd Kreuter [dBVIPS]


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com