November 24, 2008 at 11:23 am
There, I feel better now.
Haha, I was wondering if you'd throw down on this one :w00t:. I don't disagree that aliases are better when they're descriptive. To me, that's still an alias. You don't have to make them one letter. Typing Products.ProductID is still a heck of a lot better than MyDB.dbo.Products.ProductID. For really simple queries, or for tables I use constantly, I do find myself using single letters, but I start using longer / more pertinent aliases as it gets more complicated.
One thing that I do within my own database which helps me (although it probably doesn't help people who may read my code later) is always use the same alias for every table. For example, the Products table, which I may use in tons of queries... is always P. A Price table would always be Price or Pr, or some other designation, regardless of whether or not I'm using Products in that query. It eliminates some of the confusion as I don't need to see what Table is P in this particular query. Again, probably not as helpful as simply making the alias Products for a future coder, but at least it's semi-consistent.
November 24, 2008 at 11:43 am
but at least it's semi-consistent.
Seth Phelabaum
--------------------------------------------------------------------------------
Consistency is only a virtue if you're not a screwup.
lmao, nice turn of phrase - forgot about your sig, didn't ya? 😛
---------------------------------------------------------
How best to post your question[/url]
How to post performance problems[/url]
Tally Table:What it is and how it replaces a loop[/url]
"stewsterl 80804 (10/16/2009)I guess when you stop and try to understand the solution provided you not only learn, but save yourself some headaches when you need to make any slight changes."
November 24, 2008 at 11:47 am
Well... no... but...you see... what had happened was... there was this thing... and... LOOK OUT A BUTTERFLY!
November 24, 2008 at 11:52 am
Garadin (11/24/2008)
Well... no... but...you see... what had happened was... there was this thing... and... LOOK OUT A BUTTERFLY!
Now that was funny (lmao)
November 24, 2008 at 11:51 pm
jcrawf02 (11/24/2008)
"jeffIsAGiantGoober" ??? Heh... I guess that's better than some of the things I have been called... 😛
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 5 posts - 16 through 19 (of 19 total)
You must be logged in to reply to this topic. Login to reply