ISEMPTY Syntax in DAX
My DAX query was taking a long time to run when I added NOT ISBLANK() condition in CALCULATE statement. After researching for workaround, I found an article that suggested replacing ISBLANK() with ISEMPTY() function in the new SP of SQL Server. I did that
but when I run my below DAX query now, I am getting error message "The ISEMPTY function expects a table expression for argument '1', but a string or numeric expression was used."
What am I doing wrong? What is the correct ISEMPTY() syntax?
evaluate
filter
addcolumns
summarize
'ET'
'P'[Name]
"Column1", calculate (distinctcount('ET'[C_ID]), 'ET'[S_FLAG] = 1, NOT ISEMPTY ('ET'[C_ID]))
'A'[ID]=289
The ISEMPTY function requires a table function such as VALUES, DISTINCT or other... but is not the solution to your issue. You should do two things.
1) Create a calculated column with a flag TRUE/FALSE so that the filter will be a simple one in calculate
'ET'[VALID_ID] = NOT ISBLANK ( 'ET'[C_ID] )
2) Use CALCULATETABLE instead of FILTER:
EVALUATE
CALCULATETABLE (
ADDCOLUMNS (
SUMMARIZE ( 'ET', 'P'[Name] ),
"Column1", CALCULATE (
DISTINCTCOUNT ( 'ET'[C_ID] ),
'ET'[S_FLAG] = 1,
'ET'[VALID_ID] = TRUE
'A'[ID] = 289
Also consider this, if the result is the same (I don't know if moving the filters outside of SUMMARIZE can result in a lower number of rows removing blanks, and you don't want that):
EVALUATE
CALCULATETABLE (
ADDCOLUMNS (
SUMMARIZE ( 'ET', 'P'[Name] ),
"Column1", CALCULATE ( DISTINCTCOUNT ( 'ET'[C_ID] ) )
'A'[ID] = 289,
'ET'[S_FLAG] = 1,
'ET'[VALID_ID] = TRUE
Marco Russo http://www.sqlbi.com http://www.powerpivotworkshop.com http://sqlblog.com/blogs/marco_russo
Similar Messages
-
Syntax error in query expression
I am receiving the following error message:
Microsoft][ODBC Microsoft Access Driver] Syntax error
(missing operator) in query expression 'customerid_cus='.
for the following code:
If IsEmpty(Request.Form("company_cus")) Then
rs_company.Source = "SELECT customerid_cus, company_cus FROM
customers_cus WHERE customerid_cus= "&
Request.QueryString("customerid") &" "
Else
rs_company.Source = "SELECT customerid_cus, company_cus FROM
customers_cus WHERE company_cus = '"&
Request.Form("company_cus") &"' "
End If
What could the problem be?Are you sure that you are passing the querystring customerid
when the form
company_cus is empty.
Paul Whitham
Certified Dreamweaver MX2004 Professional
Adobe Community Expert - Dreamweaver
Valleybiz Internet Design
www.valleybiz.net
"aonefun" <[email protected]> wrote in
message
news:epmf3n$f3u$[email protected]..
>I am receiving the following error message:
>
> Microsoft][ODBC Microsoft Access Driver] Syntax error
(missing operator)
> in
> query expression 'customerid_cus='.
>
> for the following code:
>
> If IsEmpty(Request.Form("company_cus")) Then
>
> rs_company.Source = "SELECT customerid_cus, company_cus
FROM
> customers_cus
> WHERE customerid_cus= "&
Request.QueryString("customerid") &" "
>
> Else
>
> rs_company.Source = "SELECT customerid_cus, company_cus
FROM
> customers_cus
> WHERE company_cus = '"& Request.Form("company_cus")
>
> End If
>
> What could the problem be?
> -
TNG_recordset Syntax error in query. Incomplete query clause.
I'm using the ADDT insert record form wizard and I keep getting this error: Syntax error in query. Incomplete query clause. Can anyone help?
<br />
<br /><%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<br />
<!--#include file="../Connections/rentalpaypro.asp" -->
<br />
<!--#include file="../includes/common/KT_common.asp" -->
<br />
<!--#include file="../includes/tNG/tNG.inc.asp" -->
<br /><%<br />'Start log out user<br /> Set logout = new tNG_Logout<br /> logout.setLogoutType "link"<br /> logout.setPageRedirect "../index.html"<br /> logout.Execute<br />'End log out user<br />%>
<br /><%<br />'Make a transaction dispatcher instance<br />Dim tNGs: Set tNGs = new tNG_dispatcher<br />tNGs.Init "../"<br />%>
<br /><%<br />' Start trigger<br />Dim formValidation: Set formValidation = new tNG_FormValidation<br />formValidation.Init<br />formValidation.addField "ContactFirstName", true, "text", "", "", "", ""<br />formValidation.addField "ContactLastName", true, "text", "", "", "", ""<br />formValidation.addField "EmailAddress", true, "text", "email", "", "", ""<br />formValidation.addField "BillingAddress", true, "text", "", "", "", ""<br />formValidation.addField "City", true, "text", "", "", "", ""<br />formValidation.addField "StateOrProvince", true, "text", "", "", "", ""<br />formValidation.addField "ZipCode", true, "numeric", "", "", "", ""<br />formValidation.addField "PhoneNumber", true, "text", "", "", "", ""<br />tNGs.prepareValidation formValidation<br />' End trigger<br />%>
<br /><%<br />'Start Restrict Access to Page<br /> Dim restrict: Set restrict = new tNG_RestrictAccess<br /> restrict.Init MM_rentalpaypro_STRING, "../"<br />'Grand Levels: Any<br /> restrict.Execute<br />'End Restrict Access to Page<br />%>
<br /><%<br />' Make an insert transaction instance <br />Dim ins__Landlord_Contact_Info_: Set ins__Landlord_Contact_Info_ = new tNG_insert<br />ins__Landlord_Contact_Info_.init MM_rentalpaypro_STRING<br />tNGs.addTransaction ins__Landlord_Contact_Info_<br />' Register triggers<br />ins__Landlord_Contact_Info_.registerTrigger Array("STARTER", "Trigger_Default_Starter", 1, "POST", "KT_Insert1")<br />ins__Landlord_Contact_Info_.registerTrigger Array("BEFORE", "Trigger_Default_FormValidation", 10, formValidation)<br />ins__Landlord_Contact_Info_.registerTrigger Array("END", "Trigger_Default_Redirect", 99, "index.asp")<br />' Add columns<br />ins__Landlord_Contact_Info_.setTable ""Landlord_Contact Info""<br />ins__Landlord_Contact_Info_.addColumn "ContactFirstName", "STRING_TYPE", "POST", "ContactFirstName", ""<br />ins__Landlord_Contact_Info_.addColumn "ContactLastName", "STRING_TYPE", "POST", "ContactLastName", ""<br />ins__Landlord_Contact_Info_.addColumn "EmailAddress", "STRING_TYPE", "POST", "EmailAddress", ""<br />ins__Landlord_Contact_Info_.addColumn "BillingAddress", "STRING_TYPE", "POST", "BillingAddress", ""<br />ins__Landlord_Contact_Info_.addColumn "City", "STRING_TYPE", "POST", "City", ""<br />ins__Landlord_Contact_Info_.addColumn "CompanyName", "STRING_TYPE", "POST", "CompanyName", ""<br />ins__Landlord_Contact_Info_.addColumn "StateOrProvince", "STRING_TYPE", "POST", "StateOrProvince", ""<br />ins__Landlord_Contact_Info_.addColumn "ZipCode", "NUMERIC_TYPE", "POST", "ZipCode", ""<br />ins__Landlord_Contact_Info_.addColumn "Extension", "STRING_TYPE", "POST", "Extension", ""<br />ins__Landlord_Contact_Info_.addColumn "FaxNumber", "STRING_TYPE", "POST", "FaxNumber", ""<br />ins__Landlord_Contact_Info_.addColumn "PhoneNumber", "STRING_TYPE", "POST", "PhoneNumber", ""<br />ins__Landlord_Contact_Info_.setPrimaryKey "ContactInfoID", "NUMERIC_TYPE", "", ""<br />%>
<br /><%<br />'Execute all the registered transactions<br />tNGs.executeTransactions<br />%>
<br /><%<br />'Get the transaction recordset<br />Dim rs_Landlord_Contact_Info_<br />Dim rs_Landlord_Contact_Info__numRows<br /><br />Set rs_Landlord_Contact_Info_ = tNGs.getRecordset(""Landlord_Contact Info"")<br />rs_Landlord_Contact_Info__numRows = 0<br />%>Are you sure that you are passing the querystring customerid
when the form
company_cus is empty.
Paul Whitham
Certified Dreamweaver MX2004 Professional
Adobe Community Expert - Dreamweaver
Valleybiz Internet Design
www.valleybiz.net
"aonefun" <[email protected]> wrote in
message
news:epmf3n$f3u$[email protected]..
>I am receiving the following error message:
>
> Microsoft][ODBC Microsoft Access Driver] Syntax error
(missing operator)
> in
> query expression 'customerid_cus='.
>
> for the following code:
>
> If IsEmpty(Request.Form("company_cus")) Then
>
> rs_company.Source = "SELECT customerid_cus, company_cus
FROM
> customers_cus
> WHERE customerid_cus= "&
Request.QueryString("customerid") &" "
>
> Else
>
> rs_company.Source = "SELECT customerid_cus, company_cus
FROM
> customers_cus
> WHERE company_cus = '"& Request.Form("company_cus")
>
> End If
>
> What could the problem be?
> -
SSAS- DAX expression : Is there any DAX function that can return multiple values ?
Hi,
Iam in search of a DAX function that can return multiple values as result. please find below scenario where i want to implement the same.
I have three Tables: Table A (typeid, Cost, Qty ) ,Table B (typeid, Cost, Qty ) , Table C ( typeid,Typename ) .
Table A Table B
Table C
type id cost Qty type id Cost Qty
typeid typename
1 100 100 3 300
300 1 aa
2 200 200 4 400
400 2 bb
3 cc
4
dd
i have to club cost and Qty of two tables(four measures) as two measures in the UI report. There are more columns in these tables that restrict the UNION of the tables.(for the sake
of understanding , i have not mentioned the othr columns). In the UI report(Execl 2013-power pivot) iam plotting these measures against the
Table C.Typeid. Hence the measures drill down against each
Table C. Typeid as shown below:
Typeid Table A.cost Table A.Qty TableB.cost TableB.Qty
1 100 100
2 200 200
3
300 300
4
400 400
My requirement is to club these measures so that the report will be as below
Type id cost Qty
1 100 100
2 200 200
3 300 300
4 400 400
Since i cannot club these in model,as a work around, i created a calculated measure in excel(Analyze tab->Calculations->olap tools->calculated measure) with the condition as below:
new cost = IIF (ISEMPTY(TableA.cost)="TRUE",TableB.cost,TableA.cost)
new Qty = IIF(ISEMPTY(TableA.Qty)="TRUE",TableB.Qty,TableA.Qty) and dragged these new measures into the report. It was working fine as expected.
But this functionality of Creating calculatedmeasure in excel report is possible only in 2013 excel version.
Now the requirement is to get the same result in 2010 excel. Can you please help me in implementing the same in 2010 excel? or any other alternative method to bring the columns in model itself. I tried to create a measure in table A with DAX expression as
: new cost :=CALCULATE(SUM(Table B.cost),ISBLANK(TableA.cost)) -> but this will return only 1 result .i need Sum(Table A.cost) also if it is not blank.
Thanks in advanceYou can use SUMX ( 'Table A', 'Table A'[Cost] + 'Table B'[cost] )
However, if you install the latest version of Power Pivot in Excel 2010, it supports the ISEMPTY function, too.
http://support.microsoft.com/kb/2954099/en-us
Marco Russo http://www.sqlbi.com http://www.powerpivotworkshop.com http://sqlblog.com/blogs/marco_russo -
SSRS with DAX - parameters multivalue vs total element
Hi all,
I'm using SSRS on top of a SSAS tabular model to create intuitive dashboards for management department.
One thing I'm struggling with is the lack of a "total" on parameters. What I'm doing is, based on the fact table, I create the datasets that will feed each parameter, so it only has the dimension members available on the fact table. That is fine
performance wise, you only have 1 element and it renders very quickly.
For a management perspective at a higher level it is important to view the totals to have the big picture of the information. In my project we are in a University, so I have the parameters Year, school (there are several schools in the university campus)
and the course (computer sciences, math, statistics, etc).
At first glance, if I'm a course coordinador I want to pick my course and have a global view, and I'm achiveing that, but imagine now, that I am the school coordinator, or the university coordenator.
I want to see the aggregate values by all courses or by all schools.
In my view I have 2 ways to do this and I come from a tradition cubes background:
1 - I would use the all element the cubes hierarchy have on each attribute
2 - I would use multivalue parameters with StrToSet (worse performance)
Using DAX what is your approach?
Best regardsHi AsifMehmood,
Per my understanding you have create an SSRS report with SharePoint list, now you don’t know to create the distinct parameters by using CAML query, right?
For the CAML language doesn’t have any reserved word (or tag) to set this particular filter to remove duplicate results, but we can use the custom code to do this function. I have tested on my local environment and we can do that by create one hidden parameter(Param1)
to get all the values from the fields which will add the filter and then create another parameter(Param2) to get the distinct values based on the Param1, we use the custom code to do the deduplication.
Step by Steps information in below thread for your reference to create the parameters and the custom code:
"How to get distinct values of sharepoint column using SSRS"
Other similar thread for your reference:
https://audministrator.wordpress.com/2014/02/17/sharepoint-list-add-distinct-parameter-value/
If your problem still exists, please feel free to ask and also try to provide us more details information.
Regards
Vicky Liu -
Syntax error while creating a invoice
Hi I am new to this forum hope u guys can help me out,
I am ruuning following syntax for creating an invoice and for this error message is coming which is given below.
Select aadrnr astdc1 b~name1 into table inv_head1
From kna1 as a inner join adrc as b on aadrnr = baddrnumber.
Unknown column name "A~STDC1" . field list. . field list. field list.Hi Rupesh,
u have to mention as " select ... into corresponding fields of
table ... ".
regards
Chaitanya. -
Syntax error while writing a select query.
Hi all,
I have a requirement where I have to pick a value if the text for that value is
MYCARu2019S Lovliest Car.
And so I wrote a query that
SELECT RUECK INTO XRUECK FROM AFVC WHERE ltxa1 = ' MYCARu2019S Lovliest Car'.
ENDSELECT.
But it gives me a syntax error saying
u201CLiterals taking up more than one line not permittedu201D.
Can some one tell me what is wrong. I need to select RUECK value from AFVC table if
ltxa1 value is ' MYCARu2019S Lovliest Car'.
Kindly help what is going wrong...
Regards,
Jessica SamHi,
Narendran is right use two single quotes.
also careful wile comparing string. i think as you write ltxa1 value is ' MYCARu2019S Lovliest Car'.
so while comparing you must not use space just before staring use the following
SELECT rueck INTO xrueck FROM afvc WHERE ltxa1 = 'MYCAR''S Lovliest Car'. " Not use Space before M
ENDSELECT.
Hope will help you.
Kind Regards,
Faisal -
Syntax error while running a driver program
Hi experts,
I have developed a smartforms,in which i have declared the following,
ITAB TYPE TABLE OF MARA, in import tab of form interface...
and in se38 i have declared...
data: itab like mara occurs 0.
bujt when i am running this program, i am getting syntax error "ITAB" is neither specified under "TABLES" nor defined as internal tabels..
plz tell me why this probleming is occuring?and how can i solve this....
thnks n regards,
Ashmita.in form interface try to declare in tables tab
or
global data > types tab and declare global table using that type. -
Select-options in SELECT query - syntax error
Hi all,
I get the error below when I try to use the select options in a SELECT query . Please help me.
"The IN operator with "SO_AWART" is followed neither by an internal
table nor by a value list."
The code i have used(Logical database PNP is used):
TABLES: pernr,
catsdb.
INCLUDE ztime_cwtr_top. " global Data
INCLUDE ztime_cwtr_f01.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME.
SELECT-OPTIONS SO_AWART FOR CATSDB-AWART.
PARAMETERS P_THRES TYPE I.
SELECTION-SCREEN END OF BLOCK B1.
Get data from CATSDB table. Workdates within the date interval are considered.
SELECT pernr workdate awart catsquantity beguz enduz status
FROM catsdb
INTO TABLE it_catsdb
WHERE pernr = pernr-pernr AND
workdate GE pn-begda AND
workdate LE pn-endda AND
status IN ('20', '30') AND
awart IN so_awart .
awart IN ('1100', '1137', '1138', '1139', '1140',
'1147', '1148', '1149', '1157', '2003' ).
when I give the values directly i do not get any syntax error, but when I use select options in the where condition I get the syntax error.
I have tried different options like using only the select-options in the where condition.
Thanks in advance.....
MadhuSolved.
Code with syntax error:
include z...top .
include z...fo1.
select-options: xxxxxxx
Code with no syntax error:
select-options: xxxxxxx
include z...top .
include z...fo1.
Thanks for all your help,
Madhu -
Date syntax for MySql query in SQL Reporting Services
I am currently trying to link a mysql Stored Procedure to a Microsoft SQL Reporting Server. It is coming up with a Syntax error. I believe this is down to the
Date_from and Date_to Parameters. The query is below any help would be appreciated
DELIMITER $$
USE `mydb`$$
DROP PROCEDURE IF EXISTS `DTI`$$
CREATE DEFINER=`linkeduser`@`%` PROCEDURE `DTI`(IN date_from DATETIME,
IN date_to DATETIME)
BEGIN
SELECT title,gender,firstname,lastname,address1,town,postcode,dob,IF(co.start_date = '00-00-0000', '', CAST(DATE(co.start_date) AS DATE)) AS 'StartDate'
FROM cf_user AS us
JOIN ca_compliance AS co ON co.user_id = us.user_id
WHERE co.start_date BETWEEN date_from AND date_to;
END$$
DELIMITER ;Hello,
The dataset query runs on the external data source.
In your case, you create a report by retrieve data from MySQL database with a stored procedure. The stored procedure will run on MySQL Server and return the result in the Report designer or Report Builder. To solved this issue, please execute the stored
procedure on the MySQL database and check the syntax error.
Regards,
Fanny Liu
Fanny Liu
TechNet Community Support -
Can not use SUM in a simple query because of a syntax error?
Hi
Thank you for reading my post.
I am trying to execute the following query:
q = em.createQuery("SELECT SUM((NE.pipeLength - 0.6)+((NE.networkDepth-NE.initialDepth)*0.41)+ NE.standLenght) FROM NExpansion NE where (( NE.contract.contractor=:contractor) AND (NE.pDiameter=:diameter))");
q.setParameter("contractor", contractor);
q.setParameter("diameter", diameter);
l = (Long) q.getSingleResult();And I get the following error:
Caused by: Exception [TOPLINK-8025] (Oracle TopLink Essentials - 2.0.1 (Build b09d-fcs (12/06/2007))): oracle.toplink.essentials.exceptions.EJBQLException
Exception Description: Syntax error parsing the query [SELECT SUM((NE.pipeLength - 0.6)+((NE.networkDepth-NE.initialDepth)*0.41)+ NE.standLenght) FROM NExpansion NE where (( NE.contract.contractor=:contractor) AND (NE.pDiameter=:diameter))], line 1, column 12: unexpected token [(].
Internal Exception: line 1:12: unexpected token: (
at oracle.toplink.essentials.exceptions.EJBQLException.unexpectedToken(EJBQLException.java:389)
at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.handleANTLRException(EJBQLParser.java:350)
at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.addError(EJBQLParser.java:278)
at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.reportError(EJBQLParser.java:378)
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.aggregateExpression(EJBQLParser.java:1416)
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.selectExpression(EJBQLParser.java:1158)
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.selectClause(EJBQLParser.java:403)
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.selectStatement(EJBQLParser.java:178)
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.document(EJBQLParser.java:135)
at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.parse(EJBQLParser.java:166)
at oracle.toplink.essentials.internal.parsing.ejbql.EJBQLParser.buildParseTree(EJBQLParser.java:127)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:215)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:189)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.buildEJBQLDatabaseQuery(EJBQueryImpl.java:153)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.<init>(EJBQueryImpl.java:114)
at oracle.toplink.essentials.internal.ejb.cmp3.base.EJBQueryImpl.<init>(EJBQueryImpl.java:99)
at oracle.toplink.essentials.internal.ejb.cmp3.EJBQueryImpl.<init>(EJBQueryImpl.java:86)
at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerImpl.createQuery(EntityManagerImpl.java:204)
... 30 more
Caused by: line 1:12: unexpected token: (
at oracle.toplink.essentials.internal.parsing.ejbql.antlr273.EJBQLParser.aggregateExpression(EJBQLParser.java:1365)
... 43 morePlease let me know what am I doing wrong?
Thanks.Hello,
From the grammar in the JPA spec, SUM only takes a state_field_path_expression which is defined as
state_field_path_expression := {identification_variable | single_valued_association_path_expression}.state_field
Please feel free to file an enhancement to have this expanded upon.
Best Regards,
Chris -
Syntax for inserting a number in a shell script in applescript
who can help me correct this code?
the user will enter a number in a dialog box, and this variable will replace the 7 in the shell script.
i cant seem to keep the syntax right, i keep erroring out.
if days_back is "" then
set dialog_1 to display dialog "please enter a number " default answer ""
set the days_back to the text returned of dialog_1
end if
set the_result to (do shell script "mdfind -onlyin '/Volumes/Volume1' 'kMDItemFSContentChangeDate >=$time.today(-7)'")
display dialog the_resultTry using:
if days_back is "" then
set dialog_1 to display dialog "please enter a number " default answer ""
set the days_back to the text returned of dialog_1
end if
do shell script ("mdfind -onlyin '/Volumes/Volume1' 'kMDItemFSContentChangeDate >=$time.today(-" & days_back & ")'")
display dialog the result
(54186) -
SYNTAX_ERROR unable to log in to SAP system Syntax error in program "SAPMSE
hi SAP Experts,
I have applied Basis patch 12 and I scheduled the background. Backgroud job was terminated. System became slow. Then I stopped the server and restarted. Now, I am unable to log in to SAP GUI by entering Username and Password and getting syntax error.
Syntax error in program "SAPMSEM1".
What happened?
Error in the ABAP Application Program
The current ABAP program '????????????????????????????"
terminated because it has
come across a statement that unfortunately cannot be executed.
The following syntax error occured in program "SAPMSEM1" in include
"CL_SALV_FORM_ELEMET==========CU" in
line 13:
"the type "IF_SALV_FORM_CONFIG" is unknown."
The include has been created and last changed by:
Created by: "SAP "
Last Changed by: "SAP "
I am unable to access any transction code.
Please help me..
Thanks in advance...
Rajuhi,
Thanks for your response.
i haven't take any back up. can u pls tell me step by step procedure to implement the SP with TP.
your answer will be helpful..
Regards
Raju -
Error Message: "The formula syntax is not supported by the report"
We are using 'Development Environment: SAP Crystal Reports, version for Visual Studio 2010 u2013 Standard ' and using CrystalDecisions.CrystalReports.Engine and CrystalDecisions.ReportAppServer APIu2019s
I am reading SQLExpressionFields from one source .rpt file & want to add it to another ReportDocument. While doing so, it gives an error " The formula syntax is not supported by the report"
doc.ReportClientDocumentDataDefController.FormulaFieldController.Add(formualField); // formualField is SQLExpressionField from source ReportDocument
But when I tried to Add FormulaField, it succeeds
Please help me in knowing how to add SQlExpressionFields to ReportDocument.
Regards,
-atulThanx Don & Ludek for the reply.
CR provides support for addition/modification of SQLExpressions.
CRAXDRT.Application application = new CRAXDRT.ApplicationClass();
CRAXDRT.Report innerReport = application.OpenReport(path, CROpenReportMethod.crOpenReportByTempCopy);
innerReport .SQLExpressionFields.Add(name, strSQLExpression)
CRAXDRT.dll provides support for addition/modification of SQLExpression fields. But its not compatible with 64bit.
Just curious to know, is there any future plan to provide support for add/modify SQLExpression fields?
Thanx
-atul
Edited by: Atul Chivate on Aug 21, 2011 6:13 PM -
DB2 9.7 DFACT.SQL syntax error in Import ABAP phase - System Copy
Hi all. I'm trying a system copy with a source system SAP ECC 6.0 ehp4 based on NW 701 and db2 LUW 9.1 .
As it seems supported by SAP, i'm using db2 LUW 9.7 in target system.
O.S. is Windows 2008.
I got an error in phase "Import ABAP".
Sapinst.log says:
INFO 2010-02-18 10:12:14.337
An error occured and the user decided to retry the current step: "|NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_ABAP_Import_Dialog|ind|ind|ind|ind|5|0|NW_ABAP_Import|ind|ind|ind|ind|0|0|runMigrationMonitor".
INFO 2010-02-18 10:12:14.509
Switched to user: devadm.
INFO 2010-02-18 10:12:14.572
Creating file C:\Program Files\sapinst_instdir\ERPEhP4\LM\COPY\DB6\SYSTEM\CENTRAL\AS-ABAP\import_monitor.java.log.
INFO 2010-02-18 10:12:14.603
Switched to user: devadm.
INFO 2010-02-18 10:12:14.618
Working directory changed to C:\Program Files\sapinst_instdir\ERPEhP4\LM\COPY\DB6\SYSTEM\CENTRAL\AS-ABAP.
INFO 2010-02-18 10:12:14.618
Output of C:\j2sdk1.4.2_24-x64\bin\java.exe -classpath migmon.jar -showversion -Xmx1024m com.sap.inst.migmon.imp.ImportMonitor -sapinst is written to the logfile import_monitor.java.log.
WARNING 2010-02-18 10:12:44.790
Execution of the command "C:\j2sdk1.4.2_24-x64\bin\java.exe -classpath migmon.jar -showversion -Xmx1024m com.sap.inst.migmon.imp.ImportMonitor -sapinst" finished with return code 103. Output:
java version "1.4.2_24-rev"
Java(TM) Platform, Standard Edition for Business (build 1.4.2_24-rev-b06)
Java HotSpot(TM) 64-Bit Server VM (build 1.4.2_24-rev-b06, mixed mode)
Import Monitor jobs: running 1, waiting 1, completed 73, failed 0, total 75.
Loading of 'SAPDFACT' import package: ERROR
Import Monitor jobs: running 0, waiting 1, completed 73, failed 1, total 75.
WARNING[E] 2010-02-18 10:12:44.790
CJS-30022 Program 'Migration Monitor' exits with error code 103. For details see log file(s) import_monitor.java.log, import_monitor.log.
ERROR 2010-02-18 10:12:44.790
FCO-00011 The step runMigrationMonitor with step key |NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_ABAP_Import_Dialog|ind|ind|ind|ind|5|0|NW_ABAP_Import|ind|ind|ind|ind|0|0|runMigrationMonitor was executed with status ERROR .
Looking into import_monitor.java.log i found that the problem is in dfact import.
I've looked into sapdfact.log and i found:
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe: START OF LOG: 20100218105045
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe: sccsid @(#) $Id: //bas/701_REL/src/R3ld/R3load/R3ldmain.c#8 $ SAP
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe: version R7.01/V1.4 [UNICODE]
Compiled Jan 28 2010 20:22:25
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe -i SAPDFACT.cmd -dbcodepage 4103 -l SAPDFACT.log -stop_on_error -loadprocedure fast LOAD:COMPRESS_ALL
(DB) INFO: connected to DB
(DB6) INFO: COMPRESS YES is set during table creation.
(DB6) DB2 9.5 automatic dictionary creation does not require an explicit REORG.
(DB6) Compression threshold is ignored.
(GSI) INFO: dbname = "DEV "
(GSI) INFO: vname = "DB6 "
(GSI) INFO: hostname = "UNKNOWN "
(GSI) INFO: sysname = "Windows NT"
(GSI) INFO: nodename = "SRVSAPDEV"
(GSI) INFO: release = "6.0"
(GSI) INFO: version = "6002 Service Pack 2"
(GSI) INFO: machine = "4x AMD64 Level 6 (Mod 26 Step 5)"
(DB) ERROR: DDL statement failed with SQL error
( ALTER TABLE "/BI0/E0PPM_VC1" DROP PRIMARY KEY )
(SQL error -539)
error message returned by dsql:
SQL0539N Table or nickname "SAPDEV./BI0/E0PPM_VC1" does not have a "PRIMARY" key. SQLSTATE=42888
(IMP) INFO: a failed DROP attempt is not necessarily a problem
(DB6) INFO: executing DDL statements for object /BI0/E0PPM_VC1 from external SQL file.
(DB) ERROR: DDL statement failed with SQL error
( CREATE TYPE 2 UNIQUE INDEX "/BI0/E0PPM_VC1~0" ON "/BI0/E0PPM_VC1" ("KEY_0PPM_VC1T" , "KEY_0PPM_VC11" , "KEY_0PPM_VC1U" , "KEY_0PPM_VC1P" ) USING STOGROUP ___FAI PRIQTY 16 SECQTY 10240 FREEPAGE 0 PCTFREE 0 GBPCACHE CHANGED DEFINE NO BUFFERPOOL BP3 COPY NO PIECESIZE 2097152 K CLUSTER NOT PADDED )
(SQL error -7)
error message returned by dsql:
SQL0007N The character "_" following "" ) USING STOGROUP" is not valid. SQLSTATE=42601
(DB) INFO: disconnected from DB
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe: job finished with 1 error(s)
S:\usr\sap\DEV\SYS\exe\uc\NTAMD64\R3load.exe: END OF LOG: 20100218105045
So as you can see it seems that there's some syntax error in dfacl.log. The wrong SQL statement referred by sapdfact.log is
ind: /BI0/E0PPM_VC1~0
sql: CREATE TYPE 2 UNIQUE INDEX "/BI0/E0PPM_VC1~0" ON "/BI0/E0PPM_VC1"
("KEY_0PPM_VC1T" ,
"KEY_0PPM_VC11" ,
"KEY_0PPM_VC1U" ,
"KEY_0PPM_VC1P" )
USING STOGROUP ___FAI PRIQTY 16
SECQTY 10240 FREEPAGE 0 PCTFREE 0
GBPCACHE CHANGED DEFINE NO
BUFFERPOOL BP3 COPY NO
PIECESIZE 2097152 K CLUSTER NOT PADDED ;
|
ALTER TABLE "/BI0/E0PPM_VC1"
ADD PRIMARY KEY ("KEY_0PPM_VC1T",
"KEY_0PPM_VC11",
"KEY_0PPM_VC1U",
"KEY_0PPM_VC1P") ;
Am i missing something?
Data in referred tables (infocubes) isn't really important.
Is there a safe way to proceed?
Thanks in advance.
Regards
Simone ZaffalonAnd this is the strange point: my source system is not a BI and my dataclasses .SQL files are not empty.
Me too i would expect that the files should be empty but instead they are full of object definitions.
For example i have APPL0.SQL that contains a list of all tables of ECC system, for example
tab: MAMT
sql: CREATE TABLE "MAMT"
("MANDT" SAPDB6VARCHAR(000003)
DEFAULT '000' NOT NULL,
"MATNR" SAPDB6VARCHAR(000018)
DEFAULT ' ' NOT NULL,
"SPRAS" SAPDB6VARCHAR(000001)
DEFAULT ' ' NOT NULL,
"MEINH" SAPDB6VARCHAR(000003)
DEFAULT ' ' NOT NULL,
"MTXID" SAPDB6VARCHAR(000002)
DEFAULT ' ' NOT NULL,
"LFDNR" SAPDB6VARCHAR(000002)
DEFAULT '00' NOT NULL,
"MAKTM" SAPDB6VARCHAR(000040)
DEFAULT ' ' NOT NULL)
IN "&location&"
INDEX IN "&locationI&"
LONG IN "&locationL&"
COMPRESS YES;
ALTER TABLE "MAMT" LOCKSIZE ROW;
and like this for all others tables.
What would occur if i launch an import with such .SQL files?
(shuld i put this question to another thread or is fine for you to answer on this?)
Thank you again.
Simone Zaffalon
Maybe you are looking for
-
Trouble setting up iTunes account with Paypal
I've been having a really hard time setting an iTunes account. I don't want to use credit cards at all and according to the iTunes customer support, I don't need a credit card: "A credit card is not required. However, if you do not wish to add a cred
-
Indeign cs 5.5 Installation problems
I have two packages Adobe CS 5.5 Production Premium Adobe CS 5.5 Design Standard I need to install all Production Premium 5.5 package and (InDesign) from design standard 5.5 package. The Adobe CS 5.5 Production Premium is installed successfully, but
-
CK11N - New Overhead dependence
Hi everybody, I'm creating a new overhead procedure: 1 - I created a new table by transaction KK05 to add the field "material group" on a dependence to be used on Overhead calculate. 2 - I created the new depedence by transaction KGF4 and generate it
-
BRIDGE NOT RECOGNIZED???
HI, WHY IS BRIDGE NOT RECOGNIZED??? AFTER INSTALLATION OF CS6 3 WEEKS AGO, BRIDGE WAS WORKING FINE
-
Never received a mail to verify my apple id
What should i do?