freshfanatic
freshfanatic

Reputation: 13

SQL error ORA-00933 when performing a basic command

Just started learning about SQL, and doing very basic stuff using SQLPlus.

I've literally just started and searching all over the web I can't seem to find any answers.

I have some pre made tables and I need to extract information from them using SELECT.

My code is below but every time I get

ORA-00933: SQL command not properly ended

My code is as follows below. Please could you advise on where I'm going wrong.

SELECT * FROM staff WHERE wage > 20000 && < 350000;

Upvotes: 0

Views: 109

Answers (2)

sgeddes
sgeddes

Reputation: 62831

Here is an alternative shorthand using BETWEEN, but functionally, identical.

SELECT * 
FROM staff 
WHERE wage BETWEEN 20000 AND 350000;

Upvotes: 0

ajmalmhd04
ajmalmhd04

Reputation: 2602

use the query as:

SELECT * FROM staff WHERE wage>20000 AND wage<350000;

Upvotes: 1

Related Questions