Qserv - how to delete a table via REST API


Looking to delete an empty table in an unpublished database

Ingest: Delete a database or a table - Data Management - Confluence (lsstcorp.org)

Suggest something along the lines of

curl http://localhost:8080/ingest/database/test101/Object -X DELETE -H “Content-Type: application/json” -d ‘{“auth_key”:"###"}’

but this is returning 404 not found. So likely not getting the syntax right.

The REST services are running eg

curl http://localhost:8080/ingest/database/


Dear Mike,

thank you for the report! There was a bug in my documentation. The correct name of the resource is:


I have fixed the documentation.


Dear Igor

Thanks, that’s got rid of the 404 error I now get other errors but I think something (qserv?) has gone offline.


The error I got is

curl http://localhost:8080/ingest/table/test101/Object -X DELETE -H "Content-Type: application/json" -d '{"auth_key":"####"}'

after a few seconds

{“error”:“operation failed due to: Constructor failed mysql(-999 Error connecting to mysql with config:[host=qserv-czar, port=3306, user=root, password=XXXXXX, db=qservCssData, socket=]) [in function verify at core/modules/sql/SqlTransactionScope.cc:42]”,“error_ext”:{},“success”:0}[root@qserv-repl-ctl-0 qserv]#


Turns out the above error was due to some services being unavailable at that time.

It’s connecting now and working with

{"error":"the director table can't be deleted from the un-published catalog w/o deleting the whole database.","error_ext":{},"success":0}

which is fair enough :slight_smile: