Skip to content

Tag: sql-server

SQL Query, loop through data

I have a database with the following fields: UserID, DateRecorded and Score. A new entry is added to the table each time the score is updated. Here is an example of a user record: From the query I would like it to show me only the scores of all users with the earliest DateRecorded. Although not much familiar …

SQL Server 18 – merging dates around midnight

I would like to ask if anyone could help me with this. I have a table with user traffic on websites. The important column is Timestamp which looks like this. Timestamps are used to calculate sessions. An hour or so in timestamps means one session. The problem is that calculated session is different when the a…

Save VB6 values ​in SQL

I have this interface: When the add button is pressed, a UserControl with the same fields is added: So, the question is: How do I save the main values ​​and those that have been added? That is, if the user pressed the add button, how do I also save those values? Currently, this is the entire interface code: A…