我正在使用oracle 11g,我只能站在我的问题所在的地方.我做了很多困难的东西,但是在过去的5小时里,我在这个简单的事情上失败了:
这是功能体
FUNCTION legal_user(
level_existance number
,types_with_impel number)
RETURN BOOLEAN
IS
v_ret_val BOOLEAN;
BEGIN
v_ret_val := FALSE;
IF (level_existance*types_with_impel>0) then
v_ret_val := TRUE;
DBMS_OUTPUT.PUT_LINE('true');
else
DBMS_OUTPUT.PUT_LINE('false');
END IF;
return v_ret_val;
END legal_user;
Run Code Online (Sandbox Code Playgroud)
这是规范:
FUNCTION legal_user(
level_existance number
,types_with_impel number)
RETURN BOOLEAN;
Run Code Online (Sandbox Code Playgroud)
这符合逻辑和对等
A*B>0?true:false;
Run Code Online (Sandbox Code Playgroud)
我得到的错误信息是
ORA-06552:PL/SQL:忽略语句ORA-06553:PLS-382:表达式类型错误06552. 00000 - "PL/SQL:%s"*原因:
*操作:行错误:1列:7
这就是我在IDE中运行它的方法
SELECT compt_tree_profile_q.legal_user(1,1)
FROM dual
Run Code Online (Sandbox Code Playgroud) 希望在Jetty中使用多个静态目录.服务器运行时:
http://localhost:8282/A
http://localhost:8282/B
http://localhost:8282/C
Run Code Online (Sandbox Code Playgroud)
以下失败:
ResourceHandler resource_handler = new ResourceHandler();
resource_handler.setWelcomeFiles(new String[]{"index.html"});
resource_handler.setResourceBase(HTML_SITE);
ResourceHandler resource_handler1 = new ResourceHandler();
resource_handler1.setWelcomeFiles(new String[]{"index.html"});
resource_handler1.setResourceBase(HTML_CLIENTZONE_SITE);
// deploy engine
WebAppContext webapp = new WebAppContext();
String dir = System.getProperty("user.dir");
webapp.setResourceBase(getWebAppPath());
webapp.setContextPath("/");
HandlerList handlers = new HandlerList();
handlers.setHandlers(new Handler[]{resource_handler,resource_handler1 ,webapp, new DefaultHandler()});
server.setHandler(handlers);
Run Code Online (Sandbox Code Playgroud)
如何添加多个静态资源目录?
我有Oracle日期,我想将它翻译成我的日期,例如2011年7月24日是星期天,所以我希望有一个函数返回1,为2011年7月25日,我希望它返回2,依此类推...
我一直在搜索wwb的例子,但没有成功,请帮助我.
我有一个抽象的DAO类,它使用参数化类型E(实体)和K(主键).在每个实体我都有@NamedQuery.我想在不知道其确切名称和参数名称的情况下动态调用此命名查询.
例如,想象下面的实体 City
@Entity(name="CITY")
@NamedQuery(
name="findCityByname",
query="FROM CITY c WHERE name = :CityName"
)
public class City {
// ...
}
Run Code Online (Sandbox Code Playgroud)
还有这个 CityDao
public class CityDao extends AbstractDao<City, Long> {
public CityDao() {
super(City.class);
}
}
Run Code Online (Sandbox Code Playgroud)
我应该如何实现该findByName()方法,AbstractDao以便我不需要知道确切的名称和参数名称?
public abstract class AbstractDao<E, K> implements Dao<E, K> {
@PersistenceContext
protected EntityManager entityManager;
protected Class<E> entityClass;
protected AbstractDao(Class<E> entityClass) {
this.entityClass = entityClass;
}
@Override
public E findByName(String name) {
try {
return …Run Code Online (Sandbox Code Playgroud) 我有生成器g,一旦我从控制台运行它,它开始写入控制台输出(stdout)睡眠x秒并继续,一个数据流.
我希望我的程序运行g并将其输出绑定到java vertx应用程序作为流输入.
我希望所有的阅读都是异步的,我怎样才能实现呢?
这就是我在做的事情:
public class InputHandler extends AbstractVerticle {
final String command = "path";
@Override
public void start() throws Exception {
Runtime r = Runtime.getRuntime();
Process p; // Process tracks one external native process
BufferedReader is; // reader for output of process
String line;
p = r.exec(command);
System.out.println("In Main after exec");
is = new BufferedReader(new InputStreamReader(p.getInputStream()));
while ((line = is.readLine()) != null)
try {
System.out.println(line);
}catch (Exception ex){
System.out.println(ex);
}
}
}
Run Code Online (Sandbox Code Playgroud)
这是抛出的异常:
io.vertx.core.VertxException: Thread blocked
at …Run Code Online (Sandbox Code Playgroud) 它可能看起来很简单,但它有很多错误,我试过这种方式:
String s = gameList[0].toString();
s.replaceFirst(String.valueOf(s.charAt(0)),String.valueOf(Character.toUpperCase(s.charAt(0))) );
Run Code Online (Sandbox Code Playgroud)
它会引发异常
我的另一个尝试是:
String s = gameList[0].toString();
char c = Character.toUpperCase(gameList[0].charAt(0));
gameList[0] = s.subSequence(1, s.length());
Run Code Online (Sandbox Code Playgroud)
这个也引发了例外
我想要一个按钮,当按下它时,文本框中会显示一个新字符串
我究竟做错了什么
可以告诉我为什么这段代码不起作用?...
namespace WindowsFormsApplication1
{
public partial class Form1 : Form
{
public event Startdelegate StartEvent;
myButton button;
newTb[] tb;
public Form1()
{
InitializeComponent();
button = new myButton();
button.Parent = this;
button.Location = new Point(120, 0);
button.Text = "click on me!!!";
tb = new newTb[8];
for (int i = 0; i <= 80; i += 15)
{
tb[i / 15] = new newTb();
tb[i / 15].Parent = this;
tb[i / 15].Location = new Point(i + i, i + i); …Run Code Online (Sandbox Code Playgroud) 如何将JMeter与ajax请求一起使用?
我点击了一个按钮,通过使用fiddler,我可以找到发送到服务器的会话ID.
接下来我应该怎么做才能使用JMeter来处理这个问题.
编辑:
假设我手里拿着调用请求的标题.JSESSIONID AJAXREQUEST等我应该把它放在哪里?...我把它放在http头管理器名称和值中.
在我的HTML中我正在写:
<a href="mailto:fromJavaSceript@gmail.com?body=%A0%F9%ED%0D%0A%F9%ED%A0%EE%F9%F4%E7%E4%A0%0D%0A%FA%2E%E6%0D%0A%EE%F1%F4%F8%A0%F4%E5%EC%E9%F1%E4">websitemail@gmail.co.il </a>
Run Code Online (Sandbox Code Playgroud)
新的Outlook窗口TEXT从左到右打开,我希望它从右到左打开
我通过http poller获得一个json
{
"id":12345
"name":"",
"lastname":"",
"age":12,
"address":{"city":"XXXX" , "street":"ZZZZ" }
}
Run Code Online (Sandbox Code Playgroud)
我想在我的输出中生成两个文档:
人:
{
"id":12345
"name":"",
"lastname":"",
"age":12
}
Run Code Online (Sandbox Code Playgroud)
地址 :
{
"city":"XXXX" ,
"street":"ZZZZ"
}
Run Code Online (Sandbox Code Playgroud)
意思是我在输入中有一个事件
在输入阶段获得一个输入:
input {
http_poller {
urls => {
test1 => "http://localhost:8080"
}
}
Run Code Online (Sandbox Code Playgroud)
在过滤阶段,我想:
在输出阶段,我想: