Compare commits
3 commits
main
...
forge/BAIS
| Author | SHA1 | Date | |
|---|---|---|---|
| 7e1a43b20f | |||
| 575878b93f | |||
| bb952ba404 |
3 changed files with 50 additions and 0 deletions
3
.forge/BAIS-SPRING-SQL-001-attempt-1.md
Normal file
3
.forge/BAIS-SPRING-SQL-001-attempt-1.md
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
# BAIS-SPRING-SQL-001-attempt-1
|
||||
|
||||
Forge 이슈 작업 브랜치 `forge/BAIS-SPRING-SQL-001-attempt-1`.
|
||||
24
docs/lcfsql_transaction_map.md
Normal file
24
docs/lcfsql_transaction_map.md
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
# LcfSQL 트랜잭션 계약 맵
|
||||
|
||||
이 문서는 LcfSQL의 다양한 호출을 테이블, 조건, cardinality, transaction boundary로 정리한 것입니다.
|
||||
|
||||
## 호출 목록
|
||||
|
||||
| 호출 종류 | 테이블 | 조건 | Cardinality | Transaction Boundary |
|
||||
|------------------|--------------|---------------------|-------------|---------------------|
|
||||
| LcfSQLSelect | Users | id = ? | 0..1 | 시작 - 종료 |
|
||||
| SelectArray | Orders | userId = ? | 0..N | 시작 - 종료 |
|
||||
| Insert | Products | - | 1 | 시작 - 종료 |
|
||||
| Update | Users | id = ? | 0..1 | 시작 - 종료 |
|
||||
| Delete | Orders | id = ? | 0..1 | 시작 - 종료 |
|
||||
| OpenCursor | Transactions | userId = ? | 0..N | 시작 - 종료 |
|
||||
| Fetch | Transactions | cursorId = ? | 0..1 | 시작 - 종료 |
|
||||
|
||||
## 설명
|
||||
- **LcfSQLSelect**: 특정 사용자 정보를 조회합니다.
|
||||
- **SelectArray**: 특정 사용자의 모든 주문을 조회합니다.
|
||||
- **Insert**: 새로운 제품을 추가합니다.
|
||||
- **Update**: 특정 사용자의 정보를 업데이트합니다.
|
||||
- **Delete**: 특정 주문을 삭제합니다.
|
||||
- **OpenCursor**: 특정 사용자의 거래 내역을 커서로 열어 조회합니다.
|
||||
- **Fetch**: 열린 커서에서 거래 내역을 가져옵니다.
|
||||
23
sql/lcfsql_examples.sql
Normal file
23
sql/lcfsql_examples.sql
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
-- LcfSQL 예제 쿼리
|
||||
|
||||
-- 사용자 선택
|
||||
SELECT * FROM Users WHERE id = ?;
|
||||
|
||||
-- 주문 배열 선택
|
||||
SELECT * FROM Orders WHERE userId = ?;
|
||||
|
||||
-- 제품 삽입
|
||||
INSERT INTO Products (name, price) VALUES ('New Product', 19.99);
|
||||
|
||||
-- 사용자 업데이트
|
||||
UPDATE Users SET name = 'Updated Name' WHERE id = ?;
|
||||
|
||||
-- 주문 삭제
|
||||
DELETE FROM Orders WHERE id = ?;
|
||||
|
||||
-- 커서 열기
|
||||
DECLARE cursor CURSOR FOR SELECT * FROM Transactions WHERE userId = ?;
|
||||
OPEN cursor;
|
||||
|
||||
-- 커서에서 데이터 가져오기
|
||||
FETCH NEXT FROM cursor;
|
||||
Loading…
Add table
Add a link
Reference in a new issue