Setting environment for using xampp for Windows


Download 28.74 Kb.
Sana18.06.2023
Hajmi28.74 Kb.
#1568694
Bog'liq
dima

Setting environment for using XAMPP for Windows.


user@DESKTOP-AFAJ9JV c:\xampp
# mysql -u root
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 8
Server version: 10.4.18-MariaDB mariadb.org binary distribution

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show dadabase;


ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'dadabase' at line 1
MariaDB [(none)]> show database;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'database' at line 1
MariaDB [(none)]> show databases;
+--------------------+
| Database |
+--------------------+
| bogcha |
| elektr_taminot |
| fakultet |
| information_schema |
| institut |
| institute |
| maktab |
| maktab1 |
| maktabmb |
| mehmonxona |
| mysql |
| performance_schema |
| phpmyadmin |
| sirtqi_talim |
| talaba |
| test |
+--------------------+
16 rows in set (0.047 sec)

MariaDB [(none)]> select *from bogcha;


ERROR 1046 (3D000): No database selected
MariaDB [(none)]> create database magazinlar;
Query OK, 1 row affected (0.001 sec)

MariaDB [(none)]> show databases;


+--------------------+
| Database |
+--------------------+
| bogcha |
| elektr_taminot |
| fakultet |
| information_schema |
| institut |
| institute |
| magazinlar |
| maktab |
| maktab1 |
| maktabmb |
| mehmonxona |
| mysql |
| performance_schema |
| phpmyadmin |
| sirtqi_talim |
| talaba |
| test |
+--------------------+
17 rows in set (0.001 sec)

MariaDB [(none)]> use magazinlar:


ERROR 1049 (42000): Unknown database 'magazinlar:'
MariaDB [(none)]> use magazinlar;
Database changed
MariaDB [magazinlar]> create table
->
-> Bye

user@DESKTOP-AFAJ9JV c:\xampp


# mysql -u root
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 9
Server version: 10.4.18-MariaDB mariadb.org binary distribution

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show databases;


+--------------------+
| Database |
+--------------------+
| bogcha |
| elektr_taminot |
| fakultet |
| information_schema |
| institut |
| institute |
| magazinlar |
| maktab |
| maktab1 |
| maktabmb |
| mehmonxona |
| mysql |
| performance_schema |
| phpmyadmin |
| sirtqi_talim |
| talaba |
| test |
+--------------------+
17 rows in set (0.001 sec)

MariaDB [(none)]> create database yangiqurgon_magazinlar;


Query OK, 1 row affected (0.001 sec)

MariaDB [(none)]> show databases;


+------------------------+
| Database |
+------------------------+
| bogcha |
| elektr_taminot |
| fakultet |
| information_schema |
| institut |
| institute |
| magazinlar |
| maktab |
| maktab1 |
| maktabmb |
| mehmonxona |
| mysql |
| performance_schema |
| phpmyadmin |
| sirtqi_talim |
| talaba |
| test |
| yangiqurgon_magazinlar |
+------------------------+
18 rows in set (0.001 sec)

MariaDB [(none)]> use yangiqurgon_magazinlar;


Database changed
MariaDB [yangiqurgon_magazinlar]> create table magazin;
ERROR 1113 (42000): A table must have at least 1 column
MariaDB [yangiqurgon_magazinlar]> create table magazin(
-> id int(50),
-> magazin_nomi,
-> manzil,
-> ^Z^ZBye

user@DESKTOP-AFAJ9JV c:\xampp


#

user@DESKTOP-AFAJ9JV c:\xampp


# mysql -u root
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 10
Server version: 10.4.18-MariaDB mariadb.org binary distribution

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show databases;


+------------------------+
| Database |
+------------------------+
| bogcha |
| elektr_taminot |
| fakultet |
| information_schema |
| institut |
| institute |
| magazinlar |
| maktab |
| maktab1 |
| maktabmb |
| mehmonxona |
| mysql |
| performance_schema |
| phpmyadmin |
| sirtqi_talim |
| talaba |
| test |
| yangiqurgon_magazinlar |
+------------------------+
18 rows in set (0.001 sec)

MariaDB [(none)]> use yangiqurgon_magazinlar;


Database changed
MariaDB [yangiqurgon_magazinlar]> create table magazin(
-> id int(50),
-> manzil varchar(50),
-> tel_numer int(9),
-> magazin_rahbari varchar(50),
-> xizmat_turlari
-> );
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ')' at line 7
MariaDB [yangiqurgon_magazinlar]> create table magazin(
-> id int(50),
-> manzil varchar(50),
-> tel_numer int(9),
-> magazin_rahbari varchar(50),
-> xizmat_turlari varchar(50)
-> );
Query OK, 0 rows affected (0.036 sec)

MariaDB [yangiqurgon_magazinlar]> insert into magazin('1','yangi qurgon','930008025','asliddin','oziq ovqat');


ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ''1','yangi qurgon','930008025','asliddin','oziq ovqat')' at line 1
MariaDB [yangiqurgon_magazinlar]> insert into magazin values('1','yangi qurgon','930008025','asliddin','oziq ovqat');
Query OK, 1 row affected (0.016 sec)

MariaDB [yangiqurgon_magazinlar]> select * from magazin;


+------+--------------+-----------+-----------------+----------------+
| id | manzil | tel_numer | magazin_rahbari | xizmat_turlari |
+------+--------------+-----------+-----------------+----------------+
| 1 | yangi qurgon | 930008025 | asliddin | oziq ovqat |
+------+--------------+-----------+-----------------+----------------+
1 row in set (0.000 sec)

MariaDB [yangiqurgon_magazinlar]> insert into magazin values('1','turaqurgon','935856974','asliddin','oziq ovqat');


Query OK, 1 row affected (0.002 sec)

MariaDB [yangiqurgon_magazinlar]> insert into magazin values('3','yangi bozor','935852854','asadbek','oziq ovqat');


Query OK, 1 row affected (0.014 sec)

MariaDB [yangiqurgon_magazinlar]> select * from magazin;


+------+--------------+-----------+-----------------+----------------+
| id | manzil | tel_numer | magazin_rahbari | xizmat_turlari |
+------+--------------+-----------+-----------------+----------------+
| 1 | yangi qurgon | 930008025 | asliddin | oziq ovqat |
| 1 | turaqurgon | 935856974 | asliddin | oziq ovqat |
| 3 | yangi bozor | 935852854 | asadbek | oziq ovqat |
+------+--------------+-----------+-----------------+----------------+
3 rows in set (0.000 sec)

MariaDB [yangiqurgon_magazinlar]>










Download 28.74 Kb.

Do'stlaringiz bilan baham:




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling