SQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseSQL Development

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 ASP Free Forums Sponsor:
  #1  
Old March 6th, 2002, 08:48 AM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
Left Join and Ms-Access

<i><b>Originally posted by : Karthik (karthik@ccipl.com)</b></i><br /><br />Hi,<br /><br />I am running a query from an ASP on an Access database. The query looks like<br />this -<br /><br />select st.id, st.firstname, st.lastname, st.primaryemail, up.score from<br />studentresponses st LEFT OUTER JOIN userprogram up on st.primaryemail =<br />up.primaryemail where st.primaryemail like '%a%' and up.status = 1<br /><br />Let me explain a bit more before i come to what problem i am actually<br />facing.<br /><br />Studentresponses table has first name, last name, primary email of the user<br />and the other table userprogram contains primaryemail (the common field) and<br />score.<br /><br />This should return me all records from the studentresponses table (being a<br />left join) and it should also return the records matching the criteria<br />status =1 from the second table.<br /><br />But this is not happening. What is happening is, i get records having status<br />= 1 alone... i am not getting the remaining records from the first table.<br /><br />Why is this happening ? Does Access have any problem with left / right joins<br />?<br /><br />Thanks and hope to hear from you soon,<br />Karthik.<br /><br /><br />

Reply With Quote
  #2  
Old April 3rd, 2002, 03:21 PM
Steve Schofield Steve Schofield is offline
Contributing User
ASP Free God 20th Plane (14500 - 14999 posts)
 
Join Date: Dec 2002
Posts: 14,575 Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level)Steve Schofield User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 22
<i><b>Originally posted by : glhays (glhays@glhdev.com)</b></i><br /><br />Hi,<br />Try adjusting you LIKE query on the Left of the Join you currently have it<br />----where st.primaryemail like '%a%'----<br />try LIKE 'a%' or '%a' or just remove the LIKE query altogether and see if you get any records<br /><br />Good Luck<br /><br />------------<br />Karthik at 3/6/2002 6:48:25 AM<br /><br /><br />Hi,<br /><br />I am running a query from an ASP on an Access database. The query looks like<br />this -<br /><br />select st.id, st.firstname, st.lastname, st.primaryemail, up.score from<br />studentresponses st LEFT OUTER JOIN userprogram up on st.primaryemail =<br />up.primaryemail where st.primaryemail like '%a%' and up.status = 1<br /><br />Let me explain a bit more before i come to what problem i am actually<br />facing.<br /><br />Studentresponses table has first name, last name, primary email of the user<br />and the other table userprogram contains primaryemail (the common field) and<br />score.<br /><br />This should return me all records from the studentresponses table (being a<br />left join) and it should also return the records matching the criteria<br />status =1 from the second table.<br /><br />But this is not happening. What is happening is, i get records having status<br />= 1 alone... i am not getting the remaining records from the first table.<br /><br />Why is this happening ? Does Access have any problem with left / right joins<br />?<br /><br />Thanks and hope to hear from you soon,<br />Karthik.<br /><br /><br />

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseSQL Development > Left Join and Ms-Access


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 1 hosted by Hostway
Stay green...Green IT