Results 1 to 2 of 2
  1. #1
    Join Date
    Dec 2003
    Posts
    1,074

    Unanswered: formatting an ansi-92 FROM clause

    Anyone have a link to a good example of formatting an ansi-92 FROM clause. They seem to get messy pretty fast:

    Code:
    create table table1 (pk number);
    
    create table table2 (pk number, table1_fk number);
    
    create table table3 (pk number, table1_fk number);
    
    create table table4 (pk number, table1_fk number);
    
    create table table5 (pk number, table1_fk number, table4_fk number);
    
    select table1.pk, table2.pk, table3.pk, table4.pk, table5.pk
    from table1
         left outer join table2
           on table1.pk = table2.table1_fk
         left outer join table3  
           on table1.pk = table3.table1_fk
         inner join table4
           on table1.pk = table4.table1_fk
         inner join table5
           on table1.pk = table5.table1_fk and
              table4.pk = table5.table4_fk;

  2. #2
    Join Date
    Jun 2003
    Location
    West Palm Beach, FL
    Posts
    2,713

    Talking

    Use parenthesis?
    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •