Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
clean-and-itasks
clean-libraries
Commits
1b1314d8
Commit
1b1314d8
authored
Oct 12, 2006
by
Rinus Plasmeijer
Browse files
*** empty log message ***
parent
e02a4bae
Changes
1
Hide whitespace changes
Inline
Side-by-side
libraries/Gerda/Gerda.icl
View file @
1b1314d8
...
...
@@ -486,19 +486,21 @@ where
(
GerdaFunctions
_
layoutK
_
_)
=
gerdaInt
[
SqlPrimary
]
removeTable
::
!
String
!*
Gerda
->
*
Gerda
removeTable
tableN
ame
g
=:{
layout
,
connection
,
state
}
removeTable
n
ame
g
=:{
layout
,
connection
,
state
}
#
(
r
,
h
,
state
)
=
SQLAllocHandle
SQL_HANDLE_STMT
connection
state
|
r
<>
SQL_SUCCESS
=
abort
"SQLAllocHandle SQL_HANDLE_STMT failed"
#
drop
=
"DROP TABLE "
+++
sqlEscape
(
"*"
+++
tableName
)
#
drop
=
"DROP TABLE "
+++
sqlEscape
tableName
(
r
,
state
)
=
SQLExecDirect
h
(
TRACE_SQL
drop
)
(
size
drop
)
state
// | r <> SQL_SUCCESS = abort ("SQLExecDirect failed " +++ drop)
#
(
r
,
state
)
=
SQLFreeHandle
SQL_HANDLE_STMT
h
state
|
r
<>
SQL_SUCCESS
=
abort
"SQLFreeHandle SQL_HANDLE_STMT failed"
#
(
m
,
layout
)
=
extractTable
(
"*"
+++
tableName
)
layout
#
(
m
,
layout
)
=
extractTable
tableName
layout
g
=
{
g
&
layout
=
layout
,
state
=
state
}
=
case
m
of
Just
table
->
closeTable
table
g
_
->
g
where
tableName
=
"*"
+++
name
writeToTable
::
!
String
![
Table
]
!(
GerdaWrite
a
)
a
!*
Gerda
->
(!
Int
,
!*
Gerda
)
writeToTable
tableName
tables
write
x
g
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment