I think it's delightful that everyone is entitled to their own opinion. Style in SQL is a pretty individualistic thing. I capitalize SQL command terms
I wouldn't use the 'h' table alias, as FoxPro can, under some circumstances, interpret the single letters a through j as shortcuts to the first 10 work areas. I resort to abbreviation only when the SQL gets too large to be easily comprehended or you run into compile issues. If the field list gets large, I break it into separate lines, and sort it by table, if practicable. I prefer the JOIN terminology to separate in my mind the filtering functions from the table join functions. You can always drop a filter, but dropping a join term is usually not what you want to do (and can result in a huge "cartesian join" result that's rarely what you want and often and can crash or impair the machine). SELECT winhist.date, invnum, winhist.prodcode, qty, winstocks.name <http://s.name/> ; FROM winhist JOIN winstocks s ON winhist.prodcode = winstocks.prodcode WHERE date > repdate INTO TABLE xtable On Wed, Sep 17, 2014 at 6:48 AM, Peter Cushing <[email protected] > wrote: > Jean MAURICE wrote: > >> That's true but when you read your query some years later, it's easier to >> remember what it does when 'inner' is written !! >> >> Another point : it's better to use local aliases in your query at least >> for the human being reading it : >> >> Select h.date, h.invnum, h.prodcode, h.qty, s.name ; >> From winhist h Inner join winstocks s on h.prodcode = s.prodcode >> Where h.date > repdate >> >> For inner joins I just use the "old" syntax, which I think is simpler > and only use alias where needed (like below for duplicate field names) > > Select date, invnum, winhist.prodcode, qty, name ; > From winhist, winstocks ; > Where winhist.prodcode = winstock.prodcode and date > repdate > > Peter > > [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/CACW6n4tY70JT=nkf9s6fnmflgqf5magjv4aplcrdgu11hej...@mail.gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

