String concated from right

From: Bolla Sándor (bolla_at_mkmcom.hu)
Date: 03/17/05


Date: Thu, 17 Mar 2005 17:44:33 +0100

Hi folks,

I have a strange problem, I want to copy some records from a FoxPro
database into a MSSQL database using ADO (ODBC) and D7, I wrote the code
but in some cases I get the ODBC error that the string was concatenated
from the right (something like this in hungarian language), but the
record was not saved in the MSSQL table. What could cause the problem?
is there a limitation of ODBC using streams, or delphi limitations on
strings?

I have a sample code: qFox and ADOQ are TADOQuery components of a kind:

var ss : TStream;
...
with ADOQ do begin
...
  ss := qFox.CreateBlobStream(qFox.FieldByName('memo'), bmRead);
  ss.Seek(0,soFromBeginning);
  Parameters.ParamByName('MEMO').LoadFromStream(ss, ftString);
..
ExecSQL;

bye
Sanyi



Relevant Pages

  • encoding problems with pymssql / win
    ... I have a strange problem: some code that fetches queries from an mssql database works fine under Idle but the very same code run from a shell window obtains its strings garbled as if the encoding codepage was modified. ... This occurs only when using pymssql to connect; if I connect through odbc this problem vanishes. ... machine, while the server machine has windows server 2003 + sqlserver2k, locale is fr_CH. ...
    (comp.lang.python)
  • Re: ODBC Connections
    ... Microsoft SQL server using a 3rd party ODBC driver. ... I can import data/tables from the MSSQL database. ... No idea what a live ODBC connection would do to performance, ...
    (comp.databases.filemaker)
  • Re: python to mssql
    ... Python works with MSSQL. ... You can go through ODBC, ADO, ... etc. to work with data in MSSQL database. ...
    (comp.lang.python)