Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C Programming > CPP builder 6 and MySQL with or without VCL ?

Reply
Thread Tools

CPP builder 6 and MySQL with or without VCL ?

 
 
Lotfi
Guest
Posts: n/a
 
      08-06-2004

Hi

I am trying to access MySQL DB with C++ Builder 6 pro,
I have Apache 2 under W2000 pro and MySQL 4

I found
http://crlab.com/mydac/
but it is not free
but the trial version seems to work

I will also have a look to :
http://zeoslib.sourceforge.net/modul...name=Downloads

I need things simpler with no VCL
SO I found an example of :
____________________________________________
Author: Jethro Wright, III TS : 3/ 4/1998 9:15 */
/* Date: 02/18/1998 */
/* mytest.c : do some testing of the libmySQL.DLL.... */
/* */
/* History: */
/* 02/18/1998 jw3 also sprach zarathustra.... */
____________________________________________

it works under C++builder 6 pro in consoile mode and "C" syntax

after rebuilding the .lib .def with implib impdef in order to link them with
his C source

but If I rename its file to .CPP
and rebuild it gives lot of errors (that where warnings before) because of
the use of :
char * pszT;
and mysql DLL functions are returning a const char *

also when I include <VCL.h> file (in order to use VCL forms) then no
building is possible

mysql_com.h
gives errors near :

ypedef struct st_net {
Vio* vio;
unsigned char *buff,*buff_end,*write_pos,*read_pos;
----->>>> my_socket fd; /* For Perl DBI/dbd */
unsigned long max_packet,max_packet_size;


My QUESTION :
Has anybody succeded to compile C++ VCL forms with the standard libmySQL.DLL
given with MySQL

I just need to connect to MySQL DB and do some queries, but I need the full
VCL environement...

give me website or tutorial example / help

Thanks in advance.

Ciao

















 
Reply With Quote
 
 
 
 
Jack Klein
Guest
Posts: n/a
 
      08-06-2004
On Fri, 6 Aug 2004 04:18:21 +0200, "Lotfi"
<llbaghli(nospam)@ifrance.com> wrote in comp.lang.c:


> Hi
>
> I am trying to access MySQL DB with C++ Builder 6 pro,
> I have Apache 2 under W2000 pro and MySQL 4


You are asking your question in the wrong place. Neither comp.lang.c
nor comp.lang.c++ discuss third party libraries like MySQL nor
specific implementations like C++ Builder.


> I found
> http://crlab.com/mydac/
> but it is not free
> but the trial version seems to work
>
> I will also have a look to :
> http://zeoslib.sourceforge.net/modul...name=Downloads
>
> I need things simpler with no VCL


That's good, it is very hard to imaging anything more off-topic in
these newsgroups than Borland's VCL, which is not C or C++ at all but
written in their own proprietary extended version of Pascal.

> SO I found an example of :
> ____________________________________________
> Author: Jethro Wright, III TS : 3/ 4/1998 9:15 */
> /* Date: 02/18/1998 */
> /* mytest.c : do some testing of the libmySQL.DLL.... */


Presumably, given the name, this program was written in C.

> /* */
> /* History: */
> /* 02/18/1998 jw3 also sprach zarathustra.... */
> ____________________________________________
>
> it works under C++builder 6 pro in consoile mode and "C" syntax


....and according to you, it works as when compiled as C.

> after rebuilding the .lib .def with implib impdef in order to link them with
> his C source
>
> but If I rename its file to .CPP
> and rebuild it gives lot of errors (that where warnings before) because of
> the use of :
> char * pszT;
> and mysql DLL functions are returning a const char *


Apparently you do not understand that C is not a subset of C++. There
are programs that are perfectly valid C that are not valid C++ at all.
There are several things you can do about this. You could make sure
you understand the differences between C and C++, and manually convert
the source to C++. Or you could look for another source, in C++. You
could write your own C++ code. Or you could buy C++ source code.

> also when I include <VCL.h> file (in order to use VCL forms) then no
> building is possible


Anything at all involving Borland's VCL is completely off-topic here.
As I said, it is not even C or C++. This is discussed in Borland's
support groups, some of which even have .vcl in their names. Try the
news:borland.public.* family of groups on the server
newsgroups.borland.com.

> mysql_com.h
> gives errors near :
>
> ypedef struct st_net {
> Vio* vio;
> unsigned char *buff,*buff_end,*write_pos,*read_pos;
> ----->>>> my_socket fd; /* For Perl DBI/dbd */
> unsigned long max_packet,max_packet_size;
>
>
> My QUESTION :
> Has anybody succeded to compile C++ VCL forms with the standard libmySQL.DLL
> given with MySQL
>
> I just need to connect to MySQL DB and do some queries, but I need the full
> VCL environement...
>
> give me website or tutorial example / help
>
> Thanks in advance.
>
> Ciao


None of your issues have anything to do with the C or C++ languages,
but with non-standard extensions and third party libraries. Your best
bet is the Borland support groups.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++
http://www.contrib.andrew.cmu.edu/~a...FAQ-acllc.html
 
Reply With Quote
 
 
 
 
Lotfi
Guest
Posts: n/a
 
      08-06-2004
>
> None of your issues have anything to do with the C or C++ languages,
> but with non-standard extensions and third party libraries. Your best
> bet is the Borland support groups.



thanks for your polite answer





 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
CPP builder 6 and MySQL with or without VCL ? Lotfi C++ 4 12-28-2008 10:17 PM
C++ --ContourCube VCL for Borland C++ Builder Xproblem C++ 0 10-08-2005 05:05 PM
VCL HELP! C++ Builder axdntprone@yahoo.com C++ 2 12-22-2004 12:34 AM
Method inlined in source1.cpp and called in source2.cpp Alex Vinokur C++ 7 11-15-2004 09:14 PM
What is better /standard for creating files. a cpp file with header or cpp and seperate file for header DrUg13 C++ 1 02-10-2004 09:20 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57