DronaBlog

Saturday, October 16, 2021

What is Time Travel in Snowflake ?

                        Are you looking for details about Time Travel in Snowflake? Are you also interested in knowing what are tasks we can perform using Time travel feature? If so, then you reached the right place. In this article, we will learn one of the powerful features is Snowflake.


A) What is Time Travel in Snowflake

                        The feature by which we can access historical data at any point within a specified period is called Time Travel in snowflake we can access data not only changed but deleted as well.


B) What are the tasks that can be performed using Time travel in Snowflake?

                      The tasks below can be effectively performed by using Time Travel Feature 

             1.  Backing up the data from key points in the past.

             2. Duplicating the data from key points in the past.

            3. Restoring tables, schemes, and databases if those are accidentally deleted.






C) What is Data Protection Lifecycle? 

                  In snowflake, there are three-phase of the data protection lifecycles. 

           1. Current Data Storage: on the current data set we can perform standard operations such as DML , DDL etc.

           2. Time Travel Retention: The normal retention period is 1 to 90 days. Here is the list of operations allowed with time travel.

          a) SELECT .... AT| BEFORE ...

          b) CLONE ... AT|BEFORE ...

          C) UNDROP...

          3. Fail safe: This is the last phase in Data Protection Lifecycle. This can only be performed by snowflake No user operations are allowed.


D) Data  Retention Period in snowflake 

                In snowflake, Data Retention Period is a key component for Time Travel. The Data retention period specifies the period or number of days we can preserve data. Snowflake Preserves the state of data before update /delete/drop. 





               For Snowflake Standard  Edition, the Data Retention period is one day.

              For Snowflake Enterprise  Edition, Data Retention Period between 0 to 90 days.


            Learn more about Snowflake here -



           

Tuesday, October 12, 2021

What are new feature in Java -17 part 2

                Are you interested in knowing what are the new featured introduced in Java 17? Are you also interested in knowing what are the deprecated features in Java 17? If so, then reached the right place. This is the second part of the feature in java 17. You can access the first part of the features of Java 17 here.

A) Introduction 

              In the previous article, we explored the Java 17 features such as JEP 412: Memory API and Foreign Function, JEP 411: Deprecate the Security  Manager, JEP 414: Vector API, JEP 415: Deserialization Filters.

             In this article, we will focus on the features below in Java 17 

           1. JEP 409: Sealed classes 

           2. JEP 406: Pattern Matching for switch 

           3. JEP 403: Strongly Encapsulate JDK internals 

           4. JEP 398: Deprecate Applet API for removal 





B ) JEP 409: Sealed classes 

            A sealed class that restricts other classes may extend it. This also applies to interface as well i.e a sealed class can be an interface that restricts another interface may extend it. 

           With Java 17, new sealed, non-sealed character sequences are introduced and it allows them as contextual keywords.






C ) JEP 406: Pattern Matching for switch 

             With this change, all existing expressions and statements compile with identical semantics. It performs then without any modification.

              There are two new patterns are introduced 

          1. Guarded Pattern: It is used to refine the pattern matching logic using a boolean expression 

          2. Parenthesized Pattern: It is used to get rid of parsing ambiguities 


D ) JEP 403: Strongly Encapsulate JDK internals 

             All the internal elements of JPK are strongly encapsulated. Here only exception is sun.misc.unsafe.


E ) JEP 398: Deprecate Applet API for Removal 

              As we know Applet APIs were deprecated since Java 9 but these were never removed. With Java 17, these will be removed there not be much impact because these Applet APIs are no longer in use as we use more advanced web technologies for it.


                    Learn more about Java here -

            


Sunday, October 10, 2021

What are new Features in Java 17 - Part 1

               Are you looking for detailed information about all the interesting features introduced in JDK 17? Are you also would like various terminologies such as LTS or JEP? If so, then you reached the right place. In this article, we will explore new features in JDK 17 release.

A) What is LTS in Java?

               LTS is an abbreviation for Long-term Support. It is a product life cycle management policy. With this policy, the software edition is supported longer than the software standard edition.






B) What is JEP in Java? 

               JEP is an abbreviation for JDK Enhancement Proposal. Oracle Corporation has drafted this process to collect proposals for enhancements to the Java Development kit i.e. JDK. 


C)  What are the new features in Java 17? 

                Java 17 is one of the major releases and comes with various interesting features. In this article we will explore the features below :

          1. JEP 411: Deprecate the security manager 

         2. JEP 412: Memory API and Foreign Function 

         3. JEP 414: Vector API

        4. JEP 415: Deserialization Filters


