Using Databases in C++ and Visual Studio 6 - c++

I already did some searching on stackoverflow and as far as I can see there are many ways to use databases in C++. Unfortunately at work my tools are pretty limited. I only get to use visual studio C++ 6 and don't even have boost (although I have learned to cope with that) - I assume that I can only use what is the standard distribution being delivered togather with VS C++ 6.
Now my code generates a lot of data and I would like to store some of it in a simple databse (like an MS Access db). What tools might I be able to use?
My alternative approauch would be to create a database-like object via a struct and vectors/arrays.
I also have office 2010 installed - perhaps I could somehow use Access?
Computation-speed also plays a role - the faster the better.
Another important thing: my PC at work isn't an open client. Thus I can not install any new software. Downloading and moving files works. Basically I must be able to install the tool by just moving the files into a desired folder.
Please let me know if the question is confusing or insufficiently detailed I will do what i can to remedy the situation then.
Thnaks in advance for your help :)

Even though you said 'only standard tools', I'd still say, get SQLite. It ss a public domain software, i.e. no license whatsoever . You can download an 'amalgamation' - one .h file and one .c file and include it into your project. It should compile in VC6 no problem. Very easy to use, you will be up and running in 10 minutes.
It does exactly what you need - a DB in a single file, no servers, zero-setup, etc.

Well, Visual C++ 6 did include MFC which had a suite of classes for the creation and manipulation of databases, I'm fairly certain it would be possible to use these to create a database that is accessible from Access. Unfortunately Microsoft's online help doesn't seem to go back that far, but all the reference material you need should come with the VS 6. (In my opinion VS Help system was better back then anyways.)
On a side note, you could download an old version of boost that would work with VS6. I'm not sure what the last version of boost that supports VS6 is, my guess it's somewhere around 1.3x.

VC6 should work.
Can you use MFC's db objects? (DAO I think back then?).
If your app really generates a lot of data, you might want to look at MySql. I've run into size limitations in older Access tables. Unless it's an extraordinarily simple db, you probably don't want to brew your own (though it might be fun if you have a lot of time).
The key will be finding a driver/db combo that will work. I would install the GA (free) MySql, create a tiny db with 1 table and find the driver ("connector" in MySql terms) that will work. Maybe older ODBC driver?
Also, check out ConnectionStrings.com for info on getting connected to a particular database / driver.

Related

How can I learn array database Rasdaman easily?

I'm working at VietNam - HaNoi National University and I've a research at BigData satellite raster image by array database.
A solution is using Rasdaman database which has been developed many years. I've installed this server successfully, try to make some query with this by using this guide from rasdaman.org. Everything should be ok but I've known that this has a GUI tool name Rview.
I can't search Rview from any where (may be it's too old), I need some GUI tool because I some time don't really know what is error in my query and I need some tool that can show me the result (2D, 3D) with interractive viewer.
Please tell me how can I get a tool that can have GUI as MS SQL Database management tool, Phpmyadmin,...
Rview (recently renamed to rasdaview actually, to avoid clashing with vim) is a GUI client for rasdaman that allows to send queries and has some cool visualization capabilities for 1D to 3D data.
The problem with rasdaview is that it has been last compiled 10+ years ago against wxWidgets 1.6x and the code is so outdated and incompatible with recent wxWidgets that it's not possible to compile it anymore without significant rewriting.
So rasdaman comes with this rview binary, which amazingly still works on most systems today. However, since it's not possible to compile it, it's a bit tricky to get it running. These guidelines should help you.
Are you looking for a website where you can execute your DDL or DML statements?
If yes then try SQL Fiddle.

Using JasperReports (JasperSoft Studio + JasperReports Library) with ColdFusion 9 Standard Edition

