| Subject |
Re: Append problem xdml |
| From |
Charlie <tm@tc.com> |
| Date |
Sun, 08 Nov 2020 10:01:53 -0500 |
| Newsgroups |
dbase.getting-started |
Hi Akshat... I am the original programmer and originally wrote the original code in dos in I believe the late 80's In 2016 took around 6 moths to change this over to mainly oodml but I left some of the original program in xdml which I am more familiar with although I have learned a lot about oodml. Even so I still code many of my scrips in xdml which I will argue is easier to do and run better at least for me. (.prg only.)
All I am asking is for a reason why the size of the table is changing. This has stumped me, but there has to be a reason and I hope someone might be able to point me in the right direction to figure this out.
At any rate for this small problem hell will freeze over before I do as you say! I say this with much respect as you have helped me many times over the years.
Akshat Kapoor Wrote:
> Good Evening Charlie,
> >
> > use taldata order lname
> > do while not eof()
> > partno = part_no
> > set filter to part_no = partno
> > count to cnt
> > if cnt > 1
> > cntr = cnt
> > do while cntr > 1
> > delete
> > cntr = cntr - 1
> > enddo
> > replace qty with cnt
>
> Only the last row will be updated as rest have been deleted in the above
> loop.
> > set filter to
> > endif
> > skip
> > enddo
> >
> > And it does add the blank correctly but it also changes somehow the size of taldata.dbf and fails when you try to run talfinis.prg. I think it has something to do with an indexing problem. What happens is instead of replacing all fields, only the last record in taldata is changed. So if you add a total of 60 records in master.dbf, the last record of corresponding taldata.dbf shows a quantity of 60. I have tried to reindex taldata.dbf but i don't think that helped.
> >
> > i'm thinking possibly I can fix this in talfinis.prg but with the set relation, i'm not sure what to do.
>
> We have not idea how and why you are processing the records. So the only
> recommnedation I could make is mentioned above.
>
> You mentioned dbase 4
> In those days networking was a luxury and so this program was made for a
> single user only.
>
> In case you are not the original programmer i.e. you inherited it I
> would recommend starting from scratch and building a new program using
> the latest methods if you can afford the time.
>
> Making small changes will consume lots of time and in the end the app
> will always remain outdated.
>
> Regards
> Akshat
|
|