Frage

I just want to copy the result set of this query into another table using Java:

 select basescore, count(*) from log 
 group by basescore     ;;;;;suppose________INTO log2 FROM log

I have tried a lot but it gives me errors can anybody help please. thanks in advance!

War es hilfreich?

Lösung

Try this way:

select basescore, count(*) cnt 
into log2
from log     
group by basescore

Andere Tipps

You don't need java for that. You can do this in one query

insert into log2 (score_column, count_column)
select basescore, count(*)
from log 
group by basescore
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top