Write a query to get the length of the students names from student table

Write a query to get the length of the students names from student table


Introduction

The following exercise will help you to improve your SQLite query skills effectively. I have used DB Browser for sqlite for following exercise.


techstudy.org

Kindle Paperwhite High Resolution Display Tablet | Rs. 9999

student_id first_name last_name email mobile_number admission_date admission_fee branch branch_id
1. Mike Brown [email protected] 875695632 12-06-2013 15000 Computer Science 100
2 Chris Lee [email protected] 789652369 05-06-2012 18000 Computer Science 100
3 David Jones [email protected] 965412369 01-07-2013 14000 Mechanical Engineering 200
4 Michael Johnson [email protected] 845632136 22-08-2014 25000 Mechanical Engineering 200
5 Tom Cruise [email protected] 789563245 09-06-2013 15000 Civil Engineering 300
6 Mary Smith [email protected] 846523698 10-07-2014 23000 Electrical engineering 400
7 James Johnson [email protected] 896523145 11-02-2015 25000 Chemical engineering 600
8 Robert Smith [email protected] 984562368 25-06-2013 22000 Information technology 500
9 Maria Garcia [email protected] 895641236 12-08-2012 14500 Civil Engineering 300
10 Brett Lee [email protected] 756984562 20-06-2013 15000 Chemical engineering 600
11 James Anderson [email protected] 895621455 15-07-2018 35000 Information technology 500
12 Joe Root [email protected] 985641236 22-08-2017 40000 Chemical engineering 600
  1. SELECT first_name,last_name, LENGTH(first_name)+LENGTH(last_name) 'Length of Full Name'
  2. FROM tbl_student;

Result

sqlite excercise techstudy.org

     





Related Topics



Responses




Popular Posts

Facebook

Founded in 2016, Tech Study passionately delivers stylish and dynamic innovative information to programmer and technology lovers. http://www.techstudy.org/.