Quantcast
Channel: MySQL Forums - Microsoft SQL Server
Viewing all articles
Browse latest Browse all 686

Query SQL Server to MySql (no replies)

$
0
0
Hi,

I need help for transform the SQL Server Query from Mysql Query.

This is my query:

-------------------------------------------------------------------------------
"
DECLARE @em varchar(100) SET @em = ?
DECLARE @ident int SET @ident = (SELECT u.id_user FROM User u WHERE email = @em)
DECLARE @apel varchar(100) SET @apel = (SELECT u.apel FROM User u WHERE email = @em)
SELECT u.email, p.permission
FROM User u, user_permission p
WHERE u.id_user = p.User
AND u.email = @em;
UPDATE User SET LastAccess =GETDATE()
WHERE email = @em;
INSERT INTO Access VALUES(@apel, GETDATE(), @ident);
UPDATE User SET access= (access +1) WHERE email = @em;
"
--------------------------------------------------------------------------------

I would be grateful for those who help me because I tried and not found the solution.

Thanks.

Viewing all articles
Browse latest Browse all 686

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>