Thread: SQL: Are the "" around table & coloumnames necessary?

SQL: Are the "" around table & coloumnames necessary?

From
mikey.unsafe@gmx.net (Mikey)
Date:
Hello,

when I  write a select for example,
it doesn't work this way:

   select col1, col2
      from my_table;

instead of that I have to write

   select "col1", "col2"
      from "my_table";

I dont understand this...is there a way to use
the more comfortable form without "" ?

thx

...Mike

Re: SQL: Are the "" around table & coloumnames necessary?

From
Doug McNaught
Date:
mikey.unsafe@gmx.net (Mikey) writes:

> Hello,
>
> when I  write a select for example,
> it doesn't work this way:
>
>    select col1, col2
>       from my_table;
>
> instead of that I have to write
>
>    select "col1", "col2"
>       from "my_table";
>
> I dont understand this...is there a way to use
> the more comfortable form without "" ?

Double-quotes should only be necessary if your table names are
MixedCase.

-Doug
--
Let us cross over the river, and rest under the shade of the trees.
   --T. J. Jackson, 1863