[code]Try
Var myDB As New PostgreSQLDatabase
myDB.Host = “localhost”
myDB.Port = 5432
myDB.UserName = “postgres”
myDB.Password = “r4v4f7”
myDB.DatabaseName = “agentbox”
myDB.Connect
Var strSql As String = “select * from gat1400.ga_log order by gl_id limit 1”
Var rs As RowSet = myDB.SelectSQL(strSql)
rs.EditRow
rs.Column(“gl02”).StringValue = “test”
rs.SaveRow
myDB.CommitTransaction
Catch e As DatabaseException
Print e.Message
End Try[/code]
ERROR: relation "ga_log" does not exist
LINE 1: UPDATE ga_log SET gl02 = $1 WHERE gl_id = '1'
How To Resolve?
Probably the capitalization of that table name (“ga_log”) is somehow different (“ga_Log” maybe?) See: https://dev.to/lefebvre/dont-get-bit-by-postgresql-case-sensitivity--457i
Oh, and I see that you are using schema-qualified table names (which is a good thing) and I wonder if you overtax Xojo’s DB API’s ability to handle these properly (never used it much, so I can’t tell). You might be better off using prepared statements where you can specify the table name explicitly.
You are both right, the Recordset.Edit … .Update interface does not support schemas since ever. This is being tracked in <https://xojo.com/issue/11597> And obviously the bug was carried over to RowSet.EditRow … .SaveRow as well. Constructing the DML statements yourself does work with schema qualified table names, thus.