| /* |
| * Licensed to the Apache Software Foundation (ASF) under one |
| * or more contributor license agreements. See the NOTICE file |
| * distributed with this work for additional information |
| * regarding copyright ownership. The ASF licenses this file |
| * to you under the Apache License, Version 2.0 (the |
| * "License"); you may not use this file except in compliance |
| * with the License. You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, |
| * software distributed under the License is distributed on an |
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| * KIND, either express or implied. See the License for the |
| * specific language governing permissions and limitations |
| * under the License. |
| */ |
| |
| /* |
| * Description: tests reporting invalid argument type for numeric functions |
| */ |
| // requesttype=application/json |
| // param max-warnings:json=1000 |
| |
| use test; |
| |
| set `import-private-functions` "true"; |
| |
| from ds1 as ds1 |
| select |
| round(str1) as f1, round(str2) as f2, round("text") as f3, |
| round(id, str1) as f4, round(id, str2) as f5, round(id, "text") as f6, |
| trunc(str1, id) as f7, trunc(str2, id) as f8, trunc("text", id) as f9, |
| trunc(id, str1) as f10, trunc(id, str2) as f11, trunc(id, "text") as f12, |
| `round-half-to-even`(str1, id) as f13, `round-half-to-even`(str2, id) as f14, `round-half-to-even`("text", id) as f15, |
| `round-half-to-even`(id, str1) as f16, `round-half-to-even`(id, str2) as f17, `round-half-to-even`(id, "text") as f18; |