I have PWD which should go like 0001, 0002, 0003, 0004
So when i want to add the new record in database i get the max value like this
sql.Query(" SELECT pwrd FROM users WHERE pwrd = (SELECT max(pwrd ) FROM users)")
Dim highest As Integer = (sql.SQLDataset.Tables(0).Rows(0).Item(0))
On this way i get the highest row from table example "0004" Now when adding the new query i need to increment that value for 1 to be "0005"
If i go TextBox1.Text = Highest + 1
i will get 5 only without "000"