So this is my first time posting a question here. If I do it wrong, please, be gentle. :)
I'm trying to find a decent reporting solution at my company and it seems like JasperReports is one of the better (read: inexpensive) ways to go. They've got a newly revamped Eclipse-based banded report editor called JasperSoft Studio, and it looks really slick.
The problem I'm having is figuring out exactly what pieces I need in order to use this tool (or the files it creates) in my CF apps. After much Googling, I'm not really finding the answers I'm looking for... and what little information I do find is really pretty old.
Is anyone using JasperSoft Studio in combination with the JasperReports Library to do any on-the-fly PDF creation? We've come to a point on this particular application where cfdocument just isn't cutting it.
The things I know are:
CF is using a really (really, really) old version of JasperReports
under the hood to drive cfreport.
There is a way for me to override the really old version of
JasperReports so that CF will load the newest one.
Beyond that though, I'm not sure if it's just a matter of using JasperSoft Studio to create compiled JRXML files or (.jasper files, I'm not sure which) and then maybe just rename those to '.cfr' which cfreport knows how to deal with... or what?
If I look at the documentation for JasperReports Library it would seem that I need a lot more than just the JR Library and the JasperSoft Studio to make all of this work... but it's just kind of unclear to me. Because the library is so flexible and can be used from lots of different types of systems I'm having trouble figuring out what I need for my certain set of circumstances.
Is anyone out there using JasperReports in their CF applications or does anyone have any experience setting up to use JasperReports with CF?
There seems to be precious little information on this topic. :(
Also, in case it comes up (as it did in a few of the much older posts I found on the internet) ColdFusion is written in Java so I DO have access to any underlying Java Classes that I might need.

How to create a login application with Visual Basic (using WebHttpRequest)

Hei there, I'm not experienced at all in C++ as I need to start learning year the next year at my university, though, I've been creating a browser based game and I'm looking for someone to transform it into pc app.
Though, I'm wondering how to make that application send a http request via POST to a file on my webserver with the username / pw.
After all the tutotials I've been reading, I concluded that none worth spending my time with, because they all based on own database, and I'm looking for one that connects to a maestro server and requests the data from there.
This may not be the answer you are looking for, but you may consider two alternatives to a more pure C++ application.
If you already have a working browser game, try to take that same code and put the html/javascript/whatever in a file and give the file a ".hta" extention. It basically opens inside a browser to run your files, but it acts more like an application from the user's viewpoint. (And, as much as I hate Windows, they're pretty fun to create if I may say so). However, your source code with this option is easily read because it can be renamed to a text file (or html file).
You could use Visual C++ (or VB.net, which you have tagged to the question, as well as "Visual" C#) to create an application which mostly consists of a browser view. It could be a "standalone" application (however would rely completely on the .Net framework - may or may not be what you want) that basically accomplishes the same as the option above, but adds that you can "hide" your files inside your application.
Using the two above alternatives, you could make an application relatively quickly that would load your files, which I assume you have already created. Note that neither of the above alternatives will work on anything other than Windows OS's.
If the two above alternatives are not what you want, or if you have questions about either one, I'd be glad to attempt to help.
I've been able to find a friend that would do it in Delphi because I wouldn't want users to download net framework just for this ap.
So the program that would fit most for any apps is Delphi Prism XE (even if it's an addon of Visual Studio)

What are some open-source applications written in C/C++ using PostgreSQL?

I'm trying to find open source applications using PostgreSQL that are written in C/C++ so I can study them. A few open source projects using PostgreSQL are Evergreen ILS, SpamAssassin, and pgpool. However, Evergreen and SpamAssassin are written in Perl, and pgpool (written in C) is a replication tool, not a typical application. Moreover, I looked at the SQL code in Evergreen, and it is quite voluminous and complicated.
Hence, I'm looking for one or more applications using PostgreSQL, preferably those that are somewhat trivial (but not too trivial).
seen libpqxx? try asking on its mailing list (but scour their wiki first)
http://pqxx.org/development/libpqxx
pgAdmin is written using c++ using wxwidgets.
how about pgAdmin 3 ?
Also, you may find Qt4 a very easy way interact with databases programming in C++.
http://doc.trolltech.com/4.6-snapshot/sql-programming.html
Have you searched through the projects at http://pgfoundry.org ?
Two examples that are open-source:
Kexi (see kexi-project.org)
FOST4 (
http://support.felspar.com/Fost%204 )
It's pretty big, but the KDE Project's Amarok is written in C++ and can use a PgSQL backend (among several others). While it's pretty large, you may be able to find some interesting things in the database code. Since it uses a pre-defined schema (as opposed to the extremely general types of access that something like pgAdmin uses) it may have some good things to teach you. It will definitely be easier to pick apart than Evergreen, which actually has an entire middleware layer that actually does the data access through exposed services (The OpenSRF Project).

In native C++, how does one use a SqlCe .sdf database?

Is there a simple way, without .NET?
I've found some libraries but none for SqlCe 3.5. There is http://sqlcehelper.codeplex.com/ but it's far from done, since a major feature like using a password is not yet implemented. I've looked at the source and it uses OLEdb to handle the database.
The official Microsoft Northwind example (that is shipped with SQL Compact 3.1, but not with 3.5) also doesn't work, I've tried setting it up with no success.
Actually I don't have a sample working code. Was anyone able to set it up paired with a passworded .sdf?
What are the alternatives?
Thanks.
Several months ago, I compared certain database implementations for our desktop application. Using SqlCE with native C++ code is awful. If I remember right, some of native examples contains "goto" type jumps, hard to bind data and so on. If you have a choice then use SQLite.