Go Back > Forum > Baan Quick Support: Functional & Technical > Tools Development

User login

Frontpage Sponsor


Google search

How big is your Baan-DB (just Data AND Indexes)
0 - 200 GB
200 - 500 GB
500 - 800 GB
800 - 1200 GB
1200 - 1500 GB
1500 - 2000 GB
> 2000 GB
Total votes: 41

Baanboard at LinkedIn

Reference Content

Thread Tools Display Modes
Old 5th September 2018, 10:52
Svidos29 Svidos29 is offline
Join Date: Oct 2017
Posts: 49
Svidos29 is on a distinguished road
Baan: Baan IV - DB: Onpen Sql - OS: Windows 10
delete chars from string
Baan: ERP LN 6.1 FP8 (Infor ERP 10.2)
C/S: Client

hi all,

i should try to delete some characters from a string with certains conditions. If i have that string longer than 20 i have to delete the first characters, until i arrive to 20.
How can i manage it ?

Reply With Quote
Old 5th September 2018, 10:57
tmannais's Avatar
tmannais tmannais is offline
Senior Member
Join Date: Jul 2017
Posts: 112
tmannais is on a distinguished road
Baan: LN 10.5 - DB: MySQL - OS: Windows

output = str.substring$(your.string, len(your.string) - 20, len(your.string))
not tested though. Feel free to adjust where it needs to be done.
Reply With Quote
Sponsored Links
Old 5th September 2018, 12:08
Svidos29 Svidos29 is offline
Join Date: Oct 2017
Posts: 49
Svidos29 is on a distinguished road
Baan: Baan IV - DB: Onpen Sql - OS: Windows 10

thanks, but i've found also this way:

lng = len(trim$(field))

lng2 = 20

if lng > 20 then
diff = lng - lng2
field = field(diff;20)


Last edited by Svidos29 : 6th September 2018 at 13:14.
Reply With Quote
Old 11th September 2018, 21:05
NPRao's Avatar
NPRao NPRao is offline
Join Date: Aug 2001
Location: Pacific NW, USA
Posts: 3,076
NPRao will become famous soon enough
Baan: Baan 4-5,5.2(Reger),LN-6.1,Infor LN-10.x - DB: Oracle,MS-SQL - OS: HPUX, Linux, Windows
Since you are on the 10.2 release you can use the Standard Tools function -
function string str.remove$ (const string string$, long offset, long nchars)


Returns a copy of a string having a number of characters deleted, beginning at a specified character position.

const string string$ a string

long offset the character position to begin deleting characters; note that:

if offset < 1, then nothing is removed
if offset > len(string$), then nothing is removed

long nchars the number of characters to remove; note that:

if nchars < 0, then all characters starting at offset are removed
if nchars = 0, then nothing is removed
if offset + nchars > len(string$), then all characters starting at offset are removed

Return values
A string equivalent to the specified string less the specified number of characters

This function is implemented in the 4GL Tools and can be used in all script types. This function is available from TIV level 1700.
The art of perfection does not lie in doing extraordinary things but, doing ordinary things extraordinarily well. [-N. Prashanth Rao]
How To Ask Questions The Smart Way,BaaNBoard,NPRao
Reply With Quote

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
DEV: Export any Baan table to (proper) Excel Francesco Code & Utilities 27 2nd September 2011 15:00
Writing Export Conditions ian_j_albert Tools Development 4 22nd July 2010 08:30
Help regarding tools session rahul.kolhe22 Tools Development 4 22nd January 2010 14:31
problems with stpapi.zoom.option Finnigan AFS/DDC/OLE: Function servers 5 3rd November 2009 15:04
File Browser Bogdan Tools Development 52 7th January 2004 09:17

All times are GMT +2. The time now is 22:50.

©2001-2018 - -