SQL SERVER – Take the Quiz for a chance to win a Quadcopter Drone – Brain Teasers

SQL SERVER - Take the Quiz for a chance to win a Quadcopter Drone - Brain Teasers quadcompter It has been a long time since we ran quiz. So let us get ready for a quiz. The quiz has two parts. You have to get both the parts correct to win Quadcopter with Camera (we will call it drone). We will be giving away a total of 2 Quadcopters.

The quiz is extremely easy and I will ship the Drone anywhere in the world where Amazon will ship it.

Let us jump directly to the quiz. Please complete all the three questions of the contest.

Contest Part 1: Brain Teasers

There are two questions for you in this part of the contest.

Question: There are two 7s. How will you write select statement with a single operator that returns single 7?

Hint: SELECT 7(Answer)7

SQL SERVER - Take the Quiz for a chance to win a Quadcopter Drone - Brain Teasers emb11

Question: Write down the shortest code that produces 1 without using any numbers in the select statement?

Hint: SELECT (Answer)

SQL SERVER - Take the Quiz for a chance to win a Quadcopter Drone - Brain Teasers emb22

Contest Part 2: Download and Activate Rapid SQL

Question: Download and Activate Rapid SQL.

Hint: You have to download and activate Rapid SQL. If you do not activate Rapid SQL, you will be disqualified for the contest. Why take risk, let us start!

SQL SERVER - Take the Quiz for a chance to win a Quadcopter Drone - Brain Teasers emb33

That’s it!

Just answer above questions in the following comments area, in following format.

Remember:

  • Use comments area right below the blog to take participation in the contest
  • Answer before June 5, 2014 midnight GMT.
  • The winner will be announced on June 8.
  • The winner will be selected randomly from all the valid answers.
  • All the valid answers will be kept hidden till June 5, 2014.
  • There will be a total of two winners.
  • The contest is open for any country of the world where Amazon ships products.

Reference: Pinal Dave https://blog.sqlauthority.com/ )

Previous Post
SQL SERVER – Copy Database – SQL in Sixty Seconds #067
Next Post
SQL SERVER – Parsing SSIS Catalog Messages – Notes from the Field #030

Related Posts

No results found.

163 Comments. Leave new

  • Hi Pinal,
    Below are the answers for the questions
    1) Select 7|7
    2) Select convert(bit,’true’)

    Reply
  • vinayak narayan jamdar
    May 30, 2014 9:47 am

    1.Question: There are two 7s. How will you write select statement with a single operator that returns single 7?
    Ans : SELECT 7 & 7

    2.Question: Write down the shortest code that produces 1 without using any numbers in the select statement?

    Ans : SELECT CEILING(RAND())

    Reply
  • Ques 1 Select 7#7
    Ques 2 Select Len(‘A’)

    Reply
  • Jeetendra Gund
    May 30, 2014 10:48 am

    1) Ans : SELECT 7|7

    2) Ans : SELECT COUNT(*)

    Reply
  • Kuntesh Bhatt
    May 30, 2014 11:25 am

    Hello Sir,
    I have given answer in the comment and activated Rapid SQL. Can you confirm my candidature for the contest?

    Reply
  • Yogesh Kapase
    May 30, 2014 12:37 pm

    Question 1 Ans : select 7|7

    Question 2 Ans : select COUNT(‘a’)

    Reply
  • Philipp Mehrwald
    May 30, 2014 1:43 pm

    Hi,

    first answer is:
    select 7 & 7
    — or:
    select 7 | 7

    second answer is:
    select COUNT(*) from (select ‘a’ as a) as a

    Reply
  • Anubhav Choudhary
    May 30, 2014 2:56 pm

    Contest Part 1: Brain Teasers

    Answer1: SELECT 7|7
    Answer2: SELECT LEN(‘A’)

    Reply
  • Ronald Jayadi
    May 30, 2014 3:51 pm

    Answer Number 1 : SELECT 7|7

    Answer Number 2 : SELECT 1

    Reply
  • Select 7 & 7

    Select COUNT(‘a’)

    Reply
  • Aravind Kumar
    May 30, 2014 4:52 pm

    SELECT 7 INTERSECT 7

    Reply
  • Alin Hanghiuc
    May 30, 2014 5:00 pm

    Answer for question 1:

    select 7|7

    Answer for question 2:

    select day($)

    Reply
  • These are the answers..
    SELECT count(*)

    select 7 PRINT 7

    Reply
  • The answers are
    SELECT 7&7
    SELECT @@ROWCOUNT
    I have activated RapidSQL with my email id bhatnitinn@gmail.com

    Reply
  • Swaraj Patil
    May 31, 2014 11:21 am

    Following are answers –
    1) SELECT 7 | 7
    2) SELECT count(‘a’)

    Reply
  • why my comment says..”Your comment is awaiting moderation.”

    Reply
  • Carlos Sanchez
    May 31, 2014 1:52 pm

    Hi, here my answer

    –Question 1
    SELECT 7 & 7
    –Question 2
    SELECT LEN(‘.’)

    thx :)

    Reply
  • hariitpassion
    May 31, 2014 8:14 pm

    1. Ans : & operator (7 & 7)
    2. Ans : Count(@@version)

    Reply
  • Hi Pinal,
    My answer is as below:
    Question: There are two 7s. How will you write select statement with a single operator that returns single 7?
    Answer : Select 7 | 7

    Question: Write down the shortest code that produces 1 without using any numbers in the select statement?

    Answer: Select count (”)

    And I have also installed Rapid SQL.

    Thanks,
    Prabhat

    Reply
  • Gobikrishnan (@kmgkrishnan)
    June 1, 2014 10:37 am

    Contest Part 1:
    Answer for Question 1: bitwise AND operator and bitwise OR operator gives the same result Select 7&7, Select 7|7
    Answer for Question 2: select CONVERT(bit, ‘TRUE’)
    Contest Part 2: I have installed and activated the rapid sql.

    Reply

Leave a Reply