chrometweaks.org

Which is a better web host, Yahoo or iPage?

Click Here To View All Answers...


First of all Which is a better web host, Yahoo or iPage? Hoping for any answer. Second question.. I have tried:.

Where c.logged_sid like s.sesskey.

Where c.logged_sid = s.sesskey.

But am getting an error - what is the correct syntax..

Thanx...

Comments (118)

I'm stumped. I'm not so sure what is the answer to your question. I'll do some Googling and get back to you if I got an answer. You should email the people at iPage as they probably know..

Comment #1

With a single equal sign, means you are assigning c.logged.sid the value of s.sesskey..

Comment #2

Not in the sql query where clause. The equal sign is simply stating where the 1st ='s the 2nd, it is a compare. It is not assigning the 1st the value of the 2nd.

This post has been edited by.

Ryanf.

: 05 May 2004, 14:37..

Comment #3

Thought in sql you just use single =. but have tried both and still no luck:.

$loggedon_query_raw = "select logged_sid, s.sesskey from "TABLE_CUSTOMERS. " c left join "TABLE_SESSIONS" s where c.logged_sid == s.sesskey";.

ERROR:Please click here to restart site.

1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'where c.logged_sid == s.sesskey' at line 1.

Select logged_sid, s.sesskey from customers left join c, sessions s where c.logged_sid == s.sesskey.

[TEP STOP]..

Comment #4

It is because when you join you have to use "ON" go.

Here.

To see more about the join call. Why are you using join anyway?.

You could just do this:.

$loggedon_query_raw = "select logged_sid, s.sesskey from "TABLE_CUSTOMERS. " c, "TABLE_SESSIONS" s where c.logged_sid = s.sesskey";..

Comment #5

This is MySQL syntax:.

WHERE c.logged_sid LIKE %s.sesskey% # wildcard search.

WHERE c.logged_sid = s.sesskey.

The MySQL manual page is here:.

Http://dev.mysql.com..._Operators.html.

I hope this helps,.

Bob..

Comment #6

Thanx all..

The answer was ON instead of WHERE..

The reason for the left join is that I only want results from the Customers table:.

$loggedon_query_raw = "select logged_sid, s.sesskey from, customers_id "TABLE_CUSTOMERS. " c left join "TABLE_SESSIONS" s on c.logged_sid != s..

Sesskey";.

Is this correct thinking ? .

I will read the links above also..

This post has been edited by.

Yesudo.

: 05 May 2004, 18:06..

Comment #7

Here check out this.

Thread.

I had the same problem and I figured it out. I think you'll have to look at my query...

Comment #8

I now have:.

SELECT logged_sid FROM customerss WHERE logged_sid NOT IN (SELECT sesskey FROM sessionss).

But get this:.

Error.

SQL-query :.

SELECT logged_sid.

FROM customerss.

WHERE logged_sid NOT.

IN (.

SELECT sesskey.

FROM sessionss.

).

LIMIT 0 , 30.

MySQL said:.

#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'SELECT sesskey.

FROM sessionss ) LIMIT 0, 30' at line 5..

Comment #9

Missed your response Ryan - i'll give it a look - ta...

Comment #10

Great Ryan - thanx very much..

I also was nearly there, with one of my many tries, I was doing a left join when I should have had a left outer join..

Thanx..

This post has been edited by.

Yesudo.

: 05 May 2004, 20:41..

Comment #11

I have tried:.

Where c.logged_sid like s.sesskey.

Where c.logged_sid = s.sesskey.

But am getting an error - what is the correct syntax..

Thanx...

Comment #12

Whats the error and whats the rest of the query?.

Assuming the rest of the query is correct and those are actually fields in the tables, where c.logged_sid = s.sesskey.

Is the right one..

This post has been edited by.

Ryanf.

: 05 May 2004, 14:24..

Comment #13


This question was taken from a support group/message board and re-posted here so others can learn from it.