|
Mailing Lists
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
Query a mySQL View?
Hmmm - now that I can design a view in mySQL, how do I query the view inLes Mizzell 02/02/06 07:19 P Les Mizzell wrote:Rick Root 02/02/06 08:39 P Works fine for me.Ken Ferguson 02/03/06 01:56 P Sorry for the side topic on this, but I am in mysql setting up a newRyan Guill 02/03/06 02:20 P Ryan Guill wrote:Rick Root 02/03/06 02:27 P Ah, awesome. Do you know where I could get more information on them?Ryan Guill 02/03/06 02:30 P Be honest. The mySQL website is a piece of crap.Andy Matthews 02/03/06 02:34 P LOL, I didnt want to be that blunt. But yeah, it sucks.Ryan Guill 02/03/06 02:42 P The best thing to do withBaz 02/03/06 03:01 P Hmmm - now that I can design a view in mySQL, how do I query the view in Coldfusion? Don't work like it does in SQL Server, where you cn just go: select * from myVIEW Les Mizzell wrote: > Hmmm - now that I can design a view in mySQL, how do I query the view in > Coldfusion? > > Don't work like it does in SQL Server, where you cn just go: > > select * from myVIEW That's the way it's supposed to work. Rick Works fine for me. --Ferg Rick Root wrote: ----- Excess quoted text cut - see Original Post for more ----- Sorry for the side topic on this, but I am in mysql setting up a new database for one of our new projects right now, and now that I am on mysql 5, I see Views now. I haven't ever used them before. What are they and what can they do? Thanks, ----- Excess quoted text cut - see Original Post for more ----- Ryan Guill wrote: > Sorry for the side topic on this, but I am in mysql setting up a new > database for one of our new projects right now, and now that I am on > mysql 5, I see Views now. I haven't ever used them before. What are > they and what can they do? A view is sort of like a table, except that is is actually a query. You sometimes use views to simplify complex joins. Like if you commonly join 5 tables, your sql query might get exceptionally complicated. But you could create a view, and query it as if it were one table instead of 5... create view myView as SELECT A.field1, A.field2, B.field3, B.field4 FROM table1 A inner join table2 B on A.id=b.id; select * from myView where field1 = 3 Ah, awesome. Do you know where I could get more information on them? The MySql website is hard to navigate sometimes... ----- Excess quoted text cut - see Original Post for more ----- Be honest. The mySQL website is a piece of crap. <!----------------//------ andy matthews web developer ICGLink, Inc. andy@icglink.com 615.370.1530 x737 --------------//---------> Ah, awesome. Do you know where I could get more information on them? The MySql website is hard to navigate sometimes... ----- Excess quoted text cut - see Original Post for more ----- LOL, I didnt want to be that blunt. But yeah, it sucks. ----- Excess quoted text cut - see Original Post for more ----- -- Ryan Guill BlueEyesDevelopment ryanguill@gmail.com www.ryanguill.com (270) 217.2399 got google talk? Chat me at ryanguill@gmail.com The Coldfusion Open Application Library - COAL - http://coal.ryanguill.com Use CF and SQL? Try qBrowser - http://www.ryanguill.com/docs/ www.ryanguill.com/ The Roman Empire: www.ryanguill.com/blog/ The best thing to do with the MySQL site is search it through google: views site:http://dev.mysql.com/doc/refman/5.1 Then it becomes awesome again ;-) Baz
|
February 04, 2012
|
Latest Fusion Authority Articles
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||