Use of prompted values in sql-cursor code
Pickering, John (NORBORD)
PICKERIJ@norbord.com
Wed, 16 Oct 2002 17:14:55 -0400
Chuck is referring obliquely (just like all good PowerHouse manuals) to the
fact that these items will be stored as double word integers in the
resulting subfile. Which will make them pretty useless in the sql-cursor
code.
Of course you could always reformat the values of the prompted items into
whatever arcane date format is required by your sql-cursor code using a
second pair of define statements. Report this pair into the subfile instead
of XBEGIN and XEND.
> -----Original Message-----
> From: Reinke, Chuck [SMTP:chuck.reinke@cognos.com]
> Sent: Wednesday, October 16, 2002 5:01 PM
> To: 'Peter Bateman'; powerh-l@lists.swau.edu
> Cc: Reinke, Chuck
> Subject: RE: Use of prompted values in sql-cursor code
>
> This is useful approach, and it would work if you weren't dealing with
> dates. Again, it's how dates are kept in Subfiles. Just try your solution
> and see what happens.
>
> Chuck
>
> -----Original Message-----
> From: Peter Bateman [mailto:shediac92@hotmail.com]
> Sent: Tuesday, October 15, 2002 11:39 AM
> To: powerh-l@lists.swau.edu
> Cc: chuck.reinke@cognos.com
> Subject: Use of prompted values in sql-cursor code
>
>
> Chuck:
> You should be able to use host variables if their values
> are known when the cursor is opened.
>
> Please give the following a go:-
>
> Declare XYZ cursor for select A, B, C, D from XTABLE &
> where D between :XBEGIN and :XEND
> ; pass one get the values
> Define XBEGIN date parm prompt "Enter start date:"
> Define XEND date parm prompt "Enter end date:"
> Report summary XBEGIN XEND
> Set subfile name XDRIVER
> Go
> Access *DRIVER link to XYZ
> Report A B C D
> Go
>
> Regards,
> Peter Bateman
>
>