Exception ; ▁import ▁java . sql . Statement ; ▁ ▁public ▁class ▁Main ▁{ ▁▁▁ ▁public ▁static ▁void ▁main ( String [] ▁args ) ▁throws ▁SQL Exception ▁{ ▁▁▁▁ ▁Mys ql DataSource ▁ds ▁= ▁new ▁Mys ql DataSource (); ▁▁▁▁ ▁ds . set Database Name (" mysql "); ▁▁▁▁ ▁ds . set User (" root "); ▁▁▁▁▁ ▁try ▁( Connection ▁conn ▁= ▁ds . get Connection ()) ▁{ ▁▁▁▁▁▁ ▁try ▁( Statement ▁st mt ▁= ▁conn . create Statement ()) ▁{ ▁▁▁▁▁▁▁▁ ▁st mt . execute Update (" CREATE ▁TABLE ▁IF ▁NOT ▁EXISTS ▁products ▁( name ▁VARCHAR ( 4 0 ), ▁price ▁INT ) "); ▁▁▁▁▁▁ ▁} ▁▁▁▁▁▁▁ ▁try ▁( P rep ared Statement ▁st mt ▁= ▁conn . prepare Statement (" INSERT ▁INTO ▁products ▁VALUES ▁( ?, ▁? )" )) ▁{ ▁▁▁▁▁▁▁▁ ▁st mt . set String ( 1 , ▁" bi ke "); ▁▁▁▁▁▁▁▁ ▁st mt . set Int ( 2 , ▁ 1 0 9 0 0 ); ▁▁▁▁▁▁▁▁ ▁st mt . execute Update (); ▁▁▁▁▁▁▁▁ ▁st mt . set String ( 1 , ▁" sh o es "); ▁▁▁▁▁▁▁▁ ▁st mt . set Int ( 2 , ▁ 7 4 0 0 ); ▁▁▁▁▁▁▁▁ ▁st mt . execute Update (); ▁▁▁▁▁▁▁▁ ▁st mt . set String ( 1 , ▁" phone "); ▁▁▁▁▁▁▁▁ ▁st mt . set Int ( 2 , ▁ 2 9 5 0 0 ); ▁▁▁▁▁▁▁▁ ▁st mt . execute Update (); ▁▁▁▁▁▁ ▁} ▁▁▁▁▁▁▁ ▁try ▁( P rep ared Statement ▁st mt ▁= ▁conn .