0% found this document useful (0 votes)
19 views4 pages

Sam Ople

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 4

https://www.scribd.

com/doc/92266086/%E0%B0%B5%E0%B0%BE
%E0%B0%B0%E0%B0%95%E0%B0%BE%E0%B0%82%E0%B0%A4-%E0%B0%B6%E0%B0%B0%E0%B1%80%E0%B0%AA%E0%B0%BE%E0%B0%A6
mysql> show databases;
+--------------------+
| Database
|
+--------------------+
| information_schema |
| test
|
+--------------------+
2 rows in set (0.09 sec)
mysql> use test;
Database changed
mysql> show tables;
+----------------+
| Tables_in_test |
+----------------+
| dept
|
| emp
|
+----------------+
2 rows in set (0.01 sec)
mysql> select * from emp;
+----+----------+--------+---------+
| id | name | salary | dept_id |
+----+----------+--------+---------+
| 1 | sample | 25000 | 1
|
| 2 | ssafghhj | 20000 | 2
|
+----+----------+--------+---------+
2 rows in set (0.03 sec)
mysql> select * from dept;
+---------+-------------+
| dept_id | dept_name |
+---------+-------------+
|1
| Mathematics |
|2
| Zoology |
|3
| Botony |
+---------+-------------+
3 rows in set (0.00 sec)
mysql> update emp set dept_id=3 where id='2';
Query OK, 1 row affected (0.08 sec)
Rows matched: 1 Changed: 1 Warnings: 0
mysql> select * from dept;
+---------+-------------+
| dept_id | dept_name |
+---------+-------------+
|1
| Mathematics |
|2
| Zoology |

|3
| Botony |
+---------+-------------+
3 rows in set (0.00 sec)
mysql> select * from emp;
+----+----------+--------+---------+
| id | name | salary | dept_id |
+----+----------+--------+---------+
| 1 | sample | 25000 | 1
|
| 2 | ssafghhj | 20000 | 3
|
+----+----------+--------+---------+
2 rows in set (0.00 sec)
mysql> propmpt $
-> ;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to
your MySQL server version for the right syntax to use near 'propmpt $' at line 1
mysql> prompt $
PROMPT set to '$'
$select * from emp;
+----+----------+--------+---------+
| id | name | salary | dept_id |
+----+----------+--------+---------+
| 1 | sample | 25000 | 1
|
| 2 | ssafghhj | 20000 | 3
|
+----+----------+--------+---------+
2 rows in set (0.00 sec)
$propmpt #
-> ;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to
your MySQL server version for the right syntax to use near 'propmpt' at line 1
$prompt #
PROMPT set to '#'
#select * from emp;
+----+----------+--------+---------+
| id | name | salary | dept_id |
+----+----------+--------+---------+
| 1 | sample | 25000 | 1
|
| 2 | ssafghhj | 20000 | 3
|
+----+----------+--------+---------+
2 rows in set (0.00 sec)
#exit
8323
3d
dfd
d
fd

f
df
df
d
f
d
f
df
df
d
f
df
dfdf
d
f

a
d
ad
d
s
d
sd
s
d
s
ds
d
s
d
s
ds
d
sd
sesf
dgf
hg
h
ghj
g
jk
hj
hj
h
kjh

kj
k
ju
iy
u
ttr
t5r4
5453
r
e
r
ew
ew2
354
t
4
t4
7645
yu5
dfd
f
df
d
fd
fd
fd
fd
ereg
rgf
d
fd
g
d
g
ddg

You might also like