Case q10 · version-scope
We plan to move to Oracle 23ai on Azure VMs and use the new SQL BOOLEAN type. Anything to watch in a later hop to Azure SQL?
Expected: BOOLEAN maps to bit in SQL Server (SSMA); also note LogMiner/CDC tooling limits for BOOLEAN if recorded; scoped to 23ai+.
No tools
larger model · 1 turn · 28 s · 16.5k in / 2.8k out✓ verdict ✗ grounded ✓ cited
Grader: Correct mapping; from-memory claims (sort order, COMPATIBLE) not retrieved
Answer
Verdict: Using BOOLEAN on 23ai is fine, but Azure SQL (Database and Managed Instance) has no native BOOLEAN column type. As far as I know that is still true for SQL Server 2025, but check before you commit. Every BOOLEAN column becomes BIT, and any SQL that treats boolean expressions as values will need rewriting. Write your 23ai code in a portable style now so the later move is a simple type mapping and not a code refactor.
What breaks or changes on the Azure SQL side
- Type mapping.
BOOLEAN→BIT(0/1/NULL). The data converts cleanly, and T-SQL also accepts the strings'TRUE'/'FALSE'as BIT values. Oracle's other accepted inputs ('yes'/'no','on'/'off','t'/'f') don't convert, so fix any loaders that rely on them. - Bare predicates. 23ai lets you write
WHERE is_active,WHERE NOT is_activeandCASE WHEN flag THEN. T-SQL requiresWHERE is_active = 1. - Booleans as values. 23ai lets you write
SELECT a > b AS flagorSET flag = (x IS NULL). T-SQL doesn't; you needCASE WHEN a > b THEN 1 ELSE 0 END. IS [NOT] TRUE/FALSEtests and theTRUE/FALSEliterals. T-SQL supports neither, so rewrite them as= 1,= 0orIS NULLlogic.- Aggregates. Oracle's
BOOLEAN_AND_AGGandBOOLEAN_OR_AGGhave no T-SQL equivalent.MIN,MAXandSUMalso reject BIT directly, so you needMAX(CAST(flag AS int)). - Text output.
TO_CHAR(bool)and concatenation produce'TRUE'/'FALSE'in Oracle, but'1'/'0'from BIT in T-SQL. Check reports, CSV exports and string comparisons. - NULL sort order. Oracle puts NULLs last in ascending order; SQL Server puts them first. This affects nullable flag columns used in
ORDER BY. - Tools and connectors. Confirm that your SSMA for Oracle version supports 23ai as a source and maps SQL BOOLEAN (PL/SQL BOOLEAN has long been supported). Do the same for your ADF, DMS or Oracle connector version. Don't assume 23ai-only types pass through; test with a sample table early.
- Clients. Usually low risk: JDBC
getBoolean()and .NETboolboth work with BIT. The exceptions are raw SQL strings with Oracle literals and ORM dialect settings.
Recommendations for the 23ai phase
- Always compare explicitly (
flag = TRUE). Don't select predicates as values or use the boolean aggregates. That keeps the later rewrite mechanical (TRUE→1). - If a quick Azure SQL move is likely, consider
NUMBER(1)withCHECK (col IN (0,1))for new tables. It maps 1:1 to BIT and needs no code changes. - SQL BOOLEAN needs
COMPATIBLEset to 23 or higher on the Oracle side, and that setting can't be reversed. - Add a lint or grep rule to find the patterns above so the conversion work stays measurable.
Sources
- Oracle 23ai data types (BOOLEAN): https://docs.oracle.com/en/database/oracle/oracle-database/23/sqlrf/Data-Types.html
- T-SQL
bit: https://learn.microsoft.com/en-us/sql/t-sql/data-types/bit-transact-sql - SSMA for Oracle: https://learn.microsoft.com/en-us/sql/ssma/oracle/sql-server-migration-assistant-for-oracle-oracletosql
I wrote this from memory without looking anything up, so check the SSMA/ADF support for 23ai and the current Azure SQL type list before you plan around them.
Keyword search
larger model · 1 turn · 12 s · 18.9k in / 1.2k out✓ verdict ✓ grounded ✗ cited
Grader: BOOLEAN→bit via SSMA, 23ai scope; claims cite passages
8 keyword-search passages
feature_boolean-23aiscore 25.893mapping_data-pump--azure-dmsscore 21.008mapping_boolean-23ai--azure-pg-flexscore 18.817feature_stored-outlinesscore 16.512mapping_vector-datatype--azure-sql-dbscore 16.331mapping_boolean-23ai--azure-sql-dbscore 16.087mapping_oracle-streams--azure-dmsscore 15.911mapping_stored-outlines--azure-sql-dbscore 15.83
Answer
Verdict: Yes. Azure SQL has no boolean column type, so every 23ai BOOLEAN you adopt becomes bit in the later hop. Any SQL or PL/SQL that uses a boolean directly as a condition will have to be rewritten.
What to watch
- The type mapping: SSMA converts
BOOLEANtobit, which stores 0, 1 or NULL. Storage works out the same, so the column mapping itself is fine. [6] - Conditions must be rewritten: In SQL Server a
bitcan't stand alone as a condition. EveryWHERE is_activestyle expression has to become a comparison such asWHERE is_active = 1. [6] - NULL handling carries over: NULL bits behave like Oracle's UNKNOWN, so NULL semantics carry over. [6]
- PL/SQL boolean variables: These must also become
bitcomparisons in T-SQL. [6] - CHECK constraints and defaults: Review any that use
TRUE/FALSEliterals. [6] - Alternate spellings: 23ai lets applications write yes/no, on/off, t/f, y/n and 1/0 into a
BOOLEANcolumn, and treats any non-zero number as TRUE. [1] My sources don't say whetherbitaccepts those same inputs. If your application relies on them, assume the inputs will need translating and test it. - Converting old flag columns: If you plan to turn existing
CHAR(1)orNUMBER(1)flag columns intoBOOLEANon 23ai, you have to decide which columns and string conventions to convert. [1] Do that work once, knowing it all ends up asbiton Azure SQL anyway. - Migration tooling: For Oracle to Azure SQL, Azure DMS only supports offline migration, is in preview, and runs through SSMA. There is no online (continuous sync) path, so plan a downtime window. For ongoing replication, use GoldenGate, Fabric mirroring or Data Factory. [2][7]
For comparison: If the later hop were to Azure Database for PostgreSQL instead, BOOLEAN would map to PostgreSQL's native boolean with no changes (Ora2Pg does this by default). [3]
Sources: The passages I was given don't include URLs, so I can't cite links. Passage [1] notes that Oracle's 23ai documentation now redirects to the 26ai reference pages.
Sanity Context · GROQ
smaller model · 5 turns · 28 s · 43.6k in / 1.9k out✓ verdict ✓ grounded ✗ cited
Grader: bit mapping, scoped 23ai/26ai, SSMA source cited
4 tool calls
- initial_context on groq · 4,126 chars back
- groq_query on groq · 713 chars back
*[_type=="oracleFeature" && name match "*BOOLEAN*"]{_id, name, slug, category, introducedIn, deprecatedIn, desupportedIn, oracleReplacement, reviewStatus} - groq_query on groq · 4,199 chars back
*[_type=="mapping" && oracleFeature._ref=="feature_boolean-23ai"]{ _id, fidelity, effort, rationale, appliesToOracleVersions, "azureTarget": azureTarget->{name, slug, service, tierNotes}, "sources": sources[]->{title,url,publisher}, "caveats": *[_type=="caveat" && references(^._id)]{ severity, statement, appliesTo, firsthand, "evidence": evidence->{title,url,publisher} } } - groq_query on groq · 505 chars back
*[_type=="dispute" && (claimA._ref=="caveat_boolean-ssma-bit" || claimB._ref=="caveat_boolean-ssma-bit")]{title, whatDisagrees, resolution, "claimA": claimA->statement, "claimB": claimB->statement, "resolvedBy": resolvedBy->{title,url}}
Answer
No dispute on this. Here's the answer:
Verdict: Yes — the SQL BOOLEAN type (23ai) does not survive a later hop to Azure SQL Database with exact fidelity; it degrades to a bit column, and boolean expressions used as predicates will need rewriting.
On Azure VMs today (23ai): No mapping is recorded in the dataset for "Oracle on Azure VM" specifically for this feature — since you'd still be running native Oracle 23ai, the BOOLEAN type behaves as documented by Oracle, and no caveat/mapping entry exists for that target in this dataset.
Later hop to Azure SQL Database (fidelity: partial, effort: S, applies to Oracle 23ai/26ai):
- SQL Server has no native boolean column type. Microsoft's SSMA for Oracle maps Oracle
BOOLEANtobit(stores 0, 1, or NULL) for arguments, return values, and local variables. Storage is equivalent, and three-valued NULL logic mirrors Oracle's UNKNOWN, but everyWHERE is_activestyle predicate must be rewritten as an explicit comparison (e.g.,= 1), sincebitcannot be used as a standalone predicate. — SSMA for Oracle: Project Settings (Type Mapping) (Microsoft), severity: minor.
Note: No mapping specific to Azure SQL Managed Instance was found for this feature in the dataset — only Azure SQL Database is covered.
Aside (if a PostgreSQL hop is ever on the table instead): the dataset shows Azure Database for PostgreSQL Flexible Server gives exact fidelity — Postgres has a native boolean type usable directly as a predicate, and Ora2Pg can even promote legacy NUMBER(1)/CHAR(1) flags to boolean. — PostgreSQL documentation: Boolean type, Ora2Pg documentation (community).
No disputes are recorded on this point in the dataset.
GROQ + Knowledge Base
smaller model · 7 turns · 35 s · 59.3k in / 2.4k out✓ verdict ✓ grounded ✗ cited
Grader: bit mapping, 23ai/26ai scope, cited quotes; flags gaps
6 tool calls
- initial_context on groq · 4,126 chars back
- initial_context on kb · 7,679 chars back
- groq_query on groq · 751 chars back
*[_type=="oracleFeature" && (name match "*boolean*" || slug.current match "*boolean*")]{_id, name, slug, category, introducedIn, deprecatedIn, desupportedIn, oracleReplacement, reviewStatus} - groq_query on groq · 3,164 chars back
*[_type=="mapping" && oracleFeature._ref=="feature_boolean-23ai"]{ _id, fidelity, effort, rationale, appliesToOracleVersions, "azureTarget": azureTarget->{name, slug, service}, "sources": sources[]->{title, url}, "caveats": *[_type=="caveat" && references(^._id)]{ severity, statement, appliesTo, firsthand, "evidence": evidence->{title, url, publisher} } } - groq_query on groq · 703 chars back
*[_type=="dispute" && (claimA->statement match "*boolean*" || claimB->statement match "*boolean*" || title match "*boolean*" || title match "*Boolean*")]{title, whatDisagrees, resolution, "claimA": claimA->{statement, evidence->{title,url}}, "claimB": claimB->{statement, evidence->{title,url}}, "resolvedBy": resolvedBy->{title,url}} - groq_query on groq · 307 chars back
*[_type=="pattern" && references("mapping_boolean-23ai--azure-sql-db")]{title, problem}
Answer
No dispute or pattern on this topic. That's sufficient evidence to answer.
Verdict
Moving BOOLEAN columns from Oracle 23ai to Azure SQL Database later is partial fidelity — storage works, but predicate syntax breaks and must be rewritten.
Scoped facts
- Feature: SQL BOOLEAN datatype, introduced in Oracle 23ai. Your planned Oracle 23ai/Azure VM deployment is in scope for this mapping (
appliesToOracleVersions: 23ai, 26ai). - Oracle 23ai on Azure VM (first hop): no caveat/mapping issue recorded — this is native Oracle running on IaaS, so the BOOLEAN type behaves as on any Oracle 23ai instance. The dataset has no separate mapping entry for that leg (it's not a cross-platform hop).
- Later hop → Azure SQL Database: fidelity = partial, effort = S.
- Rationale: "SQL Server has no boolean column type; SSMA maps BOOLEAN to bit, which stores 0, 1 or NULL and cannot appear as a standalone predicate. Storage is equivalent, but every WHERE is_active style expression must be rewritten as a comparison with 1, and three-valued logic on NULL bits mirrors Oracle's UNKNOWN." — SSMA for Oracle: Project Settings (Type Mapping)
- Caveat (minor, appliesTo 23ai/26ai): "SSMA maps Oracle BOOLEAN to bit for arguments, return values and local variables (bit stores 0, 1 or NULL), so boolean expressions used directly as predicates or in SELECT lists must be rewritten as comparisons." — same source, publisher Microsoft.
- What to watch, concretely: any PL/SQL or SQL code using a boolean column/variable directly as a predicate (e.g.,
WHERE is_active) will need rewriting to an explicit comparison (WHERE is_active = 1) once on Azure SQL DB. NULL-bit semantics do carry over Oracle's three-valued (UNKNOWN) logic, so that behavior itself isn't lost — only the bare-predicate syntax is.
Gaps
- The dataset has no mapping entry for Azure SQL Managed Instance specifically for this feature — only Azure SQL Database and Azure Database for PostgreSQL Flexible Server are covered. If your later hop targets Managed Instance rather than Azure SQL Database, there's no evidence on file confirming the same SSMA bit-mapping behavior applies, though the source cited (SSMA Type Mapping page) is not DB/MI-specific in its title.
- No dispute or how-to pattern in the knowledge base touches this specific BOOLEAN-to-bit conversion, so no conflicting claims to report.