2021-04-19 Fred Gleason <fredg@paravelsystems.com>

* Escaped all SQL identifiers in 'rdcatch/'.
	* Replaced " with ' delimiters in all SQL literal strings in
	'rdcatch/'.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2021-04-19 19:29:47 -04:00
parent d7f395561e
commit 5f2dc2a7a1
12 changed files with 330 additions and 323 deletions

View File

@@ -60,8 +60,8 @@ AddRecording::AddRecording(QString *filter,QWidget *parent)
button->setFont(buttonFont());
button->setText(tr("Recording"));
button->setDisabled(true);
QString sql=QString("select CHANNEL from DECKS \
where (CARD_NUMBER>=0)&&(CHANNEL>0)&&(CHANNEL<=9)");
QString sql=QString("select `CHANNEL` from `DECKS` where ")+
"(`CARD_NUMBER`>=0)&&(`CHANNEL`>0)&&(`CHANNEL`<=9)";
RDSqlQuery *q=new RDSqlQuery(sql);
if(q->first()) {
button->setEnabled(true);
@@ -77,8 +77,8 @@ AddRecording::AddRecording(QString *filter,QWidget *parent)
button->setFont(buttonFont());
button->setText(tr("Playout"));
button->setDisabled(true);
sql=QString("select CHANNEL from DECKS where (CARD_NUMBER>=0)&&")+
"(PORT_NUMBER>=0)&&(CHANNEL>128)&&(CHANNEL<=137)";
sql=QString("select `CHANNEL` from `DECKS` where (`CARD`_NUMBER`>=0)&&")+
"(`PORT_NUMBER`>=0)&&(`CHANNEL`>128)&&(`CHANNEL`<=137)";
q=new RDSqlQuery(sql);
if(q->first()) {
button->setEnabled(true);