Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
ebc77c6d
Commit
ebc77c6d
authored
Jan 24, 2022
by
Oleksandr Byelkin
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'connect/10.2' into 10.2
parents
8acc7fb3
e3b9efb3
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
12 deletions
+20
-12
storage/connect/odbconn.cpp
storage/connect/odbconn.cpp
+13
-7
storage/connect/tabext.cpp
storage/connect/tabext.cpp
+7
-5
No files found.
storage/connect/odbconn.cpp
View file @
ebc77c6d
...
...
@@ -1422,7 +1422,7 @@ int ODBConn::ExecDirectSQL(char *sql, ODBCCOL *tocols)
PGLOBAL
&
g
=
m_G
;
void
*
buffer
;
bool
b
;
UWORD
n
;
UWORD
n
,
k
;
SWORD
len
,
tp
,
ncol
=
0
;
ODBCCOL
*
colp
;
RETCODE
rc
;
...
...
@@ -1489,15 +1489,16 @@ int ODBConn::ExecDirectSQL(char *sql, ODBCCOL *tocols)
}
else
{
do
{
rc
=
SQLExecDirect
(
hstmt
,
(
PUCHAR
)
sql
,
SQL_NTS
);
}
while
(
rc
==
SQL_STILL_EXECUTING
);
}
while
(
rc
==
SQL_STILL_EXECUTING
);
if
(
!
Check
(
rc
))
ThrowDBX
(
rc
,
"SQLExecDirect"
,
hstmt
);
do
{
rc
=
SQLNumResultCols
(
hstmt
,
&
ncol
);
}
while
(
rc
==
SQL_STILL_EXECUTING
);
}
while
(
rc
==
SQL_STILL_EXECUTING
);
k
=
0
;
// used for column number
}
// endif Srcdef
for
(
n
=
0
,
colp
=
tocols
;
colp
;
colp
=
(
PODBCCOL
)
colp
->
GetNext
())
...
...
@@ -1519,18 +1520,23 @@ int ODBConn::ExecDirectSQL(char *sql, ODBCCOL *tocols)
sprintf
(
m_G
->
Message
,
MSG
(
INV_COLUMN_TYPE
),
colp
->
GetResultType
(),
SVP
(
colp
->
GetName
()));
ThrowDBX
(
m_G
->
Message
);
}
// endif tp
}
// endif tp
if
(
m_Tdb
->
Srcdef
)
k
=
colp
->
GetIndex
();
else
k
++
;
if
(
trace
(
1
))
htrc
(
"Binding col=%u type=%d buf=%p len=%d slen=%p
\n
"
,
n
,
tp
,
buffer
,
len
,
colp
->
GetStrLen
());
k
,
tp
,
buffer
,
len
,
colp
->
GetStrLen
());
rc
=
SQLBindCol
(
hstmt
,
colp
->
GetIndex
()
,
tp
,
buffer
,
len
,
colp
->
GetStrLen
());
rc
=
SQLBindCol
(
hstmt
,
k
,
tp
,
buffer
,
len
,
colp
->
GetStrLen
());
if
(
!
Check
(
rc
))
ThrowDBX
(
rc
,
"SQLBindCol"
,
hstmt
);
}
// endif pcol
}
// endif colp
}
catch
(
DBX
*
x
)
{
if
(
trace
(
1
))
...
...
storage/connect/tabext.cpp
View file @
ebc77c6d
...
...
@@ -142,8 +142,14 @@ bool EXTDEF::DefineAM(PGLOBAL g, LPCSTR am, int poff)
Username
=
GetStringCatInfo
(
g
,
"User"
,
NULL
);
Password
=
GetStringCatInfo
(
g
,
"Password"
,
NULL
);
if
((
Srcdef
=
GetStringCatInfo
(
g
,
"Srcdef"
,
NULL
)))
// Memory was Boolean, it is now integer
if
(
!
(
Memory
=
GetIntCatInfo
(
"Memory"
,
0
)))
Memory
=
GetBoolCatInfo
(
"Memory"
,
false
)
?
1
:
0
;
if
((
Srcdef
=
GetStringCatInfo
(
g
,
"Srcdef"
,
NULL
)))
{
Read_Only
=
true
;
if
(
Memory
==
2
)
Memory
=
1
;
}
// endif Srcdef
Qrystr
=
GetStringCatInfo
(
g
,
"Query_String"
,
"?"
);
Sep
=
GetStringCatInfo
(
g
,
"Separator"
,
NULL
);
...
...
@@ -166,10 +172,6 @@ bool EXTDEF::DefineAM(PGLOBAL g, LPCSTR am, int poff)
if
(
Catfunc
==
FNC_TABLE
)
Tabtyp
=
GetStringCatInfo
(
g
,
"Tabtype"
,
NULL
);
// Memory was Boolean, it is now integer
if
(
!
(
Memory
=
GetIntCatInfo
(
"Memory"
,
0
)))
Memory
=
GetBoolCatInfo
(
"Memory"
,
false
)
?
1
:
0
;
Pseudo
=
2
;
// FILID is Ok but not ROWID
return
false
;
}
// end of DefineAM
...
...
Write
Preview
Markdown
is supported
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