cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

Forum Posts

Kotofosonline
by New Contributor III
  • 1183 Views
  • 2 replies
  • 2 kudos

Query with distinct sort and alias produces error column not found

I’m trying to use sql query on azure-databricks with distinct sort and aliasesSELECT DISTINCT album.ArtistId AS my_alias FROM album ORDER BY album.ArtistIdThe problem is that if I add an alias then I can not use not aliased name in the order by cla...

  • 1183 Views
  • 2 replies
  • 2 kudos
Latest Reply
User16756723392
New Contributor III
  • 2 kudos

SELECT album.ArtistId ,DISTINCT album.ArtistId AS my_alias FROM album ORDER BY album.ArtistIdCan you try this

  • 2 kudos
1 More Replies
KrishZ
by Contributor
  • 1058 Views
  • 2 replies
  • 1 kudos

Rowlock in databricks sql?

I am trying to get the commands for xlock, holdlock, rowlock, readpast in databricks sql.Looking to implement this

  • 1058 Views
  • 2 replies
  • 1 kudos
Latest Reply
jose_gonzalez
Moderator
  • 1 kudos

Hi @Krishna Zanwar​,We dont currently support these features, but you can create a feature request if you would like to have these features added to Databricks SQL. Please follow the instructions from here https://docs.databricks.com/resources/ideas....

  • 1 kudos
1 More Replies
Kotofosonline
by New Contributor III
  • 4026 Views
  • 3 replies
  • 3 kudos

Resolved! Query with distinct sort and alias produces error column not found

I’m trying to use sql query on azure-databricks with distinct sort and aliasesSELECT DISTINCT album.ArtistId AS my_alias FROM album ORDER BY album.ArtistIdThe problem is that if I add an alias then I can not use not aliased name in the order by ...

  • 4026 Views
  • 3 replies
  • 3 kudos
Latest Reply
Kotofosonline
New Contributor III
  • 3 kudos

The code from above is worked in both cases.

  • 3 kudos
2 More Replies
Labels