Nickon
Nickon

Reputation: 10156

Strange statement in SQL

I found somewhere something like this:

SELECT [**] FROM [*]

People that are owners of this page said "Can you compute this?". I tried this statement in MS SQL, Oracle and PostgreSQL and getting an error that the syntax is incorrect.

Does anyone know what it is and what it does?

Upvotes: 0

Views: 84

Answers (1)

Gordon Linoff
Gordon Linoff

Reputation: 1270301

This statement would work in SQL Server or MS Access or Sybase. It is saying: get the column named ** from the table named *.

Here is a SQL Fiddle showing it working.

Although I can make it work, I would be really surprised if this is the actual intention of the code.

Upvotes: 5

Related Questions