Param binding in ODAC 6.90.0.55

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
azabluda
Posts: 35
Joined: Thu 10 Sep 2009 14:45

Param binding in ODAC 6.90.0.55

Post by azabluda » Wed 27 Jan 2010 20:59

ODAC 6.90.0.55, bcb 2009, UseUnicode=true, OCIUnicode = true, Direct Mode, ORACLE 10.2.0.1, Charset=UTF-8

DDL script

Code: Select all

CREATE TABLE bt_bugs_filters (
   id                         NUMBER NOT NULL PRIMARY KEY,
   name                           VARCHAR2(30) NOT NULL,
   folder_id                      NUMBER,
   settings                       VARCHAR2(150)
)
We observed a number of bugs.

BUG #1. The following code worked in version 6.90.0.52 but fails on 6.90.0.55:

Code: Select all

void __fastcall TForm1::bindNullBTNClick(TObject *Sender)
{
   boost::scoped_ptr session(new TOraSession(0));
   session->Options->UseUnicode = true;
   session->Options->Net = true;
   session->Server = "oraxp:1521:pvs";
   session->Username = "pvs_c";
   session->Password = "ic1";
   session->ConnectMode = cmNormal;
   session->Connect();

   boost::scoped_ptr query(new TOraQuery(0));
   query->Session = session.get();

   // DELETE
   query->SQL->Text = "delete from bt_bugs_filters where id = 111";
   query->ExecSQL();

   // INSERT
   query->SQL->Text = "insert into bt_bugs_filters (id,name,folder_id) values (:id, :name, :folder_id)";
   query->Prepare();
   query->Params->ParamByName("id")->Value = 111.0;
   query->Params->ParamByName("name")->Value = UnicodeString("hello");
   query->Params->ParamByName("folder_id")->Value = Null();
   query->ExecSQL(); // Commit();
}
BUG #2. If instead of Null() I provide a value for :folder_id

Code: Select all

   query->Params->ParamByName("folder_id")->Value = 220.0;
Then it goes through, but in the database I get only garbage

Code: Select all

SQL> SELECT * FROM bt_bugs_filters
ID                     NAME                           FOLDER_ID              SETTINGS                                                                                                                                               
---------------------- ------------------------------ ---------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------ 
111                    �                             -0.00...004294966589                                                                                                                                                        
These bugs are critical. Thank you for a quick reply.

Alexander

azabluda
Posts: 35
Joined: Thu 10 Sep 2009 14:45

Post by azabluda » Wed 03 Feb 2010 18:46

Sorry guys. But one week is really not an acceptable response time. We paid money ACCURATELY IN TIME to get the product, and we count at least on some reaction once we encounter a blocking issue.

If there's something unclear in my previous post, please request for addition information. Assigning a string parameter causes corruption of all following parameters in direct mode, OCIUnicode=true, UseUnicode=true.

Did you manage (try?) to reproduce the problem?

Thanks,
Alexander

Falcon
Devart Team
Posts: 19
Joined: Tue 02 Feb 2010 10:40

Post by Falcon » Thu 04 Feb 2010 12:57

Thank you for information. We have reproduced the problem. The investigation of the problem is in progress. As soon as we solve the problem we will let you know.

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 08 Feb 2010 12:47

We have fixed this problem. The fix will be included in the next build of ODAC.

Post Reply