Valentina Client 2.0 - C++

David Nock davidn at accessitsoftware.com
Tue Mar 9 12:54:40 CST 2004



Hi Ruslan,

I'll reply to my own email as I found the problem.

VDK_Cursor has 'ExecuteSQL' and VDK_Database has 'SqlExecute'.
I've changed things around to use this and all is well.

Cheers
Dave

> 
> Hi Ruslan,
> 
> I tried this but it doesn't compile as ExecuteSQL isn't a member of
> VDK_Database. 
> 
> Anyway I changed it to:
> 
> bool MyFrame::RunQuery(wxString szQuery)
> {
>  VDK_Cursor* mCursor;
>  ulong err = 0;
>  mCursor = new VDK_Cursor(myDB);
>  try
>  {
>      const char* query = "CREATE TABLE _Preferences(fldBoolean boolean)"
>      err = mCursor->ExecuteSQL( query );
>  }
>  catch( xFBL_Exception& e )
>  {
>      err = e.GetErrorCode();
>      wxMessageBox(wxString::Format("Error executing SQL - [%ld]", err));
>  }
> 
>  ForgetObject( mCursor );
>  return (err == 0);
> }
> 
> This is into a pre-existing database. I also now have the server running
> from the dos prompt to see the debug info.
> 
> The error returned is 600 - 'Expected key word SELECT'. Why when creating a
> table??
> 
> Also, in the debug info shown in the dos prompt, it shows as 2.0a59 but the
> properties of the server.dll show as a60.
> 
> Cheers
> Dave
> 
> **********************
> David Nock
> Senior Developer
> Access-It Software Ltd
> **********************
> 
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina
> 

**********************
David Nock
Senior Developer
Access-It Software Ltd
**********************





More information about the Valentina mailing list