A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mariadb.com/docs/server/reference/data-types/row-type-of below:

ROW TYPE OF | MariaDB Documentation

ROW TYPE OF | MariaDB Documentation
  1. Reference
  2. Data Types
ROW TYPE OF

This is special declaration only available inside a stored procedure.

CREATE TABLE rowtypeof_table(
  descr VARCHAR(20),
  val INT
);
INSERT INTO rowtypeof_table VALUES ('Life', 42);
DELIMITER $$
CREATE PROCEDURE rowtypeof_proc()
BEGIN
  DECLARE rec1 ROW TYPE OF rowtypeof_table;
  SELECT * INTO rec1 FROM rowtypeof_table;
  SELECT rec1.descr, rec1.val;
END;
$$
DELIMITER ;
CALL rowtypeof_proc();

+------------+----------+
| rec1.descr | rec1.val |
+------------+----------+
| Life       |       42 |
+------------+----------+

This page is: Copyright © 2025 MariaDB. All rights reserved.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4