Clarion 2.1 for dos question 
Author Message
 Clarion 2.1 for dos question

Hello there

I was wondering if anyone could help me out with this little problem, let me
first explain i am not used to clarion for dos i have taken this project
over from someone else and am having a little trouble.  ok then i have a
growing database with currently 10,000 records with a key field job_num this
is currently at about 500 as the same number is used about 20 times thus
creating about 10,000 records what i want to do is search through this
database for this job_num when it reaches the end of the file i want it to
then write this number into a seperate database.  I can get it to find the
last file in the database but am unable to write this number into a new
database file below is what i have done allready.

             MEMBER('TEST')
TEST1      PROCEDURE

  EJECT
  CODE
  SHARE(DATA)
  SET(DATA)
   LOOP UNTIL EOF(DATA)
   NEXT(DATA)
  .
  DAT:JOB_NUM += 1          !   I now want to write this field into a new
database (which has already
                                                 !   been created) lets say
the database file name is test and the field is
                                                   ! TES:JOB_NUM

  RETURN

I know i can put this line in TES:JOB_NUM = DAT:JOB_NUM but what do i type
next to write the record into the database file I know you can use PUT(TEST)
but i can't get this working

I would be thankfull for any help i get



Fri, 12 Jul 2002 03:00:00 GMT  
 Clarion 2.1 for dos question
Hi,
There is a quicker way to do this.
? TES:JOB_NUM = records(data)???? ! find the number of records in a file
? tes:job_num = test:job_num + 1???? !? add one
? update()?????????????????????????????????????? ! update file
? put(test)?????????????????????????????????????? ! put into file
? if error() then???????????????????????????????? ! check for any errors
??? message(error())
? end
Hope this helps
John
?
?
?
Quote:

> Hello there

> I was wondering if anyone could help me out with this little problem, let me
> first explain i am not used to clarion for dos i have taken this project
> over from someone else and am having a little trouble.? ok then i have a
> growing database with currently 10,000 records with a key field job_num this
> is currently at about 500 as the same number is used about 20 times thus
> creating about 10,000 records what i want to do is search through this
> database for this job_num when it reaches the end of the file i want it to
> then write this number into a seperate database.? I can get it to find the
> last file in the database but am unable to write this number into a new
> database file below is what i have done allready.

> ???????????? MEMBER('TEST')
> TEST1????? PROCEDURE

> ? EJECT
> ? CODE
> ? SHARE(DATA)
> ? SET(DATA)
> ?? LOOP UNTIL EOF(DATA)
> ?? NEXT(DATA)
> ? .
> ? DAT:JOB_NUM += 1????????? !?? I now want to write this field into a new
> database (which has already
> ???????????????????????????????????????????????? !?? been created) lets say
> the database file name is test and the field is
> ?????????????????????????????????????????????????? ! TES:JOB_NUM

> ? RETURN

> I know i can put this line in TES:JOB_NUM = DAT:JOB_NUM but what do i type
> next to write the record into the database file I know you can use PUT(TEST)
> but i can't get this working

> I would be thankfull for any help i get



Fri, 12 Jul 2002 03:00:00 GMT  
 Clarion 2.1 for dos question
Since this is a new record use add instead of put

Jim

Quote:

> Hello there

> I was wondering if anyone could help me out with this little problem, let me
> first explain i am not used to clarion for dos i have taken this project
> over from someone else and am having a little trouble.  ok then i have a
> growing database with currently 10,000 records with a key field job_num this
> is currently at about 500 as the same number is used about 20 times thus
> creating about 10,000 records what i want to do is search through this
> database for this job_num when it reaches the end of the file i want it to
> then write this number into a seperate database.  I can get it to find the
> last file in the database but am unable to write this number into a new
> database file below is what i have done allready.

>              MEMBER('TEST')
> TEST1      PROCEDURE

>   EJECT
>   CODE
>   SHARE(DATA)
>   SET(DATA)
>    LOOP UNTIL EOF(DATA)
>    NEXT(DATA)
>   .
>   DAT:JOB_NUM += 1          !   I now want to write this field into a new
> database (which has already
>                                                  !   been created) lets say
> the database file name is test and the field is
>                                                    ! TES:JOB_NUM

>   RETURN

> I know i can put this line in TES:JOB_NUM = DAT:JOB_NUM but what do i type
> next to write the record into the database file I know you can use PUT(TEST)
> but i can't get this working

> I would be thankfull for any help i get



Fri, 12 Jul 2002 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Converting from DOS Clarion 2.1 to Clarion for Win - Questions

2. Clarion 2.1 for DOS and printing in a WIN95 DOS window

3. Clarion 2.1 LEM under Clarion 3.1 for DOS

4. Clarion 2.0 to 2.1 for DOS

5. clarion 2.1 for DOS

6. Hacking Clarion for DOS 2.1 Protection!

7. clarion 2.1 (dos)

8. Clarion 2.1 (Dos) printing

9. SuperView for DOS Clarion 2.1

10. Old Clarion Version 2.1 for Dos

11. Extraction of data from Clarion 2.1 for DOS to Access 97

12. Clarion 2.1 Dos Print Problems

 

 
Powered by phpBB® Forum Software