On 9/26/06, Warren Young <mysqlpp@stripped> wrote:
>
> Jim Langston wrote:
> > SetOffset( "Race", *reinterpret_cast<unsigned int*>( &Base->Race
> ) );
>
> *RETCH*
>
> The need for reinterpret_cast alone is a deal-killer for me. This is
> one of the reasons I don't like to use raw C.
Yes, I looked and looked but couldnt' find a better solution for this. Race
is an enum.
> if ( ! PlayerTable.LoadTable( "Name", "Serpardum" ) )
> > std::cout << "Serpardum not found" << std::endl;
> > else
> > PlayerTable.OutputMapByColumn();
> >
> > PlayerTable >> Player;
>
> I guess I'm not studying your code closely enough, because I don't see
> what you're doing here that can't be done with SSQLS.
I asked before on, I believe, this list for the ability to go directly to my
table and was told it couldn't be done. I asked specifically if MySQL++ had
the ability to load directly into a class/structure and was told no. You
are telling me I can do this with SSQLS?
> I also allow
>
> PlayerTable << Player;
>
> to set the fields in the table so I can .update() or .insert() them.
The only difference between this and SSQLS is that you are inserting
into a table object, whereas you insert into a query object with SSQLS.
Six of one, half a dozen of the other as far as I can tell.
Player is my own class with it's own variables. An instance that's being
used by the application. I was told I couldnt' do this in MySQL++
> How hard would it be to implement this in MySQL++ if it even should?
It seems to me that you're trying to reinvent SSQLS. What isn't clear
to me yet is that you've done it better.