Skip to content

DB2 Iseries 4 Issue casting date from decimal

I have decimal fields (DECIMAL(8,0)) that contain dates as 5122019 for may 12th 2019 and 12122020 as December 12th 2020. I’ve tried several ways to convert including DATE(TIMESTAMP_FORMAT(CHAR(decimalField),’MMDDYYYY’)) but they return null. What’s the best way to do this with a decima…

Nested JSON parsing using Snowflake SQL

I have a problem parsing a certain nested JSON structure in Snowflake. The problem here is the usage of special characters like @ and # for example for some of the elements. Those characters prevents me from using simple dot notation when trying to access some of the elements without resourcing to a really co…

Need to exclude the data which have multiple records

I am trying to build a query to get the the unique data from data base, but here the problem I’m facing there is some records which have multiple records and those records have null and not null values.. I have to pick the value of the record which have the latest created date and it’s data is nul…

ZPL Loop function

I’m looking for any idea can help to setup a ZPL label using a loop function to gather the information from SQL Table and print them on a label I have a Table in SQL DB has those fields Product QTY ORDER_NR for example: I have the order 111022 has 3 items lines 50023 50037 50099 And I want to