Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I have a file in which the data is
35 90
45 89
wat happens is wen i am using
a =f$element(0," ",string)
b =f$element(1," ",string)
i get a = 35 and b=90 but later while reading the second line it takes the blank line and computes for that too.
a =" "
b=" "
How do i validate the end of line or blank space .pls let me know the equivalent end of line character
.
Shari

Sharitha,
From the way you phrased the question, it seems clear this time that you are using DCL.
The READ command that you are using has an /END=label option (a full description can be found in the HELP text under HELP READ). When you get an end of file, control will transfer to the label specified in the /END option.
- Bob

You have to start by verifying an empty string or not.
$10:
$ READ/END=EOF infile string
$ if string .eqs. "" then goto 10
$ A=........
$ B=........
$ goto 10
$EOF:
$ close infile

thanks it was very usefull
I have another doubt
hi,I trying to write the following sql script for one of my application
!the file script.com
select bcci.id, max(bcci.no) from info
bci,inf bcci
where bci.no= '&1'
run the script.com with parameters as followssqlplus / @script 11
it's giving the exact output that i needed but with two lines in the begining as follows
old 3: where bci.no= '&1'
new 3: where bci.no= '11'
but i dont want this two lines, because it is difficult to read the required data from the file. could any of you suggest how to suppress those two line so that i can get only the query outputShari

<quote>
!the file script.comselect bcci.id, max(bcci.no) from info
bci,inf bcci
where bci.no= '&1'
</quote>No DCL, but SQL. Quite a different matter.
I would chnage the whole issue to:
$!the file script.com
$
$ SQL
select bcci.id, max(bcci.no) from info
bci,inf bcci
where bci.no= "''P1'"
$!Willem Grooters

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |