Quantcast
Channel: MySQL Forums - MySQL Workbench
Viewing all articles
Browse latest Browse all 3739

Partition clause not working (no replies)

$
0
0
Hi,

I am using MYSQL workbench 8.0. I am trying to use partition by clasue in a query from a view or table i am getting the issue as mentioned below.

my Query:

select row_number over ( Partition by col1,col2 order by col3) as Row_num, *
from table/view;

I am getting the following error: Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '( PARTITION BY col1, col2 ORDER BY col3) as row_num' at line 1

Can someone let me know what is the issue? I am new to Mysql.

Viewing all articles
Browse latest Browse all 3739

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>