battle programmers alliance

battle programminga forum for elite programmerswith extreme will powerto sharpen theire skills
 
HomeCalendarFAQSearchMemberlistUsergroupsRegisterLog in
Search
 
 

Display results as :
 
Rechercher Advanced Search
Latest topics
» mini A.I puzzles
Mon Apr 23, 2018 11:38 am by Moti Barski

» java and MySQL
Sun Apr 15, 2018 8:57 pm by Moti Barski

» java convert string to unicode
Sun Mar 25, 2018 8:40 pm by Admin

» java eclipse oxygen grimoire
Sat Mar 24, 2018 8:31 pm by Admin

» problem java dynamic web
Sat Mar 24, 2018 6:10 am by Admin

» auto programming dev
Wed Mar 14, 2018 8:42 pm by Admin

» JAVA design patterns
Wed Mar 07, 2018 9:53 pm by Admin

» vb.net morse ear with net lingo beef up:
Sun Mar 04, 2018 10:30 pm by Moti Barski

» java concept input output class
Tue Feb 20, 2018 7:21 pm by Admin

April 2018
SunMonTueWedThuFriSat
1234567
891011121314
15161718192021
22232425262728
2930     
CalendarCalendar
Social bookmarking
Social bookmarking digg  Social bookmarking delicious  Social bookmarking reddit  Social bookmarking stumbleupon  Social bookmarking slashdot  Social bookmarking yahoo  Social bookmarking google  Social bookmarking blogmarks  Social bookmarking live      

Bookmark and share the address of battle programmers alliance on your social bookmarking website
Share | 
 

 java and MySQL

Go down 
AuthorMessage
Moti Barski

avatar

Posts : 111
Join date : 2011-08-02

PostSubject: java and MySQL   Sun Apr 15, 2018 8:57 pm

mySQL the database
mySQL workbench : a GUI for CRUDing sql DBs
connectorJ : enables java platforms to work with sql DBs

mySQL installer : a package with the above 3

DL said installer from : https://dev.mysql.com/downloads/installer/
choose the community DL (mySql-installer-community-5.7.2.1.msi) and fire it up.

on the wizard choose: custom, mySQL server 5.7_mySQL server 5.7.21 - x64 + applications mySql workbench,
standalone mtSql server/classic, config type : development machine tcp/ip open +firewall+ port 3306,
invent pass, config mysql as win service + start server at sys startup + run service as standard

in the workbench creating a DB and table in it is right click intuitive.
PK : primary key FK (foriegn key): the PK parallal in a 2nd DB. therefor an FK can not be null.
those keys are used for join methods which are used for displaying the fusion between DBs.

you need to refresh after queries there is a refresh button in the SQL explorer window near the DB.

vars

https://www.w3schools.com/sql/sql_datatypes.asp

aggerate functiokns
https://dev.mysql.com/doc/refman/5.7/en/group-by-functions.html

MySQL query conjurations :

select * from testdb1.testtable;
select * from databeName.someTableName;

--this is a comment

http://cse.unl.edu/~sscott/ShowFiles/SQL/CheatSheet/SQLCheatSheet.html
mysql aggregate functions :
http://www.mysqltutorial.org/mysql-aggregate-functions.aspx

stored methodes :

A stored procedure is a set of SQL statements that can be stored in the server.
1 situations where stored routines can be particularly useful:
2 when security is paramount

When the routine is invoked, an implicit USE db_name is performed (and undone when the routine terminates). USE statements within stored routines are disallowed.
You can qualify routine names with the database name. This can be used to refer to a routine that is not in the current database. For example, to invoke a stored procedure p or function f that is associated with the test database, you can say CALL test.p() or test.f().
When a database is dropped, all stored routines associated with it are dropped as well.


strored methodes

http://www.mysqltutorial.org/mysql-stored-function/

http://www.cmi.ac.in/~madhavan/courses/databases10/mysql-5.0-reference-manual/stored-procedures.html

join queries

https://www.w3schools.com/sql/sql_join.asp
https://dev.mysql.com/doc/refman/8.0/en/join.html

ready made example DB for practice : northwind :
run this query (in the mysql workbench) to create it :
https://github.com/jpwhite3/northwind-MySQL/blob/master/northwind.sql
run this query to populate it with data
https://github.com/dalers/mywind/blob/master/northwind-data.sql

pig


Last edited by Moti Barski on Mon Apr 23, 2018 12:08 am; edited 2 times in total
Back to top Go down
View user profile
 
java and MySQL
Back to top 
Page 1 of 1
 Similar topics
-
» Verify command when used with Java,JUNIT and Eclipse
» opera browser not loading the page using selenium Rc(Java)
» JAVA tunnel Based UAE Solution Available in Just $149 @ VoIP
» [Help] Java input Username field as a timestamp
» LocalFileDetector (uploading files) - InternetExplorer Driver (Java platform)

Permissions in this forum:You cannot reply to topics in this forum
battle programmers alliance :: battle programming alliance :: battle programming-
Jump to: