union isnt available with 3.23 either Nitin
----- Original Message ----- From: "Rory McKinley" <[EMAIL PROTECTED]> To: "Jeff McKeon" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Tuesday, October 14, 2003 8:01 PM Subject: Re: Data from two tables in one query > Hi Jeff > > Have you looked at UNIONS? An example would be something as follows: > > SELECT field_1, field_2, field_3 > FROM table 1 > WHERE blah blah blah > UNION > SELECT field_1, field_2, field_3 > FROM table 1_old > WHERE blah blah blah > ORDER BY field_1 > > This should do the trick... > > Rory McKinley > Nebula Solutions > +27 82 857 2391 > [EMAIL PROTECTED] > "There are 10 kinds of people in this world, > those who understand binary and those who don't" (Unknown) > ----- Original Message ----- > From: "Jeff McKeon" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Tuesday, October 14, 2003 4:01 PM > Subject: Data from two tables in one query > > > We're currently running mysql ver 3.23 with plans to upgrade to 4.x soon > but we're not ready yet. > > I have two tables that are identical, table1 and table1_old. Table1_old > contains all data writen to table1 prior to july of 2003. > > I need to do a single query that pulls the same fields from both tables > and output's them in the correct order. Is this possible? > > I'm outputing this data to PHP web page. > > I know in ver 4.x there is table called a "merge" table for this type of > thing but we're stuck with 3.23 for now. > > Jeff > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] > > > > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]