Unable to "Append all values from Database" when creating parameter
Hello,
I am creating a report using Remedy AR System ODBC Driver as the connection. I tried to create a static parameter with the list of values from the database, but I was prompted with the User name and Password for AR System ODBC Data Source instead of the list being append. I entered the correct password, but I got an error message.
Logon Failed.
Error in file UNKNOWN.RPT:
Unable to connect: incorrect log on parameters. (rptcontrollers.dll)
Any suggestions? please
Thank you
Malar
Hi Malar
Please let us know the following information:
- Version of Crystal Reports Designer.
- The connectivity type (ODBC, Native or OLEDB) you are using to connect to Crystal Reports Designer.
- If you are using native connection then create a DSN and use ODBC connection and let us know the results.
Hope this helps!
Thanks
Similar Messages
-
SelectOneChoice not showing all values from database
Hi!
I have to put a list of values in my select one choice. When I do the query in database, all the values are selected. But, with the same query on JPQL, the select on choice do not show all values in database. Anyone can help me, please?
P.S.: I am using SelectOneChoice with SelectItems, in JDeveloper 11g
Code:
<af:selectOneChoice id="selAction" value="#{row.idCmd}"
unselectedLabel="<Selecione>">
<af:forEach var="alertTypeNode"
items="#{bindings.actionFindAll.iteratorBinding.allRowsInRange}">
<af:selectItem value="#{alertTypeNode.dataProvider.idCmd}"
label="#{alertTypeNode.dataProvider.nmCmd}"
id="si1"/>
</af:forEach>
</af:selectOneChoice>In your page binding check the rangesize setting for the executable you use - set it to -1.
-
I have a multi-select parameter that can have a list of thousands of entries. In general, the user will pick a few entries from the list or "Select All". If they check "Select All", I would much prefer that I get a NULL or an empty string
instead of a list of all values. Is there any way to do that?
In experimenting with a work-around, I tried putting an "All" label with a null value in the list, but it is ignored (does not display in the drop-down). If I use an empty string for the value, my "All" entry does get displayed, but so
does "Select All", which is confusing. Is there a way to suppress "Select All"?
- MarkI adapted the following from a workaround posted by JNeo on 4/16/2010 at 11:14 AM at
http://connect.microsoft.com/SQLServer/feedback/details/249227/multi-value-select-all-parameter-in-reporting-services
To get a null value instead of the full list of all values when "Select All" is chosen:
1) Add a multi-value parameter "MyParam" that lists the values to choose.
2) Add a DataSet "ParamCount" identical to the one used by "MyParam", except that it returns a single column named [Count] that is a COUNT(*) of the same data
3) Add a parameter "MyParamCount", set it to hidden and internal, then set the default value to 'Get values from a query', choosing "ParamCount" for the Dataset and the one [Count] column for the Value field.
4) Change the parameter for the main report DataSet so that instead of using [@MyParam], it uses this expression:
=IIF(Parameters!MyParam.Count =
Parameters!ParamCount.Value, Nothing, Join(Parameters!MyParam.Value, ",")) -
Unable to access values from database in login page..
Hey all,
Friends I have a login.jsp page and I want if i enter username and password then it will be accessed from database and after verifying the details it will open main.jsp.I made a database as "abc" and created DSN as 1st_login having table 1st_login. But the problem is that I am unable to access values from database.
So Please help me.
Following is my code:
<HTML>
<body background="a.jpg">
<marquee>
<CENTER><font size="5" face="times" color="#993300"><b>Welcome to the"<U><I>XYZ</I></U>" of ABC</font></b></CENTER></marquee>
<br>
<br>
<br>
<br><br>
<br>
<form name="login_form">
<CENTER><font size="4" face="times new roman">
Username
<input name="username" type="text" class="inputbox" alt="username" size="20" />
<br>
<br>
Password
<input type="password" name="pwd" class="inputbox" size="20" alt="password" />
<br/>
<input type="hidden" name="option" value="login" />
<br>
<input type="SUBMIT" name="SUBMIT" class="button" value="Submit" onClick="return check();"> </CENTER>
</td>
</tr>
<tr>
<td>
</form>
</table>
<%
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection connection = DriverManager.getConnection("jdbc:odbc:1st_login");
Statement statement = connection.createStatement();
String query = "SELECT username, password FROM 1st_login WHERE username='";
query += request.getParameter("username") + "' AND password='";
query += request.getParameter("password") + "';";
ResultSet resSum = statement.executeQuery(query);
//change: you gotta move the pointer to the first row of the result set.
resSum.next();
if (request.getParameter("username").equalsIgnoreCase(resSum.getString("username")) && request.getParameter("password").equalsIgnoreCase(resSum.getString("password")))
%>
//now it must connected to next page..
<%
else
%>
<h2>You better check your username and password!</h2>
<%
}catch (SQLException ex ){
System.err.println( ex);
}catch (Exception er){
er.printStackTrace();
%>
<input type="hidden" name="op2" value="login" />
<input type="hidden" name="lang" value="english" />
<input type="hidden" name="return" value="/" />
<input type="hidden" name="message" value="0" />
<br>
<br><br>
<br><br>
<br><br><br><br><br>
<font size="2" face="arial" color="#993300">
<p align="center"> <B>ABC © PQR</B>
</BODY>
</HTML>
and in this code i am getting following error
C:\Project\SRS\build\generated\src\org\apache\jsp\loginjsp.java:93: cannot find symbol_
C:\Project\SRS\build\generated\src\org\apache\jsp\loginjsp.java:93: cannot find symbol_
C:\Project\SRS\build\generated\src\org\apache\jsp\loginjsp.java:94: cannot find symbol_
C:\Project\SRS\build\generated\src\org\apache\jsp\loginjsp.java:95: cannot find symbol_
4 errors
C:\Project\SRS\nbproject\build-impl.xml:360: The following error occurred while executing this line:
C:\Project\SRS\nbproject\build-impl.xml:142: Compile failed; see the compiler error output for details.
BUILD FAILED (total time: 6 seconds)As long as you're unable to compile Java code, please use the 'New to Java' forum. This is really trival.
To ease writing, debugging and maintenance, I highly recommend you to write Java code in Java classes rather than JSP files. Start learning Servlets. -
Fetching values from database into a drop down box
in my JSP page there are 3 drop down boxes for date of birth......
what i need is i want to get the values from database into that drop down box when i access the JSP page.......
session is there....'m getting all other values.......
I will attach the JSP page.....
Please help me...........
Thanks in Advance......
<%@ taglib uri='/WEB-INF/taglib/struts-bean.tld' prefix='bean'%>
<%@ taglib uri='/WEB-INF/taglib/struts-logic.tld' prefix='logic'%>
<%@ taglib uri='/WEB-INF/taglib/dyna.tld' prefix='dyna'%>
<%@ taglib uri='/WEB-INF/taglib/struts-html.tld' prefix='html'%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title><bean:message key="page_title"/></title>
<link href="<bean:message key="context"/>/CSS/default.css" rel="stylesheet" type="text/css" />
<script src="<bean:message key="context"/>/js/AC_RunActiveContent.js" type="text/javascript"></script>
<link href="<bean:message key="context"/>/CSS/screen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<%!
Membership mShip = null;
%>
<script language="javascript" >
function checkDate(Form){
var d;
d = Form.year.value+"-"+Form.month.value+"-"+Form.day.value;
alert("Date is:"+d);
Form.dob.value = d;
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<jsp:include flush="true" page="../templates/header.jsp"/> </td>
</tr>
<tr>
<td class="menuTD">
<jsp:include flush="true" page="../templates/menu.jsp"/> </td>
</tr>
<tr>
<td class="sub_menuTR"> </td>
</tr>
<tr>
<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td class="column" valign="top" width="170"><jsp:include flush="true" page="../templates/left_panel.jsp"/></td>
<td valign="top" align="left">
<dyna:message error="error" warning="warning" message="message"/>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="80%" valign="top" align="left">
<%
if(session != null){
mShip = (Membership)session.getAttribute("member");
%>
<form action="updateContactDetails.dy" method="post" name="form1">
<input type="hidden" name="m" value="<%=request.getParameter("m")%>" />
<table width="100%" border="0">
<tr>
<td>First Name</td>
<td><input name="first_name" type="text" id= "first_name" value = "<bean:write name = "member" property = "first_name" />" /></td>
</tr>
<tr>
<td>Last Name </td>
<td><input name="last_name" type="text" id="last_name" value = "<bean:write name = "member" property = "last_name" />" > </td>
</tr>
<tr>
<td>Address</td>
<td><input name="address1" type="text" id="address1" value = "<bean:write name = "member" property = "address1" />" ></td>
</tr>
<tr>
<td> </td>
<td><input name="address2" type="text" id="address2" value = "<bean:write name = "member" property = "address2" />" ></td>
</tr>
<tr>
<td>Suburb/City </td>
<td><input name="city" type="text" id="city" value= "<bean:write name = "member" property = "city" />" ></td>
</tr>
<tr>
<td>State/Territory</td>
<td><input type="text" name="state" value = "<bean:write name = "member" property = "state" />" ></td>
</tr>
<tr>
<td>Postcode</td>
<td><input type="text" name="postcode" value = "<bean:write name = "member" property = "postcode" />" ></td>
</tr>
<tr>
<td>Contact Phone</td>
<td><input type="text" name="home_phone" value = "<bean:write name = "member" property = "home_phone" />" ></td>
</tr>
<tr>
<td>Mobile</td>
<td><input type="text" name="mobile" value = "<bean:write name = "member" property = "mobile" />" ></td>
</tr>
<tr>
<td>Date of birth</td>
<td nowrap="nowrap"><select name="day">
<option>Day</option>
<option value="01">1</option>
<option value="02">2</option>
<option value="03">3</option>
<option value="04">4</option>
<option value="05">5</option>
<option value="06">6</option>
<option value="07">7</option>
<option value="08">8</option>
<option value="09">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
<option value="13">13</option>
<option value="14">14</option>
<option value="15">15</option>
<option value="16">16</option>
<option value="17">17</option>
<option value="18">18</option>
<option value="19">19</option>
<option value="20">20</option>
<option value="21">21</option>
<option value="22">22</option>
<option value="23">23</option>
<option value="24">24</option>
<option value="25">25</option>
<option value="26">26</option>
<option value="27">27</option>
<option value="28">28</option>
<option value="29">29</option>
<option value="30">30</option>
<option value="31">31</option>
</select>
<select name="month">
<option>Month</option>
<option value="01">January</option>
<option value="02">February</option>
<option value="03">March</option>
<option value="04">April</option>
<option value="05">May</option>
<option value="06">June</option>
<option value="07">July</option>
<option value="08">August</option>
<option value="09">September</option>
<option value="10">October</option>
<option value="11">November</option>
<option value="12">Decembber</option>
</select>
<select name="year" onChange = "checkDate(this.form);" >
<option>Year</option>
<option value="1957">1957</option>
<option value="1956">1956</option>
<option value="1955">1955</option>
<option value="1954">1954</option>
<option value="1955">1955</option>
<option value="1956">1956</option>
<option value="1957">1957</option>
<option value="1958">1958</option>
<option value="1959">1959</option>
<option value="1960">1960</option>
<option value="1961">1961</option>
<option value="1962">1962</option>
<option value="1963">1963</option>
<option value="1964">1964</option>
<option value="1965">1965</option>
<option value="1966">1966</option>
<option value="1967">1967</option>
<option value="1968">1968</option>
<option value="1969">1969</option>
<option value="1970">1970</option>
<option value="1971">1971</option>
<option value="1972">1972</option>
<option value="1973">1973</option>
<option value="1974">1974</option>
<option value="1975">1975</option>
<option value="1976">1976</option>
<option value="1977">1977</option>
<option value="1978">1978</option>
<option value="1979">1979</option>
<option value="1980">1980</option>
<option value="1981">1981</option>
<option value="1982">1982</option>
<option value="1983">1983</option>
<option value="1984">1984</option>
<option value="1985">1985</option>
<option value="1986">1986</option>
<option value="1987">1987</option>
<option value="1988">1988</option>
<option value="1989">1989</option>
<option value="1990">1990</option>
<option value="1991">1991</option>
<option value="1992">1992</option>
<option value="1993">1993</option>
<option value="1994">1994</option>
<option value="1995">1995</option>
<option value="1996">1996</option>
<option value="1997">1997</option>
<option value="1998">1998</option>
<option value="1999">1999</option>
<option value="2000">2000</option>
<option value="2001">2001</option>
<option value="2002">2002</option>
<option value="2003">2003</option>
<option value="2004">2004</option>
<option value="2005">2005</option>
<option value="2006">2006</option>
<option value="2007">2007</option>
</select ></td></tr>
<tr>
<td><input type="hidden" name = "dob" /> </td>
<td nowrap="nowrap"><input type="submit" value="Submit" /></td>
</tr>
</table>
</form>
</td>
<td width="40"></td>
<td width="200" valign="top">
<div id="headlines">
<jsp:include flush="true" page="../templates/profile.jsp"/>
</div>
</td>
</tr>
</table>
</td>
<td> </td>
</tr>
</table></td>
</tr>
<tr>
<td><jsp:include flush="true" page="../templates/footer.jsp"/></td>
</tr>
</table>
</body>
</html>i think normally u will get data from databsae as objects.they are like java beans having getter and setter methods.so you create a collection of those objects like collect all the objects coming from database into an arraylist or....
suppose you want to populate the dropdown box with say "username" from database object s, your code will look like that
<html:select property="name">
<html:options collection="databaseList" property="username" />
</html:select>
"databaseList" is collection(say.. ArrayList) of objects you are getting from database.this dropdown will contain all the "usernames" you are getting from database. -
List of values from Database Adapter - BPM Forms
Hi all,
Can anyone tell me how to get list of values from Database adapter and a ServiceTask.
As example lets say a table has Employee and Department columns.
I want to list down all the Employees in BPM form (Select One List Box) once i provide the department to the Database Adapter.
Is it possible from the DB Adapter?? What will be the variable type?
Thanks,
NirHi DanielAtwood,
Thanks for your reply...
Actually when i send the variable in 'WHERE Clause' in Db Adapter query it will retrieve more than one record as the output.
I want to put that values to a 'SelectOneChoice' component and list down all the values..
First I tried with data control. But i couldn't find the way to pass the value to the variable(in WHERE clause) to the query in data control view.
Thanks,
Nir -
Re: [iPlanet-JATO] Re: Retrieving all Values from a Tiled View
Todd,
Let me try to explain you this time. I have a text field in a TiledViewBean.
When I display the page, the text field
html tag is created with the name="PageDetail.rDetail[0].tbFieldName" say
five times/rows with same name.
The html tags look like this.
<input type=text name="PageDetail.rDetail[0].tbFieldName" value=""
maxlength=9 size=13>
<input type=text name="PageDetail.rDetail[0].tbFieldName" value=""
maxlength=9 size=13>
<input type=text name="PageDetail.rDetail[0].tbFieldName" value=""
maxlength=9 size=13>
When the form is submitted, I want to get the text field values using the
method getTbFieldName().getValues() which
returns an array object[]. This is in case where my TiledViewBean is not
bound and it is working fine.
Now in case when my TiledView is bound to a model, it creates the html tags
as follows.
<input type=text name="PageDetail.rDetail[0].tbFieldName" value=""
maxlength=9 size=13>
<input type=text name="PageDetail.rDetail[1].tbFieldName" value=""
maxlength=9 size=13>
<input type=text name="PageDetail.rDetail[2].tbFieldName" value=""
maxlength=9 size=13>
Now when I say getTbFieldName().getValues() it returns only the first
element values in the object[] and the rest of the
values are null.
May be we need to create a utility method do get these values from
requestContext.
raju.
----- Original Message -----
From: Todd Fast <toddwork@c...>
Sent: Saturday, July 07, 2001 3:52 AM
Subject: Re: [iPlanet-JATO] Re: Retrieving all Values from a Tiled View
Raju.--
I wanted to know how the getValues() method works the reason being,
when the tiled view is NOT bound to a model, it populates all the
fields with the same name as some thing likeI'm afraid I don't understand your point--can you please clarify? Do you
mean "value" instead of "name"?
What are you trying to do? What behavior are you expecting but notseeing?
>
Without further clarification, I can say that the setValues() methodsNEVER
populates data on multiple rows of a (dataset) model, nor does it affect
multiple fields on the same row. Perhaps what you are seeing is theeffect
of default values. Model that derive from DefaulModel have the ability to
carry forward the values set on the first row to other rows in lieu ofdata
in those other rows. This behavior is for pure convenience and can be
turned off, and it is turned off for the SQL-based models.
Todd
[email protected]Hi,
I wanted to know how the getValues() method works the reason being,
when the tiled view is NOT bound to a model, it populates all the
fields with the same name as some thing like
PageDetail.rDetail[0].tbFieldValue
PageDetail.rDetail[0].tbFieldValue
in which case, the getValues() method works fine.
But in case where the tiled view is bound to a model, it populates
with different field names such as,
PageDetail.rDetail[0].tbFieldValue
PageDetail.rDetail[1].tbFieldValue
in this case, the getValues() doesn't work. Any soultion to this?
We are using Moko 1.1.1.
thanks in advance,
raju.
--- In iPlanet-JATO@y..., "Todd Fast" <toddwork@c...> wrote:
Does anyone know of is there a single method to get all values of a
display
field in a tiled view without having to iterate through all the
values ie
resetTileIndex() / nextTile() approach.
ie Something that returns an Object[] or Vector just like ND returned a
CspVector. I tried using the getValues() methods but that allways returns
a
single element array containing the first element.
(I think now, that method is used for multi selecteable ListBoxes)Actually, no. We can add this in the next patch, but for now, I'd recommend
creating a simple utility method to do the iteration on an arbitrary model
and build the list for you.
Todd -
How can i get all values from jtable with out selecting?
i have one input table and two output tables (name it as output1, output2). Selected rows from input table are displayed in output1 table. The data in output1 table is temporary(means the dat wont store in database just for display purpose).
Actually what i want is how can i get all values from output1 table to output2 table with out selecting the data in output1 table?
thanks in advance.
rajaYou could set the table's data model to be the same:
output2.setModel( output1.getModel() ); -
Store all values from updateable report on clientside for later use
apex 4.2 , 11xe
hello,
it is possible to store all values from an updateable report to something like an cache BEFORE sent it to DB ?
Background:
i have an modified updateable report ,look the jpg
http://www10.pic-upload.de/25.06.13/3zq5wr23awwg.jpg
updateable report have ever 29 rows. as example i make time entrys for an employee. very often the next employee have the same timeentrys. now iam thinking about to make the entrys for the first employee, then click a button to store the values from ALL cells into somting like a javascript cache or jquery.data() . when i pull another employee from lov i have a fresh empty report( with 29 rows) and now i want to call the data back from cache to the cells (with another button). the cache shouldnt be destroyed when refresh the page,cause there is a page refresh when pull another employee from lov.
is it possible to store all cell values(empty or not) from report all in one?
what is the best and simplest way ?
good would be an example for the code or method i should use.
or is somthing inside apex i could use for that. i looked in apex.api but didnt found something.
my report based on a view with iof trigger and apex collection.
greets/christianthx for answer jarola and sorry for my bad english.
apex collection will not work.
let me explain why not and i think something like javascript/jquery is better for that.
there is a table MAZEIT and i have this updateable report. when i select an employee from lov, a collection will be created. the collection look in MAZEIT ,perhaps there are real timeentrys, in this case the collection will be modified and give me 29 rows,some are filled. or there are no real entrys and the collection give me 29 empty rows.
here my report sql:
select
"HID_SEQ_ID",
"DATUM",
"WOTAG",
"WOTAGNR",
"KNDABT_ID",
"ZEIT",
"BEGINN",
"ENDE",
"PAUSE",
"ZUSCHLAG",
"BEM",
"MELDUNG"
from "#OWNER#"."V_COLL_MAZEIT"
here the v_coll_mazeit (view) sql
CREATE OR REPLACE VIEW V_COLL_MAZEIT AS
SELECT seq_id HID_SEQ_ID -- APEX_COLLECTIONS.SEQ_ID
,C001 HID_MAZEIT_ID -- MAZEIT.ID
,C002 DATUM -- Datum DD.MM.YYYY
,C003 WOTAG -- Wochentag Mo/Di/...
,C004 WOTAGNR -- Wochentag 1/2/...
,C005 KNDABT_ID -- Abteilung
,C006 ZEIT -- Zeit in HH24:MI
,C007 BEGINN -- Beginn in HH24:MI
,C008 ENDE -- Ende in HH24:MI
,C009 PAUSE -- Pause in HH24:MI
,C010 ZUSCHLAG
,C011 BEM
,C040 HID_MANDANT_ID
,C041 HID_KND_ID
,C042 HID_MA_ID
,C043 HID_KW
,C048 HID_HASH4CHECK -- Hash für Check auf Änderungen MAZEIT
,C049 HID_SORTIER -- für ORDER BY hier Arbeitsbeginn
,C050 MELDUNG -- für FehlerMeldungen
FROM APEX_COLLECTIONS
WHERE COLLECTION_NAME='V_COLL_MAZEIT'
ORDER BY HID_SORTIER;
here the trigger (iof) from v_coll_mazeit
CREATE OR REPLACE TRIGGER "V_COLL_MAZEIT_IOF_U_TRG"
INSTEAD OF UPDATE ON V_COLL_MAZEIT
FOR EACH ROW
BEGIN
--RAISE_APPLICATION_ERROR(-20004,'NIX DA');
CM_MEAT.V_COLL_MAZEIT_IOF_U_TRG(
:NEW.HID_SEQ_ID
,:NEW.HID_MAZEIT_ID
,:NEW.DATUM
,:NEW.WOTAG
,:NEW.WOTAGNR
,:NEW.KNDABT_ID
,:NEW.ZEIT
,:NEW.BEGINN
,:NEW.ENDE
,:NEW.PAUSE
,:NEW.ZUSCHLAG
,:NEW.BEM
,:NEW.HID_HASH4CHECK
,:NEW.HID_SORTIER
,:NEW.MELDUNG
END V_COLL_MAZEIT_IOF_U_TRG;
and here a package procedure when i select an employee:
PROCEDURE V_COLL_MAZEIT_PROC(
iAction IN PLS_INTEGER,
iDatum IN DATE DEFAULT SYSDATE,
iMandantId IN MAZEIT.MANDANT_ID%TYPE,
iKndId IN MAZEIT.KND_ID%TYPE,
iMaId IN MAZEIT.MA_ID%TYPE,
oCollName OUT VARCHAR2)
IS
TK_FUNC_NAME CONSTANT USER_OBJECTS.OBJECT_NAME%TYPE := 'V_COLL_MAZEIT_PROC';
TK_COLL_NAME CONSTANT APEX_COLLECTIONS.COLLECTION_NAME%TYPE := 'V_COLL_MAZEIT';
TK_MD5 CONSTANT VARCHAR2(2) := 'NO';
TYPE t_Tage_TAB IS TABLE OF DATE INDEX BY BINARY_INTEGER;
TYPE t_TageVC_TAB IS TABLE OF VARCHAR2(8) INDEX BY BINARY_INTEGER;
TYPE t_TageI_TAB IS TABLE OF PLS_INTEGER INDEX BY BINARY_INTEGER;
tTage t_Tage_TAB;
tTageVC t_TageVC_TAB;
tTageI t_TageI_TAB;
vDatum DATE;
vDatumCh VARCHAR2(8);
vKW4Db MAZEIT.KW%TYPE;
vI PLS_INTEGER := 0;
vAnz PLS_INTEGER := 0;
BEGIN
FOR rec IN (SELECT * FROM NLS_SESSION_PARAMETERS)
LOOP
InsProto(rec.PARAMETER||'=['||rec.VALUE||']',
QK_PACK_NAME,TK_FUNC_NAME);
END LOOP;
CMT.InsProto('iAction='||iAction||', iDatum='||iDatum||', iMandantId='||iMandantId||', iKndId='||iKndId||', iMaId'||iMaId,
QK_PACK_NAME,TK_FUNC_NAME);
oCollName := TK_COLL_NAME;
IF iAction=0 THEN -- löschen
IF APEX_COLLECTION.COLLECTION_EXISTS(p_collection_name=>TK_COLL_NAME) THEN
APEX_COLLECTION.TRUNCATE_COLLECTION(TK_COLL_NAME);
APEX_COLLECTION.DELETE_COLLECTION(TK_COLL_NAME);
END IF;
|| Säubern und anlegen
ELSIF iAction=1 THEN
IF APEX_COLLECTION.COLLECTION_EXISTS(p_collection_name=>TK_COLL_NAME) THEN
APEX_COLLECTION.TRUNCATE_COLLECTION(p_collection_name=>TK_COLL_NAME);
ELSE
APEX_COLLECTION.CREATE_COLLECTION(p_collection_name=>TK_COLL_NAME);
END IF;
vDatum := NVL(iDATUM,SYSDATE);
vDatum := TO_DATE(TO_CHAR(vDatum,'YYYYMMDD')||'000000','YYYYMMDDHH24MISS');
vKW4Db := GetKW4Db(vDatum);
tTage(1) := CMT.GetMonday(vDATUM,0);
SELECT tTage(1) + 1DAY,tTage(1) + 2DAY,tTage(1) + 3DAY,tTage(1) + 4DAY,tTage(1) + 5DAY,tTage(1) + 6DAY
INTO tTage(2),tTage(3),tTage(4),tTage(5),tTage(6),tTage(7)
FROM DUAL;
FOR i IN 1..7 LOOP tTageI(i) := 0; tTageVC(i) := TO_CHAR(tTage(i),'YYYYMMDD'); END LOOP;
-- erste Zeile enthält Default-Werte
APEX_COLLECTION.add_member( p_COLLECTION_name=> TK_COLL_NAME,p_generate_md5=>TK_MD5
,P_C001 => 0 -- MAZEIT.ID
,P_C002 => '<b>Vorgabe</b>' -- Datum DD.MM.YYYY
,P_C003 => ' ' -- Wochentag Mo/Di/...
,P_C004 => ' ' -- Wochentag 1/2/...
,P_C005 => 0 -- MAZEIT.KNDABT_ID
,P_C006 => NULL -- Zeit in HH24:MI
,P_C007 => NULL -- Beginn in HH24:MI
,P_C008 => NULL -- Ende in HH24:MI
,P_C009 => NULL -- Pause in HH24:MI
,P_C010 => NULL -- Zuschlag
,P_C011 => NULL -- Bem
,P_C040 => iMandantId
,P_C041 => iKndId
,P_C042 => iMaId
,P_C043 => vKW4Db
,P_C048 => '-1' -- Hash für Check auf Änderungen MAZEIT
,P_C049 => ' ' -- für ORDER BY hier Arbeitsbeginn
,P_C050 => NULL
FOR rec IN (SELECT z.*,
TO_CHAR(DBMS_UTILITY.get_hash_value(
z.id||'|'||
z.mandant_id||'|'||
z.majob_id||'|'||
z.ma_id||'|'||
z.knd_id||'|'||
z.kndabt_id||'|'||
z.kw||'|'||
z.arb_beg||'|'||
z.arb_end||'|'||
z.zeit||'|'||
z.pause||'|'||
z.zuschlag||'|'||
z.stk_anz||'|'||
z.stk_kg||'|'||
z.stk_gemuur||'|'||
z.stk_bezahlt||'|'||
z.bem||'|'||
z.ART4RECH
,1,POWER(2,30))) AS HID_HASH4CHECK
FROM MAZEIT z
WHERE z.MANDANT_ID=iMandantId AND
z.KND_ID=iKndId AND
z.MA_ID=iMaId AND
z.KW = GetKW4Db(tTage(1)) AND
z.ART4RECH IN (CMT.GetTCVNum('MAZEIT_ART4RECH_STD'),CMT.GetTCVNum('MAZEIT_ART4RECH_STK'),CMT.GetTCVNum('MAZEIT_ART4RECH_KG'))
ORDER BY z.ARB_BEG)
LOOP
IF rec.ZUSCHLAG=0 THEN
rec.ZUSCHLAG := NULL;
END IF;
vI := 0;
vDatumCh := TO_CHAR(rec.ARB_BEG,'YYYYMMDD');
FOR i IN 1..7 LOOP
IF tTageVC(i)=vDatumCh THEN
tTageI(i) := tTageI(i) + 1;
vI := i;
EXIT;
END IF;
END LOOP;
-- Stücklohn kommt an den Anfang der Bemerkung gekennzeichnet mit QK_COLL_MAZEIT_STK_KZ ursprüngliche Bemekuung nach dem :
rec.BEM := RTRIM(rec.BEM);
IF rec.ART4RECH = CMT.GetTCVNum('MAZEIT_ART4RECH_STK') THEN
DECLARE
vBem MAZEIT.BEM%TYPE := QK_COLL_MAZEIT_STK_KZ;
BEGIN
IF rec.STK_BEZAHLT > 0. THEN
vBem := QK_COLL_MAZEIT_STK_KZ||TO_CHAR(rec.stk_bezahlt,'FM9999D00');
ELSIF rec.STK_ANZ > 0 THEN
vBem := QK_COLL_MAZEIT_STA_KZ||TO_CHAR(rec.stk_anz,'FM9999');
END IF;
IF rec.BEM IS NULL THEN
rec.BEM := vBem;
ELSE
rec.BEM := SUBSTR(vBem||':'||rec.BEM,1,CMT.GetColLen('MAZEIT','BEM'));
END IF;
END;
ELSIF rec.ART4RECH = CMT.GetTCVNum('MAZEIT_ART4RECH_KG') THEN
DECLARE
vBem MAZEIT.BEM%TYPE := QK_COLL_MAZEIT_KG_KZ;
BEGIN
IF rec.STK_KG > 0. THEN
vBem := QK_COLL_MAZEIT_KG_KZ||TO_CHAR(rec.stk_kg,'FM999999D000');
END IF;
IF rec.BEM IS NULL THEN
rec.BEM := vBem;
ELSE
rec.BEM := SUBSTR(vBem||':'||rec.BEM,1,CMT.GetColLen('MAZEIT','BEM'));
END IF;
END;
END IF;
IF vI>0 THEN
IF tTageI(vI)=1 THEN
APEX_COLLECTION.add_member( p_COLLECTION_name=> TK_COLL_NAME,p_generate_md5=>TK_MD5
,P_C001 => rec.id -- MAZEIT.ID
,P_C002 => TO_CHAR(rec.ARB_BEG,'DD.MM.YYYY') -- Datum DD.MM.YYYY
,P_C003 => CMT.WoTag(rec.ARB_BEG) -- Wochentag Mo/Di/...
,P_C004 => CMT.WoTagNr(rec.ARB_BEG) -- Wochentag 1/2/...
,P_C005 => rec.KNDABT_ID -- MAZEIT.KNDABT_ID
,P_C006 => CMT.Minuten2InduZeit(rec.ZEIT) -- Zeit als InduZeit in HH24,MI
,P_C007 => TO_CHAR(rec.ARB_BEG,'HH24:MI') -- Beginn in HH24:MI
,P_C008 => TO_CHAR(rec.ARB_END,'HH24:MI') -- Ende in HH24:MI
,P_C009 => CMT.Minuten2HHMI(rec.PAUSE,TRUE) -- Pause in HH24:MI
,P_C010 => rec.ZUSCHLAG
,P_C011 => rec.BEM
,P_C040 => iMandantId
,P_C041 => iKndId
,P_C042 => iMaId
,P_C043 => vKW4Db
,P_C048 => rec.HID_HASH4CHECK -- Hash für Check auf Änderungen MAZEIT
,P_C049 => TO_CHAR(rec.ARB_BEG,'YYYYMMDDHH24MI') -- für ORDER BY hier Arbeitsbeginn
,P_C050 => NULL -- für FehlerMeldungen
ELSE
APEX_COLLECTION.add_member( p_COLLECTION_name=> TK_COLL_NAME,p_generate_md5=>TK_MD5
,P_C001 => rec.id -- MAZEIT.ID
,P_C002 => NULL -- Datum DD.MM.YYYY
,P_C003 => NULL -- Wochentag Mo/Di/...
,P_C004 => NULL -- Wochentag 1/2/...
,P_C005 => rec.KNDABT_ID -- MAZEIT.KNDABT_ID
,P_C006 => CMT.Minuten2InduZeit(rec.ZEIT) -- Zeit als InduZeit in HH24,MI
,P_C007 => TO_CHAR(rec.ARB_BEG,'HH24:MI') -- Beginn in HH24:MI
,P_C008 => TO_CHAR(rec.ARB_END,'HH24:MI') -- Ende in HH24:MI
,P_C009 => CMT.Minuten2HHMI(rec.PAUSE,TRUE) -- Pause in HH24:MI
,P_C010 => rec.ZUSCHLAG
,P_C011 => rec.BEM
,P_C040 => iMandantId
,P_C041 => iKndId
,P_C042 => iMaId
,P_C043 => vKW4Db
,P_C048 => rec.HID_HASH4CHECK -- Hash für Check auf Änderungen MAZEIT
,P_C049 => TO_CHAR(rec.ARB_BEG,'YYYYMMDDHH24MI') -- für ORDER BY hier Arbeitsbeginn
,P_C050 => NULL -- für FehlerMeldungen
END IF;
vAnz := vAnz + 1;
END IF;
END LOOP;
FOR i IN 1..7 LOOP
IF tTageI(i)<4 THEN
FOR j IN tTageI(i)+1..4 LOOP
IF j=1 THEN
APEX_COLLECTION.add_member( p_COLLECTION_name=> TK_COLL_NAME,p_generate_md5=>TK_MD5
,P_C001 => -1 -- MAZEIT.ID
,P_C002 => TO_CHAR(tTage(i),'DD.MM.YYYY') -- Datum DD.MM.YYYY
,P_C003 => CMT.WoTag(tTage(i)) -- Wochentag Mo/Di/...
,P_C004 => CMT.WoTagNr(tTage(i)) -- Wochentag 1/2/...
,P_C005 => 0 -- MAZEIT.KNDABT_ID
--,P_C006 => Minuten2InduZeit(0) -- Zeit als InduZeit in HH24,MI
,P_C006 => NULL -- Zeit als InduZeit in HH24,MI
--,P_C007 => '06:30' -- Beginn in HH24:MI
,P_C007 => NULL -- Beginn in HH24:MI
,P_C008 => NULL -- Ende in HH24:MI
--,P_C009 => Minuten2HHMI(0) -- Pause in HH24:MI
,P_C009 => NULL -- Pause in HH24:MI
,P_C010 => NULL -- Zuschlag
,P_C011 => NULL -- Bem
,P_C040 => iMandantId
,P_C041 => iKndId
,P_C042 => iMaId
,P_C043 => vKW4Db
,P_C048 => '-1' -- Hash für Check auf Änderungen MAZEIT
,P_C049 => TO_CHAR(tTage(i),'YYYYMMDD')||'99'||TO_CHAR(j,'FM09') -- für ORDER BY hier Arbeitsbeginn
,P_C050 => NULL
ELSE -- auffüllen
APEX_COLLECTION.add_member( p_COLLECTION_name=> TK_COLL_NAME,p_generate_md5=>TK_MD5
,P_C001 => -1 -- MAZEIT.ID
,P_C002 => NULL -- Datum DD.MM.YYYY
,P_C003 => NULL -- Wochentag Mo/Di/...
,P_C004 => NULL -- Wochentag 1/2/...
,P_C005 => 0 -- MAZEIT.KNDABT_ID
--,P_C006 => Minuten2HHMI(0) -- Zeit in HH24:MI
,P_C006 => NULL -- Zeit in HH24:MI
--,P_C007 => '06:30' -- Beginn in HH24:MI
,P_C007 => NULL -- Beginn in HH24:MI
,P_C008 => NULL -- Ende in HH24:MI
--,P_C009 => Minuten2InduZeit(0) -- Pause als InduZeit in HH24,MI
,P_C009 => NULL -- Pause als InduZeit in HH24,MI
,P_C010 => NULL -- Zuschlag
,P_C011 => NULL -- Bem
,P_C040 => iMandantId
,P_C041 => iKndId
,P_C042 => iMaId
,P_C043 => vKW4Db
,P_C048 => '-1' -- Hash für Check auf Änderungen MAZEIT
,P_C049 => TO_CHAR(tTage(i),'YYYYMMDD')||'99'||TO_CHAR(j,'FM09') -- für ORDER BY hier Arbeitsbeginn
,P_C050 => NULL
END IF;
END LOOP;
END IF;
END LOOP;
vI := 0;
FOR rec IN (SELECT * FROM V_COLL_MAZEIT) LOOP
vI := vI + 1;
CMT.InsProto('i='||LPAD(TO_CHAR(vI),3,' ')||':'||
rec.hid_seq_id||'|'||
rec.hid_mazeit_id||'|'||
rec.datum||'|'||
rec.wotag||'|'||
rec.wotagnr||'|'||
rec.zeit||'|'||
rec.beginn||'|'||
rec.ende||'|'||
rec.pause||'|'||
rec.zuschlag||'|'||
rec.bem||'|'||
rec.hid_hash4check||'|'||
rec.hid_sortier||'|'||
rec.meldung
,QK_PACK_NAME,TK_FUNC_NAME);
END LOOP;
ELSE
raise_Application_ERROR(-20100,'kann ich doch nicht Action='||TO_CHAR(iAction));
END IF;
END V_COLL_MAZEIT_PROC;
and here the procedure (look for real entrys in table)
PROCEDURE V_COLL_MAZEIT_IOF_U_TRG(
iHID_SEQ_ID apex_collections.seq_id%TYPE
,iHID_MAZEIT_ID apex_collections.C001%TYPE
,iDATUM apex_collections.C002%TYPE
,iWOTAG apex_collections.C003%TYPE
,iWOTAGNR apex_collections.C004%TYPE
,iKNDABT_ID apex_collections.C005%TYPE
,iZEIT apex_collections.C006%TYPE
,iBEGINN apex_collections.C007%TYPE
,iENDE apex_collections.C008%TYPE
,iPAUSE apex_collections.C009%TYPE
,iZUSCHLAG apex_collections.C010%TYPE
,iBEM apex_collections.C011%TYPE
,iHID_HASH4CHECK apex_collections.C048%TYPE
,iHID_SORTIER apex_collections.C049%TYPE
,iMELDUNG apex_collections.C050%TYPE
IS
PRAGMA AUTONOMOUS_TRANSACTION;
TK_FUNC_NAME CONSTANT USER_OBJECTS.OBJECT_NAME%TYPE := 'V_COLL_MAZEIT_IOF_U_TRG';
TK_COLL_NAME CONSTANT APEX_COLLECTIONS.COLLECTION_NAME%TYPE := 'V_COLL_MAZEIT';
vRcString VARCHAR2(2000) := NULL;
rCollMaZeit0 V_COLL_MAZEIT%ROWTYPE;
rCollMaZeit V_COLL_MAZEIT%ROWTYPE;
rMaZeit MAZEIT%ROWTYPE;
vHash4Check PLS_INTEGER;
vURow ROWID;
BEGIN
CMT.InsProto(
ihid_seq_id||'|'||
ihid_mazeit_id||'|'||
idatum||'|'||
iwotag||'|'||
iwotagnr||'|'||
iKNDABT_ID||'|'||
izeit||'|'||
ibeginn||'|'||
iende||'|'||
ipause||'|'||
izuschlag||'|'||
ibem||'|'||
ihid_hash4check||'|'||
ihid_sortier||'|'||
imeldung
,QK_PACK_NAME,TK_FUNC_NAME);
-- VIEW-ZeitZeile lesen
SELECT t.* INTO rCollMaZeit
FROM V_COLL_MAZEIT t
WHERE t.HID_SEQ_ID = iHID_SEQ_ID;
IF iHID_MAZEIT_ID!=rCollMaZeit.HID_MAZEIT_ID OR
iHID_HASH4CHECK!=rCollMaZeit.HID_HASH4CHECK THEN
vRcString := 'Daten seit Anzeige verändert';
GOTO MARK_TRANSEND;
END IF;
-- VIEW-ZeitDefaultZeile setzen
IF rCollMaZeit.HID_MAZEIT_ID=0 THEN
--,P_C005 => 0 -- MAZEIT.KNDABT_ID
--,P_C006 => NULL -- Zeit in HH24,MI
--,P_C007 => NULL -- Beginn in HH24:MI
--,P_C008 => NULL -- Ende in HH24:MI
--,P_C009 => NULL -- Pause in HH24,MI
--,P_C010 => NULL -- Zuschlag
--,P_C011 => NULL -- Bem
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>5, p_attr_value=>iKNDABT_ID);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>6, p_attr_value=>iZEIT);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>7, p_attr_value=>iBEGINN);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>8, p_attr_value=>iENDE);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>9, p_attr_value=>iPAUSE);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>10, p_attr_value=>iZUSCHLAG);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>11, p_attr_value=>iBEM);
IF iBEM LIKE '#%' THEN -- Verteilen
-- VIEW-ZeitDefaultZeile lesen
SELECT t.* INTO rCollMaZeit0
FROM V_COLL_MAZEIT t
WHERE t.HID_MAZEIT_ID = 0;
rCollMaZeit0.BEM := SUBSTR(iBEM,2);
DECLARE
vAnz PLS_INTEGER := 0;
nVert MAZEIT.ZEIT%TYPE;
nZeitMinuten MAZEIT.ZEIT%TYPE;
nDiffMinuten MAZEIT.ZEIT%TYPE;
BEGIN
SELECT NVL(COUNT(*),0) INTO vAnz
FROM V_COLL_MAZEIT t
WHERE t.HID_MAZEIT_ID = -1 AND
t.DATUM IS NOT NULL AND
t.WOTAGNR IN ('1','2','3','4','5'); -- nur Mo-Fr
IF vAnz<=0 THEN
vRcString := 'Verteilen nicht möglich keine freien Tage gefunden';
ELSIF TRIM(iZEIT) IS NULL OR TRIM(iZEIT) IN ('00,00','0,00','0',',00',',0','0,','0,0') THEN
vRcString := 'Verteilen von Null Minuten nicht möglich';
ELSE
nDiffMinuten := 0;
nZeitMinuten := CMT.InduZeit2MinutenNum(TRIM(iZEIT));
IF nZeitMinuten>(vAnz*1440) THEN
vRcString := 'Zu verteilende Zeit zu groß';
ELSIF vAnz>1 THEN
nVert := FLOOR(nZeitMinuten/vAnz);
nDiffMinuten := nZeitMinuten - (nVert*vAnz);
nZeitMinuten := nVert;
END IF;
IF vRcString IS NULL THEN
FOR rec IN (SELECT t.* INTO rCollMaZeit
FROM V_COLL_MAZEIT t
WHERE t.HID_MAZEIT_ID = -1 AND
t.DATUM IS NOT NULL AND
t.WOTAGNR IN ('1','2','3','4','5')) -- nur Mo-Fr)
LOOP
rCollMaZeit := rec;
vRcString := qV_COLL_MAZEIT_Insert(iKNDABT_ID, iZEIT, nZeitMinuten+nDiffMinuten, iBEGINN, iENDE, iPAUSE, iZUSCHLAG, SUBSTR(iBEM,2),
rCollMaZeit0, rCollMaZeit, rMaZeit);
IF vRcString IS NOT NULL THEN
EXIT;
END IF;
nDiffMinuten := 0;
END LOOP;
END IF;
END IF;
END;
END IF;
-- MAZEIT-Vorhandener Eintrag
ELSIF rCollMaZeit.HID_MAZEIT_ID>0 THEN
SELECT z.ROWID, TO_CHAR(DBMS_UTILITY.get_hash_value(
z.id||'|'||
z.mandant_id||'|'||
z.majob_id||'|'||
z.ma_id||'|'||
z.knd_id||'|'||
z.kndabt_id||'|'||
z.kw||'|'||
z.arb_beg||'|'||
z.arb_end||'|'||
z.zeit||'|'||
z.pause||'|'||
z.zuschlag||'|'||
z.stk_anz||'|'||
z.stk_kg||'|'||
z.stk_gemuur||'|'||
z.stk_bezahlt||'|'||
z.bem||'|'||
z.ART4RECH
,1,POWER(2,30))) AS HID_HASH4CHECK
INTO vURow, vHash4Check
FROM MAZEIT z
WHERE z.ID=rCollMaZeit.HID_MAZEIT_ID
FOR UPDATE NOWAIT;
IF vHash4Check!=rCollMaZeit.HID_HASH4CHECK THEN
vRcString := 'Daten seit Anzeige verändert';
GOTO MARK_TRANSEND;
END IF;
SELECT z.* INTO rMaZeit
FROM MAZEIT z
WHERE ROWID=vURow;
rMaZeit.KNDABT_ID := TO_NUMBER(TRIM(iKNDABT_ID));
IF TRIM(iBEGINN) IS NULL THEN
rMaZeit.ARB_BEG := NULL;
ELSE
rMaZeit.ARB_BEG := TO_DATE(TO_CHAR(rMaZeit.ARB_BEG,'YYYYMMDD')||TRIM(SUBSTR(iBEGINN,1,5)),'YYYYMMDDHH24:MI');
END IF;
IF TRIM(iENDE) IS NULL THEN
rMaZeit.ARB_END := NULL;
ELSE
rMaZeit.ARB_END := TO_DATE(TO_CHAR(rMaZeit.ARB_BEG,'YYYYMMDD')||TRIM(SUBSTR(iENDE,1,5)),'YYYYMMDDHH24:MI');
END IF;
IF TRIM(iZEIT) IS NULL THEN
rMaZeit.ZEIT := NULL;
ELSE
rMaZeit.ZEIT := CMT.InduZeit2MinutenNum(TRIM(iZEIT));
END IF;
IF TRIM(iPAUSE) IS NULL THEN
rMaZeit.PAUSE := NULL;
ELSE
rMaZeit.PAUSE := CMT.HHMI2Minuten(TRIM(iPAUSE));
END IF;
IF iWOTAGNR IN (6,7) AND
rMaZeit.PAUSE IS NOT NULL AND rMaZeit.PAUSE<>0 THEN
vRcString := 'Eintrag Pause am Wochenende nicht erlaubt';
GOTO MARK_TRANSEND;
END IF;
IF TRIM(iZUSCHLAG) IS NULL THEN
rMaZeit.ZUSCHLAG := NULL;
ELSE
rMaZeit.ZUSCHLAG := TO_NUMBER(TRIM(iZUSCHLAG));
END IF;
IF RTRIM(iBEM) IS NULL THEN
rMaZeit.BEM := NULL;
ELSE
rMaZeit.BEM := RTRIM(iBEM);
END IF;
IF (rMaZeit.KNDABT_ID IS NOT NULL AND rMaZeit.KNDABT_ID>0) OR
rMaZeit.ARB_BEG IS NOT NULL OR rMaZeit.ARB_END IS NOT NULL OR
(rMaZeit.ZEIT IS NOT NULL AND rMaZeit.ZEIT!=0) OR rMaZeit.PAUSE IS NOT NULL OR
rMaZeit.ZUSCHLAG IS NOT NULL OR rMaZeit.BEM IS NOT NULL THEN
DECLARE
vBem MAZEIT.BEM%TYPE := rMaZeit.BEM;
BEGIN
rMaZeit.ZUSCHLAG := NVL(rMaZeit.ZUSCHLAG,0.0);
qV_COLL_MAZEIT_BEM_CHK(rMaZeit); -- Bem prüfen wg. ART4RECH Verschlüsselung mittels QK_COLL_MAZEIT_STK_KZ
UPDATE MAZEIT z
SET z.KNDABT_ID = rMaZeit.KNDABT_ID
,z.ARB_BEG = rMaZeit.ARB_BEG
,z.ARB_END = rMaZeit.ARB_END
,z.ZEIT = rMaZeit.ZEIT
,z.PAUSE = rMaZeit.PAUSE
,z.ZUSCHLAG = rMaZeit.ZUSCHLAG
,z.BEM = rMaZeit.BEM
,z.STK_BEZAHLT = rMaZeit.STK_BEZAHLT
,z.STK_ANZ = rMaZeit.STK_ANZ
,z.STK_KG = rMaZeit.STK_KG
,z.ART4RECH = rMaZeit.ART4RECH
WHERE ROWID=vURow;
IF SQL%ROWCOUNT=1 THEN
NULL;
ELSIF SQL%ROWCOUNT<1 THEN
RAISE NO_DATA_FOUND;
ELSE
RAISE TOO_MANY_ROWS;
END IF;
rMaZeit.BEM := vBem;
END;
ELSE
DELETE FROM MAZEIT z
WHERE ROWID=vURow;
IF SQL%ROWCOUNT=1 THEN
NULL;
ELSIF SQL%ROWCOUNT<1 THEN
RAISE NO_DATA_FOUND;
ELSE
RAISE TOO_MANY_ROWS;
END IF;
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>1, p_attr_value=>-1);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>48, p_attr_value=>'-1');
END IF;
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>5, p_attr_value=>rMaZeit.KNDABT_ID);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>6, p_attr_value=>CMT.Minuten2InduZeit(rMaZeit.ZEIT));
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>7, p_attr_value=>TO_CHAR(rMaZeit.ARB_BEG,'HH24:MI'));
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>8, p_attr_value=>TO_CHAR(rMaZeit.ARB_END,'HH24:MI'));
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>9, p_attr_value=>CMT.Minuten2InduZeit(rMaZeit.PAUSE,TRUE) );
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>10, p_attr_value=>rMaZeit.ZUSCHLAG);
APEX_COLLECTION.update_member_attribute( p_COLLECTION_name=> TK_COLL_NAME, p_seq=>rCollMaZeit.HID_SEQ_ID
,p_attr_number=>11, p_attr_value=>RTRIM(rMaZeit.BEM));
-- MAZEIT neuer Eintrag
ELSIF rCollMaZeit.HID_MAZEIT_ID=-1 THEN
-- VIEW-ZeitDefaultZeile lesen
SELECT t.* INTO rCollMaZeit0
FROM V_COLL_MAZEIT t
WHERE t.HID_MAZEIT_ID = 0;
vRcString := qV_COLL_MAZEIT_Insert(iKNDABT_ID, iZEIT, NULL, iBEGINN, iENDE, iPAUSE, iZUSCHLAG, iBEM,
rCollMaZeit0, rCollMaZeit, rMaZeit);
ELSE
vRcString := 'Ungültige HID_MAZEIT_ID '||TO_CHAR(rCollMaZeit.HID_MAZEIT_ID);
END IF;
<<MARK_TRANSEND>>
IF vRcString IS NULL THEN
COMMIT;
ELSE
ROLLBACK;
RAISE_APPLICATION_ERROR(-20100,vRcString);
END IF;
END V_COLL_MAZEIT_IOF_U_TRG;
and in end there are 3 other procedures, all for table MAZEIT, the collection and and the report.
in princip its a good idea,to create another collection, but difficult to bind it to the report TOO,cause my "cell-fill- functionality" is to complicated.
my idea is another: to look with javascript/jquery whatever on clientside the cell-values. and only the editable cells. not the hidden cells.there would be ca. 180 editable cells. i want store the values from this cells all in one in a cache (clientside! ).
then select next employee (collection will be created with view ect.) and give me this 29 rows. in this moment i have cells with ID f02_0001 as example and can use the cache values with that. the ID's ever the same,cause i have ever 29 rows.
greets/christian -
Hi,
I am a Systems and Software Engineer based in Vancouver. I developed an automated test system using LabVIEW 2013 and TestStand 2013 with custom operator interface.
I encountered 'missing VIs' problem which is kind of weird because I passed analyzing the sequence for both TestStand Sequence Editor and TestStand Deployment Utility >> Distrubuted Files Tab.
But when I tried building the installer and reaching the point 'Calling distribution VIs, it always throw an error saying 'An error occurred while trying to read the depencies of the VIs, possible because the VIs are not saved in the current version of LabVIEW. Do you want to save any modified now?'. I tried both cases (i.e. Yes and No) for this option but it did not solve the issue.
This is part of the original error message displayed in TestStand Deployment Utility:
While Processing VIs...
Error: Unable to locate all subVIs from saved VIs because a subVI is missing or the VI is not saved in the current version of LabVIEW.
The call chain to missing VIs:
1 - ATE_AccelerometerTest.vi
2 - CreateAndMergeErrors.vi (missing)
3 - LogControl_CheckForErrorSendUpdates.vi (missing) "
All missing VIs are coming from userlib.
Actions Done:
- Analyzed sequence file using TestStand Sequence Editor and TestStand Deployment Utility
- Verified 'Search Directories' include all necessary files/dependencies.
- Mass compile the directory of the missing VIs
- Added all needed files and folders in the workspace file.
The result is still the same based from the actions done.
The last debugging I did earlier is that I tried locating the sequence and steps of missing VIs as mentioned above (e.g. ATE_AccelerometerTest.vi)
and I found out that the step seems to be an empty action step. Would this be possible even if it already passed the analysis?
Other considerations include:
I am using LabVIEW 2013 sp1 and TestStand 2013. We tried building from three (3) computers and we only succeeded once to a freshly-installed comptuer.
Hope to hear from you soon.
With Best Regards,
Michael Panganiban
Systems and Software Engineer
www.synovus.ca
[email protected]
Hi All,
We were able to resolve the issue. First to note is that the release notes in TestStand 2013 is outdated and we confirmed from NI Engineer in Austin that TestStand 2013 works fine with LabVIEW 2013 SP1.
Secondly, we played around TestStand Deployment option that resolved the issue. Attached are the images.
We just enabled the 'Remove Unused VI Components'. It could be one of the libraries (lvlib) we included in the build but we haven't figured it out yet because we verified that all VIs are working. It could be also something else that I think very difficult to find based from the information. However, if anybody experienced the same issue, this could be helpful.
Again, we revert back in using TestStand 2013 and LabVIEW 2013 SP1.
I appreciate any comments and feedbacks. Otherwise, you can close this support request.
Thank you.
With Best Regards,
Michael Panganiban
Systems and Software Engineer
-
Error: Unable to find all subVIs from saved VIs.
TestStand 2010 SP1, LabVIEW 2011, WinXP
Trying to build a deployment in TestStand.
During the build, I get the now-infamous popup:
Title: "Save Modified VIs?"
Text: "An error occured while trying to read the dependencies of your VIs; a possible cause for this problem is VIs not saved in the current version of LabVIEW. Would you like to save any modified VIs now?"
I select "yes", and the build then fails with errors in the log pane of the "Build Status" window. The error is:
Error: Unable to find all subVIs from saved VIs, either a subVI is missing or the VI is not saved under the current LabVIEW version.
The missing file path is: etc, etc.
I go to said missing path. The VI is in fact present. I open the VI and do "Save All", try again. Same thing. Then, I try a Mass Compile on the test VI directory. Attempt to build again, same error.
Note that I do call some VIs dynamically, but those are all present in my workspace, and are not found in this error.
Is there a debugging option or log file or some kind of trace I can do to dig into this and find out the state of things causing the error? Please help me out here.
-AndyOne quick way to narrow down the issue is to change your LabVIEW adapter to Run-Time engine and then try and run the sequence in the Sequence Editor.
Also, triple check your search directories and make sure you're not pulling in VIs from an unexpected location.
When you see that dialog it's already too late to save so trying to Save at that point never works.
Another tip is to ignore which VIs it says are not saved in the current version and instead look at the subVIs that those VIs are calling. You can run into this if you have two subVIs loaded with the same name.
CTA, CLA, MTFBWY -
I cant back up my all data from database
how can i take backup my all data from database with large object library (blob)
when i want back up i writing this statement on "cmd"
exp dbas/dbas@ddds file=D:\dms\ddfm.dmp
so it's only just backup data without large object library, any table contain large object library it can't take it
so i would like take backup all data from databaseOracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
PL/SQL Release 10.2.0.3.0 - Production
CORE 10.2.0.3.0 Production
TNS for 32-bit Windows: Version 10.2.0.3.0 - Production
NLSRTL Version 10.2.0.3.0 - Production
and i am used win7 32bit
when i want back up i writing this statement on "cmd"
exp dbas/dbas@ddds file=D:\dms\ddfm.dmp
so it's only just backup data without large object library, any table contain large object library it can't take it
so i would like take backup all data from database
Edited by: 940639 on Jun 27, 2012 12:35 AM -
How can i get the all values from the Property file to Hashtable?
how can i get the all values from the Property file to Hashtable?
ok,consider my property file name is pro.PROPERTIES
and it contain
8326=sun developer
4306=sun java developer
3943=java developer
how can i get the all keys & values from the pro.PROPERTIES to hashtable
plz help guys..............The Properties class is already a subclass of Hashtable. So if you have a Properties object, you already have a Hashtable. So all you need to do is the first part of that:Properties props = new Properties();
InputStream is = new FileInputStream("tivoli.properties");
props.load(is); -
How to get all values from an interval using select statement
Hi,
Is it possible to write a select statement that returns all values from an interval? Interval boundaries are variable.
something like this:
select (for x in 1,1024 loop x end loop) from dual
(this, of course, doesn't work)
The result in this example should be 1024 rows of numbers from 1 to 1024. These numbers are parameters, so it is not possible to create a table with predefined values.
Thanks in advance for your help,
Mia.For your simple case, with a lower boundary of 1, you can use:
SELECT rownum
FROM all_objects
WHERE rownum <= 1024For a set of number between say 50 - 100, you can use something like:
SELECT rownum + (50 - 1)
FROM all_objects
WHERE rownum <= (100 - 50 + 1)Note, that all_objects was used only because it generally has a lot of rows. Any table with at least the number of rows in your range will work.
TTFN
John -
Returning sql statement instead of values from database
hi am reading value from database but my problem is am get sql statement values instead of values in database
my code is
java:337)There is no doubt: you get what you want:
return s_getValue;
bye
TPD
Maybe you are looking for
-
Multiple IOS devices with one apple id and different PCs to synch
I have 2 macs, 1 Apple TV, 2 iPhones, 2 iPads, 3 iPods and 1 windows pc. I would like to: 1) sync each of them with one of the Macs using the same apple Id; 2) connect with FaceTime with each of them separately (at least the iPads and iPhones); 3) sy
-
SAP Add On for Crystal Reports - no window for account setup
Already installed the add on: windows server 2008 64 bit / SAP Business One 8.8 PL 12. Crystal Runtime is installed too. After activating the add on, we tried to do the 'account setup'. But there was a error: ' Item - could not commit action because
-
I have a uk iTunes account, but I want to download music on the US version of iTunes, how can this be done?
-
How to install BMC performance manager?
Please help give some tips, links and share experience. Thanks a lot!
-
For some reason my computer has been running super slow. When watching video like youtube and ustream. My video and audio will randomly start freezing which is super annoying, kind of like a skipping cd or dvd. I have reset safari and cache and its s