@@ -501,42 +501,20 @@ or C<CPointer>.
501
501
= head1 Examples
502
502
503
503
Some examples can be found L < in the DBIsh repository
504
- |https://github.com/perl6/DBIish/tree/master/lib/DBDish > .
504
+ |https://github.com/perl6/DBIish/tree/master/examples > .
505
505
506
506
= head2 MySQL
507
507
508
- = comment TODO Do we really need this here? Seems like this info should just go
509
- along-side that example in the git repo, rather than replicated
510
- on p6doc.
511
-
512
- There is an example of using the MySQL client library. There is a project
513
- L < https://github.com/mberends/minidbi > that wraps these functions with a DBI
514
- compatible interface. You'll need that library to hand; on Debian-esque systems
508
+ You'll need to install MySQL server locally; on Debian-esque systems
515
509
it can be installed with something like:
516
510
517
- sudo apt-get install libmysqlclient
511
+ sudo apt-get install mysql-server
518
512
519
513
Prepare your system along these lines before trying out the examples:
520
514
521
515
$ mysql -u root -p
522
- CREATE DATABASE zavolaj;
523
- CREATE USER 'testuser'@'localhost' IDENTIFIED BY 'testpass';
524
- GRANT CREATE ON zavolaj.* TO 'testuser'@'localhost';
525
- GRANT DROP ON zavolaj.* TO 'testuser'@'localhost';
526
- GRANT INSERT ON zavolaj.* TO 'testuser'@'localhost';
527
- GRANT DELETE ON zavolaj.* TO 'testuser'@'localhost';
528
- GRANT SELECT ON zavolaj.* TO 'testuser'@'localhost';
529
- GRANT LOCK TABLES ON zavolaj.* TO 'testuser'@'localhost';
530
- GRANT SELECT ON mysql.* TO 'testuser'@'localhost';
531
- # or maybe otherwise
532
- GRANT ALL PRIVILEGES ON zavolaj.* TO 'testuser'@'localhost';
533
-
534
- You can look at the results via a normal mysql connection:
535
-
536
- $ mysql -utestuser -ptestpass
537
- USE zavolaj;
538
- SHOW TABLES;
539
- SELECT * FROM nom;
516
+ UPDATE mysql.user SET password=password('sa') WHERE user = 'root';
517
+ CREATE DATABASE test;
540
518
541
519
= head2 Microsoft Windows
542
520
0 commit comments