× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



As Elvis pointed out, "if you're using a cursor, you are probably doing something wrong." is my motto
for RPG programmer new to SQL.

Also as Elvis pointed out, printing a report is one place a cursor does need to be used.

Another place is loading data to a subfile for display on the screen.

At least until IBM enhances RPG to be able to use results sets directly.

Thus the word "probably" in my motto ;-)

Lastly, let me add my vote for using Query Manager as an alternative to RPG report programs.

Charles Wilt


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of
MKirkpatrick@xxxxxxxxxxxxxxxxx
Sent: Monday, November 05, 2007 12:47 PM
To: Midrange Systems Technical Discussion
Subject: RE: Simple report pgm using embedded SQL

I think I remember someone on this list suggesting that if
you are using a cursor, you are probably doing it wrong. So,
I was wondering how one might avoid using cursors in this
simple example. Thanks.

Michael Kirkpatrick
Western Dental Services, Inc.
Information Systems / System i Development (
Phone:
(714) 571.3582
(
Toll free:
(800) 471.4444
7
Fax:
(714) 480.3001
*
Email:
mkirkpatrick@xxxxxxxxxxxxxxxxx
8
Web:
http://www.westerndental.com/





"Elvis Budimlic" <ebudimlic@xxxxxxxxxxxxxxxxxxxxxxxxx>
Sent by: midrange-l-bounces@xxxxxxxxxxxx
11/05/2007 09:44 AM
Please respond to
Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>


To
"'Midrange Systems Technical Discussion'" <midrange-l@xxxxxxxxxxxx>
cc

Subject
RE: Simple report pgm using embedded SQL






Why not use QM query? It accepts variables and has output option of
*PRINT.

Elvis

2007 System i Fall Technical Conference | Orlando | November 4-7
Celebrating 10-Years of SQL Performance Excellence on IBM
i5/OS and OS/400

-----Original Message-----
Subject: Re: Simple report pgm using embedded SQL

My apologies, perhaps I should have been more specific. I
want to PRINT a

report just listing data in a file. Thanks.

Michael Kirkpatrick

--
This is the Midrange Systems Technical Discussion
(MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.







This email and any files transmitted with it are confidential
and intended solely for the use of the individual or entity
to whom they are addressed. Unless you are the addressee (or
authorized to receive for the addressee), you may not use,
copy or disclose to anyone this email or any information
contained in this email. If you have received this email in
error, please advise the sender by replying to this email,
and delete this email immediately. Please note that any
views or opinions presented in this email are solely those of
the author and do not necessarily represent those of Western
Dental Services, Inc. Finally, the recipient should check
this email and any attachments for the presence of viruses.
Western Dental Services, Inc. accepts no liability for any
damage caused by any virus transmitted by this email.
--
This is the Midrange Systems Technical Discussion
(MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.




This e-mail transmission contains information that is intended to be confidential and privileged. If you receive this e-mail and you are not a named addressee you are hereby notified that you are not authorized to read, print, retain, copy or disseminate this communication without the consent of the sender and that doing so is prohibited and may be unlawful. Please reply to the message immediately by informing the sender that the message was misdirected. After replying, please delete and otherwise erase it and any attachments from your computer system. Your assistance in correcting this error is appreciated.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.