This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare | |
o0 dbms_sql.varchar2_table; | |
o1 dbms_sql.varchar2_table; | |
c0 sys_refcursor; | |
c1 sys_refcursor; | |
begin | |
update "C##TEST"."AUTHOR" | |
set "C##TEST"."AUTHOR"."FIRST_NAME" = ? | |
where "C##TEST"."AUTHOR"."LAST_NAME" = ? | |
returning "C##TEST"."AUTHOR"."FIRST_NAME", "C##TEST"."AUTHOR"."LAST_NAME" bulk collect into o0, o1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
at ...Delete...ServiceBeanImpl.delete...(Delete...ServiceBeanImpl.java:50) | |
at sun.reflect.GeneratedMethodAccessor1257.invoke(Unknown Source) | |
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) | |
at java.lang.reflect.Method.invoke(Method.java:498) | |
at org.jboss.as.ee.component.ManagedReferenceMethodInterceptor.processInvocation(ManagedReferenceMethodInterceptor.java:52) | |
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:422) | |
at org.jboss.invocation.InterceptorContext$Invocation.proceed(InterceptorContext.java:509) | |
at org.jboss.as.weld.interceptors.Jsr299BindingsInterceptor.doMethodInterception(Jsr299BindingsInterceptor.java:90) | |
at org.jboss.as.weld.interceptors.Jsr299BindingsInterceptor.processInvocation(Jsr299BindingsInterceptor.java:101) | |
at org.jboss.as.ee.component.interceptors.UserInterceptorFactory$1.processInvocation(UserInterceptorFactory.java:63) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import javax.persistence.*; | |
@Entity | |
class Scratch { | |
@Id | |
@GeneratedValue(strategy = GenerationType.AUTO) | |
String a; | |
@ManyToOne(fetch = FetchType.LAZY, cascade = {CascadeType.MERGE, CascadeType.PERSIST, CascadeType.REFRESH}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static void enableMetroDumps() { | |
// https://metro.java.net/guide/ch02.html#logging | |
// dumps encrypted transport messages | |
System.setProperty("com.sun.xml.internal.ws.transport.http.client.HttpTransportPipe.dump", "true"); | |
System.setProperty("com.sun.xml.ws.transport.http.client.HttpTransportPipe.dump", "true"); | |
// dumps unencrypted/decrypted message before/after security tube's processing | |
System.setProperty("com.sun.xml.wss.provider.wsit.SecurityTubeFactory.dump", "true"); | |
System.setProperty("com.sun.xml.ws.transport.http.HttpAdapter.dumpTreshold", "100000"); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT a1.* | |
FROM attribute a1 | |
WHERE a1.Name = 'referencenumber' AND a1.value LIKE '%A123%'; | |
SELECT a0.* | |
FROM attribute a0 | |
WHERE a0.userid IN ( | |
SELECT a1.userid | |
FROM attribute a1 | |
WHERE a1.Name = 'referencenumber' AND a1.value LIKE '%A123%'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Simple Xml validation using the joox library. | |
*/ | |
@Grapes( | |
@Grab(group = 'org.jooq', module = 'joox', version = '1.4.0') | |
) | |
import static org.joox.JOOX.* | |
def document = $(new File('instance-xs11.xml')) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Simple schematron executer for a schema which is embedded into a Xml schema. | |
*/ | |
import javax.xml.transform.TransformerFactory | |
import javax.xml.transform.stream.StreamResult | |
import javax.xml.transform.stream.StreamSource | |
def schemaName = 'choice-schematron.xsd' | |
def instanceName = 'instance-schematron.xml' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Xsd 1.1 validation with a pimped xerces2 jar. | |
*/ | |
@Grapes( | |
@Grab(group = 'com.rackspace.apache', module = 'xerces2-xsd11', version = '2.11.2') | |
) | |
import javax.xml.transform.stream.StreamSource | |
import javax.xml.validation.SchemaFactory |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def iClass = 'java.lang.Integer' as Class | |
assert iClass.newInstance(26) == 26 | |
def greeting = 'Hello' | |
def method = 'length' | |
assert greeting."$method"() == 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
configurations.all { | |
resolutionStrategy { | |
eachDependency { | |
DependencyResolveDetails details -> | |
// Bouncy castle is unfriendly to the maven resolution process. Override the dependencies here. | |
if (details.requested.name.startsWith('bcprov-')) { | |
details.useTarget 'org.bouncycastle:bcprov-jdk15on:1.46' | |
} | |
if (details.requested.name.startsWith('bcmail-')) { | |
details.useTarget 'org.bouncycastle:bcmail-jdk15on:1.46' |
NewerOlder