Skip to content

Tag: sql

MySQL Default Record from Table

I use MySQL 5.6 and I have 3 tables. Two of them are a list of data, and the third table is used for a relationship between them. In the third table I would like to identify a default record for each id1, so I added a column named predt to let me know which record is the default one.

oracle data base error ORA-00920 invalid relational operator

This is my code after check syntax this error appear ORA-00920 invalid relational operator What problem on this code? Answer Unless you have a function called region that accepts three string arguments, this code does not make sense: I assume that you are missing the in:

Timestamps and addition of weeks

My query requires me to find the number of people positive and their infectious periods which is plus and minus 2 weeks. In my query below I keep getting null in my 2 weeks Timestamp What is wrong with my equation and why won’t it add the 2 weeks in the next column? In DB browser this is the format