Search
 
SCRIPT & CODE EXAMPLE
 

SQL

insert data into multiple tables mysql

BEGIN;
INSERT INTO users (username, password)
  VALUES('test', 'test');
INSERT INTO profiles (userid, bio, homepage) 
  VALUES(LAST_INSERT_ID(),'Hello world!', 'http://www.stackoverflow.com');
COMMIT;
Comment

mysql insert into multiple tables

BEGIN;
INSERT INTO users (username, password)
  VALUES('test', 'test');
INSERT INTO profiles (userid, bio, homepage) 
  VALUES(LAST_INSERT_ID(),'Hello world!', 'http://www.stackoverflow.com');
COMMIT;
Comment

PREVIOUS NEXT
Code Example
Sql :: equi join in sql 
Sql :: aggregate functions 
Sql :: mysql dump database tables only 
Sql :: what is mysql 
Sql :: asp.net core sql server stored procedure 
Sql :: adding column 
Sql :: Sql Text or Varchar 
Sql :: select * from 
Sql :: How do I install microsoft SQL on my Mac? 
Sql :: migrations.RunSQL 
Sql :: oracle select into and inner join 
Sql :: how to use sqlcommand 
Sql :: sqlite3.OperationalError: near "WHERE": syntax error 
Sql :: sql to linq converter 
Sql :: oracle sysdba connect as another user 
Sql :: setup mysql and wordpress on docker mac 
Sql :: cronjob mysql backup 
Sql :: ORACLE: How to get all column with GROUP by only 1 column? 
Sql :: how to create a table in sql stack overflow 
Sql :: PDOException: SQLSTATE[HY093]: Invalid parameter numb 
Sql :: from UCSC MySQL database Use database hg38. 
Sql :: get start of week big query 
Sql :: creating a simple notify in postgresql 
Sql :: postgresql insert string 
Sql :: MySql shutdown unexpectedly InnoDB: Mutexes and rw_locks use Windows interlocked functions InnoDB: Uses event mutexes 
Sql :: SQL IN Operator With Duplicate Values 
Sql :: INSERT INTO RAHULDEV 
Sql :: sql gather statistics to increase performance 
Sql :: get all databases and their tables without primary key mysql 
Sql :: mysql view command does not work - privileges problem 
ADD CONTENT
Topic
Content
Source link
Name
7+4 =