Jumat, 04 Desember 2015

CARA MEMBUAT CLIENT SERVER DENGAN DATABASE MYSQL DAN MENGGUNAKAN VB.NET SEBAGAI BAHASA PEMOGRAMANNYA

CONFIGURATION SERVER
1.       Open your localhost/phpmyadmin
2.       Import your database in localhost example db_printing_station.sql
3.       Choose tab users

4.       Click add user

5.       Fill textbox
Menu Login Information
·         username : client_ps
·         host : %
Note :
If you write with ip address client, the server only access that ip address and another client cant access the server
example : %192.168.100.140
·         password : mleisure
·         re-type : mleisure
·         generator password :
·         Menu Database for user
Choose None


Menu Privileges click Check All
Click Add User

6.       Click Edit Privelege on client_ps

7.       Go Menu Database specific priveleges
Choose db_printing_station

This rules for client can acces db_printing_station only (OPTIONAL)

Click go will show

Click Check all (OPTIONAL)

8.       Open control panel
9.       Window firewall
10.   Advanced setting
11.   Inbound Rules
12.   New Rule
13.   Select port - next

14.   fill textbox spesific local ports : 3306     - next

15.   choose allow connection - next

16.   Check All Domain, Private and Public - next


17.   Fill the name rule - finish




  CONFIGURATION CLIENT
1.       Change db_uid : client_ps   - on your connection setting in vb.net
2.       Change db_server : 192.168.100.140   - on your connection setting in vb.net
Note : That ipaddress server
3.       Run your program in vb.net

If you want see database on server you must install sqlyog
this configuration new connection mysql host

Number 1 and number 2 is Ipaddress the server
Number 3 and number 4 user and password client on server localhost/phpmyadmin
Number 5 is port default mysql
Number 6
If you not write thats textbox you will see all database on server but if you want more spesific database write db_printing_station
Click connect


Finally run your program in vb.net and you will connect database on the server