MyRecord.where(field_name: value).takenow fails with
TinyTds::Error: Invalid column name '"TicketNo", "UniqueID", "ItemNo"'.: EXEC sp_executesql N'SELECT [Tkscale].* FROM [Tkscale] WHERE [Tkscale].[TicketNo] = @0 ORDER BY [Tkscale].["TicketNo", "UniqueID", "ItemNo"] ASC OFFSET 0 ROWS FETCH NEXT @1 ROWS ONLY', N'@0 nvarchar(max), @1 int', @0 = N'10234770', @1 = 1which is odd since I didn't ask for the ordering. I'm not sure how to fix this. I have set
MyRecord.table_name = 'Tkbatch'and
MyRecord.primary_key = :UniqueId.
["TicketNo", "UniqueID", "ItemNo"]. I can't find an issue or in the code where this should be addressed. any ideas?
orderbut that's kind of a workaround
connectis has the wrong username. There was an
@serverautomatically appended to it. I don't know if that is what the problem might be?
connect server name not founderror. I'm thinking this is just for connecting to a local sql server, and not one that is on a completely different machine. Can anyone point me in the right direction?
Perhaps I'm missing something, is there a way to define an Identity column that is not a primary key?
I am working with a legacy database which has some non-PK identity columns. When a performed a schema dump against our development database nothing seems to indicate that these columns are to be auto incremented.