Recent

Author Topic: update row with combination of fields in same row  (Read 2225 times)

ronhud

  • Full Member
  • ***
  • Posts: 105
update row with combination of fields in same row
« on: September 24, 2018, 12:42:23 pm »
I have a Firebird database with about 100 tables with identical structure.  A table has rows which contain a Date column , a Time column and a Timestamp column.   I want to update the Timestamp by combining the Date and Time coulmns for that row.    I can find examples of using two different tables for this but not so far for the same table.  I thought of a SQLQuery with update and select but I cant see how to combine these in the one statement .

ttomas

  • Sr. Member
  • ****
  • Posts: 251
Re: update row with combination of fields in same row
« Reply #1 on: September 24, 2018, 01:04:52 pm »
This is FirebirdSQL question
Code: Pascal  [Select][+][-]
  1. update table1 set mytimestampfield=mydatefield+mytimefield

ronhud

  • Full Member
  • ***
  • Posts: 105
Re: update row with combination of fields in same row
« Reply #2 on: September 24, 2018, 01:08:09 pm »
thanks so simple!

 

TinyPortal © 2005-2018