FR [ 2143573 ] Enhancements to financial reporting
This commit is contained in:
parent
0f1bf88326
commit
ba3130cb9c
|
@ -246,6 +246,19 @@ public interface I_AD_Column
|
|||
*/
|
||||
public int getFieldLength();
|
||||
|
||||
/** Column name FormatPattern */
|
||||
public static final String COLUMNNAME_FormatPattern = "FormatPattern";
|
||||
|
||||
/** Set Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern);
|
||||
|
||||
/** Get Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern();
|
||||
|
||||
/** Column name Help */
|
||||
public static final String COLUMNNAME_Help = "Help";
|
||||
|
||||
|
|
|
@ -205,6 +205,19 @@ public interface I_AD_PrintFormatItem
|
|||
*/
|
||||
public String getFieldAlignmentType();
|
||||
|
||||
/** Column name FormatPattern */
|
||||
public static final String COLUMNNAME_FormatPattern = "FormatPattern";
|
||||
|
||||
/** Set Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern);
|
||||
|
||||
/** Get Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern();
|
||||
|
||||
/** Column name ImageIsAttached */
|
||||
public static final String COLUMNNAME_ImageIsAttached = "ImageIsAttached";
|
||||
|
||||
|
|
|
@ -236,6 +236,32 @@ public interface I_PA_ReportColumn
|
|||
*/
|
||||
public String getElementType();
|
||||
|
||||
/** Column name Factor */
|
||||
public static final String COLUMNNAME_Factor = "Factor";
|
||||
|
||||
/** Set Factor.
|
||||
* Scaling factor.
|
||||
*/
|
||||
public void setFactor (String Factor);
|
||||
|
||||
/** Get Factor.
|
||||
* Scaling factor.
|
||||
*/
|
||||
public String getFactor();
|
||||
|
||||
/** Column name FormatPattern */
|
||||
public static final String COLUMNNAME_FormatPattern = "FormatPattern";
|
||||
|
||||
/** Set Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern);
|
||||
|
||||
/** Get Format Pattern.
|
||||
* The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern();
|
||||
|
||||
/** Column name GL_Budget_ID */
|
||||
public static final String COLUMNNAME_GL_Budget_ID = "GL_Budget_ID";
|
||||
|
||||
|
|
|
@ -455,6 +455,23 @@ public class X_AD_Column extends PO implements I_AD_Column, I_Persistent
|
|||
return ii.intValue();
|
||||
}
|
||||
|
||||
/** Set Format Pattern.
|
||||
@param FormatPattern
|
||||
The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern)
|
||||
{
|
||||
set_Value (COLUMNNAME_FormatPattern, FormatPattern);
|
||||
}
|
||||
|
||||
/** Get Format Pattern.
|
||||
@return The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern ()
|
||||
{
|
||||
return (String)get_Value(COLUMNNAME_FormatPattern);
|
||||
}
|
||||
|
||||
/** Set Comment/Help.
|
||||
@param Help
|
||||
Comment or Hint
|
||||
|
|
|
@ -498,6 +498,23 @@ public class X_AD_PrintFormatItem extends PO implements I_AD_PrintFormatItem, I_
|
|||
return (String)get_Value(COLUMNNAME_FieldAlignmentType);
|
||||
}
|
||||
|
||||
/** Set Format Pattern.
|
||||
@param FormatPattern
|
||||
The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern)
|
||||
{
|
||||
set_Value (COLUMNNAME_FormatPattern, FormatPattern);
|
||||
}
|
||||
|
||||
/** Get Format Pattern.
|
||||
@return The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern ()
|
||||
{
|
||||
return (String)get_Value(COLUMNNAME_FormatPattern);
|
||||
}
|
||||
|
||||
/** Set Image attached.
|
||||
@param ImageIsAttached
|
||||
The image to be printed is attached to the record
|
||||
|
|
|
@ -586,6 +586,47 @@ public class X_PA_ReportColumn extends PO implements I_PA_ReportColumn, I_Persis
|
|||
return (String)get_Value(COLUMNNAME_ElementType);
|
||||
}
|
||||
|
||||
/** Factor AD_Reference_ID=53285 */
|
||||
public static final int FACTOR_AD_Reference_ID=53285;
|
||||
/** Thousand = k */
|
||||
public static final String FACTOR_Thousand = "k";
|
||||
/** Million = m */
|
||||
public static final String FACTOR_Million = "m";
|
||||
/** Set Factor.
|
||||
@param Factor
|
||||
Scaling factor.
|
||||
*/
|
||||
public void setFactor (String Factor)
|
||||
{
|
||||
|
||||
if (Factor == null || Factor.equals("k") || Factor.equals("m")); else throw new IllegalArgumentException ("Factor Invalid value - " + Factor + " - Reference_ID=53285 - k - m"); set_Value (COLUMNNAME_Factor, Factor);
|
||||
}
|
||||
|
||||
/** Get Factor.
|
||||
@return Scaling factor.
|
||||
*/
|
||||
public String getFactor ()
|
||||
{
|
||||
return (String)get_Value(COLUMNNAME_Factor);
|
||||
}
|
||||
|
||||
/** Set Format Pattern.
|
||||
@param FormatPattern
|
||||
The pattern used to format a number or date.
|
||||
*/
|
||||
public void setFormatPattern (String FormatPattern)
|
||||
{
|
||||
set_Value (COLUMNNAME_FormatPattern, FormatPattern);
|
||||
}
|
||||
|
||||
/** Get Format Pattern.
|
||||
@return The pattern used to format a number or date.
|
||||
*/
|
||||
public String getFormatPattern ()
|
||||
{
|
||||
return (String)get_Value(COLUMNNAME_FormatPattern);
|
||||
}
|
||||
|
||||
public I_GL_Budget getGL_Budget() throws Exception
|
||||
{
|
||||
Class<?> clazz = MTable.getClass(I_GL_Budget.Table_Name);
|
||||
|
|
|
@ -220,7 +220,7 @@ public class DataEngine
|
|||
+ "pfi.IsMinCalc,pfi.IsMaxCalc, " // 18..19
|
||||
+ "pfi.isRunningTotal,pfi.RunningTotalLines, " // 20..21
|
||||
+ "pfi.IsVarianceCalc, pfi.IsDeviationCalc, " // 22..23
|
||||
+ "c.ColumnSQL " // 24
|
||||
+ "c.ColumnSQL, COALESCE(pfi.FormatPattern, c.FormatPattern) " // 24, 25
|
||||
+ "FROM AD_PrintFormat pf"
|
||||
+ " INNER JOIN AD_PrintFormatItem pfi ON (pf.AD_PrintFormat_ID=pfi.AD_PrintFormat_ID)"
|
||||
+ " INNER JOIN AD_Column c ON (pfi.AD_Column_ID=c.AD_Column_ID)"
|
||||
|
@ -291,6 +291,8 @@ public class DataEngine
|
|||
boolean IsPrinted = "Y".equals(rs.getString(15));
|
||||
int SortNo = rs.getInt(16);
|
||||
boolean isPageBreak = "Y".equals(rs.getString(17));
|
||||
|
||||
String formatPattern = rs.getString(25);
|
||||
|
||||
// Fully qualified Table.Column for ordering
|
||||
String orderName = tableName + "." + ColumnName;
|
||||
|
@ -550,6 +552,7 @@ public class DataEngine
|
|||
if (pdc == null || (!IsPrinted && !IsKey))
|
||||
continue;
|
||||
|
||||
pdc.setFormatPattern(formatPattern);
|
||||
columns.add(pdc);
|
||||
} // for all Fields in Tab
|
||||
}
|
||||
|
@ -782,7 +785,7 @@ public class DataEngine
|
|||
valueString = DisplayType.getDateFormat(pdc.getDisplayType(), m_language).format(value);
|
||||
valueString += PrintDataFunction.getFunctionSymbol(functions[f]);
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
valueString, DisplayType.String, false, pdc.isPageBreak()));
|
||||
valueString, DisplayType.String, false, pdc.isPageBreak(), pdc.getFormatPattern()));
|
||||
}
|
||||
else if (m_group.isFunctionColumn(pdc.getColumnName(), functions[f]))
|
||||
{
|
||||
|
@ -790,7 +793,7 @@ public class DataEngine
|
|||
m_group.getValue(group_pdc.getColumnName(),
|
||||
pdc.getColumnName(), functions[f]),
|
||||
PrintDataFunction.getFunctionDisplayType(functions[f], pdc.getDisplayType()),
|
||||
false, pdc.isPageBreak()));
|
||||
false, pdc.isPageBreak(), pdc.getFormatPattern()));
|
||||
}
|
||||
} // for all columns
|
||||
} // for all functions
|
||||
|
@ -827,7 +830,8 @@ public class DataEngine
|
|||
if (!rs.wasNull())
|
||||
{
|
||||
KeyNamePair pp = new KeyNamePair(id, KEY); // Key
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(), true, pdc.isPageBreak());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(),
|
||||
true, pdc.isPageBreak(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -837,7 +841,8 @@ public class DataEngine
|
|||
if (!rs.wasNull())
|
||||
{
|
||||
ValueNamePair pp = new ValueNamePair(id, KEY); // Key
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(), true, pdc.isPageBreak());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(),
|
||||
true, pdc.isPageBreak(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -855,7 +860,7 @@ public class DataEngine
|
|||
if (display != null && !rs.wasNull())
|
||||
{
|
||||
KeyNamePair pp = new KeyNamePair(id, display);
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -864,7 +869,7 @@ public class DataEngine
|
|||
if (display != null && !rs.wasNull())
|
||||
{
|
||||
ValueNamePair pp = new ValueNamePair(id, display);
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), pp, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -878,7 +883,7 @@ public class DataEngine
|
|||
if (!rs.wasNull())
|
||||
{
|
||||
boolean b = s.equals("Y");
|
||||
pde = new PrintDataElement(pdc.getColumnName(), new Boolean(b), pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), new Boolean(b), pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
else if (pdc.getDisplayType() == DisplayType.TextLong)
|
||||
|
@ -890,13 +895,13 @@ public class DataEngine
|
|||
long length = clob.length();
|
||||
value = clob.getSubString(1, (int)length);
|
||||
}
|
||||
pde = new PrintDataElement(pdc.getColumnName(), value, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), value, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
// fix bug [ 1755592 ] Printing time in format
|
||||
else if (pdc.getDisplayType() == DisplayType.DateTime)
|
||||
{
|
||||
Timestamp datetime = rs.getTimestamp(counter++);
|
||||
pde = new PrintDataElement(pdc.getColumnName(), datetime, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), datetime, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
else
|
||||
// The general case
|
||||
|
@ -915,10 +920,10 @@ public class DataEngine
|
|||
{
|
||||
String s = (String)obj;
|
||||
s = Msg.parseTranslation(pd.getCtx(), s);
|
||||
pde = new PrintDataElement(pdc.getColumnName(), s, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), s, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
else
|
||||
pde = new PrintDataElement(pdc.getColumnName(), obj, pdc.getDisplayType());
|
||||
pde = new PrintDataElement(pdc.getColumnName(), obj, pdc.getDisplayType(), pdc.getFormatPattern());
|
||||
}
|
||||
}
|
||||
} // Value only
|
||||
|
@ -972,14 +977,15 @@ public class DataEngine
|
|||
valueString = DisplayType.getDateFormat(pdc.getDisplayType(), m_language).format(value);
|
||||
valueString += PrintDataFunction.getFunctionSymbol(functions[f]);
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
valueString, DisplayType.String));
|
||||
valueString, DisplayType.String, pdc.getFormatPattern()));
|
||||
}
|
||||
else if (m_group.isFunctionColumn(pdc.getColumnName(), functions[f]))
|
||||
{
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
m_group.getValue(group_pdc.getColumnName(),
|
||||
pdc.getColumnName(), functions[f]),
|
||||
PrintDataFunction.getFunctionDisplayType(functions[f], pdc.getDisplayType())));
|
||||
PrintDataFunction.getFunctionDisplayType(functions[f],
|
||||
pdc.getDisplayType()),pdc.getFormatPattern()));
|
||||
}
|
||||
}
|
||||
} // for all functions
|
||||
|
@ -1006,14 +1012,15 @@ public class DataEngine
|
|||
if (!format.getTableFormat().isPrintFunctionSymbols()) // Translate Sum, etc.
|
||||
name = Msg.getMsg(format.getLanguage(), PrintDataFunction.getFunctionName(functions[f]));
|
||||
name += PrintDataFunction.getFunctionSymbol(functions[f]); // Symbol
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(), name.trim(), DisplayType.String));
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(), name.trim(),
|
||||
DisplayType.String, pdc.getFormatPattern()));
|
||||
}
|
||||
else if (m_group.isFunctionColumn(pdc.getColumnName(), functions[f]))
|
||||
{
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
m_group.getValue(PrintDataGroup.TOTAL,
|
||||
pdc.getColumnName(), functions[f]),
|
||||
PrintDataFunction.getFunctionDisplayType(functions[f], pdc.getDisplayType())));
|
||||
PrintDataFunction.getFunctionDisplayType(functions[f], pdc.getDisplayType()), pdc.getFormatPattern()));
|
||||
}
|
||||
} // for all columns
|
||||
} // for all functions
|
||||
|
@ -1064,13 +1071,14 @@ public class DataEngine
|
|||
{
|
||||
String title = "RunningTotal";
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
title, DisplayType.String, false, rt==0)); // page break
|
||||
title, DisplayType.String, false, rt==0, pdc.getFormatPattern())); // page break
|
||||
}
|
||||
else if (m_group.isFunctionColumn(pdc.getColumnName(), PrintDataFunction.F_SUM))
|
||||
{
|
||||
pd.addNode(new PrintDataElement(pdc.getColumnName(),
|
||||
m_group.getValue(PrintDataGroup.TOTAL, pdc.getColumnName(), PrintDataFunction.F_SUM),
|
||||
PrintDataFunction.getFunctionDisplayType(PrintDataFunction.F_SUM, pdc.getDisplayType()), false, false));
|
||||
PrintDataFunction.getFunctionDisplayType(PrintDataFunction.F_SUM,
|
||||
pdc.getDisplayType()), false, false, pdc.getFormatPattern()));
|
||||
}
|
||||
} // for all sum columns
|
||||
} // two lines
|
||||
|
|
|
@ -236,7 +236,7 @@ public class PrintData implements Serializable
|
|||
if (functionRow)
|
||||
m_functionRows.add(new Integer(m_row));
|
||||
if (m_hasLevelNo && levelNo != 0)
|
||||
addNode(new PrintDataElement(LEVEL_NO, new Integer(levelNo), DisplayType.Integer));
|
||||
addNode(new PrintDataElement(LEVEL_NO, new Integer(levelNo), DisplayType.Integer, null));
|
||||
} // addRow
|
||||
|
||||
/**
|
||||
|
@ -747,18 +747,18 @@ public class PrintData implements Serializable
|
|||
public static void main(String[] args)
|
||||
{
|
||||
PrintData pd = new PrintData(new Properties(), "test1");
|
||||
pd.addNode(new PrintDataElement("test1element1","testvalue<1>",0));
|
||||
pd.addNode(new PrintDataElement("test1element2","testvalue&2&",0));
|
||||
pd.addNode(new PrintDataElement("test1element1","testvalue<1>",0,null));
|
||||
pd.addNode(new PrintDataElement("test1element2","testvalue&2&",0,null));
|
||||
|
||||
PrintData pdx = new PrintData(new Properties(), "test2");
|
||||
pdx.addNode(new PrintDataElement("test2element1-1","testvalue11",0));
|
||||
pdx.addNode(new PrintDataElement("test2element1-2","testvalue12",0));
|
||||
pdx.addNode(new PrintDataElement("test2element1-1","testvalue11",0,null));
|
||||
pdx.addNode(new PrintDataElement("test2element1-2","testvalue12",0,null));
|
||||
pdx.addRow(false, 0);
|
||||
pdx.addNode(new PrintDataElement("test2element2-1","testvalue21",0));
|
||||
pdx.addNode(new PrintDataElement("test2element2-2","testvalue22",0));
|
||||
pdx.addNode(new PrintDataElement("test2element2-1","testvalue21",0,null));
|
||||
pdx.addNode(new PrintDataElement("test2element2-2","testvalue22",0,null));
|
||||
|
||||
pd.addNode(pdx);
|
||||
pd.addNode(new PrintDataElement("test1element3","testvalue/3/",0));
|
||||
pd.addNode(new PrintDataElement("test1element3","testvalue/3/",0,null));
|
||||
|
||||
pd.createXML("C:\\Temp\\printData.xml");
|
||||
pd.createXML(new StreamResult(System.out));
|
||||
|
|
|
@ -59,6 +59,7 @@ public class PrintDataColumn
|
|||
private int m_columnSize;
|
||||
private String m_alias;
|
||||
private boolean m_pageBreak;
|
||||
private String m_FormatPattern;
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
|
@ -134,4 +135,12 @@ public class PrintDataColumn
|
|||
return sb.toString();
|
||||
} // toString
|
||||
|
||||
public void setFormatPattern(String formatPattern) {
|
||||
m_FormatPattern = formatPattern;
|
||||
}
|
||||
|
||||
public String getFormatPattern() {
|
||||
return m_FormatPattern;
|
||||
}
|
||||
|
||||
} // PrintDataColumn
|
||||
|
|
|
@ -18,6 +18,10 @@ package org.compiere.print;
|
|||
|
||||
import java.math.*;
|
||||
import java.sql.*;
|
||||
import java.text.DecimalFormat;
|
||||
import java.text.NumberFormat;
|
||||
import java.util.Locale;
|
||||
|
||||
import org.compiere.model.*;
|
||||
import org.compiere.util.*;
|
||||
|
||||
|
@ -37,7 +41,7 @@ public class PrintDataElement
|
|||
* @param isPKey is primary key
|
||||
* @param isPageBreak if true force page break
|
||||
*/
|
||||
public PrintDataElement (String columnName, Object value, int displayType, boolean isPKey, boolean isPageBreak)
|
||||
public PrintDataElement (String columnName, Object value, int displayType, boolean isPKey, boolean isPageBreak, String format)
|
||||
{
|
||||
if (columnName == null)
|
||||
throw new IllegalArgumentException("PrintDataElement - Name cannot be null");
|
||||
|
@ -46,17 +50,19 @@ public class PrintDataElement
|
|||
m_displayType = displayType;
|
||||
m_isPKey = isPKey;
|
||||
m_isPageBreak = isPageBreak;
|
||||
m_formatPattern = format;
|
||||
} // PrintDataElement
|
||||
|
||||
/**
|
||||
* Print Data Element Constructor
|
||||
* @param columnName name
|
||||
* @param value display value
|
||||
* @param pattern Number/date format pattern
|
||||
* @param displayType optional displayType
|
||||
*/
|
||||
public PrintDataElement(String columnName, Object value, int displayType)
|
||||
public PrintDataElement(String columnName, Object value, int displayType, String pattern)
|
||||
{
|
||||
this (columnName, value, displayType, false, false);
|
||||
this (columnName, value, displayType, false, false, pattern);
|
||||
} // PrintDataElement
|
||||
|
||||
/** Data Name */
|
||||
|
@ -69,6 +75,8 @@ public class PrintDataElement
|
|||
private boolean m_isPKey;
|
||||
/** Is Page Break */
|
||||
private boolean m_isPageBreak;
|
||||
/** Value format pattern */
|
||||
private String m_formatPattern;
|
||||
|
||||
|
||||
/** XML Element Name */
|
||||
|
@ -126,9 +134,10 @@ public class PrintDataElement
|
|||
return new BigDecimal(s.length());
|
||||
} // getFunctionValue
|
||||
|
||||
|
||||
/**
|
||||
* Get Node Value Display
|
||||
* @param language optional language - if null nubers/dates are not formatted
|
||||
* @param language optional language - if null numbers/dates are not formatted
|
||||
* @return display value optionally formatted
|
||||
*/
|
||||
public String getValueDisplay (Language language)
|
||||
|
@ -147,10 +156,11 @@ public class PrintDataElement
|
|||
;
|
||||
else if (language != null) // Optional formatting of Numbers and Dates
|
||||
{
|
||||
if (DisplayType.isNumeric(m_displayType))
|
||||
retValue = DisplayType.getNumberFormat(m_displayType, language).format(m_value);
|
||||
if (DisplayType.isNumeric(m_displayType)) {
|
||||
retValue = DisplayType.getNumberFormat(m_displayType, language, m_formatPattern).format(m_value);
|
||||
}
|
||||
else if (DisplayType.isDate(m_displayType))
|
||||
retValue = DisplayType.getDateFormat(m_displayType, language).format(m_value);
|
||||
retValue = DisplayType.getDateFormat(m_displayType, language, m_formatPattern).format(m_value);
|
||||
}
|
||||
return retValue;
|
||||
} // getValueDisplay
|
||||
|
@ -386,4 +396,12 @@ public class PrintDataElement
|
|||
return toString();
|
||||
} // toStringX
|
||||
|
||||
public String getM_formatPattern() {
|
||||
return m_formatPattern;
|
||||
}
|
||||
|
||||
public void setM_formatPattern(String pattern) {
|
||||
m_formatPattern = pattern;
|
||||
}
|
||||
|
||||
} // PrintDataElement
|
||||
|
|
|
@ -129,7 +129,7 @@ public class PrintDataHandler extends DefaultHandler
|
|||
}
|
||||
else if (qName.equals(PrintDataElement.XML_TAG))
|
||||
{
|
||||
m_curPD.addNode(new PrintDataElement(m_curPDEname, m_curPDEvalue.toString(),0));
|
||||
m_curPD.addNode(new PrintDataElement(m_curPDEname, m_curPDEvalue.toString(),0, null));
|
||||
}
|
||||
} // endElement
|
||||
|
||||
|
|
|
@ -258,6 +258,8 @@ public class FinReport extends SvrProcess
|
|||
doCalculations();
|
||||
|
||||
deleteUnprintedLines();
|
||||
|
||||
scaleResults();
|
||||
|
||||
// Create Report
|
||||
if (Ini.isClient())
|
||||
|
@ -269,7 +271,6 @@ public class FinReport extends SvrProcess
|
|||
return "";
|
||||
} // doIt
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
* For all columns (in a line) with relative period access
|
||||
* @param line line
|
||||
|
@ -1061,6 +1062,32 @@ public class FinReport extends SvrProcess
|
|||
} // for all lines
|
||||
} // deleteUnprintedLines
|
||||
|
||||
|
||||
private void scaleResults() {
|
||||
|
||||
for (int column = 0; column < m_columns.length; column++)
|
||||
{
|
||||
String factor = m_columns[column].getFactor();
|
||||
if ( factor != null )
|
||||
{
|
||||
int divisor = 1;
|
||||
if ( factor.equals("k") )
|
||||
divisor = 1000;
|
||||
else if (factor.equals("M"))
|
||||
divisor = 1000000;
|
||||
else
|
||||
break;
|
||||
|
||||
String sql = "UPDATE T_Report SET Col_" + column
|
||||
+ "=Col_" + column + "/" + divisor
|
||||
+ " WHERE AD_PInstance_ID=" + getAD_PInstance_ID();
|
||||
int no = DB.executeUpdate(sql, get_TrxName());
|
||||
if (no > 0)
|
||||
log.fine(m_columns[column].getName() + " - #" + no);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* Get/Create PrintFormat
|
||||
|
@ -1122,6 +1149,16 @@ public class FinReport extends SvrProcess
|
|||
{
|
||||
pfi.setIsPrinted(m_columns[index].isPrinted());
|
||||
String s = m_columns[index].getName();
|
||||
|
||||
if (m_columns[index].isColumnTypeRelativePeriod())
|
||||
{
|
||||
BigDecimal relativeOffset = m_columns[index].getRelativePeriod();
|
||||
FinReportPeriod frp = getPeriod (relativeOffset);
|
||||
|
||||
if ( s.contains("@Period@") )
|
||||
s = s.replace("@Period@", frp.getName() );
|
||||
}
|
||||
|
||||
if (!pfi.getName().equals(s))
|
||||
{
|
||||
pfi.setName (s);
|
||||
|
@ -1130,6 +1167,9 @@ public class FinReport extends SvrProcess
|
|||
int seq = 30 + index;
|
||||
if (pfi.getSeqNo() != seq)
|
||||
pfi.setSeqNo(seq);
|
||||
|
||||
s = m_columns[index].getFormatPattern();
|
||||
pfi.setFormatPattern(s);
|
||||
}
|
||||
else // not printed
|
||||
{
|
||||
|
@ -1196,9 +1236,9 @@ public class FinReport extends SvrProcess
|
|||
}
|
||||
// set translated to original
|
||||
pf.setTranslation();
|
||||
// First one is unsorted - just re-load
|
||||
if (createNew)
|
||||
pf = MPrintFormat.get (getCtx(), AD_PrintFormat_ID, false); // use Cache
|
||||
|
||||
// Reload to pick up changed pfi
|
||||
pf = MPrintFormat.get (getCtx(), AD_PrintFormat_ID, true); // no cache
|
||||
return pf;
|
||||
} // getPrintFormat
|
||||
|
||||
|
|
|
@ -18,6 +18,7 @@ package org.compiere.util;
|
|||
|
||||
import java.text.*;
|
||||
import java.util.*;
|
||||
import java.util.logging.Level;
|
||||
|
||||
/**
|
||||
* System Display Types.
|
||||
|
@ -235,9 +236,10 @@ public final class DisplayType
|
|||
* Return Format for numeric DisplayType
|
||||
* @param displayType Display Type (default Number)
|
||||
* @param language Language
|
||||
* @param pattern Java Number Format pattern e.g. "#,##0.00"
|
||||
* @return number format
|
||||
*/
|
||||
public static DecimalFormat getNumberFormat(int displayType, Language language)
|
||||
public static DecimalFormat getNumberFormat(int displayType, Language language, String pattern)
|
||||
{
|
||||
Language myLanguage = language;
|
||||
if (myLanguage == null)
|
||||
|
@ -249,7 +251,17 @@ public final class DisplayType
|
|||
else
|
||||
format = (DecimalFormat)NumberFormat.getNumberInstance(Locale.US);
|
||||
//
|
||||
if (displayType == Integer)
|
||||
if (pattern != null && pattern.length() > 0)
|
||||
{
|
||||
try {
|
||||
format.applyPattern(pattern);
|
||||
return format;
|
||||
}
|
||||
catch (IllegalArgumentException e) {
|
||||
s_log.log(Level.WARNING, "Invalid number format: " + pattern);
|
||||
}
|
||||
}
|
||||
else if (displayType == Integer)
|
||||
{
|
||||
format.setParseIntegerOnly(true);
|
||||
format.setMaximumIntegerDigits(INTEGER_DIGITS);
|
||||
|
@ -280,7 +292,18 @@ public final class DisplayType
|
|||
}
|
||||
return format;
|
||||
} // getDecimalFormat
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
* Return Format for numeric DisplayType
|
||||
* @param displayType Display Type (default Number)
|
||||
* @param language Language
|
||||
* @return number format
|
||||
*/
|
||||
public static DecimalFormat getNumberFormat(int displayType, Language language)
|
||||
{
|
||||
return getNumberFormat(displayType, language, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return Format for numeric DisplayType
|
||||
* @param displayType Display Type
|
||||
|
@ -328,11 +351,34 @@ public final class DisplayType
|
|||
* @return date format
|
||||
*/
|
||||
public static SimpleDateFormat getDateFormat (int displayType, Language language)
|
||||
{
|
||||
return getDateFormat(displayType, language, null);
|
||||
}
|
||||
/**
|
||||
* Return format for date displayType
|
||||
* @param displayType Display Type (default Date)
|
||||
* @param language Language
|
||||
* @param pattern Java Simple Date Format pattern e.g. "dd/MM/yy"
|
||||
* @return date format
|
||||
*/
|
||||
public static SimpleDateFormat getDateFormat (int displayType, Language language, String pattern)
|
||||
{
|
||||
Language myLanguage = language;
|
||||
if (myLanguage == null)
|
||||
myLanguage = Language.getLoginLanguage();
|
||||
//
|
||||
if ( pattern != null && pattern.length() > 0)
|
||||
{
|
||||
SimpleDateFormat format = (SimpleDateFormat)DateFormat.getInstance();
|
||||
try {
|
||||
format.applyPattern(pattern);
|
||||
return format;
|
||||
}
|
||||
catch (IllegalArgumentException e) {
|
||||
s_log.log(Level.WARNING, "Invalid date pattern: " + pattern);
|
||||
}
|
||||
}
|
||||
|
||||
if (displayType == DateTime)
|
||||
return myLanguage.getDateTimeFormat();
|
||||
else if (displayType == Time)
|
||||
|
|
|
@ -0,0 +1,216 @@
|
|||
|
||||
-- 26/09/2008 16:58:43
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element (AD_Org_ID,AD_Client_ID,AD_Element_ID,ColumnName,Created,CreatedBy,Description,EntityType,Help,IsActive,Name,PO_Name,PrintName,Updated,UpdatedBy) VALUES (0,0,53687,'FormatPattern',TO_DATE('2008-09-26 16:58:43','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Format Pattern',NULL,'Format Pattern',TO_DATE('2008-09-26 16:58:43','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:58:44
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Description,Help,Name,PO_Description,PO_Help,PO_Name,PO_PrintName,PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Element_ID, t.Description,t.Help,t.Name,t.PO_Description,t.PO_Help,t.PO_Name,t.PO_PrintName,t.PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=53687 AND EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Element_ID!=t.AD_Element_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:59:38
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56351,53686,10,489,'FormatPattern2',TO_DATE('2008-09-26 16:59:37','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern22',0,TO_DATE('2008-09-26 16:59:37','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:59:38
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56351 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column SET AD_Element_ID=53687, ColumnName='FormatPattern', Description='The pattern used to format a number or date.', Help='A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.', Name='Format Pattern',Updated=TO_DATE('2008-09-26 17:00:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=56351
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column_Trl SET IsTranslated='N' WHERE AD_Column_ID=56351
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET Name='Format Pattern', Description='The pattern used to format a number or date.', Help='A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.' WHERE AD_Column_ID=56351 AND IsCentrallyMaintained='Y'
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:02:12
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56352,53687,10,101,'FormatPattern',TO_DATE('2008-09-26 17:02:11','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern',0,TO_DATE('2008-09-26 17:02:11','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:02:12
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56352 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:00
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56353,53687,10,446,'FormatPattern',TO_DATE('2008-09-26 17:03:59','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern',0,TO_DATE('2008-09-26 17:03:59','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:00
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56353 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:41
|
||||
-- Financial reporting improvements
|
||||
CREATE TABLE PA_ReportColumn (AD_Client_ID NUMBER(10) DEFAULT NULL NOT NULL, AD_Org_ID NUMBER(10) DEFAULT NULL NOT NULL, AmountType NVARCHAR2(2) DEFAULT 'BP', C_Activity_ID NUMBER(10), CalculationType CHAR(1) DEFAULT 'A', C_BPartner_ID NUMBER(10), C_Campaign_ID NUMBER(10), C_Currency_ID NUMBER(10), C_ElementValue_ID NUMBER(10), C_Location_ID NUMBER(10), ColumnType CHAR(1) DEFAULT 'R' NOT NULL, C_Project_ID NUMBER(10), Created DATE NOT NULL, CreatedBy NUMBER(10) NOT NULL, C_SalesRegion_ID NUMBER(10), CurrencyType CHAR(1) DEFAULT 'A', Description NVARCHAR2(255), ElementType NVARCHAR2(2), FormatPattern NVARCHAR2(22), GL_Budget_ID NUMBER(10), IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, IsAdhocConversion CHAR(1) DEFAULT 'N' CHECK (IsAdhocConversion IN ('Y','N')), IsIncludeNullsActivity CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsActivity IN ('Y','N')) NOT NULL, IsIncludeNullsBPartner CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsBPartner IN ('Y','N')) NOT NULL, IsIncludeNullsCampaign CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsCampaign IN ('Y','N')) NOT NULL, IsIncludeNullsElementValue CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsElementValue IN ('Y','N')) NOT NULL, IsIncludeNullsLocation CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsLocation IN ('Y','N')) NOT NULL, IsIncludeNullsOrg CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsOrg IN ('Y','N')) NOT NULL, IsIncludeNullsProduct CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProduct IN ('Y','N')) NOT NULL, IsIncludeNullsProject CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProject IN ('Y','N')) NOT NULL, IsIncludeNullsSalesRegion CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsSalesRegion IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement1 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement1 IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement2 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement2 IN ('Y','N')) NOT NULL, IsPrinted CHAR(1) DEFAULT 'Y' CHECK (IsPrinted IN ('Y','N')) NOT NULL, M_Product_ID NUMBER(10), Name NVARCHAR2(60) NOT NULL, Oper_1_ID NUMBER(10), Oper_2_ID NUMBER(10), Org_ID NUMBER(10), PA_ReportColumn_ID NUMBER(10) NOT NULL, PA_ReportColumnSet_ID NUMBER(10) NOT NULL, PostingType CHAR(1) DEFAULT 'A' NOT NULL, RelativePeriod NUMBER DEFAULT 0, SeqNo NUMBER(10) DEFAULT NULL NOT NULL, Updated DATE NOT NULL, UpdatedBy NUMBER(10) NOT NULL, UserElement1_ID NUMBER(10), UserElement2_ID NUMBER(10), CONSTRAINT PA_ReportColumn_Key PRIMARY KEY (PA_ReportColumn_ID))
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:09:15
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element (AD_Org_ID,AD_Client_ID,AD_Element_ID,ColumnName,Created,CreatedBy,Description,EntityType,Help,IsActive,Name,PrintName,Updated,UpdatedBy) VALUES (0,0,53688,'Factor',TO_DATE('2008-09-26 17:09:14','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.','D','Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Factor','Factor',TO_DATE('2008-09-26 17:09:14','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:09:15
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Description,Help,Name,PO_Description,PO_Help,PO_Name,PO_PrintName,PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Element_ID, t.Description,t.Help,t.Name,t.PO_Description,t.PO_Help,t.PO_Name,t.PO_PrintName,t.PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=53688 AND EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Element_ID!=t.AD_Element_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:10:06
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56354,53688,11,446,'Factor',TO_DATE('2008-09-26 17:10:05','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.','D',10,'Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Factor',0,TO_DATE('2008-09-26 17:10:05','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:10:06
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56354 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:13:53
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,DisplayLogic,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56351,0,0,56373,426,TO_DATE('2008-09-26 17:13:52','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'@PrintFormatType@=F','D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',145,0,TO_DATE('2008-09-26 17:13:52','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:13:53
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56373 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:16:17
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56352,0,0,56374,101,TO_DATE('2008-09-26 17:16:16','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',390,0,TO_DATE('2008-09-26 17:16:16','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:16:17
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56374 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:10
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56353,0,0,56375,374,TO_DATE('2008-09-26 17:19:09','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',430,0,TO_DATE('2008-09-26 17:19:09','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:10
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56375 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:39
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56354,0,0,56376,374,TO_DATE('2008-09-26 17:19:39','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.',0,'D','Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Y','Y','N','N','N','N','Y','Factor',440,0,TO_DATE('2008-09-26 17:19:39','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:39
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56376 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:22:27
|
||||
-- Financial reporting improvements
|
||||
CREATE TABLE PA_ReportColumn (AD_Client_ID NUMBER(10) DEFAULT NULL NOT NULL, AD_Org_ID NUMBER(10) DEFAULT NULL NOT NULL, AmountType NVARCHAR2(2) DEFAULT 'BP', C_Activity_ID NUMBER(10), CalculationType CHAR(1) DEFAULT 'A', C_BPartner_ID NUMBER(10), C_Campaign_ID NUMBER(10), C_Currency_ID NUMBER(10), C_ElementValue_ID NUMBER(10), C_Location_ID NUMBER(10), ColumnType CHAR(1) DEFAULT 'R' NOT NULL, C_Project_ID NUMBER(10), Created DATE NOT NULL, CreatedBy NUMBER(10) NOT NULL, C_SalesRegion_ID NUMBER(10), CurrencyType CHAR(1) DEFAULT 'A', Description NVARCHAR2(255), ElementType NVARCHAR2(2), Factor NUMBER(10), FormatPattern NVARCHAR2(22), GL_Budget_ID NUMBER(10), IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, IsAdhocConversion CHAR(1) DEFAULT 'N' CHECK (IsAdhocConversion IN ('Y','N')), IsIncludeNullsActivity CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsActivity IN ('Y','N')) NOT NULL, IsIncludeNullsBPartner CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsBPartner IN ('Y','N')) NOT NULL, IsIncludeNullsCampaign CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsCampaign IN ('Y','N')) NOT NULL, IsIncludeNullsElementValue CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsElementValue IN ('Y','N')) NOT NULL, IsIncludeNullsLocation CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsLocation IN ('Y','N')) NOT NULL, IsIncludeNullsOrg CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsOrg IN ('Y','N')) NOT NULL, IsIncludeNullsProduct CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProduct IN ('Y','N')) NOT NULL, IsIncludeNullsProject CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProject IN ('Y','N')) NOT NULL, IsIncludeNullsSalesRegion CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsSalesRegion IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement1 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement1 IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement2 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement2 IN ('Y','N')) NOT NULL, IsPrinted CHAR(1) DEFAULT 'Y' CHECK (IsPrinted IN ('Y','N')) NOT NULL, M_Product_ID NUMBER(10), Name NVARCHAR2(60) NOT NULL, Oper_1_ID NUMBER(10), Oper_2_ID NUMBER(10), Org_ID NUMBER(10), PA_ReportColumn_ID NUMBER(10) NOT NULL, PA_ReportColumnSet_ID NUMBER(10) NOT NULL, PostingType CHAR(1) DEFAULT 'A' NOT NULL, RelativePeriod NUMBER DEFAULT 0, SeqNo NUMBER(10) DEFAULT NULL NOT NULL, Updated DATE NOT NULL, UpdatedBy NUMBER(10) NOT NULL, UserElement1_ID NUMBER(10), UserElement2_ID NUMBER(10), CONSTRAINT PA_ReportColumn_Key PRIMARY KEY (PA_ReportColumn_ID))
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:30:21
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE PA_ReportColumn ADD Factor CHAR(1)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:30:38
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE PA_ReportColumn ADD FormatPattern NVARCHAR2(22)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:32:21
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE AD_Column ADD FormatPattern NVARCHAR2(22)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:33:00
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE AD_PrintFormatItem ADD FormatPattern NVARCHAR2(22)
|
||||
;
|
||||
|
||||
-- 3/10/2008 11:19:23
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET DisplayLogic='@AD_Reference_ID@=11 | @AD_Reference_ID@=12 | @AD_Reference_ID@=15 | @AD_Reference_ID@=22 | @AD_Reference_ID@=29 | @AD_Reference_ID@=16 | @AD_Reference_ID@=37', SeqNo=165,Updated=TO_DATE('2008-10-03 11:19:23','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56374
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:30:21
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Reference (AD_Org_ID,AD_Client_ID,AD_Reference_ID,Created,CreatedBy,EntityType,IsActive,IsOrderByValue,Name,Updated,UpdatedBy,ValidationType) VALUES (0,0,53285,TO_DATE('2008-10-03 12:30:19','YYYY-MM-DD HH24:MI:SS'),100,'D','Y','Y','Factors',TO_DATE('2008-10-03 12:30:19','YYYY-MM-DD HH24:MI:SS'),100,'L')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:30:21
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Reference_Trl (AD_Language,AD_Reference_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Reference_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Reference t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Reference_ID=53285 AND EXISTS (SELECT * FROM AD_Reference_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Reference_ID!=t.AD_Reference_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:13
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List (AD_Org_ID,AD_Client_ID,AD_Reference_ID,AD_Ref_List_ID,Created,CreatedBy,Description,EntityType,IsActive,Name,Updated,UpdatedBy,Value) VALUES (0,0,53285,53436,TO_DATE('2008-10-03 12:31:12','YYYY-MM-DD HH24:MI:SS'),100,'Thousand','D','Y','Thousand',TO_DATE('2008-10-03 12:31:12','YYYY-MM-DD HH24:MI:SS'),100,'k')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:13
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List_Trl (AD_Language,AD_Ref_List_ID, Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Ref_List_ID, t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Ref_List t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Ref_List_ID=53436 AND EXISTS (SELECT * FROM AD_Ref_List_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Ref_List_ID!=t.AD_Ref_List_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:28
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List (AD_Org_ID,AD_Client_ID,AD_Reference_ID,AD_Ref_List_ID,Created,CreatedBy,Description,EntityType,IsActive,Name,Updated,UpdatedBy,Value) VALUES (0,0,53285,53437,TO_DATE('2008-10-03 12:31:27','YYYY-MM-DD HH24:MI:SS'),100,'Million','D','Y','Million',TO_DATE('2008-10-03 12:31:27','YYYY-MM-DD HH24:MI:SS'),100,'m')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:28
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List_Trl (AD_Language,AD_Ref_List_ID, Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Ref_List_ID, t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Ref_List t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Ref_List_ID=53437 AND EXISTS (SELECT * FROM AD_Ref_List_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Ref_List_ID!=t.AD_Ref_List_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:43
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference SET Name='Scaling Factors',Updated=TO_DATE('2008-10-03 12:31:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:43
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference_Trl SET IsTranslated='N' WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:32:44
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference SET Description='Factors for scaling the results of financial reports.', Help='Currently supported: thousand, million.',Updated=TO_DATE('2008-10-03 12:32:44','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:32:44
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference_Trl SET IsTranslated='N' WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:33:17
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column SET AD_Reference_Value_ID=53285, AD_Reference_ID=17, FieldLength=1, Help='Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of "Thousand" will display as 123.',Updated=TO_DATE('2008-10-03 12:33:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=56354
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:33:17
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET Name='Factor', Description='Scaling factor.', Help='Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of "Thousand" will display as 123.' WHERE AD_Column_ID=56354 AND IsCentrallyMaintained='Y'
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:53:38
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Ref_List SET Value='M',Updated=TO_DATE('2008-10-03 12:53:38','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Ref_List_ID=53437
|
||||
;
|
||||
|
|
@ -0,0 +1,216 @@
|
|||
|
||||
-- 26/09/2008 16:58:44
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element (AD_Org_ID,AD_Client_ID,AD_Element_ID,ColumnName,Created,CreatedBy,Description,EntityType,Help,IsActive,Name,PO_Name,PrintName,Updated,UpdatedBy) VALUES (0,0,53687,'FormatPattern',TO_TIMESTAMP('2008-09-26 16:58:43','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Format Pattern',NULL,'Format Pattern',TO_TIMESTAMP('2008-09-26 16:58:43','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:58:44
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Description,Help,Name,PO_Description,PO_Help,PO_Name,PO_PrintName,PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Element_ID, t.Description,t.Help,t.Name,t.PO_Description,t.PO_Help,t.PO_Name,t.PO_PrintName,t.PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=53687 AND EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Element_ID!=t.AD_Element_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:59:38
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56351,53686,10,489,'FormatPattern2',TO_TIMESTAMP('2008-09-26 16:59:37','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern22',0,TO_TIMESTAMP('2008-09-26 16:59:37','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 16:59:38
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56351 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column SET AD_Element_ID=53687, ColumnName='FormatPattern', Description='The pattern used to format a number or date.', Help='A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.', Name='Format Pattern',Updated=TO_TIMESTAMP('2008-09-26 17:00:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=56351
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column_Trl SET IsTranslated='N' WHERE AD_Column_ID=56351
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:00:09
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET Name='Format Pattern', Description='The pattern used to format a number or date.', Help='A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.' WHERE AD_Column_ID=56351 AND IsCentrallyMaintained='Y'
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:02:12
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56352,53687,10,101,'FormatPattern',TO_TIMESTAMP('2008-09-26 17:02:11','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern',0,TO_TIMESTAMP('2008-09-26 17:02:11','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:02:12
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56352 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:00
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56353,53687,10,446,'FormatPattern',TO_TIMESTAMP('2008-09-26 17:03:59','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.','D',22,'A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Format Pattern',0,TO_TIMESTAMP('2008-09-26 17:03:59','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:00
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56353 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:04:41
|
||||
-- Financial reporting improvements
|
||||
CREATE TABLE PA_ReportColumn (AD_Client_ID NUMERIC(10) DEFAULT NULL NOT NULL, AD_Org_ID NUMERIC(10) DEFAULT NULL NOT NULL, AmountType VARCHAR(2) DEFAULT 'BP', C_Activity_ID NUMERIC(10), CalculationType CHAR(1) DEFAULT 'A', C_BPartner_ID NUMERIC(10), C_Campaign_ID NUMERIC(10), C_Currency_ID NUMERIC(10), C_ElementValue_ID NUMERIC(10), C_Location_ID NUMERIC(10), ColumnType CHAR(1) DEFAULT 'R' NOT NULL, C_Project_ID NUMERIC(10), Created TIMESTAMP NOT NULL, CreatedBy NUMERIC(10) NOT NULL, C_SalesRegion_ID NUMERIC(10), CurrencyType CHAR(1) DEFAULT 'A', Description VARCHAR(255), ElementType VARCHAR(2), FormatPattern VARCHAR(22), GL_Budget_ID NUMERIC(10), IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, IsAdhocConversion CHAR(1) DEFAULT 'N' CHECK (IsAdhocConversion IN ('Y','N')), IsIncludeNullsActivity CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsActivity IN ('Y','N')) NOT NULL, IsIncludeNullsBPartner CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsBPartner IN ('Y','N')) NOT NULL, IsIncludeNullsCampaign CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsCampaign IN ('Y','N')) NOT NULL, IsIncludeNullsElementValue CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsElementValue IN ('Y','N')) NOT NULL, IsIncludeNullsLocation CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsLocation IN ('Y','N')) NOT NULL, IsIncludeNullsOrg CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsOrg IN ('Y','N')) NOT NULL, IsIncludeNullsProduct CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProduct IN ('Y','N')) NOT NULL, IsIncludeNullsProject CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProject IN ('Y','N')) NOT NULL, IsIncludeNullsSalesRegion CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsSalesRegion IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement1 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement1 IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement2 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement2 IN ('Y','N')) NOT NULL, IsPrinted CHAR(1) DEFAULT 'Y' CHECK (IsPrinted IN ('Y','N')) NOT NULL, M_Product_ID NUMERIC(10), Name VARCHAR(60) NOT NULL, Oper_1_ID NUMERIC(10), Oper_2_ID NUMERIC(10), Org_ID NUMERIC(10), PA_ReportColumn_ID NUMERIC(10) NOT NULL, PA_ReportColumnSet_ID NUMERIC(10) NOT NULL, PostingType CHAR(1) DEFAULT 'A' NOT NULL, RelativePeriod NUMERIC DEFAULT 0, SeqNo NUMERIC(10) DEFAULT NULL NOT NULL, Updated TIMESTAMP NOT NULL, UpdatedBy NUMERIC(10) NOT NULL, UserElement1_ID NUMERIC(10), UserElement2_ID NUMERIC(10), CONSTRAINT PA_ReportColumn_Key PRIMARY KEY (PA_ReportColumn_ID))
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:09:15
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element (AD_Org_ID,AD_Client_ID,AD_Element_ID,ColumnName,Created,CreatedBy,Description,EntityType,Help,IsActive,Name,PrintName,Updated,UpdatedBy) VALUES (0,0,53688,'Factor',TO_TIMESTAMP('2008-09-26 17:09:14','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.','D','Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Factor','Factor',TO_TIMESTAMP('2008-09-26 17:09:14','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:09:15
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Element_Trl (AD_Language,AD_Element_ID, Description,Help,Name,PO_Description,PO_Help,PO_Name,PO_PrintName,PrintName, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Element_ID, t.Description,t.Help,t.Name,t.PO_Description,t.PO_Help,t.PO_Name,t.PO_PrintName,t.PrintName, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Element t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Element_ID=53688 AND EXISTS (SELECT * FROM AD_Element_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Element_ID!=t.AD_Element_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:10:06
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column (AD_Org_ID,AD_Client_ID,AD_Column_ID,AD_Element_ID,AD_Reference_ID,AD_Table_ID,ColumnName,Created,CreatedBy,Description,EntityType,FieldLength,Help,IsActive,IsAllowLogging,IsAlwaysUpdateable,IsAutocomplete,IsEncrypted,IsIdentifier,IsKey,IsMandatory,IsParent,IsSelectionColumn,IsSyncDatabase,IsTranslated,IsUpdateable,Name,SeqNo,Updated,UpdatedBy,Version) VALUES (0,0,56354,53688,11,446,'Factor',TO_TIMESTAMP('2008-09-26 17:10:05','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.','D',10,'Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Y','N','N','N','N','N','N','N','N','N','N','Y','Factor',0,TO_TIMESTAMP('2008-09-26 17:10:05','YYYY-MM-DD HH24:MI:SS'),100,0)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:10:06
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Column_Trl (AD_Language,AD_Column_ID, Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Column_ID, t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Column t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Column_ID=56354 AND EXISTS (SELECT * FROM AD_Column_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Column_ID!=t.AD_Column_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:13:53
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,DisplayLogic,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56351,0,0,56373,426,TO_TIMESTAMP('2008-09-26 17:13:52','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'@PrintFormatType@=F','D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',145,0,TO_TIMESTAMP('2008-09-26 17:13:52','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:13:53
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56373 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:16:17
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56352,0,0,56374,101,TO_TIMESTAMP('2008-09-26 17:16:16','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',390,0,TO_TIMESTAMP('2008-09-26 17:16:16','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:16:17
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56374 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:10
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56353,0,0,56375,374,TO_TIMESTAMP('2008-09-26 17:19:09','YYYY-MM-DD HH24:MI:SS'),100,'The pattern used to format a number or date.',14,'D','A string complying with either Java SimpleDateFormat or DecimalFormat pattern syntax used to override the default presentation format of a date or number type field.','Y','Y','Y','N','N','N','N','N','Format Pattern',430,0,TO_TIMESTAMP('2008-09-26 17:19:09','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:10
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56375 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:39
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field (AD_Column_ID,AD_Org_ID,AD_Client_ID,AD_Field_ID,AD_Tab_ID,Created,CreatedBy,Description,DisplayLength,EntityType,Help,IsActive,IsCentrallyMaintained,IsDisplayed,IsEncrypted,IsFieldOnly,IsHeading,IsReadOnly,IsSameLine,Name,SeqNo,SortNo,Updated,UpdatedBy) VALUES (56354,0,0,56376,374,TO_TIMESTAMP('2008-09-26 17:19:39','YYYY-MM-DD HH24:MI:SS'),100,'Scaling factor.',0,'D','Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of 1,000 will display as 123.','Y','Y','Y','N','N','N','N','Y','Factor',440,0,TO_TIMESTAMP('2008-09-26 17:19:39','YYYY-MM-DD HH24:MI:SS'),100)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:19:39
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Field_Trl (AD_Language,AD_Field_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Field_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Field t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Field_ID=56376 AND EXISTS (SELECT * FROM AD_Field_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Field_ID!=t.AD_Field_ID)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:22:27
|
||||
-- Financial reporting improvements
|
||||
CREATE TABLE PA_ReportColumn (AD_Client_ID NUMERIC(10) DEFAULT NULL NOT NULL, AD_Org_ID NUMERIC(10) DEFAULT NULL NOT NULL, AmountType VARCHAR(2) DEFAULT 'BP', C_Activity_ID NUMERIC(10), CalculationType CHAR(1) DEFAULT 'A', C_BPartner_ID NUMERIC(10), C_Campaign_ID NUMERIC(10), C_Currency_ID NUMERIC(10), C_ElementValue_ID NUMERIC(10), C_Location_ID NUMERIC(10), ColumnType CHAR(1) DEFAULT 'R' NOT NULL, C_Project_ID NUMERIC(10), Created TIMESTAMP NOT NULL, CreatedBy NUMERIC(10) NOT NULL, C_SalesRegion_ID NUMERIC(10), CurrencyType CHAR(1) DEFAULT 'A', Description VARCHAR(255), ElementType VARCHAR(2), Factor NUMERIC(10), FormatPattern VARCHAR(22), GL_Budget_ID NUMERIC(10), IsActive CHAR(1) DEFAULT 'Y' CHECK (IsActive IN ('Y','N')) NOT NULL, IsAdhocConversion CHAR(1) DEFAULT 'N' CHECK (IsAdhocConversion IN ('Y','N')), IsIncludeNullsActivity CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsActivity IN ('Y','N')) NOT NULL, IsIncludeNullsBPartner CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsBPartner IN ('Y','N')) NOT NULL, IsIncludeNullsCampaign CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsCampaign IN ('Y','N')) NOT NULL, IsIncludeNullsElementValue CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsElementValue IN ('Y','N')) NOT NULL, IsIncludeNullsLocation CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsLocation IN ('Y','N')) NOT NULL, IsIncludeNullsOrg CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsOrg IN ('Y','N')) NOT NULL, IsIncludeNullsProduct CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProduct IN ('Y','N')) NOT NULL, IsIncludeNullsProject CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsProject IN ('Y','N')) NOT NULL, IsIncludeNullsSalesRegion CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsSalesRegion IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement1 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement1 IN ('Y','N')) NOT NULL, IsIncludeNullsUserElement2 CHAR(1) DEFAULT 'N' CHECK (IsIncludeNullsUserElement2 IN ('Y','N')) NOT NULL, IsPrinted CHAR(1) DEFAULT 'Y' CHECK (IsPrinted IN ('Y','N')) NOT NULL, M_Product_ID NUMERIC(10), Name VARCHAR(60) NOT NULL, Oper_1_ID NUMERIC(10), Oper_2_ID NUMERIC(10), Org_ID NUMERIC(10), PA_ReportColumn_ID NUMERIC(10) NOT NULL, PA_ReportColumnSet_ID NUMERIC(10) NOT NULL, PostingType CHAR(1) DEFAULT 'A' NOT NULL, RelativePeriod NUMERIC DEFAULT 0, SeqNo NUMERIC(10) DEFAULT NULL NOT NULL, Updated TIMESTAMP NOT NULL, UpdatedBy NUMERIC(10) NOT NULL, UserElement1_ID NUMERIC(10), UserElement2_ID NUMERIC(10), CONSTRAINT PA_ReportColumn_Key PRIMARY KEY (PA_ReportColumn_ID))
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:30:21
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE PA_ReportColumn ADD COLUMN Factor CHAR(1)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:30:38
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE PA_ReportColumn ADD COLUMN FormatPattern VARCHAR(22)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:32:21
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE AD_Column ADD COLUMN FormatPattern VARCHAR(22)
|
||||
;
|
||||
|
||||
-- 26/09/2008 17:33:00
|
||||
-- Financial reporting improvements
|
||||
ALTER TABLE AD_PrintFormatItem ADD COLUMN FormatPattern VARCHAR(22)
|
||||
;
|
||||
|
||||
-- 3/10/2008 11:19:23
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET DisplayLogic='@AD_Reference_ID@=11 | @AD_Reference_ID@=12 | @AD_Reference_ID@=15 | @AD_Reference_ID@=22 | @AD_Reference_ID@=29 | @AD_Reference_ID@=16 | @AD_Reference_ID@=37', SeqNo=165,Updated=TO_TIMESTAMP('2008-10-03 11:19:23','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Field_ID=56374
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:30:21
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Reference (AD_Org_ID,AD_Client_ID,AD_Reference_ID,Created,CreatedBy,EntityType,IsActive,IsOrderByValue,Name,Updated,UpdatedBy,ValidationType) VALUES (0,0,53285,TO_TIMESTAMP('2008-10-03 12:30:19','YYYY-MM-DD HH24:MI:SS'),100,'D','Y','Y','Factors',TO_TIMESTAMP('2008-10-03 12:30:19','YYYY-MM-DD HH24:MI:SS'),100,'L')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:30:21
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Reference_Trl (AD_Language,AD_Reference_ID, Description,Help,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Reference_ID, t.Description,t.Help,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Reference t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Reference_ID=53285 AND EXISTS (SELECT * FROM AD_Reference_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Reference_ID!=t.AD_Reference_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:13
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List (AD_Org_ID,AD_Client_ID,AD_Reference_ID,AD_Ref_List_ID,Created,CreatedBy,Description,EntityType,IsActive,Name,Updated,UpdatedBy,Value) VALUES (0,0,53285,53436,TO_TIMESTAMP('2008-10-03 12:31:12','YYYY-MM-DD HH24:MI:SS'),100,'Thousand','D','Y','Thousand',TO_TIMESTAMP('2008-10-03 12:31:12','YYYY-MM-DD HH24:MI:SS'),100,'k')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:13
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List_Trl (AD_Language,AD_Ref_List_ID, Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Ref_List_ID, t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Ref_List t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Ref_List_ID=53436 AND EXISTS (SELECT * FROM AD_Ref_List_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Ref_List_ID!=t.AD_Ref_List_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:28
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List (AD_Org_ID,AD_Client_ID,AD_Reference_ID,AD_Ref_List_ID,Created,CreatedBy,Description,EntityType,IsActive,Name,Updated,UpdatedBy,Value) VALUES (0,0,53285,53437,TO_TIMESTAMP('2008-10-03 12:31:27','YYYY-MM-DD HH24:MI:SS'),100,'Million','D','Y','Million',TO_TIMESTAMP('2008-10-03 12:31:27','YYYY-MM-DD HH24:MI:SS'),100,'m')
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:28
|
||||
-- Financial reporting improvements
|
||||
INSERT INTO AD_Ref_List_Trl (AD_Language,AD_Ref_List_ID, Description,Name, IsTranslated,AD_Client_ID,AD_Org_ID,Created,Createdby,Updated,UpdatedBy) SELECT l.AD_Language,t.AD_Ref_List_ID, t.Description,t.Name, 'N',t.AD_Client_ID,t.AD_Org_ID,t.Created,t.Createdby,t.Updated,t.UpdatedBy FROM AD_Language l, AD_Ref_List t WHERE l.IsActive='Y' AND l.IsSystemLanguage='Y' AND l.IsBaseLanguage='N' AND t.AD_Ref_List_ID=53437 AND EXISTS (SELECT * FROM AD_Ref_List_Trl tt WHERE tt.AD_Language!=l.AD_Language OR tt.AD_Ref_List_ID!=t.AD_Ref_List_ID)
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:43
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference SET Name='Scaling Factors',Updated=TO_TIMESTAMP('2008-10-03 12:31:43','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:31:43
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference_Trl SET IsTranslated='N' WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:32:44
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference SET Description='Factors for scaling the results of financial reports.', Help='Currently supported: thousand, million.',Updated=TO_TIMESTAMP('2008-10-03 12:32:44','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:32:44
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Reference_Trl SET IsTranslated='N' WHERE AD_Reference_ID=53285
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:33:17
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Column SET AD_Reference_Value_ID=53285, AD_Reference_ID=17, FieldLength=1, Help='Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of "Thousand" will display as 123.',Updated=TO_TIMESTAMP('2008-10-03 12:33:17','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=56354
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:33:17
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Field SET Name='Factor', Description='Scaling factor.', Help='Numbers are divided by the scaling factor for presentation. E.g. 123,000 with a scaling factor of "Thousand" will display as 123.' WHERE AD_Column_ID=56354 AND IsCentrallyMaintained='Y'
|
||||
;
|
||||
|
||||
-- 3/10/2008 12:53:38
|
||||
-- Financial reporting improvements
|
||||
UPDATE AD_Ref_List SET Value='M',Updated=TO_TIMESTAMP('2008-10-03 12:53:38','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Ref_List_ID=53437
|
||||
;
|
||||
|
Loading…
Reference in New Issue