{"record":{"id":"b0f8aa3cb68e7f82","repo":"sqlmapproject/sqlmap","slug":"switch-dump-is-incompatible-with-switch-sea","errorCode":null,"errorMessage":"switch '--dump' is incompatible with switch '--search'","messagePattern":"switch '--dump' is incompatible with switch '--search'","errorType":"exception","errorClass":"SqlmapSyntaxException","httpStatus":null,"severity":"error","filePath":"lib/core/option.py","lineNumber":2849,"sourceCode":"    if conf.secondUrl and conf.secondReq:\n        errMsg = \"option '--second-url' is incompatible with option '--second-req')\"\n        raise SqlmapSyntaxException(errMsg)\n\n    if conf.direct and conf.url:\n        errMsg = \"option '-d' is incompatible with option '-u' ('--url')\"\n        raise SqlmapSyntaxException(errMsg)\n\n    if conf.direct and conf.dbms:\n        errMsg = \"option '-d' is incompatible with option '--dbms'\"\n        raise SqlmapSyntaxException(errMsg)\n\n    if conf.titles and conf.nullConnection:\n        errMsg = \"switch '--titles' is incompatible with switch '--null-connection'\"\n        raise SqlmapSyntaxException(errMsg)\n\n    if conf.dumpTable and conf.search:\n        errMsg = \"switch '--dump' is incompatible with switch '--search'\"\n        raise SqlmapSyntaxException(errMsg)\n\n    if conf.alert and os.environ.get(\"SQLMAP_UNSAFE_ALERT\") != '1':\n        errMsg = \"for security reasons, to prevent execution of potentially malicious \"\n        errMsg += \"OS commands via configuration files or copy-paste attacks, \"\n        errMsg += \"the '--alert' option requires the environment variable \"\n        errMsg += \"'SQLMAP_UNSAFE_ALERT=1' to be explicitly set\"\n        raise SqlmapSystemException(errMsg)\n\n    if conf.evalCode and os.environ.get(\"SQLMAP_UNSAFE_EVAL\") != '1':\n        errMsg = \"for security reasons, to prevent execution of potentially malicious \"\n        errMsg += \"Python code via configuration files or copy-paste attacks, \"\n        errMsg += \"the '--eval' option requires the environment variable \"\n        errMsg += \"'SQLMAP_UNSAFE_EVAL=1' to be explicitly set\"\n        raise SqlmapSystemException(errMsg)\n\n    if conf.chunked and not any((conf.data, conf.requestFile, conf.forms, conf.openApiFile)):\n        errMsg = \"switch '--chunked' requires usage of (POST) options/switches '--data', '-r', '--forms' or '--openapi'\"\n        raise SqlmapSyntaxException(errMsg)","sourceCodeStart":2831,"sourceCodeEnd":2867,"githubUrl":"https://github.com/sqlmapproject/sqlmap/blob/0a35b20e3953d341be6c7ac75ccb0b3362540c8d/lib/core/option.py#L2831-L2867","documentation":"Startup-time mutual-exclusivity guard in _basicOptionValidation: sqlmap refuses to run when conf.dumpTable (--dump) and conf.search (--search) are both set, because --dump extracts known table contents while --search searches for database/table/column names by pattern — combining them is ambiguous and unsupported.","triggerScenarios":"Thrown at lib/core/option.py:2849 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Remove either --dump or --search from the command line, choosing the mode you actually want","To search for tables/columns by pattern, keep --search and drop --dump","To dump table data, keep --dump (with -D/-T/-C as needed) and remove --search"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0a35b20e3953d341be6c7ac75ccb0b3362540c8d","analyzedAt":"2026-08-26T23:02:52.002Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}