AbsaOSS / AbsaOSS/cobrix

Getting BDW header error convert Ebcdic file to ascii

未關閉
#589 6 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Scala
星號
170
分支
96
平均合併
57 分鐘
30 天內合併 PR
2

描述

I have a use-case where i have a variable block Cobol file and need to parse the file in ASCII format using the Cobrix dependencies. I am using below Cobrix dependency jar file.
spark-cobol_2.12-2.6.3.jar
cobol-parse_2.12-2.6.3.jar
scodec-core_2.12-1.10.3.jar
scodec-bite_2.12-1.1.4.jar
antlr-runtime-4.8.ar

But i am getting error- BDW headers contain non-zero values where zeros are expected(check rdw_big_endian flag. Header:125,149,0,0, offset:0..

Even i have tried other option like - rdw_adjustment -4 , is_bdw_big_endian is true and is_rdw_big_endian is true but getting same header error.

So how header is generated in the ebcdic file and what could be the solution of this issue

Below is my data frame to read the file

val df = spark
.read
.format("cobol")
.option("copybook_contents", copybook)
.option("record_format", "VB")
.option("copybook", "copybook")
.option("is_bdw_big_endian", "false")
.option("is_rdw_big_endian", "false")
.option("schema_retention_policy", "collapse_root")
.load("data")

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。