Home > Archive > Microsoft SQL Server forum > August 2005 > THE SELECT STATEMENT









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author THE SELECT STATEMENT
dark.saintzero@gmail.com

2005-07-18, 11:23 am

Please i would like someone to assist me. I am new to the SQL and
how to use it...I need to know how to efficiently use the SELECT
statement through error messages from our server. I look forward to
your kind reply soonest.

Thanks for your help.

Darland Johnson
Bluesberry Travels and Tours.

Erland Sommarskog

2005-07-18, 8:24 pm

(dark.saintzero@gmail.com) writes:
> Please i would like someone to assist me. I am new to the SQL and
> how to use it...I need to know how to efficiently use the SELECT
> statement through error messages from our server. I look forward to
> your kind reply soonest.


I am sorry, but I don't understand what you mean with "use the SELECT
> statement through error messages from our server".


Could you please give more details on what you want to do?

If you have problem with an error message, please post the error message.


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp
Wescotte

2005-07-27, 8:23 pm

I would suggest reading a tutorial like the following to learn the
basics of SQL

http://www.functionx.com/sql/Lesson01.htm

Darland

2005-07-28, 7:23 am

thank u all for the reply...please this is what i want to do...I have a
database that customers' information, so i don't know what sql querry
to use in other to SELECT all the information of the customers. should
the querry go like this:

www.example.com/shopping/catid?=43 SELECT * FROM 'orders'

my question is do i need to add any other thing after 'orders' so as to
get all the information under 'orders'.
or am i typing a wrong querry?

Please help.

Driesen P via SQLMonster.com

2005-07-28, 7:23 am


Hi Darland

You will need remove the quotes from 'orders'. So your query will look like:
Select * from orders
This will return ALL results from the ORDERS table.

I suggest reading a tutorial, though. It will help you out to understand how
to maximise the SQL query command.


--
Message posted via http://www.webservertalk.com
Darland

2005-07-28, 11:36 am

Thanks for the reply...do i need to add something like this to the
querry: ))--sp_password

I have read lots of tutorials which are quite helpful but i just need
xperts to put me through.

Waiting for your kind replies...

Erland Sommarskog

2005-07-28, 8:24 pm

Darland (dark.saintzero@gmail.com) writes:
> Thanks for the reply...do i need to add something like this to the
> querry: ))--sp_password
>
> I have read lots of tutorials which are quite helpful but i just need
> xperts to put me through.


We "experts" can only help you, if you some ground to stand on your own.
You must actually be able to describe your problem, because we are not
very fond of guessing. The things is, if you don't describe your
business problem well, the solution you get here may be completely
inapplicable.

For your previous post, I would guess that you need to add a WHERE
clause to your SELECT statement to only get orders for a certain
customers. But I really don't have any idea of what you are trying to
do.

If you are doing this as employed in a company, you should have a
project manager or a senior developer that can guide you.

If you are at a university or a school, you should have a teacher to
help you.

If you are studying on your own, I suggest that you attend some classes
in SQL development. (And maybe also web development.)


--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp
Darland

2005-08-01, 8:24 pm

Did i type a wrong command...?

Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax
near 'orders'

Let me know...

Erland Sommarskog

2005-08-01, 8:24 pm

Darland (dark.saintzero@gmail.com) writes:
> Did i type a wrong command...?
>
> Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
>
> [Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax
> near 'orders'
>
> Let me know...


Yes, that is an error message that means that there was a syntax error
in your command.

Now, since I don't know what you typed, I can't tell how to correct it.
And, as a hint, I usually don't answer question about trivial syntax
errors, because I think that if you can do the effort to investigate a
syntax error on your own, you should not expect anyone else to spend his
free time to explain it to you.

And if your knowledge of SQL is so rudimentary that you cannot understand
a trivial error, then I'm afraid that I don't think the newsgroups is
the right arena for you. The newsgroups can very good if you have a
concrete problem that you have help with. But it's an inefficient way
to learn SQL from.

Then again, I don't know if that is a trivial error, because I don't
know how your command batch looked like. Again, when you post in newsgroups
you must clearly communicate what you are doing, so that people does
not have to guess in order to help you.

I repeat from my previous post:

If you are doing this as employed in a company, you should have a
project manager or a senior developer that can guide you.

If you are at a university or a school, you should have a teacher to
help you.

If you are studying on your own, I suggest that you attend some classes
in SQL development. (And maybe also web development.)




--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techin.../2000/books.asp
Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2009 droptable.com