6
I need to insert into a table ACCESS
some values from another table plus the time and the user who made the record.
I know to get the data from the other table just do something like:
INSERT INTO TABELA(ID, NOME, ENDERECO)
SELECT ID, NOME, ENDERECO FROM MEUBANCO2..MINHATABELA
WHERE ..
How do I also enter the time and user data in the same command INSERT
INTO, besides the SELECT
(that is already getting some data from another table)?
Can’t you just add a GETDATE()? INSERT INTO TABLE(ID, NAME, ADDRESS, DATA) SELECT ID, NAME, ADDRESS, GETDATE() AS 'DATA' FROM...
– Leandro Angelo
User is a table or system user? You want to enter the time of action?
– Randrade
Which database?
– David
Thank you, @Leandroangelo!
– Leandro
It’s an Access database, @David. Thanks! Abs!
– Leandro