Hi all,
I have a database table where a specific field (e. g. ID) is specified as character.
This field contains a number.
Now I want to get the highest ID which is available in the database table.
This statement does not work, because the max value is only determined by the first character.
SELECT single * FROM <table>
INTO <workarea>
WHERE id = (
SELECT MAX( id ) FROM <table>
).
Example: Entries in database table
ID
1
10
2
3
The max value is here then 3 and not 10. -> only the first character will be checked
Any ideas?
regards