Westy92.com If you're bored enough, go ahead and read this. :)

20Feb/110

Reading From a MySQL Database Using C++

I Googled it. I could not find an easy example of how to set up an environment to do this, so I decided to research a bunch and write my own tutorial!

First things first. You need:

  • Ubuntu (or other linux distribution)
  • A functioning MySQL database to read from
  • Patience!

The first thing you need to do is to install the MySQL++ library on linux.  Open up Terminal and type "sudo apt-get install libmysql++-dev" and press enter.

It should ask for your password, so type that in and watch it install MySQL++.

Now that that is over, create a new folder and navigate to it in Terminal.  Create two blank files, naming one "main.cpp" and "makefile" for the other.

Inside of "main.cpp", paste the following:


Inside of "makefile", paste the following:


Now, you have the basic template saved. You must fill in your MySQL database information for the variables "db", "server", "user", and "pass" in order for this program to work.


Once you have the database info filled in, where it says "select * from database", you may change that to something more appropriate, such as "select first_name, last_name, user_id, email from users".


Now you may simply save it, run "make" and then run the program.


Cheers!

</Westy92>

1Oct/100

Apologies for my Lack of Blogging

It's a fact. I have not blogged in...*checks calendar*...too long. I hope to change that. SOON. I am currently working on a design for my personal website, and am happy regarding good it is looking. I hope to have that done soon as well. I plan on blogging much more in the future.

I have recently composed a commercial in a class at school which I am very proud of, so I will share that with you:

That's all, and I hope to post again soon!

Filed under: Uncategorized No Comments
15Apr/1013

Week 13, I cannot believe the project is over!

This project has actually gotten me to read more, but it seemed somewhat like of a nuisance, considering my busy schedule. This final week I am happy to say that I read 5 final hours. I finished my second and final book, “Into the Wild”.

“Into the Wild” was very interesting, as it was about the journey of Mr. McCandless into the Alaskan wilderness, never to return. It also included many other similar stories. The reason I chose to read this book and ended up liking it was the feeling of adventure. My favorite book of all time is still "Hatchet", and this book seemed very similar. I give this book a rating of 3.5 out of 5 stars.

The other book I read during this project was “What the Dormouse Said: How the Sixties Counterculture Shaped the Personal Computer Industry”. This book taught me a great deal about the history of computers, and how they would not be the same without the counterculture that helped mold them into what they are today. I rate this book at 4 out of 5 stars.

My final thoughts on this unit of English are quite positive. I read quite a bit more than usual, which was both good and bad, but overall good. I would like to thank Mr. Strusz, who had us do this, and I encourage him to do it next year. I believe it would benefit the students by extending the reading time to 15 weeks.

TOTALS:

Total pages read: 494 pages.
Total time read: 35.25 hours.

8Apr/101

Week 12, which means 1 week remaining!

I read the most I ever have this week. I started "Into the Wild" and ended up reading the first 116 pages of it in 8 hours. In the beginning 2/3 (which is quite a bit to recall for this) Chris McCandless - he had a few "first" names - was a very intelligent young man from a family that was quite wealthy abandoned all for nothing. He donated about $25,000 of his savings to local charities, abandoned his car, burnt almost all of the cash in his wallet, and took off on the journey of a lifetime. He ended up traveling all over the country, mostly on the Western half, and ended up dying in an abandoned bus in Alaska. It is a very interesting story and I am eager to finish it!

Total pages: 453 pages. Total time read: 30.25 hours.

1Apr/101

Week 11!

This week I read more than usual. I read 5.5 hours this week. I ended up finishing the book “What the Dormouse Said: How the Sixties Counterculture Shaped the Personal Computer Industry”. I overall liked the book, but it had a History fell to it rather than a story which I found to be hard for me to follow at times. My goals for reading over Spring Break include the following: -Get 30 hours (total) of reading in -Finish my next book, "Into the Wild" -Start "One Flew Over the Cuckoo's Nest"

Total Pages Read: 337 Pages Total Time Read: 22.25 Hours

online games juegos gratis games online free games free online games
online game jogos online jeux gratuits giochi gratis oyunlar