Input data to variable type char
Hello,
i would like to know how to input data to Char
import java.util.Scanner;
Scanner sc = new Scanner(System.in);
x = sc.nextInt();
but, its not working on Char
You can also use
char c = sc.next("\\p{Alpha}").charAt(0);This accepts a single character, a-z or A-Z, and throws InputMismatchException for any other input.
If you want to change what is acceptable input, select the desired category from those listed in the Pattern class - or create your own.
Your use of "Char" leaves it unclear as to whether you meant the Character class, or the primitive char. I assumed the latter.
Similar Messages
-
Enable "dynamic date calculation" variable type
When saving reporting date/period in a report variant, we may use "dynamic date calculation" to specific date as selection parameter. But the "Dynamic date calculation" is not visible in some ABAP reports - only "Table Variable from TVARVC" type is available for selection.
For those reports that are missing that variable type, how can we enable the "Dynamic date calculation" variable type to be visible?Hi Paco:
Yes, they are z-reports, both have the same almost everything, created by the same ABAPer, for the same application SD, just grouping the data differently.
It seems a screen (#100?) is missing, In the old version, it's screen 100 where to activate the "D" and "B" variable types. Now it goes to screen 281.
Stacy -
Conversion of date field format from char to dats
Hi All,
one issue with Date field.
in my internal table i have a date field with type char(10).
But when I upload the data to database through upload program, there I have a date field with type "DATS".
how do I convert and store it in "DATS " format in database.
please help...HI ,
Try this use CONVERT_DATE_TO_INTERNAl
CALL FUNCTION 'CONVERT_DATE_TO_INTERNAL'
EXPORTING
date_external = "ur date from file
ACCEPT_INITIAL_DATE =
IMPORTING
DATE_INTERNAL = "( date in dats format )
EXCEPTIONS
DATE_EXTERNAL_IS_INVALID = 1
OTHERS = 2
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. -
How to convert DATE variable to CHAR variable
dear all,
How to convert DATE variable to CHAR variable
thanqDepending on your final goal here are 2 options.
DATA: datein TYPE d.
DATA: dateout(10) TYPE c.
DATA: dateout2(8) TYPE c.
datein = sy-datum.
WRITE datein TO dateout MM/DD/YYYY.
dateout2 = datein.
WRITE:/ datein, dateout, dateout2.
and the output
05022008 05/02/2008 20080502 -
Formula variable for a user input DATE value
Hi All,
I want to create Formula variable for a user input DATE value as I need to use it in a formula to compare between user entry date & date in the DSO. Does any body has any idea about it?
I tried to create formula variable with manual entry but then I am not getting DATE option.
Regards,
SonalHi ,
You have to create a formula variable in the formula.
The formula variable in the general tab would have the reference characteristic as your date characteristic on which you have created a user entry variable or on which you intend to create a date entry variable.
Give the proceesing type as replacement path.
Next in Replacement path mention you would replace the variable with value of another variable.
Mention the variable name.(This is the actual varaible created on the selection screen),
Also mention you would replace only from value/to value of the variable.
Check the following help link
[Replacement path type formula variable|http://help.sap.com/saphelp_nw70/helpdata/en/e3/e60138fede083de10000009b38f8cf/frameset.htm]
Hope this helps,
Best regards,
Sunmit. -
Input data type of Matlab script node
Hi,
I have 1D array of complex number in single precision.
Matlab script node is used to import data into Matlab and do some data processing, and then export.
Data type of input is currently double precision.
How to re-define this input data type of the Matlab script node?
Thanks,Right, arrays of singles are not supported. See Comparison of MathScript RT Module and the MATLAB® Software Data Types in LabVIEW
As for memory usage, Profiling the VI should let you know how much memory Labview uses when running your code. Communication with MATLAB® is done through ActiveX, and I'm actually not 100% sure whether it will reflect memory usage from script execution. I think it'll be simple enough to profile your VI with and without the MATLAB Script node and note the memory usage difference...
Misha -
Hi experts,
A simple query. Do the data type CHAR accepts the values like 8923, 452A, etc? while creating an infoobject.?
Thanks in advance.
Regards
DubbuYes it accepts .
for data consistency you have to maintain alfa conversion.
Regards,
Ramnaresh. -
Variable Type EXIT - Locking Transaction Data
Dear all,
I have to use a variable type Exit in the level to identify all cost centers for a planner and his corresponding boss (master data lookup). Now e.g.
the planner has cost center 1 and 2 as possible single values. The boss has cost center 1, 2, 3,and 4 because he also is the boss of an other one.
The result is now that the boss locks all cost centers 1,2,3 and four even if he only plans e.g. the cost center 4. In this way it is not possible for the planner to enter data for 1 or 2 the same time.
Does anybody has an idea to solve this situation or how to lock only the values of the variable that is really in use?
Thanks a lot
DieterHi Dieter,
Refer to Marc's comment in the below post that Planning layouts lock all data
How to avoid SEM-BPS Lock entries
Hence the best option would be to create a different Planning level for Cost center based on the need for planning.
You could also explore the possibility of creating a BEx report wherein the data just needs to be viewed by the boss and not planned.
Hope it helps
Cheers
Anurag
Also take a look at this document to get some more insight into locking in BPS
https://websmp102.sap-ag.de/~sapdownload/011000358700004574572003E/SEMBPSLocking.pdf
Hope you have access to the service marketplace.
Message was edited by: Anurag Khungar -
How can i validate input number into a Field of type char in oracle form?
hi.....
can any one help me.....please...!!!?!!
How can i validate input number into a Field of type char in oracle form?i have tried doing that, but still the field except numbersthere was an error in that code. it should have been
var_num:=to_number(var_char);however, it appears that you want the entry NOT to be a number. if this is the case then try
begin
if to_number(:block.item) = 0 then null; end if;
message('The entry cannot be numeric');
raise form_trigger_failure
exception
when value_error then
/* this is where you put the code you want to be run when the
entry is non-numeric */
end; -
Operand data type char is invalid for sum operator
can someone help me re-writing the following so I wont keep getting thie baopv ementioned error: here is the statement:
RIGHT('0000000000'+REPLACE(CAST(SUM(PAID_AMT) AS VARCHAR),'.',''),14) AS TOT_NET_PAID
+
RIGHT('0000000000'+REPLACE(CAST(SUM(PAID_AMT)
AS
VARCHAR),'.',''),14)
AS TOT_NET_PAID
It keeps retuning he following error messages:
Operand data type char is invalid for sum operatorAs Jingyang said, you cannot sum a non numeric field. Cast it to a numeric first (INT maybe?)
+ RIGHT('0000000000'+REPLACE(CAST(SUM(CAST(PAID_AMT AS INT)) AS VARCHAR),'.',''),14) AS TOT_NET_PAID
Don't forget to mark helpful posts, and answers. It helps others to find relevant posts to the same question. -
Date picker for af:inputDate is not picking up the correct input date
view source:
<af:inputDate value="#{bindings.DateField.attributeValue}" label="#{bindings.DateField.hints.label}"
required="#{bindings.DateField.hints.mandatory}"
valueChangeListener="#{pageFlowScope.CollectApplicantInformation.datesItemChanged}"
columns="#{bindings.DateField.hints.displayWidth}" shortDesc="#{CustomTooltip[DateField]}"
autoSubmit="true" helpTopicId="AppDt" id="DateField" simple="true">
<f:validator binding="#{bindings.DateField.validator}"/>
*<f:converter converterId="CustomConverter"/>*
</af:inputDate>
Here I am not using <af:ConvertDateTime> insted using customConverter, so what code changes do I need to make sure the date picker always picks the already existind date in the inputDate rather picking the current date?
Here is my CustomConverter.java
CustomConverter.java
public class CustomConverter extends DateTimeConverter implements ClientConverter, Converter
public Object getAsObject(FacesContext context, UIComponent component, String value)
String dataType = (String) resolveExpression("#{bindings." + component.getId() + ".attributeDef.javaType.name}");
if (dataType != null && !dataType.equalsIgnoreCase("oracle.jbo.domain.Date") && !dataType.equalsIgnoreCase("oracle.jbo.domain.Timestamp"))
String test = null;
if (context == null || component == null)
throw new NullPointerException();
if (value != null)
// To solve DB transaction dirty issue, Check isEmpty and return null.
if (value.isEmpty())
return null;
// the "value" is stored on the value property of the component.
// The Unified EL allows us to check the type
ValueExpression expression = component.getValueExpression("value");
if (expression != null)
Class<?> expectedType = expression.getType(context.getELContext());
if (expectedType != null)
System.out.println("expectedType Value:::" + expectedType.getName());
// try to convert the value (Object) to the TYPE of the "value" property
// of the underlying JSF component
try
return TypeFactory.getInstance(expectedType, value);
catch (DataCreationException e)
String errorMessage;
if (expectedType.equals(CustomNumber.class))
errorMessage = "You can enter only Numbers in this field";
else
errorMessage = e.getMessage();
if (errorMessage != null)
FacesContext ctx = FacesContext.getCurrentInstance();
FacesMessage fm = new FacesMessage(FacesMessage.SEVERITY_ERROR, "Invalid Format" , errorMessage);
ctx.addMessage(component.getClientId(), fm);
catch (CustomDomainException e)
int errorCode = e.getErrorMessageCode();
String[] errorMessage = e.getErrorMessageParams();
if (errorCode == 7 && errorMessage != null)
String msg = "Invalid " + errorMessage[0];
FacesContext ctx = FacesContext.getCurrentInstance();
FacesMessage fm = new FacesMessage(FacesMessage.SEVERITY_ERROR, "Application Error: ", msg);
ctx.addMessage(component.getClientId(), fm);
catch (JboException e)
Throwable cause = e.getCause();
if (cause == null)
cause = e;
test = "not good format";
throw e;
return null;
else
return value != null? value: null;
public String getAsString(FacesContext context, UIComponent component, Object value)
return value != null? value.toString(): null;
public String getClientLibrarySource(FacesContext context)
return null;
@Override
public Collection<String> getClientImportNames()
return Collections.emptySet();
@Override
public String getClientScript(FacesContext context, UIComponent component)
String formatMask = (String) resolveExpression("#{bindings." + component.getId() + ".format}");
if (formatMask != null)
String dataType = (String) resolveExpression("#{bindings." + component.getId() + ".attributeDef.javaType.name}");
if (dataType.equalsIgnoreCase("oracle.jbo.domain.Date") || dataType.equalsIgnoreCase("oracle.jbo.domain.Timestamp"))
if (component == null)
_LOG.severe("The component is null, but it is needed for the client id, so no script written");
return null;
// Add a JavaScript Object to store the datefield formats
// on the client-side. We currently store the format string
// for each and every field. It'd be more efficient to have
// an array of formats, then store for each field the
// index of the format, especially if we could delay outputting
// these objects to when the <form> closes.
String clientId = component.getClientId(context);
if (clientId != null)
// =-=AEW Only if Javascript...
Map<String, Object> requestMap = context.getExternalContext().getRequestMap();
// this fetch could be at the place where we append, but has been
// moved ahead to optimize use of StringBuilder
String jsPattern = getJSPattern(context, component);
String loc = _getLocaleString(context);
// FIX - figure out size!!!
// 127 chars for javascript + length of jspattern + locale + 12 chars for
// tranforming to name in the worst case.
StringBuilder buff = new StringBuilder(139 + jsPattern.length() + loc.length());
if (requestMap.get(_PATTERN_WRITTEN_KEY) == null)
requestMap.put(_PATTERN_WRITTEN_KEY, Boolean.TRUE);
// only create the _dfs object if it doesn't exist, so we don't
// wipe out _dfs[xxx] values if we ppr the first date field on a
// page with multiple date fields.
buff.append("if(window['_dfs'] == undefined){var _dfs=new Object();}if(window['_dl'] == undefined){var _dl=new Object();}");
buff.append("_dfs[\"");
buff.append(clientId);
buff.append("\"]=");
buff.append(jsPattern);
buff.append(";");
buff.append("_dl[\"");
buff.append(clientId);
buff.append("\"]=");
buff.append(loc);
buff.append(";");
return buff.toString();
else
LOG.severe("NULLCLINET_ID_NO_SCRIPT_RENDERED");
return null;
else
return null;
else
return null;
private String _getLocaleString(FacesContext context)
Locale dateTimeConverterLocale = getLocale();
if (dateTimeConverterLocale != null)
Locale defaultLocale = RenderingContext.getCurrentInstance().getLocaleContext().getFormattingLocale();
if (!(dateTimeConverterLocale.equals(defaultLocale)))
String loc = dateTimeConverterLocale.toString();
StringBuffer sb = new StringBuffer(2 + loc.length());
sb.append("'");
sb.append(loc);
sb.append("'");
return (sb.toString());
return "null";
@Override
@Deprecated
public String getClientConversion(FacesContext context, UIComponent component)
String formatMask = (String) resolveExpression("#{bindings." + component.getId() + ".format}");
if (formatMask != null)
String dataType = (String) resolveExpression("#{bindings." + component.getId() + ".attributeDef.javaType.name}");
if (dataType.equalsIgnoreCase("oracle.jbo.domain.Date") || dataType.equalsIgnoreCase("oracle.jbo.domain.Timestamp"))
String jsPattern = getJSPattern(context, component);
Map<String, String> messages = new HashMap<String, String>();
if (jsPattern != null)
Class<?> formatclass = formatMask.getClass();
System.out.println("FormatClass::" + formatclass);
System.out.println(" Format Mask : " + formatMask);
// SimpleDateFormat sdfDestination = new SimpleDateFormat(formatMask);
String pattern = formatMask; //getPattern();
if (pattern == null)
pattern = getSecondaryPattern();
String key = getViolationMessageKey(pattern);
Object[] params = new Object[]
{ "{0}", "{1}", "{2}" };
Object msgPattern = getMessagePattern(context, key, params, component);
//if hintFormat is null, no custom hint for date, time or both has been specified
String hintFormat = _getHint();
FacesMessage msg = null;
String detailMessage = null;
if (msgPattern != null)
msg = MessageFactory.getMessage(context, key, msgPattern, params, component);
detailMessage = XhtmlLafUtils.escapeJS(msg.getDetail());
Locale loc = context.getViewRoot().getLocale();
SimpleDateFormat formatter = new SimpleDateFormat(pattern, loc);
java.lang.Object obj = resolveExpression("#{bindings." + component.getId() + ".attributeValue}");
String databaseDate=null;
if(obj!=null)
databaseDate = obj.toString();
DateFormat df = new SimpleDateFormat(pattern,loc);
System.out.println("DateComponent input value :::::::::::::::::::::::::"+databaseDate);
Date today;
try {
// System.out.println("Before Conversion::::::::::::"+df.parse(databaseDate).toString());
if(databaseDate!=null)
today = df.parse(databaseDate);
else
today = new Date();
System.out.println("After Conversion Date :::::::::::::::::::::::::::::"+today.toString());
//Date today = new Date();
String dt = formatter.format(today);
String exampleString = dt;
String escapedType = XhtmlLafUtils.escapeJS(getType().toUpperCase());
StringBuilder outBuffer = new StringBuilder();
outBuffer.append("new TrDateTimeConverter(");
outBuffer.append(jsPattern);
// loc = getLocale();
if (loc != null)
outBuffer.append(",'");
outBuffer.append(loc.toString());
outBuffer.append("','");
else
outBuffer.append(",null,'");
outBuffer.append(exampleString);
outBuffer.append("','");
outBuffer.append(escapedType);
outBuffer.append("'");
if (msgPattern != null || hintFormat != null)
messages.put("detail", detailMessage);
messages.put("hint", hintFormat);
outBuffer.append(',');
// try
// JsonUtils.writeMap(outBuffer, messages, false);
// catch (IOException e)
// outBuffer.append("null");
outBuffer.append(')'); // 2
return outBuffer.toString();
catch(ParseException e)
System.out.println("Parse Exception :::::::::::::::::::::"+e);
return null;
else
// no pattern-matchable date
return null;
else
return null;
else
return null;
protected String getJSPattern(FacesContext context, UIComponent component)
String jsPattern = null;
String datePattern = (String) resolveExpression("#{bindings." + component.getId() + ".format}");
if (datePattern != null)
String secondaryPattern = getSecondaryPattern();
if (datePattern != _NO_JS_PATTERN)
int length = datePattern.length() * 2 + 2;
if (secondaryPattern != null)
length = length + 3 + secondaryPattern.length() * 2;
StringBuilder outBuffer = new StringBuilder(length);
jsPattern = _getEscapedPattern(outBuffer, datePattern, secondaryPattern);
else
jsPattern = datePattern;
return jsPattern;
private static void _escapePattern(StringBuilder buffer, String pattern)
buffer.append('\'');
XhtmlUtils.escapeJS(buffer, pattern);
buffer.append('\'');
private static String _getEscapedPattern(StringBuilder buffer, String pattern, String secondaryPattern)
if (secondaryPattern != null)
buffer.append('[');
_escapePattern(buffer, pattern);
if (secondaryPattern != null)
buffer.append(",'");
XhtmlUtils.escapeJS(buffer, secondaryPattern);
buffer.append("']");
return buffer.toString();
private String _getHint()
String type = getType();
if (type.equals("date"))
return getHintDate();
else if (type.equals("both"))
return getHintBoth();
else
return getHintTime();
public static Object resolveExpression(String pExpression)
FacesContext facesContext = FacesContext.getCurrentInstance();
Application app = facesContext.getApplication();
ExpressionFactory elFactory = app.getExpressionFactory();
ELContext elContext = facesContext.getELContext();
ValueExpression valueExp = null;
valueExp = elFactory.createValueExpression(elContext, pExpression, Object.class);
return valueExp.getValue(elContext);
private static final String _NO_JS_PATTERN = new String();
private static final TrinidadLogger _LOG = TrinidadLogger.createTrinidadLogger(DateTimeConverter.class);
// RenderingContext key indicating the _dateFormat object
// has been created
private static final String _PATTERN_WRITTEN_KEY = "org.apache.myfaces.trinidadinternal.convert.DateTimeConverter._PATTERN_WRITTEN";
*Problem is if any input date componet is displaying other than current date then the date picker is always picking the current date rather existing date*
Please suggest me where to make changes?
Edited by: 858782 on Oct 3, 2011 7:43 AM
Edited by: 858782 on Oct 3, 2011 11:44 PMI need custom date foramts to be applied for different inputDates which are not defined in <af:convertDateTime>
Thanks
Edited by: 858782 on Oct 13, 2011 4:59 PM -
'F4IF_INT_TABLE_VALUE_REQUEST' retfield is of type CHAR?
Hi.
For the function 'F4IF_INT_TABLE_VALUE_REQUEST', the import parameter <b>retfield</b> seems to be a char import parameter. However, when I try to use a char variable to provide the value for retfield, I encounter an error. Why is that so? Thanks.
DATA: CONCAT_RFIELD1(20) TYPE C VALUE 'LOAD_ID'.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = CONCAT_RFIELD1
Error: The function module interface allows you to specify only fields of a particular type under "RETFIELD". The field "CONCAT_RFIELD1" specified here is a different field typeHi
The Function Module that you specified provides an F4 help that returns the values that have selected in an internal table.
This FM(Function Module) is quite useful when you are programming your own F4 help for a field.
the following example may be of some help to you:
DATA: lf_repid LIKE sy-repid,
lf_dynnr LIKE sy-dynnr,
lf_dynprofield LIKE help_info-dynprofld,
lf_retfield LIKE dfies-fieldname.
MOVE sy-repid TO lf_repid.
MOVE sy-dynnr TO lf_dynnr.
MOVE 'PA_DPROF' TO lf_dynprofield.
MOVE 'PROFILNAME' TO lf_retfield.
PERFORM prepare_gt_value_tab.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = lf_retfield
dynpprog = lf_repid
dynpnr = lf_dynnr
dynprofield = lf_dynprofield
value_org = 'S'
TABLES
value_tab = it_value_tab
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Regards
Pavan -
Cannot create a date in cfformitem type="script"
I tried to create date variables using "new Date" in
cfformitem type="script" and got an error about the "new" reserver
word. Therefore, I removed the "new" and tested the script. It
worked with the wrong result because the todayDate and selectedDate
in the CheckDate2 were the same. By some reason, it ignored all the
input parameters. However, everything worked fine in the
cfsavecontent.
Anyone has idea? Thanks in advance.
Here is the script:
<cfsavecontent variable="CheckDate1">
var todayDate = new Date(myForm.todayYear,
myForm.todayMonth, myForm.todayDate, 0, 0, 0, 0);
var selectedDate = new Date(
myForm.select_date1.substr(6, 4),
myForm.select_date1.substr(0, 2) - 1,
myForm.select_date1.substr(3, 2),
0, 0, 0, 0
alert("Today's Date in the cfsavecontent:\n" + todayDate +
"\n\n" +
"Seleced Date in the cfsavecontent:\n" + selectedDate);
if (selectedDate > todayDate)
alert("You cannot select a date greater than today's date");
else
alert("You are ok.");
</cfsavecontent>
<cfform name="myForm" format="Flash">
<cfformitem type="script">
function CheckDate2():Void
var todayDate = Date(myForm.todayYear, myForm.todayMonth,
myForm.todayDate, 0, 0, 0, 0);
var selectedDate = Date(
myForm.select_date2.substr(6, 4),
myForm.select_date2.substr(0, 2) - 1,
myForm.select_date2.substr(3, 2),
0, 0, 0, 0
alert("Today's Date in the cfformitem:\n" + todayDate +
"\n\n" +
"Seleced Date in the cfformitem:\n" + selectedDate);
if (selectedDate > todayDate)
alert("You cannot select a date greater than today's date");
else
alert("You are ok.");
</cfformitem>
<CFCALENDAR name="select_date1" height="150" width="310"
onchange="#CheckDate1#">
<CFCALENDAR name="select_date2" height="150" width="310"
onchange="CheckDate2()">
<cfinput type="text" name="todayYear"
value="#DateFormat(Now(), 'yyyy')#" label="todayYear">
<cfinput type="text" name="todayMonth"
value="#DateFormat(Now(), 'm') - 1#" label="todayMonth">
<cfinput type="text" name="todayDate"
value="#DateFormat(Now(), 'd')#" label="todayDate">
</cfform>> I am using CF 7.0.2.
Good. That's that sorted.
> The problem is the cfformitem does not allow
“new” or other reserved words
As I'm sure you're already aware, it is so by design. For
security reasons, the Coldfusion Flash form compiler does not allow
the creation of objects in an event handler. It therefore prohibits
the use of the "new" keyword in an event handler script. In fact,
It may not even allow its occurrence in a comment!
> When I put the function in a .as file and include it in the
CFM file or use
> cfsavecontent to store the as function, the CF compiler
accepts the reserved
> word “new” and the script works fine.
It's a hack, one design gremlin that got away. In programming
as in nature there are (un)lucky accidents.
> the Date constructor ignores the input parameters and
creates the
> current system date in the date objects.
We should be glad it even gets that far. Without the "new"
keyword, it should not be possible to create a new Date object. The
flash compiler encounters a familiar constructor pattern, and
simply makes do by creating the default date of today, right down
to hours, minutes and seconds. Your arguments are ignored.
Thus, the following will all return the same result, namely,
the date of today.
var todayDate = Date(myForm.todayYear, myForm.todayMonth,
myForm.todayDate, 0, 0, 0, 0);
var todayDate = Date(myForm.todayYear, myForm.todayMonth,
myForm.todayDate);
var todayDate = Date(0);
var todayDate = Date(100000000000);
var todayDate = Date();
Even then, the todayDate variable doesn't behave properly
like a Date object. For example, function calls like
todayDate.getDate() fail. Comparing dates also fails. That is
possibly because the machine cannot cast the todayDate variable.
However, here is an approach that does what you want.
<cfformitem type="script">
function CheckDate2() {
var todayDate:Date = Date();
var todayDateInMillis =
Date.UTC(myForm.todayYear,myForm.todayMonth,myForm.todayDate);
var selected_date:Date = select_date2.selectedDate;
var selected_dateInMillis = selected_date.getTime();
alert("Today's Date from cfformitem tag :\n" + todayDate +
"\n\n" + "Selected Date from cfformitem tag:\n" + selected_date);
if (selected_dateInMillis > todayDateInMillis) alert("You
cannot select a date greater than today's date");
else
alert("You are ok.");
</cfformitem> -
User Report data bind variable problems
Hello,
I am trying to build a simple report in SQLDeveloper, using a DATE bind variable. But it fails with the error message:
Inconsistent datatype, expected DATE got NUMBER
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = trunc(:TARGET_DATE)
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
Running this query in SQLDeveloper worksheet executes properly after a dialog box pops up and I enter: current_date - 1
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = trunc(&TARGET_DATE)
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
I've searched but no clear solutions present themselves. If you have one it would be most appreciated.
ThanksYou'll have to convert the input to date yourself:
SELECT * FROM FLOW_COMP_REC_SUMMARY_RU
where create_date = TO_DATE(:TARGET_DATE, 'DD/MM/YYYY')
and type = 'D'
ORDER BY MESSAGE_FLOW_ID
Have fun,
K. -
How to define new variable types in BPEL?
Is there a way to define a new variable type directly in BPEL, without modifying any of the WSDL files used by Partnerlinks?
Or to import an XSD with variable definitions?It depends on what you want to use the variable for. You may not need to do it yourself. Let's assume you have a main wsdl for your service that you can't change but it has the inputs and outputs already defined.
In the middle you want to grab the input and shove it into a database table. You can create a new partner link. Rright click in the swim lanes on the BPEL page and pick the little database icon. Go through the steps to link to the db via an insert or package. You will need a db connection to do this.
jdeveloper will create the partner link wsdl and schema for you to match the table or the ins/outs of the package/procedure automatically.
Then drag an invoke onto the page and pull the arrow to your new partner link. Use the magic wand on the invoke screen to create the input/output variables.
Then you can use a transformation or assign/copy to pull the data from the input message variable of the main wsdl into the input variable of your database wsdl.
Or your situation may not be that complicated...if you click the little (X) on the edge of the box on the BPEL screen you can go through a picking process.
Maybe you are looking for
-
Report for displaying BSID & VBRP Details ( Outstanding Invoice details )
Dear friends, For creatinf a report. First I have to select the details from BSID. Then on the basis of VBELN fiels in BSID , I have to take the Details from VBRK & VBRP based . But VBELN field is null for some BSID Recors. Then How can I pick the VB
-
Three months ago, I had to buy a new printer because the old one experienced a slow and painful death. Fast forward three months to the present day, my new printer has suddenly died. Now, there's only one printer left in the house, and it's in anot
-
How do I get my apps to store on the cloud?
I pay for 25 g of storage but the apps won't store to the cloud....
-
Oracle.tip.transport.TransportException: Requested operation is invalid
Hi all, I'm facing the following error in my B2B implementation when I try to put a file in a SFTP server. oracle.tip.transport.TransportException: Requested operation is invalid. at oracle.tip.transport.basic.sftp.SftpClient.put(SftpClient.java:104)
-
Leaving the front panel displayed on a subpanel after stopping
I have a tab control. Each tab control has a subpanel. Each subpanel has a static vi reference attached to it for launching. I would like the image of the front panel displayed in the subpanel after the program has finished running so that any inform