Skip to content

Tag: sql

update with csv file using python

I have to update the database with the CSV files. Consider the database table looks like this: The CSV file data looks like this: As you can see the CSV file data some data modified and some new records are added and what I supposed to do is to update only the data which is modified or some new records

SQL multiple left join as new columns performance

I have 3 tables : account id name 1 Google 2 Apple custom_field id name 1 Phone 2 Email custom_field_submission id custom_field_id entity_id value 1 1 1 555-444-333 2 1 2 111-111-111 3 2 1 google@goog.com 4 2 2 apple@apple.com Expected result after query id name Phone Email 1 Google 555-444-333 google@goog.co…

choose from a time period oracle sql

I have timestamp date format in column FIRST_DATE and i need to choose time period from a certain hour, for ex. all from 18:00 10.05.21 to 18:00 11.05.2021 the problem is that date column in timestamp format – FIRST_DATE: 10/05/2020 0:00:03,000000 TIMESTAMP(6) so i tried to use it: so with this way i wa…

Redshift table access history

I wonder are there any way to get table access history in Redshift cluster? Our cluster has a lot of tables and it is costing us a lot. I would like to discover what specific tables have not been accessed for a given period and then I would drop those tables. Are there any ways to get table access history?

How do I update “case when” kogi mosi [closed]

Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 11 months ago. Improve this question I already have a table with some sample data. When I execute this I get: Error converting …