Detail:
DataStage โดยเฉพาะ Server Edition จะมีปัญหากับการคำนวณตัวเลขที่มีค่ามหาศาล ไม่ว่าจะตัวเลขนั้นจะเป็น integer หรือ decimal ก็ตาม เท่าที่เคยเจอเคสก็คือหลักหมื่นล้าน 1ตามด้วยศูนย์ 10 ตัวขึ้นไป ถึงแม้ว่าจะกำหนด precision และ scale ของ decimal ใน table definition อย่างถูกต้องแล้วก็ตาม ผลลัพธ์ที่ได้จากการบวก ลบ คูณ หาร ก็ยังคงผิดเพี้ยนไปหมด เช่น ทศนิยมหายไป ตัวเลขหลักท้ายๆหายไป เป็นต้น
Action:
ใช้ String Math Function แทนเครื่องหมาย + - * / ธรรมดา ดังนี้
- SADD แทน +
- SSUB แทน -
- SMUL แทน *
- SDIV แทน /
มันขึ้นสีแดงเพราะ DS ไม่รู้จัก function นี้ ถ้าไม่ซีเรียสก็ปล่อยมันไป ถ้าอยากให้ดูเรียบร้อยก็ไปเพิ่ม function เหล่านี้ใน DSParams ซึ่งเป็นไฟล์ที่เก็บชื่อ function, routine และตัวแปรต่างๆ ของ DataStage
1 comment:
If you want to get the best Plans....for converting your car to run as Hybrid Hydrogen and save hundreds of dollars on your fuel expense there is a mechanic form Detroit that explains how he tested these car kits conversions. Just go to Google and search for "http://tophhogascar.com".
Post a Comment