[MySQL Student App] New database export, remove usings - FINITO

This commit is contained in:
Alex Thomassen 2019-04-11 16:01:14 +02:00
parent 69f05deab3
commit 34f9638ec0
Signed by: Alex
GPG Key ID: 10BD786B5F6FF5DE
4 changed files with 16 additions and 15 deletions

View File

@ -0,0 +1,4 @@
#!/bin/bash
DATE=$(date +"%Y-%m-%d_%H%M%S")
mysqldump -B --user=homestead --host=127.0.0.1 --protocol=tcp --default-character-set=utf8 --routines --skip-triggers "student2018" > "student2018_$DATE.sql"

View File

@ -15,6 +15,14 @@
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Current Database: `student2018`
--
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `student2018` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `student2018`;
--
-- Table structure for table `fylke`
--
@ -87,7 +95,7 @@ CREATE TABLE `student` (
PRIMARY KEY (`idStudent`,`Postnummer`),
KEY `StudentPostnummerID_idx` (`Postnummer`),
CONSTRAINT `StudentPostnummerID` FOREIGN KEY (`Postnummer`) REFERENCES `poststed` (`Postnummer`)
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8 COMMENT=' ';
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=utf8 COMMENT=' ';
/*!40101 SET character_set_client = @saved_cs_client */;
--
@ -96,7 +104,7 @@ CREATE TABLE `student` (
LOCK TABLES `student` WRITE;
/*!40000 ALTER TABLE `student` DISABLE KEYS */;
INSERT INTO `student` VALUES (1,'Thomassen','Alex','Skolevegen 6','47634677',21,'M',2383),(2,'Nordmann','Ola','Blankeveien 82','88228833',19,'M',0191),(3,'Schnøring','Hakke','Smockrettinnveien 99','22336622',20,'K',0191),(4,'Larsen','Stian','Bøttekottet 47','21345676',22,'M',2315),(6,'Finsrud','Øyvind','Hakkebakkeskogen 66','77554422',21,'M',2815),(8,'Stian','Blipp','Klovngata 51','99887766',44,'M',0191),(9,'Larsen','Stian','Aldershjemmet 55','45678982',25,'M',2383),(10,'Ås','Åsmund','Bruuuuuuumund 511','123123123',22,'M',2815),(11,'Thomassen','Karin','Rostadvegen 9','62342318',31,'K',2383),(12,'Anne Kari','Thomassen','Rælhaugen 22','22113322',25,'K',0191),(13,'Morken Haugen','Katrine','Lia 1','21356788',20,'K',2815),(14,'Kristiansen','Hanne','Borettslaget 44','77222772',21,'K',2383),(15,'Laubakken','Bjønn','OppiDerEnPlass 44','77228822',23,'M',2383),(16,'Snartenkt','Helge','Hoppihavet 19','56786578',22,'M',2383);
INSERT INTO `student` VALUES (1,'Thomassen','Alex','Skolevegen 6','47634677',21,'M',2383),(2,'Nordmann','Ola','Blankeveien 82','88228833',19,'M',0191),(3,'Schnøring','Hakke','Smockrettinnveien 99','22336622',20,'K',0191),(4,'Larsen','Stian','Bøttekottet 47','21345676',22,'M',2315),(6,'Finsrud','Øyvind','Hakkebakkeskogen 66','77554422',21,'M',2815),(8,'Stian','Blipp','Klovngata 51','99887766',44,'M',0191),(9,'Larsen','Stian','Aldershjemmet 55','45678982',25,'M',2383),(10,'Ås','Åsmund','Bruuuuuuumund 511','123123123',22,'M',2815),(11,'Thomassen','Karin','Rostadvegen 9','62342318',31,'K',2383),(12,'Anne Kari','Thomassen','Rælhaugen 22','22113322',25,'K',0191),(13,'Morken Haugen','Katrine','Lia 1','21356788',20,'K',2815),(15,'Laubakken','Bjønn','OppiDerEnPlass 44','77228822',23,'M',2383),(16,'Snartenkt','Helge','Hoppihavet 19','56786578',22,'M',2383);
/*!40000 ALTER TABLE `student` ENABLE KEYS */;
UNLOCK TABLES;
@ -288,4 +296,4 @@ DELIMITER ;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2019-04-11 13:31:19
-- Dump completed on 2019-04-11 14:00:21

View File

@ -1,10 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace MySQLStoredProcedureStudent
namespace MySQLStoredProcedureStudent
{
public class PoststedItem
{

View File

@ -1,11 +1,6 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using MySql.Data.MySqlClient;