Github user bomeng commented on a diff in the pull request:
https://github.com/apache/spark/pull/12104#discussion_r58419381
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/InMemoryCatalog.scala
---
@@ -48,7 +48,7 @@ class InMemoryCatalog extends ExternalCatalog {
private val catalog = new scala.collection.mutable.HashMap[String,
DatabaseDesc]
private def filterPattern(names: Seq[String], pattern: String):
Seq[String] = {
- val regex = pattern.replaceAll("\\*", ".*").r
+ val regex = pattern.replaceAll("\\.\\*", "\\*").replaceAll("\\*",
"\\.\\*").r
--- End diff --
@andrewor14 If you want to include my changes in your PR, that is fine. I
did not see your changes for that though.
@yhuai I think we need to have consistent behavior as Hive does. Hive
supports query like "list functions like '\*f\*' " or "list functions like
'f.\*' ", for the first case, our current implementation will cause exception
and return empty.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]