Functions in the Beas Database
Beas creates additional functions inside the database
All functions starting with "beas_"
MSSQL: for using functions, you need always the Prefix "dbo.", example : select dbo.beas_getdate()
Function |
Description |
|---|---|
beas_getdate() |
Returns the Mandant - Date-Time-Stamp same as getCompanyTime() from sap, but compatible to all sap-Versions. Example MSSQL: select dbo.beas_getdate()
|
beas_getsetup(variable,default) |
Returns system variable from Beas. If the variable does not exist, this function returns the default value.
Example MSSQL: select dbo.beas_getsetup('fert_afoabgallow','J') if return = J, user can't close a work order position
Example HANA: select beas_getsetup('fert_afoabgallow','J')
|
beas_getlocal(clientname,variable,default) |
Returns a local variable (Client-Variable) of Beas. If the variable does not exist, this function returns the default value.
Example MSSQL: select dbo.beas_getlocal('mystationname','fert_afoabgallow','J')
|
to_varchar(datetime date,varchar format) |
Alternative for HANA Syntax converts date time to string format is yyyy-mm-dd or yyymmdd all other formats are returned as an empty string Example: select dbo.to_varchar(getdate(),'yyyy-mm-dd') |
rpad(varchar text,int length) |
Alternative for HANA Syntax Do not use space or replicate. Use "dbo.rpad" this function converts this in "replicate" select dbo.rpad(' ',10) is the same as select replicate(' ',10) |
For more information on MSSQL and Hana see select