From cd3c7325a57ef65d43edf60994853eae41517aa1 Mon Sep 17 00:00:00 2001 From: Peter van Dijk Date: Fri, 11 Nov 2016 18:03:22 +0100 Subject: [PATCH] update odbc-sqlite3 queries in regression tests --- .../backends/godbc_sqlite3-master | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/regression-tests/backends/godbc_sqlite3-master b/regression-tests/backends/godbc_sqlite3-master index d977e4d74..af031c1d4 100644 --- a/regression-tests/backends/godbc_sqlite3-master +++ b/regression-tests/backends/godbc_sqlite3-master @@ -11,6 +11,7 @@ module-dir=./modules launch=godbc godbc-datasource=$GODBC_SQLITE3_DSN +# ../pdns/pdns_server --module-dir=./modules/ --launch=gsqlite3 --config | grep gsqlite3 | grep query | grep = | cut -c3- | perl -pe 's/^gsqlite3/godbc/; s/:\w+/?/g' godbc-activate-domain-key-query=update cryptokeys set active=1 where domain_id=(select id from domains where name=?) and cryptokeys.id=? godbc-add-domain-key-query=insert into cryptokeys (domain_id, flags, active, content) select id, ?,?, ? from domains where name=? godbc-any-id-query=SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE disabled=0 and name=? and domain_id=? @@ -31,35 +32,34 @@ godbc-delete-zone-query=delete from records where domain_id=? godbc-get-all-domain-metadata-query=select kind,content from domains, domainmetadata where domainmetadata.domain_id=domains.id and name=? godbc-get-all-domains-query=select domains.id, domains.name, records.content, domains.type, domains.master, domains.notified_serial, domains.last_check, domains.account from domains LEFT JOIN records ON records.domain_id=domains.id AND records.type='SOA' AND records.name=domains.name WHERE records.disabled=0 OR ? godbc-get-domain-metadata-query=select content from domains, domainmetadata where domainmetadata.domain_id=domains.id and name=? and domainmetadata.kind=? +godbc-get-last-inserted-key-id-query=select last_insert_rowid() godbc-get-order-after-query=select min(ordername) from records where disabled=0 and ordername > ? and domain_id=? and ordername is not null godbc-get-order-before-query=select ordername, name from records where disabled=0 and ordername <= ? and domain_id=? and ordername is not null order by 1 desc limit 1 godbc-get-order-first-query=select ordername from records where disabled=0 and domain_id=? and ordername is not null order by 1 asc limit 1 -godbc-get-order-last-query=select ordername from records where disabled=0 and ordername != '' and domain_id=? and ordername is not null order by 1 desc limit 1 +godbc-get-order-last-query=select ordername, name from records where disabled=0 and ordername != '' and domain_id=? and ordername is not null order by 1 desc limit 1 godbc-get-tsig-key-query=select algorithm, secret from tsigkeys where name=? godbc-get-tsig-keys-query=select name,algorithm, secret from tsigkeys godbc-id-query=SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE disabled=0 and type=? and name=? and domain_id=? godbc-info-all-master-query=select id,name,master,last_check,notified_serial,type from domains where type='MASTER' -godbc-info-all-slaves-query=select id,name,master,last_check,type from domains where type='SLAVE' +godbc-info-all-slaves-query=select id,name,master,last_check from domains where type='SLAVE' godbc-info-zone-query=select id,name,master,last_check,notified_serial,type,account from domains where name=? godbc-insert-comment-query=INSERT INTO comments (domain_id, name, type, modified_at, account, comment) VALUES (?, ?, ?, ?, ?, ?) -godbc-insert-empty-non-terminal-query=insert into records (domain_id,name,type,disabled,auth) values (?,?,null,0,'1') -godbc-insert-ent-order-query=insert into records (type,domain_id,disabled,name,ordername,auth) values (null,?,0,?,?,?) -godbc-insert-ent-query=insert into records (type,domain_id,disabled,name,auth) values (null,?,0,?,?) -godbc-insert-record-order-query=insert into records (content,ttl,prio,type,domain_id,disabled,name,ordername,auth) values (?,?,?,?,?,?,?,?,?) -godbc-insert-record-query=insert into records (content,ttl,prio,type,domain_id,disabled,name,auth) values (?,?,?,?,?,?,?,?) -godbc-insert-slave-query=insert into domains (type,name,master,account) values('SLAVE',?,?,?) -godbc-insert-zone-query=insert into domains (type,name) values('NATIVE',?) +godbc-insert-empty-non-terminal-order-query=insert into records (type,domain_id,disabled,name,ordername,auth,ttl,prio,change_date,content) values (null,?,0,?,?,?,null,null,null,null) +godbc-insert-record-query=insert into records (content,ttl,prio,type,domain_id,disabled,name,ordername,auth,change_date) values (?,?,?,?,?,?,?,?,?,null) +godbc-insert-zone-query=insert into domains (type,name,master,account,last_check,notified_serial) values(?, ?, ?, ?, null, null) godbc-list-comments-query=SELECT domain_id,name,type,modified_at,account,comment FROM comments WHERE domain_id=? godbc-list-domain-keys-query=select cryptokeys.id, flags, active, content from domains, cryptokeys where cryptokeys.domain_id=domains.id and name=? godbc-list-query=SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE (disabled=0 OR ?) and domain_id=? order by name, type godbc-list-subzone-query=SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE disabled=0 and (name=? OR name like ?) and domain_id=? godbc-master-zone-query=select master from domains where name=? and type='SLAVE' godbc-nullify-ordername-and-update-auth-query=update records set ordername=NULL,auth=? where domain_id=? and name=? and disabled=0 +godbc-nullify-ordername-and-update-auth-type-query=update records set ordername=NULL,auth=? where domain_id=? and name=? and type=? and disabled=0 godbc-remove-domain-key-query=delete from cryptokeys where domain_id=(select id from domains where name=?) and cryptokeys.id=? godbc-remove-empty-non-terminals-from-zone-query=delete from records where domain_id=? and type is null +godbc-search-comments-query=SELECT domain_id,name,type,modified_at,account,comment FROM comments WHERE name LIKE ? OR comment LIKE ? LIMIT ? +godbc-search-records-query=SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE name LIKE ? OR content LIKE ? LIMIT ? godbc-set-domain-metadata-query=insert into domainmetadata (domain_id, kind, content) select id, ?, ? from domains where name=? godbc-set-tsig-key-query=replace into tsigkeys (name,algorithm,secret) values(?,?,?) -godbc-supermaster-name-to-ips=select ip,account from supermasters where nameserver=? and account=? godbc-supermaster-query=select account from supermasters where ip=? and nameserver=? godbc-update-account-query=update domains set account=? where name=? godbc-update-kind-query=update domains set type=? where name=? -- 2.49.0