Package DE_EPAGES::Object::API::Table::Currency
interface for table Currency
Functions
- DeleteCurrency
- ExistsCurrency
- ExistsCurrencyByNumCode
- GetAllInfoCurrencies
- GetAllPKeyCurrencies
- GetInfoCurrenciesByLeadCurrencyID
- GetInfoCurrenciesByNumCode
- GetInfoCurrency
- GetInfoCurrencyByNumCode
- GetPKeyCurrenciesByLeadCurrencyID
- GetPKeyCurrenciesByNumCode
- GetPKeyCurrencyByNumCode
- InsertCurrency
- UpdateCurrency
DeleteCurrency
Deletes a(n) Currency.
Syntax |
DeleteCurrency($CurrencyID);
DeleteCurrency($hCurrency); # if $hCurrency includes CurrencyID
|
Input |
- $CurrencyID (char(3))
- alpha currency code (ISO 4217) (primary key)
|
ExistsCurrency
Returns true if the Currency exists.
Syntax |
$exists = ExistsCurrency($CurrencyID);
|
Input |
- $CurrencyID (char(3))
- alpha currency code (ISO 4217)
|
Return |
- $exists (boolean)
- 1/0 the Currency exists (yes/no)
|
ExistsCurrencyByNumCode
Returns true if a Currency by alternate key NumCode exists.
Syntax |
$CurrencyID = ExistsCurrencyByNumCode($NumCode);
|
Input |
- $NumCode (int)
- numeric code of currency iso 4217
|
Return |
- $exists (boolean)
- 1/0 the u_currency_numcode exists (yes/no)
|
GetAllInfoCurrencies
Returns all objects of Currency.
Syntax |
$ahCurrencys = GetAllInfoCurrencies();
|
Return |
- $ahCurrencys (reference to array of hashes)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
GetAllPKeyCurrencies
Returns all Currency identifiers.
Syntax |
$aCurrencyIDs = GetAllPKeyCurrencies();
|
Return |
- $aCurrencyIDs (reference to array of char(3))
- alpha currency code (ISO 4217)
|
GetInfoCurrenciesByLeadCurrencyID
Returns objects of Currency by alternate key LeadCurrencyID.
Syntax |
$ahCurrencies = GetInfoCurrenciesByLeadCurrencyID($LeadCurrencyID);
|
Input |
- $LeadCurrencyID (char(3))
- lead currency code
|
Return |
- $ahCurrencies (reference to array of hashes)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
GetInfoCurrenciesByNumCode
Returns objects of Currency by alternate key NumCode.
Syntax |
$ahCurrencies = GetInfoCurrenciesByNumCode($NumCode);
|
Input |
- $NumCode (int)
- numeric code of currency iso 4217
|
Return |
- $ahCurrencies (reference to array of hashes)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
GetInfoCurrency
Returns the Currency by identifier.
Syntax |
$hCurrency = GetInfoCurrency($CurrencyID);
|
Input |
- $CurrencyID (char(3))
- alpha currency code (ISO 4217) (primary key)
|
Return |
- $hCurrency (reference to hash)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
GetInfoCurrencyByNumCode
Returns the object of Currency by alternate key NumCode.
Syntax |
$hCurrency = GetInfoCurrencyByNumCode($NumCode);
|
Input |
- $NumCode (int)
- numeric code of currency iso 4217
|
Return |
- $hCurrency (reference to hash)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
GetPKeyCurrenciesByLeadCurrencyID
Returns primary keys of Currency by alternate key LeadCurrencyID.
Syntax |
$aKeys = GetPKeyCurrenciesByLeadCurrencyID($LeadCurrencyID);
|
Input |
- $LeadCurrencyID (char(3))
- lead currency code
|
Return |
- $aKeys (reference to array of char(3))
- alpha currency code (ISO 4217) (primary key)
|
GetPKeyCurrenciesByNumCode
Returns primary keys of Currency by alternate key NumCode.
Syntax |
$aKeys = GetPKeyCurrenciesByNumCode($NumCode);
|
Input |
- $NumCode (int)
- numeric code of currency iso 4217
|
Return |
- $aKeys (reference to array of char(3))
- alpha currency code (ISO 4217) (primary key)
|
GetPKeyCurrencyByNumCode
Returns primary key of Currency by alternate key NumCode.
Syntax |
$CurrencyID = GetPKeyCurrencyByNumCode($NumCode);
|
Input |
- $NumCode (int)
- numeric code of currency iso 4217
|
Return |
- $CurrencyID (char(3))
- alpha currency code (ISO 4217) (primary key)
|
InsertCurrency
Creates an entry of Currency.
Syntax |
InsertCurrency($hCurrency);
|
Input |
- $hCurrency (reference to hash)
- with following keys:
- CurrencyID - alpha currency code (ISO 4217) (primary key)- char(3)
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|
UpdateCurrency
Updates a(n) Currency if any element was changed.
Syntax |
UpdateCurrency($CurrencyID, $hCurrency);
UpdateCurrency($hCurrency); # if $hCurrency includes CurrencyID
|
Input |
- $CurrencyID (char(3))
- alpha currency code (ISO 4217) (primary key)
- $hCurrency (reference to hash)
- with following keys:
- IsUsed - is currency used - bit
- NumCode - numeric code of currency iso 4217 - int
- Name - name of currency - varchar(255)
- MinorUnit - decimals of minor unit (optional)- int
- LeadCurrencyID - lead currency code (optional)- char(3)
- Factor - factor lead to current (Currency = Lead * Factor) (optional)- numeric(20,10)
- Symbol - default symbol of currency (optional)- nvarchar(5)
- PosFormat - format for positive numbers, symbol in front of or behind number ('¤ x' or 'x ¤'), x will be replaced by number ¤ by currency symbol. (optional)- varchar(10)
- NegFormat - format for negative numbers, symbol in front of or behind number ('-¤ x' or 'x ¤-'), x will be replaced by number ¤ by currency symbol. its only allowed to use '-' for negative numbers. (optional)- varchar(10)
|