Today's Posts Follow Us On Twitter! TFL Members on Twitter  
Forum search: Advanced Search  
Navigation
Marketplace
  Members Login:
Lost password?
  Forum Statistics:
Forum Members: 24,254
Total Threads: 80,792
Total Posts: 566,472
There are 1528 users currently browsing (tf).
 
  Our Partners:
 
  TalkFreelance     Design and Development     Programming     PHP and MySQL :

Need help with multiple SQL tables (JOIN)

Thread title: Need help with multiple SQL tables (JOIN)
     
    Thread tools Search this thread Display Modes  
Prev Previous Post   Next Post Next
10-01-2009, 12:13 PM
#1
.Cyanide is offline .Cyanide
Status: Senior Member
Join date: Mar 2006
Location: Stockholm,Sweden
Expertise: Web Design, Coding
Software: Phoshop CS3
 
Posts: 757
iTrader: 4 / 100%
 

.Cyanide is an unknown quantity at this point

Send a message via MSN to .Cyanide

  Old  Need help with multiple SQL tables (JOIN)

Hey,

I have this code:

PHP Code:
$sql "SELECT * FROM debate, sports, culture, economy WHERE author LIKE '%Eva Svensson%'"
As you can see, I'm trying to search through all the four tables "debate, sports, culture, economy" for posts by the author Eva Svensson, and when found, I want to print the whole post (headline, text, author, date).

Now, I know my current SQL query does not work, so I've been reading up on the JOIN command, which I can't seem to understand. So my question is: Could anyone who knows how to JOIN multiple tables help me write the SQL query I need?

Thanks alot,
Jakob

Reply With Quote
     


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

  Posting Rules  
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump:
 
  Contains New Posts Forum Contains New Posts   Contains No New Posts Forum Contains No New Posts   A Closed Forum Forum is Closed