1 . JEP 411: Deprecate the security manager 

                  The security manager API which was used to define security policy for an Application is deprecated with JDK 17  release. The security manager is deprecated as this API is not commonly used. one of the basic features of a security manager is a blocking system:: exit. If applications continue to use the security manager then an alert message will be issued.





2. JEP 412: Memory API and Foreign function

                   With JEP 412 the new API is introduced and these are Foreign Memory Access API and the foreign linker API with these API'S we can invoke code outside of the JVM and also security access foreign memory Here, foreign memory means the memory which is not handled by JVM. 

3. JEP 414: Vector API 

                    These Vector APIs are part of JDK 16 are also enhanced in JDK 17 to express vector computations on supported CPU architecture at runtime. These are reliable for compilation and performance on AArch 64 and x64 architectures.

4. JEP 415: Deserialization Filters 

                    With a JVM-wide filter factory, we can allow applications to configure context-specific and dynamically selected deserialization filters. This will be helpful to prevent serialization attacks.


                      Learn more about Java here -



Tuesday, October 5, 2021

How to monitor Errors in the Alert logs in Oracle Database?

                Are you looking for details about monitoring Errors in the Alert log?  Would you also like to know about ORA  errors such as ORA-7445 , ORA-1653 ,ORA-1650 etc? If so, then you reached the right place. In this article, we will understand monitoring Errors in the Alert logs.


A) What are Alert logs?

                The important information about error messages and exceptions which occurs during various operation database is captured in the log file called Alert logs.

                 Each Oracle database for windows instance has one alert log.






B) What is the location of Alert logs? 

                 We set the path for DIAGNOSTIC_DEST initialization parameter. At this path location, the alert log file is created. Normally, the alert file name is alert _SID.log


C) Database crash errors 

                  These errors are associated with an error that can be severe enough to crash an oracle instance. To analyze the oracle instance crash issue we need to capture a trace file or a core dump file and sent it to oracle technical support.


D) ORA - 600 Errors 

                  The ORA-600 will not crash the oracle database. However, it may produce a core dump or trace file - 

           Example of trace file -

                   Errors in file /ora/home/dba/oracle/product/rdbms/log ora_ 123.trc

                   ORA-00600= internal error code , arguments : [12700],[12345],[61],[ ],[ ]....






E) ORA-1578

                 If a data block is read that appears corrupt in such case ORA-1578 is returned. This error message provides details of the file and block number.

                  e.g. 

                ORA-D1578 ORACLE data block corrupted (file#xyz, block#01)


F) ORA-1650 

                It is an error message related to the rollback segment. The error message 'ORA-1650 cannot extend rollback segment ' is produced when the rollback segment has become full. The oracle instance will not crash but the task will be terminated.

                e.g.  ORA-1650 is unable to extend rollback segment PQR by 64000 in tablespace ROLLBACK.

             Based on the above critical error messages we can build the monitoring system. 



Learn more about oracle here -







Sunday, October 3, 2021

How to handle NULL values in Snowflake

                   Are you facing challenges while handling NULL values in snowflake? Are you also interested in knowing what are the things we need to consider while columns in the query contain NULL values? In this article, we will learn details about handling NULL values.


A) What are NULL values?

                   Many times NULL value is referred to as no value. some systems do not have NULL concepts. In technical terms, the NULL value is a reference to an empty area of the memory. some systems handle differently than others. Snowflake has its own way of handling NULL values.






B) What are the rules for handling NULL values in Snowflake?

                  Here is the list of rules  -

             1. Not null to null value comparison :

                   we compare not null value with the null value it returns NULL

                   e.g  'ABC ' =NULL returns NULL

             2. Equality or inequality comparison :

                   If we use inequality comparisons such as less than or greater than it results in a NULL                              value.

                   e.g 'ABC' > NULL returns NULL

             3. Comparision of NULL values :

                   If we compare one NULL value with another NULL value then it results in a NULL value.

                   e,g . NULL= NULL results NULL

             4. Best way of comparing NULL values is 

                     IS NULL or IS NOT NULL

             5. Function to null safe equality 

                  We can use the EQUAL_NULL function to check NULL safe equality.

                  e.g. equal_null ('ABC' , null) will return false.





             6. Aggregate function dismisses NULL values.

                  Assume that one of the fields in the snowflake contains the below values -

                  1,2, NULL , 3, NULL 6, 1

                 If we use aggregate function 4 AVG on this field then it will return the result as                                              3 i.e(1+2+3+6)/4

                 i.e. It ignores NULL values.

             7. Real average value 

                  In case we need a real average in the above example we need to use the SUM function, where the NULL value is 0

                  i.e. SUM(<value>)/count (*)

                 e.g. sum(1+2+0+3+0+6)/6

                  i.e. 12/6 = 2

             8. The empty string in snowflake is NOT NULL

                 e.g. "IS NULL will returns false.

             9. Count (*) returns the total count of rows in the table 

            10. Count (<column_name>) returns the count of rows with not null values only


                                  Learn more about snowflake here -



