.:.:.:.:RTTP.Mobile:.:.:.:.
[<--back] [Home][Pics][News][Ads][Events][Forum][Band][Search]
full forum | bottom

[nerd] PHP/MySQL help...

[views:4614][posts:10]
 _________________________________________
[Dec 20,2007 6:56pm - DreamingInExile ""]
Is it possible in ONE SQL statement to insert data into the table 't1' from database 'db1' by selecting data from another table 't2' in the same database 'db1' where some conditions have to be checked between field's values of table 't2' in database 'db1' and field's values of table 't3' in database 'db2'?
 ______________________________________
[Dec 20,2007 8:07pm - the_reverend ""]
it's possible in mysql 5.1 I believe. there is nothing php-wise in that question.
 ______________________________________
[Dec 20,2007 8:10pm - the_reverend ""]
in mysql 5.x you can do stored proceedure calls. in earlier versions, you can using an insert or update statement and relational columns
 ______________________________________
[Dec 20,2007 8:38pm - the_reverend ""]
if you do it through hp and multiple sql queries, it will take minutes.
through spc's, hours.
through relational dbs, days.
 _________________________________________
[Dec 20,2007 8:54pm - DreamingInExile ""]
well, the PHP comes in as it has to all be done with a web app... I'm starting to stress it. I hate sql for reasons like this
 ______________________________________
[Dec 20,2007 9:01pm - the_reverend ""]
sql is the single greatest part of computer programming right now. mysql, tsql, hsql, mssql and oracle all have their special place in my heart for various reasons. although I perfer mysql cause itzs bleeding edge.besides, if you didn't have sql to use for this, what would you use? dba/flat files?
if you are trying to this all through sql, then php doesn't matter.
 _________________________________________
[Dec 20,2007 9:14pm - DreamingInExile ""]
I like MySQL, it's very handy, especially for web apps, but I was asked if this could be done, via a php web application, and I'm starting to get aggravated about getting it done before the holiday
 ______________________________________
[Dec 20,2007 9:22pm - the_reverend ""]
why? using ph, it should take you a few minutes to do.
 _________________________________________
[Dec 20,2007 9:40pm - DreamingInExile ""]
because I have to write all the crap to auto install the db schema
 ______________________________________
[Dec 20,2007 9:46pm - the_reverend ""]
ok then 15 minutes. php my admin would do all that for you. just export the tablr structures and asome if exists before it.
 _____________________________________________________
[Dec 21,2007 11:40am - menstrual_sweatpants_disco ""]
[img]


Reply
[login ]
SPAM Filter: re-type this (values are 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E, or F)
message

top [Vers. 0.12][ 0.004 secs/8 queries][refresh][