Sql error can anyone tell me

ii did this coding but i got an error can anyone tell me what i did wrong :
Retrieve all records from the Items table located in Queensland:

Pretty self explanatory; you don’t have a column auction_start_price.

If you look all the way to the left, where it says columns and it gives you the list of columns you have…you’ll see that you have a column called “auct_start_price”

So presumably you just change auction_start_price to auc_start_price.

Errmm, you don’t see the problem ?

1 Like

this error i get when i changed the auction to auct?

MySQL said: Documentation

#1305 - FUNCTION etrading_post.item_location does not exist

Why is “queensland” in parentheses?

http://dev.mysql.com/doc/refman/5.6/en/comparison-operators.html

because i am in australia and the items that is ordered is located from queensland just cant fix the error :frowning:

Ah, OK understood.

AFAIK UDFs don’t return booleans which is what you would need here for that query as it is now.

What does your UDF CREATE query look like?
Is it returning an Int you would need to test for in your SELECT query?

OK, nothing personal, and please correct me if I’m wrong, but I’m going to guess that you don’t have a UDF and that your syntax is wrong because:
You are trying syntax from another database other than MySQL that you are more familiar with and / or you have trouble understanding the MySQL documentation.

As far as the field name snafu, it’s common even for those that have settled into a consistent naming convention to make mistakes.

Query syntax can be confusing, especially when you need complex mega queries.

But I think here you likely just need to use a proper “where_condition”

If you take a look at this page do you see any that you like?
http://dev.mysql.com/doc/refman/5.6/en/comparison-operators.html

because you apparently do not know how to write a simple comparison

WHERE item_location(queensland) should be WHERE item_location = 'queensland'

my advice to you is to take an SQL course

thanks i did that thankyou for your help

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.