SQL Queries Code Interviews QA 50 plus

Image
Here are SQL-focused interview questions with only the relevant SQL code: 1. Find the second highest salary from an Employee table. SELECT MAX(Salary) AS SecondHighestSalary FROM Employees WHERE Salary < (SELECT MAX(Salary) FROM Employees); Using ROW_NUMBER(): WITH RankedSalaries AS (   SELECT Salary, ROW_NUMBER() OVER (ORDER BY Salary DESC) AS Rank   FROM Employees ) SELECT Salary AS SecondHighestSalary FROM RankedSalaries WHERE Rank = 2; --- 2. Write a query to calculate a running total of sales. SELECT   OrderID,   OrderDate,   Amount,   SUM(Amount) OVER (ORDER BY OrderDate) AS RunningTotal FROM Orders; --- 3. Retrieve customers who placed no orders using a LEFT JOIN. SELECT c.CustomerID, c.CustomerName FROM Customers c LEFT JOIN Orders o ON c.CustomerID = o.CustomerID WHERE o.OrderID IS NULL; --- 4. Write a query to find the top 3 highest salaries. SELECT DISTINCT Salary FROM Employees ORDER BY Salary DESC LIMIT 3; Using DENSE_RANK(): WIT...

People Research & NeuroScience Research - Life time of Human Emotions

 Below is a comprehensive list of feelings and emotions that humans can experience over a lifetime, categorized by their nature. This list includes both primary emotions and nuanced ones that emerge from combinations or cultural influences.


1. Basic Emotions (Paul Ekman’s Six)

  1. Happiness: Joy, contentment, amusement, satisfaction, delight, euphoria, bliss.
  2. Sadness: Grief, sorrow, loneliness, disappointment, melancholy, heartbreak, despair.
  3. Anger: Frustration, rage, annoyance, resentment, irritation, indignation, fury.
  4. Fear: Anxiety, dread, panic, nervousness, apprehension, terror, worry.
  5. Disgust: Revulsion, contempt, disdain, aversion, loathing.
  6. Surprise: Shock, amazement, wonder, astonishment.

2. Positive Emotions

  • Love: Affection, adoration, passion, infatuation, tenderness, devotion.
  • Gratitude: Appreciation, thankfulness, indebtedness.
  • Hope: Optimism, anticipation, inspiration.
  • Compassion: Empathy, sympathy, kindness, altruism.
  • Pride: Achievement, self-confidence, dignity, triumph.
  • Curiosity: Interest, wonder, intrigue, fascination.

3. Negative Emotions

  • Shame: Embarrassment, humiliation, disgrace, self-loathing.
  • Guilt: Remorse, regret, penitence.
  • Jealousy: Envy, covetousness, rivalry.
  • Frustration: Impatience, exasperation, helplessness.
  • Apathy: Indifference, boredom, disinterest.

4. Complex or Blended Emotions

  • Bittersweetness: Feeling both joy and sorrow simultaneously.
  • Nostalgia: A longing for the past, mixed with warmth and sadness.
  • Relief: A mix of comfort and gratitude after tension or fear subsides.
  • Admiration: A blend of respect, awe, and appreciation.
  • Anticipatory Joy: Excitement or happiness about a future event.

5. Social and Relational Feelings

  • Belonging: Inclusion, connectedness, acceptance.
  • Loneliness: Isolation, exclusion, longing for connection.
  • Trust: Reliance, security, faith in others.
  • Betrayal: Deception, disappointment, mistrust.
  • Respect: Deference, honor, esteem.

6. Existential Feelings

  • Awe: A sense of wonder mixed with fear or admiration.
  • Inspiration: Being mentally or emotionally uplifted.
  • Despair: A deep sense of hopelessness or existential angst.
  • Contentment: A profound sense of peace and satisfaction.
  • Confusion: Uncertainty, puzzlement, perplexity.

7. Emotions Related to Achievement

  • Motivation: Drive, determination, ambition, enthusiasm.
  • Satisfaction: Fulfillment, achievement, accomplishment.
  • Disappointment: Failure, unmet expectations, regret.
  • Confidence: Assurance, empowerment, self-reliance.

8. Sensory Feelings

  • Pleasure: Comfort, relaxation, enjoyment.
  • Discomfort: Pain, irritation, unease.
  • Excitement: Thrill, exhilaration, arousal.
  • Calmness: Serenity, tranquility, peace.

9. Spiritual and Philosophical Emotions

  • Reverence: Deep respect, veneration.
  • Transcendence: Feeling beyond the self, connected to something greater.
  • Faith: Trust, conviction, devotion.
  • Doubt: Uncertainty, skepticism.

10. Rare or Culturally Specific Feelings

Some emotions are deeply tied to culture or are less commonly articulated:

  • Saudade (Portuguese): A deep emotional state of nostalgia or longing for something absent.
  • Schadenfreude (German): Pleasure derived from another’s misfortune.
  • Amae (Japanese): A pleasant feeling of dependence and indulgence in someone else’s care.
  • Limerence: The intense, involuntary infatuation with another person.
  • Koi No Yokan (Japanese): The sense upon meeting someone that falling in love with them is inevitable.

Summary

Humans experience a rich tapestry of feelings throughout life, ranging from fleeting micro-emotions to deep, enduring states. Many feelings overlap, and new ones can arise as culture and language evolve.

Comments

Popular posts from this blog

"How to maintain or retain tabs in same tab after button click events or postback?" using JQuery in ASP.NET C#

Login and Registration forms in C# windows application with Back end Microsoft SQL Server for data access