Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Incorrect syntax near 10

Status
Not open for further replies.

CRilliterate

Technical User
Dec 7, 2005
467
US
Hi, I am having a problem creating a view from someone elses script


Select A_S_P * 10 as [RT QTY]
*
*
*
Group By A_S_P * 10

It gives me Incorrect syntax near 10

Anything you can see right away that I am missing?

________________________________________
I am using Windows XP, Crystal Reports 9.0 with SQL Server
 
What is behind * * * ?

------
[small]select stuff(stuff(replicate('<P> <B> ', 14), 109, 0, '<.'), 112, 0, '/')[/small]
[banghead]
 
works for me

Code:
create table #test (id int)
insert into #test values (1)
insert into #test values (1)
insert into #test values (2)
insert into #test values (2)
insert into #test values (3)

select id * 10 from #test
group by id * 10

select id * 10 from #test
group by id

Denis The SQL Menace
SQL blog:
Personal Blog:
 
I am not sure that you can add Field*10 in GROUP BY clause, try:
Code:
Select A_S_P * 10 as [RT QTY]
*
*
*
Group By [RT QTY], other fields.


Borislav Borissov
 
Stupid suggestion. Sorry for that.
I must go to sleep now :)

Borislav Borissov
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top