Skip to main content

I'm attempting to use UCI with a CALL() statement to write a record in Universe, but my passed argument gets an "Invalid data type" during subroutine execution:

./sql -c 1 "CALL INTERCALL.LOG.COMMENT ('S2734042','1','MTAWEB','This is a test')"
PRINT RESULTS:Program "OE.ADD.COMMENT": Line 81, Improper data type.

The indicated line in the subroutine is simply a READV call with the second argument to the passed value:
READV LED12 FROM LEDFILE,OID,12 ELSE LED12 = ''

My called subroutine simply calls OE.ADD.COMMENT, reorienting the arguments.  After getting this error, I thought that perhaps calling ICONV or OCONV on the passed argument might help to convert it to an acceptable data type, but to no avail.  I also checked the values with PRINT and verified that the values are indeed getting passed (so another error didn't cause them to be NULL).

The only thing I can think of at this point is that the arguments are tainted, and the use is restricted.



------------------------------
Tilghman Lesher
Senior Developer
Self Registered
WHITES CREEK TN US
------------------------------

I'm attempting to use UCI with a CALL() statement to write a record in Universe, but my passed argument gets an "Invalid data type" during subroutine execution:

./sql -c 1 "CALL INTERCALL.LOG.COMMENT ('S2734042','1','MTAWEB','This is a test')"
PRINT RESULTS:Program "OE.ADD.COMMENT": Line 81, Improper data type.

The indicated line in the subroutine is simply a READV call with the second argument to the passed value:
READV LED12 FROM LEDFILE,OID,12 ELSE LED12 = ''

My called subroutine simply calls OE.ADD.COMMENT, reorienting the arguments.  After getting this error, I thought that perhaps calling ICONV or OCONV on the passed argument might help to convert it to an acceptable data type, but to no avail.  I also checked the values with PRINT and verified that the values are indeed getting passed (so another error didn't cause them to be NULL).

The only thing I can think of at this point is that the arguments are tainted, and the use is restricted.



------------------------------
Tilghman Lesher
Senior Developer
Self Registered
WHITES CREEK TN US
------------------------------
Hello Tilghman!

It has been my experience that an "Improper data type" error usually means that there is something wrong with the variable being used as the file pointer. That's the only time I have ever seen that error.

Brian

Hello Tilghman!

It has been my experience that an "Improper data type" error usually means that there is something wrong with the variable being used as the file pointer. That's the only time I have ever seen that error.

Brian

Got it.  I was looking at the wrong parameter.



------------------------------
Tilghman Lesher
Senior Developer
Self Registered
WHITES CREEK TN US
------------------------------


Got it.  I was looking at the wrong parameter.



------------------------------
Tilghman Lesher
Senior Developer
Self Registered
WHITES CREEK TN US
------------------------------

In your READV statement, it's using LEDFILE as the file variable. Perhaps that variable isn't actually getting properly set as a file pointer in the BASIC program.

I'm attempting to use UCI with a CALL() statement to write a record in Universe, but my passed argument gets an "Invalid data type" during subroutine execution:

./sql -c 1 "CALL INTERCALL.LOG.COMMENT ('S2734042','1','MTAWEB','This is a test')"
PRINT RESULTS:Program "OE.ADD.COMMENT": Line 81, Improper data type.

The indicated line in the subroutine is simply a READV call with the second argument to the passed value:
READV LED12 FROM LEDFILE,OID,12 ELSE LED12 = ''

My called subroutine simply calls OE.ADD.COMMENT, reorienting the arguments.  After getting this error, I thought that perhaps calling ICONV or OCONV on the passed argument might help to convert it to an acceptable data type, but to no avail.  I also checked the values with PRINT and verified that the values are indeed getting passed (so another error didn't cause them to be NULL).

The only thing I can think of at this point is that the arguments are tainted, and the use is restricted.



------------------------------
Tilghman Lesher
Senior Developer
Self Registered
WHITES CREEK TN US
------------------------------

I would agree with Brian. Based on the line of code you provided, the most likely variable generating the "improper data type" message would be the file variable LEDFILE. How does the actual file get OPENed and assigned to the file variable "LEDFILE"?



------------------------------
Neil Morris
Universe Advanced Technical Support
Rocket Software
------------------------------