{"record":{"id":"fbbeb9d06e0a784a","repo":"googleapis/mcp-toolbox","slug":"unable-to-execute-query-w-fbbeb9","errorCode":null,"errorMessage":"unable to execute query: %w","messagePattern":"unable to execute query: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/sources/snowflake/snowflake.go","lineNumber":108,"sourceCode":"\treturn false\n}\n\nfunc (s *Source) SourceType() string {\n\treturn SourceType\n}\n\nfunc (s *Source) ToConfig() sources.SourceConfig {\n\treturn s.Config\n}\n\nfunc (s *Source) SnowflakeDB() *sqlx.DB {\n\treturn s.DB\n}\n\nfunc (s *Source) RunSQL(ctx context.Context, statement string, params []any) (any, error) {\n\trows, err := s.DB.QueryxContext(ctx, statement, params...)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"unable to execute query: %w\", err)\n\t}\n\tdefer rows.Close()\n\n\tout := []any{}\n\tfor rows.Next() {\n\t\tcols, err := rows.Columns()\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"unable to get columns: %w\", err)\n\t\t}\n\n\t\tvalues := make([]interface{}, len(cols))\n\t\tvaluePtrs := make([]interface{}, len(cols))\n\t\tfor i := range values {\n\t\t\tvaluePtrs[i] = &values[i]\n\t\t}\n\n\t\tif err := rows.Scan(valuePtrs...); err != nil {\n\t\t\treturn nil, fmt.Errorf(\"unable to scan row: %w\", err)","sourceCodeStart":90,"sourceCodeEnd":126,"githubUrl":"https://github.com/googleapis/mcp-toolbox/blob/8cc6e09de2ad7b8bffc77751799585a1401a48eb/internal/sources/snowflake/snowflake.go#L90-L126","documentation":"QueryxContext failed executing the statement in RunSQL — the SQL was rejected by Snowflake (syntax, unknown object, permissions) or the connection dropped mid-query.","triggerScenarios":"Thrown at internal/sources/snowflake/snowflake.go:108 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Check the SQL statement syntax and referenced objects","Verify the role has privileges on the warehouse/schema/table","Retry on transient network or session-expiration errors"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"8cc6e09de2ad7b8bffc77751799585a1401a48eb","analyzedAt":"2026-09-05T01:10:36.887Z","contentChangedAt":"2026-09-05T01:10:36.887Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}