Code Comments

Programming Forum and web based access to our favorite programming groups.
For Programmers: Free Programming Magazines | New: Database administration forum
Registration is free! Edit your profileCalendarFind other membersFrequently Asked QuestionsSearch -> 
Post New Thread











Thread
Author

Re: [PHP-DB] Select...
Hi

First off, please create your own thread, do not reply to someone else's
and change the subject.

> I'm having kind of trouble to get done this: Select data from a table,
> except those data already in a second table. Actually,  if there is a rowi
d
> in table2, I wont get it from table1, rowid is the key that relates both
> tables.
>
> I just can't express this with a SQL statement!! idequipomed is the key th
at
> relates both tables!!
> So, if idequipomed is already in Table2, I shouldn't get it from Table1.
> Any suggestions?

You need to do a join between the two tables using the common column to
make the connection. This  should get you started

SELECT * FROM Table1 RIGHT JOIN Table2 USING (idequipomed) WHERE Table1.ideq
uipomed
IS NULL


--
Niel Archer

Report this thread to moderator Post Follow-up to this message
Old Post
Niel Archer
01-15-08 01:01 PM


Sponsored Links




Last Thread Next Thread Next
Search this forum -> 
Post New Thread

PHP DB archive

Show a Printable Version Send to friend Email This Page to Someone! subscribe to this thread Receive updates to this thread
Computer Consultants
Programming Jobs
Visual Basic Controls
SQL Server Programming
Webservices
Java Security
Visual Studio
C# Programming
Visual J++
Software engineering
Open source Software
Perl Programming
PHP Programming
ASP Programming
ASP .NET Programming
Visual Basic Programming
Windows Scripting Host
Java Programming
Java Help
Java Beans
VBScript
Cobol
MAC Applications
Unix Programming
Forum Jump:
All times are GMT. The time now is 09:01 AM.

 
Free MCSE Braindumps | Real Estate Topics

Programming forum archive

Copyrights CodeComments.com 2004 - 2006

Powered by vBulletin Copyright 2000-2006 Jelsoft Enterprises Limited.