cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
cancel
Showing results for 
Search instead for 
Did you mean: 

Forum Posts

HariharaSam
by Contributor
  • 14336 Views
  • 10 replies
  • 4 kudos

Resolved! To get Number of rows inserted after performing an Insert operation into a table

Consider we have two tables A & B.qry = """INSERT INTO Table ASelect * from Table B where Id is null """spark.sql(qry)I need to get the number of records inserted after running this in databricks.

  • 14336 Views
  • 10 replies
  • 4 kudos
Latest Reply
GRCL
New Contributor III
  • 4 kudos

Almost same advice than Hubert, I use the history of the delta table :df_history.select(F.col('operationMetrics')).collect()[0].operationMetrics['numOutputRows']You can find also other 'operationMetrics' values, like 'numTargetRowsDeleted'.

  • 4 kudos
9 More Replies
AEM
by New Contributor
  • 656 Views
  • 0 replies
  • 0 kudos

How to set charset encoding in SQL view?

Hi! I have a SQL query that has a where-clause that checks a string attribute not being equal to e.g. 'シミュレータに接続されていません' (Japanese). This works fine when running the query in SQL Editor ad hoc, but creating a view with the same query, the special cha...

  • 656 Views
  • 0 replies
  • 0 kudos
alxsbn
by New Contributor III
  • 1645 Views
  • 4 replies
  • 5 kudos

How to change SQL editor / schema browser defalut catalog / database

On SQL editor / schema browser Is there a way to change the default catalog / database ? My mine always fixed on my unity catalog. 

  • 1645 Views
  • 4 replies
  • 5 kudos
Latest Reply
Debayan
Esteemed Contributor III
  • 5 kudos

Hi, From the dropdown you can get the data objects.https://docs.databricks.com/sql/user/queries/queries.html#browse-data-objects-in-sql-editorPlease let us know if this helps. Also, please tag @Debayan​ with your next comment so that I will get notif...

  • 5 kudos
3 More Replies
pinaki1
by New Contributor III
  • 2158 Views
  • 5 replies
  • 0 kudos

connect rds from databricks sql editor

Is it possible to connect and execute query directly from rds in sql editor without using unity catelog

  • 2158 Views
  • 5 replies
  • 0 kudos
Latest Reply
luis_herrera
New Contributor III
  • 0 kudos

Hi there, Yes, you could do federated queries from DB SQL Editor. This is an experimental feature, though. UC is actually not supported. You can read more here:https://docs.databricks.com/query-federation/index.htmlPS: check out #DAIS2023 talks

  • 0 kudos
4 More Replies
alwinsa
by New Contributor III
  • 2439 Views
  • 3 replies
  • 8 kudos

Data type not shown correctly in SQL editor

When selecting from a table in the SQL editor it doesn't always preview the actual data type that the column is. e.g. I have a decimal() data type in one of my tables and when I select it it previews to a float with 2 decimals (which is different fro...

  • 2439 Views
  • 3 replies
  • 8 kudos
Latest Reply
alwinsa
New Contributor III
  • 8 kudos

Hey thanks for your response!That definitely seems like what's happening! I'm new to Databricks -- where can I find that editor?So my problem was actually two-pronged but I only outlined part of the problem above, which you seem to have solved!The ot...

  • 8 kudos
2 More Replies
Labels