ue_datastorevalues

This is an dynamic array which manages a set of Datastores.

Each Datastore has a unique name.

 

You need to declare it like:

 

instance datastore lds

 

Now you can add a Datastore with:

 

lds=<sql-Anweisung>

 

You can access the values with Place holders <objectname.spaltenname> and / or within the multi mode with <datastorename.spaltenname> (inside the Multimode you need to provide the objectname.

 

help-achtung

The Syntax inside the Multi mode will always be                [objectname].[command].[datastorename]=[arguments]

and within the normal mode ( Simple mode ) it will be :        [objectname].[command].[arguments]

 

Set a field with a value:

objectname.columnname.value=<value>

 

Get a field value:

messagebox=<objectname.columnname.value>

 

The attribute "value"  is not compelling on this occasion

 

Example:

declare=lds=ue_datastorevalues

// we don't use "select *"

// faster is command "select (fieldfrom="tablename") ..."

lds=select (fieldfrom="OITM") from "OITM"

lds.setrow=1

if <lds.itemcode.value> = "myitem" then

  lds.u_beas_match.value=yes

end if

destroy=lds

 

Videos

youtube Display content of a datastore

youtube Extended Datastore Import

youtube bsl and datastore

 

Commands:

 

Methode

Description

multimode=<0/1>

select=<sqlstatement>

bsl=<odata get command>

execute <procedure>

add=<sql>

add=<psr-file>
multimode:
add=mytds=<sql>

setrow=<row>

Set actual row

setrow=-x,+x,top,buttom
  setrow=top

  setrow=<loop>

  setrow=+5  

  setrow=tomtom=10

destroy

Destroy all Datastores



dir=<director>

sort=<sortarguments>

Sort the Datastore

lds=sort=itemcode d

filter=<arguments>

Filter the Datastore

lds=filter=substring(itemcode,1,1)='1'

find=<argument>

insertrow

Insert a row the then end end set the Cursor on that row
lds=insertrow

deleterow

Delete the current row and set the cursor to the next row.

lds=deleterow

setitem=<colname>=<value>

Set Item.

lds=setitem=itemname=hello

rowscopy=<datasdlatore>

rowscopytodwx=<dw_x>

copy datastore in datawindow dw_x

lds=rowscopytodwx=dw_1

updatetable=<table>

updatetable=<table[,primary[,primary]]>

 

 

update

Updates the DataStore

 

 

Methode

Description

addfield=fieldname=length=typ

Add a field to the Datastore
typ=n,i or d=numeric, d=datetime, otherwise Chars

fieldreset

reset all fields which has been declared with "addfield"

getparent=<datastorename>

 

get reference datastorevalue from parent window

declare=mydts=ue_datastorevalues

mydts=getparent=mydtsfromparentwindow

 

getparentcopy=<datastorevalue>

get copy from parent datastorevalue

declare=mydts=ue_datastorevalues

mydts=getparentcopy=mydtsfromparentwindow

blobread=<id>

blobwrite=<id>=<filename>

 

Export / Import

Methode

Description

saveas=<typ>=<filename>

importfromfile=<filename>

importfromdbfile

importfromexcel

importfromxml=<filename>[<tab>Properties]

importfromfile=<filename>[<tab>Properties]

importfromxmlstring=<string>

Import from string. Format see importfromxml

importdbstring=<dbstring>

Import from string in Datastore from Format "dbstring"

return errormessage in "value". If empty, all is ok

example:

lds1.saveas=dbstring

lds2.importdbstring=<value>

importtextfile=<filename>=<startrow>

importcsvfile=<filename>=<separator>

importdbase3file=<filename>

import a dbase3-file