Using the CRUD database and files from the knowledge base link
(http://
kb.4d.com/search/assetid=76084), I queried for the Company.Name and
Company. Status fields (alpha 100 and Boolean, respectively). The
values for Status appear to be false or 0, but upon verification in
4D, the Status value for the companies “Benchmark Breakers and Coding
Crackers” is set to true. As this table and contents were created from
the create.php file, I haven’t done anything different to the table or
values.
Expected results:
Query Boolean Test - SELECT Name, status FROM Company
Company Name Status
Acme, Inc.
Alpha Beta
Aardvark Advocates
Benchmark Breakers 1
Coding Crackers 1
Actual results:
Query Boolean Test - SELECT Name, status FROM Company
Company Name Status
Acme, Inc.
Alpha Beta
Aardvark Advocates
Benchmark Breakers 0
Coding Crackers 0
Database results via Quick Report:
Name status
Acme, Inc. False
Alpha Beta False
Aardvark Advocates False
Benchmark Breakers True
Coding Crackers True
Of note, if the query is modified with the SQL function CAST(), the
results appear as expected.
Query Boolean Test - SELECT Name, CAST(status AS VARCHAR) AS Status
FROM Company
Company Name Status
Acme, Inc.
Alpha Beta
Aardvark Advocates
Benchmark Breakers true
Coding Crackers true
Web server: Apache 2.2.17, PHP 5.3.3 (MSVC9 (Visual C++ 2008)) on a
Windows Server 2003 Standard Edition Service Pack 2. I'm assuming the
version of PDO is 0.3 even though a phpinfo() shows 0.1 alpha as I
obtained the .dll from .zip link at
http://forums.4d.fr/Post/FR/3549301/1/3601455#3601455
4D: v12.1 build 82774 on a Windows Server 2008 Standard Edition and
Windows Seven Business Edition, 64-bit