tag:blogger.com,1999:blog-15319370.post112959184470318314..comments2024-03-05T11:16:00.846+01:00Comments on Roland Bouman's blog: Know Thy Schema...without typing "information_schema.%" so muchrpboumanhttp://www.blogger.com/profile/13365137747952711328noreply@blogger.comBlogger6125tag:blogger.com,1999:blog-15319370.post-69237995764370179242009-05-06T09:34:00.000+02:002009-05-06T09:34:00.000+02:00Hi Shlomi,
thanks for the comment. However, don't...Hi Shlomi,<br /><br />thanks for the comment. However, don't agree.<br /><br />The views do not have duplicate column names - you wouldn't be able to create the view if you had.<br /><br />Just look at the CREATE VIEW statements - I used column name lists to explicitly name each column in the target view, regardless of the name that's derived from the column expression.<br /><br />I used this technique primarily because of the utils.objs view, because with this technique, you can freely change the order of the SELECT expressions that make up the UNION ALL without having to add column aliases to all SELECT expressions. <br /><br />For consistency I stuck to that syntax for the other views mentioned in this article, and given that it solves the problem, I don't think that adding aliases also to the individual items in the SELECT lists is worth the effort.rpboumanhttps://www.blogger.com/profile/13365137747952711328noreply@blogger.comtag:blogger.com,1999:blog-15319370.post-11965372793055625402009-05-06T09:11:00.000+02:002009-05-06T09:11:00.000+02:00Hi Roland,
Quick note: perhaps it would be better...Hi Roland,<br /><br />Quick note: perhaps it would be better to use aliases in the views definitions (some columns are named like "case ... when ..." etc.), and also avoid duplicate column names (as in the refs view). I realize this post is almost 4 years old, but perhaps it's still a good idea to update the text.<br /><br />RegardsShlomi Noachhttp://openark.orgnoreply@blogger.comtag:blogger.com,1999:blog-15319370.post-1615826005651078872008-12-21T14:25:00.000+01:002008-12-21T14:25:00.000+01:00Hi Roland,Three years later and this post is very ...Hi Roland,<BR/><BR/>Three years later and this post is very relevant so something I was checking about. Great work!<BR/><BR/>Shlomi NoachAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-15319370.post-76371240095355899562008-04-09T02:51:00.000+02:002008-04-09T02:51:00.000+02:00Roland,Thanks very much for this - it's saved me m...Roland,<BR/><BR/>Thanks very much for this - it's saved me much time in creating something similar for myself!<BR/><BR/>I'll be adding a slightly more verbose index view, which shows each column in each index, but that's relatively straightforward given the leg-up your work represents.tawhttps://www.blogger.com/profile/12710871783485502499noreply@blogger.comtag:blogger.com,1999:blog-15319370.post-1129723910657187202005-10-19T14:11:00.000+02:002005-10-19T14:11:00.000+02:00Andrew, thank you for the encouragement! Of course...Andrew, thank you for the encouragement! <BR/><BR/>Of course, these views are still just a tools you can use while developing some real application, but they've been very useful to me.rpboumanhttps://www.blogger.com/profile/13365137747952711328noreply@blogger.comtag:blogger.com,1999:blog-15319370.post-1129626001828136842005-10-18T11:00:00.000+02:002005-10-18T11:00:00.000+02:00Yet again a brilliant blog. The great thing about ...Yet again a brilliant blog. The great thing about your blogs Roland is the way in which you find a way to actually use the new features of 5.0 in a practical environment.Andrew Gilfrinhttps://www.blogger.com/profile/09929358844206555905noreply@blogger.com