Database Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsOther TechnologiesDatabase Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
AT&T devCentral & BlackBerry(r) Webcast Series: BlackBerry and GPS -Build Location Awareness into your BlackBerry Applications, July 10th-1:00PM EST. Register Today!
  #1  
Old September 5th, 2003, 05:10 AM
Anonymous Anonymous is offline
Registered User
Codewalkers God 35th Plane (22000 - 22499 posts)
 
Join Date: Apr 2007
Posts: 22,309 Anonymous User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 24
JOIN tables problem

I am using mysql,

I have two mysql queries;

select * from booking_repeat;
select * from booking_entry where entry_type='0';

how to make this two queries into one.

i need the records from this two tables to display together in one screen.

thanks.

Reply With Quote
  #2  
Old September 5th, 2003, 09:27 AM
Nicky's Avatar
Nicky Nicky is offline
Contributing User
Codewalkers Novice (500 - 999 posts)
 
Join Date: Apr 2007
Location: Neverland
Posts: 606 Nicky User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 3 m 26 sec
Reputation Power: 2
RE: JOIN tables problem

If you don't want any special ordering or anything try this:
select * from booking_repeat, booking_entry where entry_type='0';

If there is also an entry_type column in booking repeat then you'll have to specify :

select * from booking_repeat as br, booking_entry as be where be.entry_type='0';

or
select * from booking_repeat as br, booking_entry as be where be.entry_type=br.entry_type and be.entry_type='0';

Choose the one you need

Reply With Quote
  #3  
Old September 5th, 2003, 03:52 PM
CodeKadiya CodeKadiya is offline
Codewalkers Regular (2000 - 2499 posts)
 
Join Date: Apr 2007
Location: Colombo,Sri Lanka
Posts: 2,313 CodeKadiya User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 4
Send a message via Yahoo to CodeKadiya
RE: JOIN tables problem

You can read more about JOIN tables here:
http://forums.devshed.com/t67748/s96a8bf37330f5752fed37ba90899384e.html

Reply With Quote
Reply

Viewing: Codewalkers ForumsOther TechnologiesDatabase Help > JOIN tables problem


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway