dbTalk Databases Forums  

SSQLS compilation errors when KEYS = 0

mailing.database.mysql-plusplus mailing.database.mysql-plusplus


Discuss SSQLS compilation errors when KEYS = 0 in the mailing.database.mysql-plusplus forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Stephen Povilaitis
 
Posts: n/a

Default SSQLS compilation errors when KEYS = 0 - 01-17-2006 , 11:59 AM






------_=_NextPart_001_01C61B8F.B71BCE88
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Most exalted ones,

I'm using gcc 3.4.3 on Redhat Enterprise Linux with MySQL 4.0.1 and =
mysql++ 2.0.4.

I'm having some issues trying to use SSQLS that I would appreciate some =
help with.

If I try to use the following code from the manual I get errors:

using namespace std;
using namespace mysqlpp;

sql_create_5(stock, 0, 0, // KEYS value is 0
string, item,
int, num, =20
double, weight, =20
double, price, =20
mysqlpp:ate, date)

When compiling I get these errors:

:33: error: expected primary-expression before ',' token
33: error: `value' undeclared (first use this function)
33: error: `NUM' undeclared (first use this function)
33: error: there are no arguments to `sql_compare_type_def_NUM' that =
depend on a template parameter, so a declaration of =
`sql_compare_type_def_NUM' must be available
33: error: (if you use `-fpermissive', G++ will accept your code, but =
allowing the use of an undeclared name is deprecated)
33: error: expected primary-expression before ',' token
33: error: `field' undeclared (first use this function)
33: error: `NUM' undeclared (first use this function)
33: error: there are no arguments to `sql_compare_type_def_NUM' that =
depend on a template parameter, so a declaration of =
`sql_compare_type_def_NUM' must be available
33: error: expected primary-expression before ',' token
33: error: `NUM' undeclared (first use this function)
33: error: there are no arguments to `sql_compare_type_defe_NUM' that =
depend on a template parameter, so a declaration of =
`sql_compare_type_defe_NUM' must be available
33: instantiated from here
:33: error: `sql_compare_type_def_NUM' undeclared (first use this =
function)
33: instantiated from here
33: error: `sql_compare_type_def_NUM' undeclared (first use this =
function)
33: instantiated from here
33: error: `sql_compare_type_defe_NUM' undeclared (first use this =
function)

Yet if I change the SSQLS Macro call to:

sql_create_5(stock, 1, 0, // KEYS value is 1st field
string, item,
int, num, =20
double, weight, =20
double, price, =20
mysqlpp:ate, date)

everything works fine.

What is going on here? According to the manual 0 should always work for =
the KEYS and INITPARMS fields.

thanks in advance,

Steve Povilaitis



------_=_NextPart_001_01C61B8F.B71BCE88--

Reply With Quote
  #2  
Old   
Warren Young
 
Posts: n/a

Default Re: SSQLS compilation errors when KEYS = 0 - 01-17-2006 , 02:22 PM






Stephen Povilaitis wrote:
Quote:
Most exalted ones,
Yes, O lowly supplicant?

Quote:
sql_create_5(stock, 0, 0, // KEYS value is 0
The manual is wrong. I don't remember where we left the issue, but we
discussed it here only a month or so ago.

--
MySQL++ Mailing List
For list archives: http://lists.mysql.com/plusplus
To unsubscribe: http://lists.mysql.com/plusplus?unsu...ie.nctu.edu.tw



Reply With Quote
Reply




Thread Tools
Display Modes

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.