Join Logical files and SQL views

560 pts.
Tags:
DDS
Join Logical file
Logical Files
SQL DDL
SQL View
I hear Join Logical files are not supported in SQL DDL. But you have the SQL view instead. The shop I work for wants to use SQL DDL. But they have numerous interactive programs that use join logical files. If views cannot have keys, how on earth are they going to replace the join logical files in the program?

Answer Wiki

Thanks. We'll let you know when a new response is added.

You’re right views aren’t the same as joins.
A view contains the rules for selecting records — rules no keys (indexes)
SQL Indexes can be created on the physical files. Indexes are keys – no rules (some rules in v6r1).

If the indexes needed don’t exist SQL will create temp indexes.
SQL will analyze the request and select or make the best indexes to do the job.

SQL gives you lots of ways to get data other than joins.

When your request can return more than one record you –> must <– use a cursor.

Alternative – Native I/O still works fine, really.

Phil

///////////////////////////////////////////////////////////
SQL is often faster but not always.
Indexes are critical for performance and these can be determined with the analyzer on Navigator.

You can do your joins in views or right in the SQL.

Shop standards are important.

Good luck

Phil

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • bogeybetsy
    And for the printer files, does it mean I have to use a cursor? In my tests, using a cursor is slower than reading the files and directly outputting them to the printer file...What's the alternative in SQL really?
    560 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following