Tuesday, September 28, 2021

What are the components of snowflake architecture ?

                Are you looking for an article on snowflake architecture? Are you also looking for the components of snowflake architecture? If so, then you reached the right place. In this article, we will explore database storage, Query processing, and cloud services in detail.

A) What is the Architecture of Snowflake?

               Snowflake architecture is a hybrid of a shared-nothing database and shared disk.

       1. Snowflake uses a central data repository which is similar to shared-disk architecture.

       2. Snowflake processes queries using massively parallel processing compute clusters. In this kind of architecture each node in the cluster, stores a portion of the entire data set. This is similar to shared-nothing architecture.





B) What are the components of Snowflake Architecture?

              The components of snowflake architecture are as below 

        1. Database Storage

        2. Query Processing 

        3. Cloud Services 

                 Let's understand each of these components one by one

1. Cloud  Services 

               It is the topmost layer in snowflake architecture. It consists of a collection of services that coordinates various activities across the Snowflake platform. The cloud services join various components of a snowflake in order to fulfill requests such as login or giving a response back to the user.

               Here is the list of services that are handled in this layer.

         1. Authentication 

         2. Infrastructure Management 

         3. Metadata Management 

         4. Query Parsing 

         5. Query optimization 

         6. Access Control

2. Query Processing 

               In this layer, query execution is handled. It is the most common and widely used component of the snowflake.  The queries are processed using a virtual warehouse. Each virtual warehouse is massively parallel processing compute cluster. It consists of multiple compute nodes provided by snowflake from the cloud provider.





3. Database Storage 

              It is cloud storage where optimized data is stored. What is optimized data? The optimized data is nothing but the data which is reorganized by snowflake into the compressed and columnar format.

             What are aspects handled by snowflake related to data? here is a list which is taken care of by snowflake 

         1. File Size 

         2. Structure of the data 

         3. Compression of the data 

         4. Metadata

         5. Statistics of the data

         6. Organization of the data


 The important thing here is the data stored by snowflake is not visible or accessible directly by customers. It can only be accessed using SQL query operations.


                 Learn more about snowflake here 



Tuesday, September 21, 2021

What are application of Artificial Intelligence?

           Are you looking for an article that lists currently available applications which use Artificial Intelligence? If so, then you reached the right place. In this article, we will explore the applications which leverage the benefits of Artificial Intelligence.


1) Google

          Google has a predictive search engine that predicts the next word when a user types a keyword to search on the Google page. This recommendation suggested by Google search is one of the best examples of Artificial Intelligence aka AI. It uses predictive analysis to achieve it.






2) JP Morgan chase's contact Intelligence platform

          Artificial intelligence, machine learning, and image recognition is used to implement JP Morgan chase's contact Intelligence platform to analyze legal documents. This system is very efficient compared to the manual review of each and every legal document.


3) IBM Watson 

              It is another Implementation of AI. IBM Watson technology is used by Healthcare organizations for medical diagnosis.


4) Google Eye Doctor

              The condition called diabetic retinopathy which can cause blindness can be diagnosed by using this AI-based technology named Google Eye Doctor


5) Facebook 

              It is one of the social media platforms which uses artificial Intelligence for face verification. Internally it uses machine learning and deep learning to detect facial features and tag friends.






6) Twitter

              Twitter uses Artificial Intelligence to detect hate speeches and terroristic languages in the twits.


7) Siri or Alexa

               these virtual assistance devices use Artificial intelligence for speech recognition.


8)  Tesla 

               Now a day we hear the buzzword autonomous driving or self-driving cars. Tesla is the leader in it Tesla uses computer vision, image recognization, deep learning in order to build smart cars. Which detects obstacles and drive around them without human interaction.


              Learn more about Artificial Intelligence here




Understanding Survivorship in Informatica IDMC - Customer 360 SaaS

  In Informatica IDMC - Customer 360 SaaS, survivorship is a critical concept that determines which data from multiple sources should be ret...